function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }

function _toArray(arr) { return _arrayWithHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableRest(); }

function _construct(Parent, args, Class) { if (_isNativeReflectConstruct()) { _construct = Reflect.construct; } else { _construct = function _construct(Parent, args, Class) { var a = [null]; a.push.apply(a, args); var Constructor = Function.bind.apply(Parent, a); var instance = new Constructor(); if (Class) _setPrototypeOf(instance, Class.prototype); return instance; }; } return _construct.apply(null, arguments); }

function _get(target, property, receiver) { if (typeof Reflect !== "undefined" && Reflect.get) { _get = Reflect.get; } else { _get = function _get(target, property, receiver) { var base = _superPropBase(target, property); if (!base) return; var desc = Object.getOwnPropertyDescriptor(base, property); if (desc.get) { return desc.get.call(receiver); } return desc.value; }; } return _get(target, property, receiver || target); }

function _superPropBase(object, property) { while (!Object.prototype.hasOwnProperty.call(object, property)) { object = _getPrototypeOf(object); if (object === null) break; } return object; }

function _createForOfIteratorHelper(o) { if (typeof Symbol === "undefined" || o[Symbol.iterator] == null) { if (Array.isArray(o) || (o = _unsupportedIterableToArray(o))) { var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e2) { throw _e2; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var it, normalCompletion = true, didErr = false, err; return { s: function s() { it = o[Symbol.iterator](); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e3) { didErr = true; err = _e3; }, f: function f() { try { if (!normalCompletion && it["return"] != null) it["return"](); } finally { if (didErr) throw err; } } }; }

function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }

function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }

function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function () { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }

function _possibleConstructorReturn(self, call) { if (call && (typeof call === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); }

function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }

function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } }

function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }

function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }

function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }

function _iterableToArrayLimit(arr, i) { if (typeof Symbol === "undefined" || !(Symbol.iterator in Object(arr))) return; var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }

function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }

function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }

function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }

function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }

function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && Symbol.iterator in Object(iter)) return Array.from(iter); }

function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }

function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }

function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }

function _createClass2(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }

function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }

(window["webpackJsonp"] = window["webpackJsonp"] || []).push([["vendor"], {
  /***/
  "./node_modules/@angular/animations/__ivy_ngcc__/fesm2015/animations.js":
  /*!******************************************************************************!*\
    !*** ./node_modules/@angular/animations/__ivy_ngcc__/fesm2015/animations.js ***!
    \******************************************************************************/

  /*! exports provided: AUTO_STYLE, AnimationBuilder, AnimationFactory, NoopAnimationPlayer, animate, animateChild, animation, group, keyframes, query, sequence, stagger, state, style, transition, trigger, useAnimation, ɵAnimationGroupPlayer, ɵPRE_STYLE */

  /***/
  function node_modulesAngularAnimations__ivy_ngcc__Fesm2015AnimationsJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AUTO_STYLE", function () {
      return AUTO_STYLE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AnimationBuilder", function () {
      return AnimationBuilder;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AnimationFactory", function () {
      return AnimationFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NoopAnimationPlayer", function () {
      return NoopAnimationPlayer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "animate", function () {
      return animate;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "animateChild", function () {
      return animateChild;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "animation", function () {
      return animation;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "group", function () {
      return group;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "keyframes", function () {
      return keyframes;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "query", function () {
      return query;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "sequence", function () {
      return sequence;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "stagger", function () {
      return stagger;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "state", function () {
      return state;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "style", function () {
      return style;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "transition", function () {
      return transition;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "trigger", function () {
      return trigger;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "useAnimation", function () {
      return useAnimation;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵAnimationGroupPlayer", function () {
      return AnimationGroupPlayer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵPRE_STYLE", function () {
      return ɵPRE_STYLE;
    });
    /**
     * @license Angular v9.1.4
     * (c) 2010-2020 Google LLC. https://angular.io/
     * License: MIT
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/src/animation_builder.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * An injectable service that produces an animation sequence programmatically within an
     * Angular component or directive.
     * Provided by the `BrowserAnimationsModule` or `NoopAnimationsModule`.
     *
     * \@usageNotes
     *
     * To use this service, add it to your component or directive as a dependency.
     * The service is instantiated along with your component.
     *
     * Apps do not typically need to create their own animation players, but if you
     * do need to, follow these steps:
     *
     * 1. Use the `build()` method to create a programmatic animation using the
     * `animate()` function. The method returns an `AnimationFactory` instance.
     *
     * 2. Use the factory object to create an `AnimationPlayer` and attach it to a DOM element.
     *
     * 3. Use the player object to control the animation programmatically.
     *
     * For example:
     *
     * ```ts
     * // import the service from BrowserAnimationsModule
     * import {AnimationBuilder} from '\@angular/animations';
     * // require the service as a dependency
     * class MyCmp {
     *   constructor(private _builder: AnimationBuilder) {}
     *
     *   makeAnimation(element: any) {
     *     // first define a reusable animation
     *     const myAnimation = this._builder.build([
     *       style({ width: 0 }),
     *       animate(1000, style({ width: '100px' }))
     *     ]);
     *
     *     // use the returned factory object to create a player
     *     const player = myAnimation.create(element);
     *
     *     player.play();
     *   }
     * }
     * ```
     *
     * \@publicApi
     * @abstract
     */


    var AnimationBuilder = function AnimationBuilder() {
      _classCallCheck(this, AnimationBuilder);
    };

    if (false) {}
    /**
     * A factory object returned from the `AnimationBuilder`.`build()` method.
     *
     * \@publicApi
     * @abstract
     */


    var AnimationFactory = function AnimationFactory() {
      _classCallCheck(this, AnimationFactory);
    };

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/src/animation_metadata.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Represents a set of CSS styles for use in an animation style.
     * @record
     */


    function ɵStyleData() {}
    /** @enum {number} */


    var AnimationMetadataType = {
      /**
       * Associates a named animation state with a set of CSS styles.
       * See `state()`
       */
      State: 0,

      /**
       * Data for a transition from one animation state to another.
       * See `transition()`
       */
      Transition: 1,

      /**
       * Contains a set of animation steps.
       * See `sequence()`
       */
      Sequence: 2,

      /**
       * Contains a set of animation steps.
       * See `{@link animations/group group()}`
       */
      Group: 3,

      /**
       * Contains an animation step.
       * See `animate()`
       */
      Animate: 4,

      /**
       * Contains a set of animation steps.
       * See `keyframes()`
       */
      Keyframes: 5,

      /**
       * Contains a set of CSS property-value pairs into a named style.
       * See `style()`
       */
      Style: 6,

      /**
       * Associates an animation with an entry trigger that can be attached to an element.
       * See `trigger()`
       */
      Trigger: 7,

      /**
       * Contains a re-usable animation.
       * See `animation()`
       */
      Reference: 8,

      /**
       * Contains data to use in executing child animations returned by a query.
       * See `animateChild()`
       */
      AnimateChild: 9,

      /**
       * Contains animation parameters for a re-usable animation.
       * See `useAnimation()`
       */
      AnimateRef: 10,

      /**
       * Contains child-animation query data.
       * See `query()`
       */
      Query: 11,

      /**
       * Contains data for staggering an animation sequence.
       * See `stagger()`
       */
      Stagger: 12
    };
    /**
     * Specifies automatic styling.
     *
     * \@publicApi
     * @type {?}
     */

    var AUTO_STYLE = '*';
    /**
     * Base for animation data structures.
     *
     * \@publicApi
     * @record
     */

    function AnimationMetadata() {}

    if (false) {}
    /**
     * Contains an animation trigger. Instantiated and returned by the
     * `trigger()` function.
     *
     * \@publicApi
     * @record
     */


    function AnimationTriggerMetadata() {}

    if (false) {}
    /**
     * Encapsulates an animation state by associating a state name with a set of CSS styles.
     * Instantiated and returned by the `state()` function.
     *
     * \@publicApi
     * @record
     */


    function AnimationStateMetadata() {}

    if (false) {}
    /**
     * Encapsulates an animation transition. Instantiated and returned by the
     * `transition()` function.
     *
     * \@publicApi
     * @record
     */


    function AnimationTransitionMetadata() {}

    if (false) {}
    /**
     * Encapsulates a reusable animation, which is a collection of individual animation steps.
     * Instantiated and returned by the `animation()` function, and
     * passed to the `useAnimation()` function.
     *
     * \@publicApi
     * @record
     */


    function AnimationReferenceMetadata() {}

    if (false) {}
    /**
     * Encapsulates an animation query. Instantiated and returned by
     * the `query()` function.
     *
     * \@publicApi
     * @record
     */


    function AnimationQueryMetadata() {}

    if (false) {}
    /**
     * Encapsulates a keyframes sequence. Instantiated and returned by
     * the `keyframes()` function.
     *
     * \@publicApi
     * @record
     */


    function AnimationKeyframesSequenceMetadata() {}

    if (false) {}
    /**
     * Encapsulates an animation style. Instantiated and returned by
     * the `style()` function.
     *
     * \@publicApi
     * @record
     */


    function AnimationStyleMetadata() {}

    if (false) {}
    /**
     * Encapsulates an animation step. Instantiated and returned by
     * the `animate()` function.
     *
     * \@publicApi
     * @record
     */


    function AnimationAnimateMetadata() {}

    if (false) {}
    /**
     * Encapsulates a child animation, that can be run explicitly when the parent is run.
     * Instantiated and returned by the `animateChild` function.
     *
     * \@publicApi
     * @record
     */


    function AnimationAnimateChildMetadata() {}

    if (false) {}
    /**
     * Encapsulates a reusable animation.
     * Instantiated and returned by the `useAnimation()` function.
     *
     * \@publicApi
     * @record
     */


    function AnimationAnimateRefMetadata() {}

    if (false) {}
    /**
     * Encapsulates an animation sequence.
     * Instantiated and returned by the `sequence()` function.
     *
     * \@publicApi
     * @record
     */


    function AnimationSequenceMetadata() {}

    if (false) {}
    /**
     * Encapsulates an animation group.
     * Instantiated and returned by the `{\@link animations/group group()}` function.
     *
     * \@publicApi
     * @record
     */


    function AnimationGroupMetadata() {}

    if (false) {}
    /**
     * Encapsulates parameters for staggering the start times of a set of animation steps.
     * Instantiated and returned by the `stagger()` function.
     *
     * \@publicApi
     *
     * @record
     */


    function AnimationStaggerMetadata() {}

    if (false) {}
    /**
     * Creates a named animation trigger, containing a  list of `state()`
     * and `transition()` entries to be evaluated when the expression
     * bound to the trigger changes.
     *
     * \@usageNotes
     * Define an animation trigger in the `animations` section of `\@Component` metadata.
     * In the template, reference the trigger by name and bind it to a trigger expression that
     * evaluates to a defined animation state, using the following format:
     *
     * `[\@triggerName]="expression"`
     *
     * Animation trigger bindings convert all values to strings, and then match the
     * previous and current values against any linked transitions.
     * Booleans can be specified as `1` or `true` and `0` or `false`.
     *
     * ### Usage Example
     *
     * The following example creates an animation trigger reference based on the provided
     * name value.
     * The provided animation value is expected to be an array consisting of state and
     * transition declarations.
     *
     * ```typescript
     * \@Component({
     *   selector: "my-component",
     *   templateUrl: "my-component-tpl.html",
     *   animations: [
     *     trigger("myAnimationTrigger", [
     *       state(...),
     *       state(...),
     *       transition(...),
     *       transition(...)
     *     ])
     *   ]
     * })
     * class MyComponent {
     *   myStatusExp = "something";
     * }
     * ```
     *
     * The template associated with this component makes use of the defined trigger
     * by binding to an element within its template code.
     *
     * ```html
     * <!-- somewhere inside of my-component-tpl.html -->
     * <div [\@myAnimationTrigger]="myStatusExp">...</div>
     * ```
     *
     * ### Using an inline function
     * The `transition` animation method also supports reading an inline function which can decide
     * if its associated animation should be run.
     *
     * ```typescript
     * // this method is run each time the `myAnimationTrigger` trigger value changes.
     * function myInlineMatcherFn(fromState: string, toState: string, element: any, params: {[key:
     * string]: any}): boolean {
     *   // notice that `element` and `params` are also available here
     *   return toState == 'yes-please-animate';
     * }
     *  /
     *   selector: 'my-component',
     *   templateUrl: 'my-component-tpl.html',
     *   animations: [
     *     trigger('myAnimationTrigger', [
     *       transition(myInlineMatcherFn, [
     *         // the animation sequence code
     *       ]),
     *     ])
     *   ]
     * })
     * class MyComponent {
     *   myStatusExp = "yes-please-animate";
     * }
     * ```
     *
     * ### Disabling Animations
     * When true, the special animation control binding `\@.disabled` binding prevents
     * all animations from rendering.
     * Place the  `\@.disabled` binding on an element to disable
     * animations on the element itself, as well as any inner animation triggers
     * within the element.
     *
     * The following example shows how to use this feature:
     *
     * ```typescript /
     *   selector: 'my-component',
     *   template: `
     *     <div [\@.disabled]="isDisabled">
     *       <div [\@childAnimation]="exp"></div>
     *     </div>
     *   `,
     *   animations: [
     *     trigger("childAnimation", [
     *       // ...
     *     ])
     *   ]
     * })
     * class MyComponent {
     *   isDisabled = true;
     *   exp = '...';
     * }
     * ```
     *
     * When `\@.disabled` is true, it prevents the `\@childAnimation` trigger from animating,
     * along with any inner animations.
     *
     * ### Disable animations application-wide
     * When an area of the template is set to have animations disabled,
     * **all** inner components have their animations disabled as well.
     * This means that you can disable all animations for an app
     * by placing a host binding set on `\@.disabled` on the topmost Angular component.
     *
     * ```typescript
     * import {Component, HostBinding} from '\@angular/core';
     *  /
     *   selector: 'app-component',
     *   templateUrl: 'app.component.html',
     * })
     * class AppComponent {
     * \@HostBinding('@.disabled')
     *   public animationsDisabled = true;
     * }
     * ```
     *
     * ### Overriding disablement of inner animations
     * Despite inner animations being disabled, a parent animation can `query()`
     * for inner elements located in disabled areas of the template and still animate
     * them if needed. This is also the case for when a sub animation is
     * queried by a parent and then later animated using `animateChild()`.
     *
     * ### Detecting when an animation is disabled
     * If a region of the DOM (or the entire application) has its animations disabled, the animation
     * trigger callbacks still fire, but for zero seconds. When the callback fires, it provides
     * an instance of an `AnimationEvent`. If animations are disabled,
     * the `.disabled` flag on the event is true.
     *
     * \@publicApi
     * @param {?} name An identifying string.
     * @param {?} definitions  An animation definition object, containing an array of `state()`
     * and `transition()` declarations.
     *
     * @return {?} An object that encapsulates the trigger data.
     *
     */


    function trigger(name, definitions) {
      return {
        type: 7
        /* Trigger */
        ,
        name: name,
        definitions: definitions,
        options: {}
      };
    }
    /**
     * Defines an animation step that combines styling information with timing information.
     *
     * \@usageNotes
     * Call within an animation `sequence()`, `{\@link animations/group group()}`, or
     * `transition()` call to specify an animation step
     * that applies given style data to the parent animation for a given amount of time.
     *
     * ### Syntax Examples
     * **Timing examples**
     *
     * The following examples show various `timings` specifications.
     * - `animate(500)` : Duration is 500 milliseconds.
     * - `animate("1s")` : Duration is 1000 milliseconds.
     * - `animate("100ms 0.5s")` : Duration is 100 milliseconds, delay is 500 milliseconds.
     * - `animate("5s ease-in")` : Duration is 5000 milliseconds, easing in.
     * - `animate("5s 10ms cubic-bezier(.17,.67,.88,.1)")` : Duration is 5000 milliseconds, delay is 10
     * milliseconds, easing according to a bezier curve.
     *
     * **Style examples**
     *
     * The following example calls `style()` to set a single CSS style.
     * ```typescript
     * animate(500, style({ background: "red" }))
     * ```
     * The following example calls `keyframes()` to set a CSS style
     * to different values for successive keyframes.
     * ```typescript
     * animate(500, keyframes(
     *  [
     *   style({ background: "blue" })),
     *   style({ background: "red" }))
     *  ])
     * ```
     *
     * \@publicApi
     * @param {?} timings Sets `AnimateTimings` for the parent animation.
     * A string in the format "duration [delay] [easing]".
     *  - Duration and delay are expressed as a number and optional time unit,
     * such as "1s" or "10ms" for one second and 10 milliseconds, respectively.
     * The default unit is milliseconds.
     *  - The easing value controls how the animation accelerates and decelerates
     * during its runtime. Value is one of  `ease`, `ease-in`, `ease-out`,
     * `ease-in-out`, or a `cubic-bezier()` function call.
     * If not supplied, no easing is applied.
     *
     * For example, the string "1s 100ms ease-out" specifies a duration of
     * 1000 milliseconds, and delay of 100 ms, and the "ease-out" easing style,
     * which decelerates near the end of the duration.
     * @param {?=} styles Sets AnimationStyles for the parent animation.
     * A function call to either `style()` or `keyframes()`
     * that returns a collection of CSS style entries to be applied to the parent animation.
     * When null, uses the styles from the destination state.
     * This is useful when describing an animation step that will complete an animation;
     * see "Animating to the final state" in `transitions()`.
     * @return {?} An object that encapsulates the animation step.
     *
     */


    function animate(timings) {
      var styles = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
      return {
        type: 4
        /* Animate */
        ,
        styles: styles,
        timings: timings
      };
    }
    /**
     * \@description Defines a list of animation steps to be run in parallel.
     *
     * \@usageNotes
     * Grouped animations are useful when a series of styles must be
     * animated at different starting times and closed off at different ending times.
     *
     * When called within a `sequence()` or a
     * `transition()` call, does not continue to the next
     * instruction until all of the inner animation steps have completed.
     *
     * \@publicApi
     * @param {?} steps An array of animation step objects.
     * - When steps are defined by `style()` or `animate()`
     * function calls, each call within the group is executed instantly.
     * - To specify offset styles to be applied at a later time, define steps with
     * `keyframes()`, or use `animate()` calls with a delay value.
     * For example:
     *
     * ```typescript
     * group([
     *   animate("1s", style({ background: "black" })),
     *   animate("2s", style({ color: "white" }))
     * ])
     * ```
     *
     * @param {?=} options An options object containing a delay and
     * developer-defined parameters that provide styling defaults and
     * can be overridden on invocation.
     *
     * @return {?} An object that encapsulates the group data.
     *
     */


    function group(steps) {
      var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
      return {
        type: 3
        /* Group */
        ,
        steps: steps,
        options: options
      };
    }
    /**
     * Defines a list of animation steps to be run sequentially, one by one.
     *
     * \@usageNotes
     * When you pass an array of steps to a
     * `transition()` call, the steps run sequentially by default.
     * Compare this to the `{\@link animations/group group()}` call, which runs animation steps in
     * parallel.
     *
     * When a sequence is used within a `{\@link animations/group group()}` or a `transition()` call,
     * execution continues to the next instruction only after each of the inner animation
     * steps have completed.
     *
     * \@publicApi
     *
     * @param {?} steps An array of animation step objects.
     * - Steps defined by `style()` calls apply the styling data immediately.
     * - Steps defined by `animate()` calls apply the styling data over time
     *   as specified by the timing data.
     *
     * ```typescript
     * sequence([
     *   style({ opacity: 0 }),
     *   animate("1s", style({ opacity: 1 }))
     * ])
     * ```
     *
     * @param {?=} options An options object containing a delay and
     * developer-defined parameters that provide styling defaults and
     * can be overridden on invocation.
     *
     * @return {?} An object that encapsulates the sequence data.
     *
     */


    function sequence(steps) {
      var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
      return {
        type: 2
        /* Sequence */
        ,
        steps: steps,
        options: options
      };
    }
    /**
     * Declares a key/value object containing CSS properties/styles that
     * can then be used for an animation `state`, within an animation `sequence`,
     * or as styling data for calls to `animate()` and `keyframes()`.
     *
     * \@usageNotes
     * The following examples create animation styles that collect a set of
     * CSS property values:
     *
     * ```typescript
     * // string values for CSS properties
     * style({ background: "red", color: "blue" })
     *
     * // numerical pixel values
     * style({ width: 100, height: 0 })
     * ```
     *
     * The following example uses auto-styling to allow a component to animate from
     * a height of 0 up to the height of the parent element:
     *
     * ```
     * style({ height: 0 }),
     * animate("1s", style({ height: "*" }))
     * ```
     *
     * \@publicApi
     *
     * @param {?} tokens A set of CSS styles or HTML styles associated with an animation state.
     * The value can be any of the following:
     * - A key-value style pair associating a CSS property with a value.
     * - An array of key-value style pairs.
     * - An asterisk (*), to use auto-styling, where styles are derived from the element
     * being animated and applied to the animation when it starts.
     *
     * Auto-styling can be used to define a state that depends on layout or other
     * environmental factors.
     *
     * @return {?} An object that encapsulates the style data.
     *
     */


    function style(tokens) {
      return {
        type: 6
        /* Style */
        ,
        styles: tokens,
        offset: null
      };
    }
    /**
     * Declares an animation state within a trigger attached to an element.
     *
     * \@usageNotes
     * Use the `trigger()` function to register states to an animation trigger.
     * Use the `transition()` function to animate between states.
     * When a state is active within a component, its associated styles persist on the element,
     * even when the animation ends.
     *
     * \@publicApi
     *
     * @param {?} name One or more names for the defined state in a comma-separated string.
     * The following reserved state names can be supplied to define a style for specific use
     * cases:
     *
     * - `void` You can associate styles with this name to be used when
     * the element is detached from the application. For example, when an `ngIf` evaluates
     * to false, the state of the associated element is void.
     *  - `*` (asterisk) Indicates the default state. You can associate styles with this name
     * to be used as the fallback when the state that is being animated is not declared
     * within the trigger.
     *
     * @param {?} styles A set of CSS styles associated with this state, created using the
     * `style()` function.
     * This set of styles persists on the element once the state has been reached.
     * @param {?=} options Parameters that can be passed to the state when it is invoked.
     * 0 or more key-value pairs.
     * @return {?} An object that encapsulates the new state data.
     *
     */


    function state(name, styles, options) {
      return {
        type: 0
        /* State */
        ,
        name: name,
        styles: styles,
        options: options
      };
    }
    /**
     * Defines a set of animation styles, associating each style with an optional `offset` value.
     *
     * \@usageNotes
     * Use with the `animate()` call. Instead of applying animations
     * from the current state
     * to the destination state, keyframes describe how each style entry is applied and at what point
     * within the animation arc.
     * Compare [CSS Keyframe Animations](https://www.w3schools.com/css/css3_animations.asp).
     *
     * ### Usage
     *
     * In the following example, the offset values describe
     * when each `backgroundColor` value is applied. The color is red at the start, and changes to
     * blue when 20% of the total time has elapsed.
     *
     * ```typescript
     * // the provided offset values
     * animate("5s", keyframes([
     *   style({ backgroundColor: "red", offset: 0 }),
     *   style({ backgroundColor: "blue", offset: 0.2 }),
     *   style({ backgroundColor: "orange", offset: 0.3 }),
     *   style({ backgroundColor: "black", offset: 1 })
     * ]))
     * ```
     *
     * If there are no `offset` values specified in the style entries, the offsets
     * are calculated automatically.
     *
     * ```typescript
     * animate("5s", keyframes([
     *   style({ backgroundColor: "red" }) // offset = 0
     *   style({ backgroundColor: "blue" }) // offset = 0.33
     *   style({ backgroundColor: "orange" }) // offset = 0.66
     *   style({ backgroundColor: "black" }) // offset = 1
     * ]))
     * ```
     * \@publicApi
     * @param {?} steps A set of animation styles with optional offset data.
     * The optional `offset` value for a style specifies a percentage of the total animation
     * time at which that style is applied.
     * @return {?} An object that encapsulates the keyframes data.
     *
     */


    function keyframes(steps) {
      return {
        type: 5
        /* Keyframes */
        ,
        steps: steps
      };
    }
    /**
     * Declares an animation transition as a sequence of animation steps to run when a given
     * condition is satisfied. The condition is a Boolean expression or function that compares
     * the previous and current animation states, and returns true if this transition should occur.
     * When the state criteria of a defined transition are met, the associated animation is
     * triggered.
     *
     * \@usageNotes
     * The template associated with a component binds an animation trigger to an element.
     *
     * ```HTML
     * <!-- somewhere inside of my-component-tpl.html -->
     * <div [\@myAnimationTrigger]="myStatusExp">...</div>
     * ```
     *
     * All transitions are defined within an animation trigger,
     * along with named states that the transitions change to and from.
     *
     * ```typescript
     * trigger("myAnimationTrigger", [
     *  // define states
     *  state("on", style({ background: "green" })),
     *  state("off", style({ background: "grey" })),
     *  ...]
     * ```
     *
     * Note that when you call the `sequence()` function within a `{\@link animations/group group()}`
     * or a `transition()` call, execution does not continue to the next instruction
     * until each of the inner animation steps have completed.
     *
     * ### Syntax examples
     *
     * The following examples define transitions between the two defined states (and default states),
     * using various options:
     *
     * ```typescript
     * // Transition occurs when the state value
     * // bound to "myAnimationTrigger" changes from "on" to "off"
     * transition("on => off", animate(500))
     * // Run the same animation for both directions
     * transition("on <=> off", animate(500))
     * // Define multiple state-change pairs separated by commas
     * transition("on => off, off => void", animate(500))
     * ```
     *
     * ### Special values for state-change expressions
     *
     * - Catch-all state change for when an element is inserted into the page and the
     * destination state is unknown:
     *
     * ```typescript
     * transition("void => *", [
     *  style({ opacity: 0 }),
     *  animate(500)
     *  ])
     * ```
     *
     * - Capture a state change between any states:
     *
     *  `transition("* => *", animate("1s 0s"))`
     *
     * - Entry and exit transitions:
     *
     * ```typescript
     * transition(":enter", [
     *   style({ opacity: 0 }),
     *   animate(500, style({ opacity: 1 }))
     *   ]),
     * transition(":leave", [
     *   animate(500, style({ opacity: 0 }))
     *   ])
     * ```
     *
     * - Use `:increment` and `:decrement` to initiate transitions:
     *
     * ```typescript
     * transition(":increment", group([
     *  query(':enter', [
     *     style({ left: '100%' }),
     *     animate('0.5s ease-out', style('*'))
     *   ]),
     *  query(':leave', [
     *     animate('0.5s ease-out', style({ left: '-100%' }))
     *  ])
     * ]))
     *
     * transition(":decrement", group([
     *  query(':enter', [
     *     style({ left: '100%' }),
     *     animate('0.5s ease-out', style('*'))
     *   ]),
     *  query(':leave', [
     *     animate('0.5s ease-out', style({ left: '-100%' }))
     *  ])
     * ]))
     * ```
     *
     * ### State-change functions
     *
     * Here is an example of a `fromState` specified as a state-change function that invokes an
     * animation when true:
     *
     * ```typescript
     * transition((fromState, toState) =>
     *  {
     *   return fromState == "off" && toState == "on";
     *  },
     *  animate("1s 0s"))
     * ```
     *
     * ### Animating to the final state
     *
     * If the final step in a transition is a call to `animate()` that uses a timing value
     * with no style data, that step is automatically considered the final animation arc,
     * for the element to reach the final state. Angular automatically adds or removes
     * CSS styles to ensure that the element is in the correct final state.
     *
     * The following example defines a transition that starts by hiding the element,
     * then makes sure that it animates properly to whatever state is currently active for trigger:
     *
     * ```typescript
     * transition("void => *", [
     *   style({ opacity: 0 }),
     *   animate(500)
     *  ])
     * ```
     * ### Boolean value matching
     * If a trigger binding value is a Boolean, it can be matched using a transition expression
     * that compares true and false or 1 and 0. For example:
     *
     * ```
     * // in the template
     * <div [\@openClose]="open ? true : false">...</div>
     * // in the component metadata
     * trigger('openClose', [
     *   state('true', style({ height: '*' })),
     *   state('false', style({ height: '0px' })),
     *   transition('false <=> true', animate(500))
     * ])
     * ```
     *
     * \@publicApi
     *
     * @param {?} stateChangeExpr A Boolean expression or function that compares the previous and current
     * animation states, and returns true if this transition should occur. Note that  "true" and "false"
     * match 1 and 0, respectively. An expression is evaluated each time a state change occurs in the
     * animation trigger element.
     * The animation steps run when the expression evaluates to true.
     *
     * - A state-change string takes the form "state1 => state2", where each side is a defined animation
     * state, or an asterix (*) to refer to a dynamic start or end state.
     *   - The expression string can contain multiple comma-separated statements;
     * for example "state1 => state2, state3 => state4".
     *   - Special values `:enter` and `:leave` initiate a transition on the entry and exit states,
     * equivalent to  "void => *"  and "* => void".
     *   - Special values `:increment` and `:decrement` initiate a transition when a numeric value has
     * increased or decreased in value.
     * - A function is executed each time a state change occurs in the animation trigger element.
     * The animation steps run when the function returns true.
     *
     * @param {?} steps One or more animation objects, as returned by the `animate()` or
     * `sequence()` function, that form a transformation from one state to another.
     * A sequence is used by default when you pass an array.
     * @param {?=} options An options object that can contain a delay value for the start of the animation,
     * and additional developer-defined parameters. Provided values for additional parameters are used
     * as defaults, and override values can be passed to the caller on invocation.
     * @return {?} An object that encapsulates the transition data.
     *
     */


    function transition(stateChangeExpr, steps) {
      var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
      return {
        type: 1
        /* Transition */
        ,
        expr: stateChangeExpr,
        animation: steps,
        options: options
      };
    }
    /**
     * Produces a reusable animation that can be invoked in another animation or sequence,
     * by calling the `useAnimation()` function.
     *
     * \@usageNotes
     * The following example defines a reusable animation, providing some default parameter
     * values.
     *
     * ```typescript
     * var fadeAnimation = animation([
     *   style({ opacity: '{{ start }}' }),
     *   animate('{{ time }}',
     *   style({ opacity: '{{ end }}'}))
     *   ],
     *   { params: { time: '1000ms', start: 0, end: 1 }});
     * ```
     *
     * The following invokes the defined animation with a call to `useAnimation()`,
     * passing in override parameter values.
     *
     * ```js
     * useAnimation(fadeAnimation, {
     *   params: {
     *     time: '2s',
     *     start: 1,
     *     end: 0
     *   }
     * })
     * ```
     *
     * If any of the passed-in parameter values are missing from this call,
     * the default values are used. If one or more parameter values are missing before a step is
     * animated, `useAnimation()` throws an error.
     *
     * \@publicApi
     * @param {?} steps One or more animation objects, as returned by the `animate()`
     * or `sequence()` function, that form a transformation from one state to another.
     * A sequence is used by default when you pass an array.
     * @param {?=} options An options object that can contain a delay value for the start of the
     * animation, and additional developer-defined parameters.
     * Provided values for additional parameters are used as defaults,
     * and override values can be passed to the caller on invocation.
     * @return {?} An object that encapsulates the animation data.
     *
     */


    function animation(steps) {
      var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
      return {
        type: 8
        /* Reference */
        ,
        animation: steps,
        options: options
      };
    }
    /**
     * Executes a queried inner animation element within an animation sequence.
     *
     * \@usageNotes
     * Each time an animation is triggered in Angular, the parent animation
     * has priority and any child animations are blocked. In order
     * for a child animation to run, the parent animation must query each of the elements
     * containing child animations, and run them using this function.
     *
     * Note that this feature is designed to be used with `query()` and it will only work
     * with animations that are assigned using the Angular animation library. CSS keyframes
     * and transitions are not handled by this API.
     *
     * \@publicApi
     * @param {?=} options An options object that can contain a delay value for the start of the
     * animation, and additional override values for developer-defined parameters.
     * @return {?} An object that encapsulates the child animation data.
     *
     */


    function animateChild() {
      var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
      return {
        type: 9
        /* AnimateChild */
        ,
        options: options
      };
    }
    /**
     * Starts a reusable animation that is created using the `animation()` function.
     *
     * \@publicApi
     * @param {?} animation The reusable animation to start.
     * @param {?=} options An options object that can contain a delay value for the start of
     * the animation, and additional override values for developer-defined parameters.
     * @return {?} An object that contains the animation parameters.
     *
     */


    function useAnimation(animation) {
      var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
      return {
        type: 10
        /* AnimateRef */
        ,
        animation: animation,
        options: options
      };
    }
    /**
     * Finds one or more inner elements within the current element that is
     * being animated within a sequence. Use with `animate()`.
     *
     * \@usageNotes
     * Tokens can be merged into a combined query selector string. For example:
     *
     * ```typescript
     *  query(':self, .record:enter, .record:leave, \@subTrigger', [...])
     * ```
     *
     * The `query()` function collects multiple elements and works internally by using
     * `element.querySelectorAll`. Use the `limit` field of an options object to limit
     * the total number of items to be collected. For example:
     *
     * ```js
     * query('div', [
     *   animate(...),
     *   animate(...)
     * ], { limit: 1 })
     * ```
     *
     * By default, throws an error when zero items are found. Set the
     * `optional` flag to ignore this error. For example:
     *
     * ```js
     * query('.some-element-that-may-not-be-there', [
     *   animate(...),
     *   animate(...)
     * ], { optional: true })
     * ```
     *
     * ### Usage Example
     *
     * The following example queries for inner elements and animates them
     * individually using `animate()`.
     *
     * ```typescript
     * \@Component({
     *   selector: 'inner',
     *   template: `
     *     <div [\@queryAnimation]="exp">
     *       <h1>Title</h1>
     *       <div class="content">
     *         Blah blah blah
     *       </div>
     *     </div>
     *   `,
     *   animations: [
     *    trigger('queryAnimation', [
     *      transition('* => goAnimate', [
     *        // hide the inner elements
     *        query('h1', style({ opacity: 0 })),
     *        query('.content', style({ opacity: 0 })),
     *
     *        // animate the inner elements in, one by one
     *        query('h1', animate(1000, style({ opacity: 1 }))),
     *        query('.content', animate(1000, style({ opacity: 1 }))),
     *      ])
     *    ])
     *  ]
     * })
     * class Cmp {
     *   exp = '';
     *
     *   goAnimate() {
     *     this.exp = 'goAnimate';
     *   }
     * }
     * ```
     *
     * \@publicApi
     * @param {?} selector The element to query, or a set of elements that contain Angular-specific
     * characteristics, specified with one or more of the following tokens.
     *  - `query(":enter")` or `query(":leave")` : Query for newly inserted/removed elements.
     *  - `query(":animating")` : Query all currently animating elements.
     *  - `query("\@triggerName")` : Query elements that contain an animation trigger.
     *  - `query("\@*")` : Query all elements that contain an animation triggers.
     *  - `query(":self")` : Include the current element into the animation sequence.
     *
     * @param {?} animation One or more animation steps to apply to the queried element or elements.
     * An array is treated as an animation sequence.
     * @param {?=} options An options object. Use the 'limit' field to limit the total number of
     * items to collect.
     * @return {?} An object that encapsulates the query data.
     *
     */


    function query(selector, animation) {
      var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
      return {
        type: 11
        /* Query */
        ,
        selector: selector,
        animation: animation,
        options: options
      };
    }
    /**
     * Use within an animation `query()` call to issue a timing gap after
     * each queried item is animated.
     *
     * \@usageNotes
     * In the following example, a container element wraps a list of items stamped out
     * by an `ngFor`. The container element contains an animation trigger that will later be set
     * to query for each of the inner items.
     *
     * Each time items are added, the opacity fade-in animation runs,
     * and each removed item is faded out.
     * When either of these animations occur, the stagger effect is
     * applied after each item's animation is started.
     *
     * ```html
     * <!-- list.component.html -->
     * <button (click)="toggle()">Show / Hide Items</button>
     * <hr />
     * <div [\@listAnimation]="items.length">
     *   <div *ngFor="let item of items">
     *     {{ item }}
     *   </div>
     * </div>
     * ```
     *
     * Here is the component code:
     *
     * ```typescript
     * import {trigger, transition, style, animate, query, stagger} from '\@angular/animations';
     * \@Component({
     *   templateUrl: 'list.component.html',
     *   animations: [
     *     trigger('listAnimation', [
     *     ...
     *     ])
     *   ]
     * })
     * class ListComponent {
     *   items = [];
     *
     *   showItems() {
     *     this.items = [0,1,2,3,4];
     *   }
     *
     *   hideItems() {
     *     this.items = [];
     *   }
     *
     *   toggle() {
     *     this.items.length ? this.hideItems() : this.showItems();
     *    }
     *  }
     * ```
     *
     * Here is the animation trigger code:
     *
     * ```typescript
     * trigger('listAnimation', [
     *   transition('* => *', [ // each time the binding value changes
     *     query(':leave', [
     *       stagger(100, [
     *         animate('0.5s', style({ opacity: 0 }))
     *       ])
     *     ]),
     *     query(':enter', [
     *       style({ opacity: 0 }),
     *       stagger(100, [
     *         animate('0.5s', style({ opacity: 1 }))
     *       ])
     *     ])
     *   ])
     * ])
     * ```
     *
     * \@publicApi
     * @param {?} timings A delay value.
     * @param {?} animation One ore more animation steps.
     * @return {?} An object that encapsulates the stagger data.
     *
     */


    function stagger(timings, animation) {
      return {
        type: 12
        /* Stagger */
        ,
        timings: timings,
        animation: animation
      };
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/src/util.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     * @param {?} cb
     * @return {?}
     */


    function scheduleMicroTask(cb) {
      Promise.resolve(null).then(cb);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/src/players/animation_player.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Provides programmatic control of a reusable animation sequence,
     * built using the `build()` method of `AnimationBuilder`. The `build()` method
     * returns a factory, whose `create()` method instantiates and initializes this interface.
     *
     * @see `AnimationBuilder`
     * @see `AnimationFactory`
     * @see `animate()`
     *
     * \@publicApi
     * @record
     */


    function AnimationPlayer() {}

    if (false) {}
    /**
     * An empty programmatic controller for reusable animations.
     * Used internally when animations are disabled, to avoid
     * checking for the null case when an animation player is expected.
     *
     * @see `animate()`
     * @see `AnimationPlayer`
     * @see `GroupPlayer`
     *
     * \@publicApi
     */


    var NoopAnimationPlayer = /*#__PURE__*/function () {
      /**
       * @param {?=} duration
       * @param {?=} delay
       */
      function NoopAnimationPlayer() {
        var duration = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
        var delay = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;

        _classCallCheck(this, NoopAnimationPlayer);

        this._onDoneFns = [];
        this._onStartFns = [];
        this._onDestroyFns = [];
        this._started = false;
        this._destroyed = false;
        this._finished = false;
        this.parentPlayer = null;
        this.totalTime = duration + delay;
      }
      /**
       * @private
       * @return {?}
       */


      _createClass2(NoopAnimationPlayer, [{
        key: "_onFinish",
        value: function _onFinish() {
          if (!this._finished) {
            this._finished = true;

            this._onDoneFns.forEach(
            /**
            * @param {?} fn
            * @return {?}
            */
            function (fn) {
              return fn();
            });

            this._onDoneFns = [];
          }
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "onStart",
        value: function onStart(fn) {
          this._onStartFns.push(fn);
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "onDone",
        value: function onDone(fn) {
          this._onDoneFns.push(fn);
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "onDestroy",
        value: function onDestroy(fn) {
          this._onDestroyFns.push(fn);
        }
        /**
         * @return {?}
         */

      }, {
        key: "hasStarted",
        value: function hasStarted() {
          return this._started;
        }
        /**
         * @return {?}
         */

      }, {
        key: "init",
        value: function init() {}
        /**
         * @return {?}
         */

      }, {
        key: "play",
        value: function play() {
          if (!this.hasStarted()) {
            this._onStart();

            this.triggerMicrotask();
          }

          this._started = true;
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "triggerMicrotask",
        value: function triggerMicrotask() {
          var _this = this;

          scheduleMicroTask(
          /**
          * @return {?}
          */
          function () {
            return _this._onFinish();
          });
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_onStart",
        value: function _onStart() {
          this._onStartFns.forEach(
          /**
          * @param {?} fn
          * @return {?}
          */
          function (fn) {
            return fn();
          });

          this._onStartFns = [];
        }
        /**
         * @return {?}
         */

      }, {
        key: "pause",
        value: function pause() {}
        /**
         * @return {?}
         */

      }, {
        key: "restart",
        value: function restart() {}
        /**
         * @return {?}
         */

      }, {
        key: "finish",
        value: function finish() {
          this._onFinish();
        }
        /**
         * @return {?}
         */

      }, {
        key: "destroy",
        value: function destroy() {
          if (!this._destroyed) {
            this._destroyed = true;

            if (!this.hasStarted()) {
              this._onStart();
            }

            this.finish();

            this._onDestroyFns.forEach(
            /**
            * @param {?} fn
            * @return {?}
            */
            function (fn) {
              return fn();
            });

            this._onDestroyFns = [];
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "reset",
        value: function reset() {}
        /**
         * @param {?} position
         * @return {?}
         */

      }, {
        key: "setPosition",
        value: function setPosition(position) {}
        /**
         * @return {?}
         */

      }, {
        key: "getPosition",
        value: function getPosition() {
          return 0;
        }
        /**
         * \@internal
         * @param {?} phaseName
         * @return {?}
         */

      }, {
        key: "triggerCallback",
        value: function triggerCallback(phaseName) {
          /** @type {?} */
          var methods = phaseName == 'start' ? this._onStartFns : this._onDoneFns;
          methods.forEach(
          /**
          * @param {?} fn
          * @return {?}
          */
          function (fn) {
            return fn();
          });
          methods.length = 0;
        }
      }]);

      return NoopAnimationPlayer;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/src/players/animation_group_player.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * A programmatic controller for a group of reusable animations.
     * Used internally to control animations.
     *
     * @see `AnimationPlayer`
     * @see `{\@link animations/group group()}`
     *
     */


    var AnimationGroupPlayer = /*#__PURE__*/function () {
      /**
       * @param {?} _players
       */
      function AnimationGroupPlayer(_players) {
        var _this2 = this;

        _classCallCheck(this, AnimationGroupPlayer);

        this._onDoneFns = [];
        this._onStartFns = [];
        this._finished = false;
        this._started = false;
        this._destroyed = false;
        this._onDestroyFns = [];
        this.parentPlayer = null;
        this.totalTime = 0;
        this.players = _players;
        /** @type {?} */

        var doneCount = 0;
        /** @type {?} */

        var destroyCount = 0;
        /** @type {?} */

        var startCount = 0;
        /** @type {?} */

        var total = this.players.length;

        if (total == 0) {
          scheduleMicroTask(
          /**
          * @return {?}
          */
          function () {
            return _this2._onFinish();
          });
        } else {
          this.players.forEach(
          /**
          * @param {?} player
          * @return {?}
          */
          function (player) {
            player.onDone(
            /**
            * @return {?}
            */
            function () {
              if (++doneCount == total) {
                _this2._onFinish();
              }
            });
            player.onDestroy(
            /**
            * @return {?}
            */
            function () {
              if (++destroyCount == total) {
                _this2._onDestroy();
              }
            });
            player.onStart(
            /**
            * @return {?}
            */
            function () {
              if (++startCount == total) {
                _this2._onStart();
              }
            });
          });
        }

        this.totalTime = this.players.reduce(
        /**
        * @param {?} time
        * @param {?} player
        * @return {?}
        */
        function (time, player) {
          return Math.max(time, player.totalTime);
        }, 0);
      }
      /**
       * @private
       * @return {?}
       */


      _createClass2(AnimationGroupPlayer, [{
        key: "_onFinish",
        value: function _onFinish() {
          if (!this._finished) {
            this._finished = true;

            this._onDoneFns.forEach(
            /**
            * @param {?} fn
            * @return {?}
            */
            function (fn) {
              return fn();
            });

            this._onDoneFns = [];
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "init",
        value: function init() {
          this.players.forEach(
          /**
          * @param {?} player
          * @return {?}
          */
          function (player) {
            return player.init();
          });
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "onStart",
        value: function onStart(fn) {
          this._onStartFns.push(fn);
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_onStart",
        value: function _onStart() {
          if (!this.hasStarted()) {
            this._started = true;

            this._onStartFns.forEach(
            /**
            * @param {?} fn
            * @return {?}
            */
            function (fn) {
              return fn();
            });

            this._onStartFns = [];
          }
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "onDone",
        value: function onDone(fn) {
          this._onDoneFns.push(fn);
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "onDestroy",
        value: function onDestroy(fn) {
          this._onDestroyFns.push(fn);
        }
        /**
         * @return {?}
         */

      }, {
        key: "hasStarted",
        value: function hasStarted() {
          return this._started;
        }
        /**
         * @return {?}
         */

      }, {
        key: "play",
        value: function play() {
          if (!this.parentPlayer) {
            this.init();
          }

          this._onStart();

          this.players.forEach(
          /**
          * @param {?} player
          * @return {?}
          */
          function (player) {
            return player.play();
          });
        }
        /**
         * @return {?}
         */

      }, {
        key: "pause",
        value: function pause() {
          this.players.forEach(
          /**
          * @param {?} player
          * @return {?}
          */
          function (player) {
            return player.pause();
          });
        }
        /**
         * @return {?}
         */

      }, {
        key: "restart",
        value: function restart() {
          this.players.forEach(
          /**
          * @param {?} player
          * @return {?}
          */
          function (player) {
            return player.restart();
          });
        }
        /**
         * @return {?}
         */

      }, {
        key: "finish",
        value: function finish() {
          this._onFinish();

          this.players.forEach(
          /**
          * @param {?} player
          * @return {?}
          */
          function (player) {
            return player.finish();
          });
        }
        /**
         * @return {?}
         */

      }, {
        key: "destroy",
        value: function destroy() {
          this._onDestroy();
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_onDestroy",
        value: function _onDestroy() {
          if (!this._destroyed) {
            this._destroyed = true;

            this._onFinish();

            this.players.forEach(
            /**
            * @param {?} player
            * @return {?}
            */
            function (player) {
              return player.destroy();
            });

            this._onDestroyFns.forEach(
            /**
            * @param {?} fn
            * @return {?}
            */
            function (fn) {
              return fn();
            });

            this._onDestroyFns = [];
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "reset",
        value: function reset() {
          this.players.forEach(
          /**
          * @param {?} player
          * @return {?}
          */
          function (player) {
            return player.reset();
          });
          this._destroyed = false;
          this._finished = false;
          this._started = false;
        }
        /**
         * @param {?} p
         * @return {?}
         */

      }, {
        key: "setPosition",
        value: function setPosition(p) {
          /** @type {?} */
          var timeAtPosition = p * this.totalTime;
          this.players.forEach(
          /**
          * @param {?} player
          * @return {?}
          */
          function (player) {
            /** @type {?} */
            var position = player.totalTime ? Math.min(1, timeAtPosition / player.totalTime) : 1;
            player.setPosition(position);
          });
        }
        /**
         * @return {?}
         */

      }, {
        key: "getPosition",
        value: function getPosition() {
          /** @type {?} */
          var min = 0;
          this.players.forEach(
          /**
          * @param {?} player
          * @return {?}
          */
          function (player) {
            /** @type {?} */
            var p = player.getPosition();
            min = Math.min(p, min);
          });
          return min;
        }
        /**
         * @return {?}
         */

      }, {
        key: "beforeDestroy",
        value: function beforeDestroy() {
          this.players.forEach(
          /**
          * @param {?} player
          * @return {?}
          */
          function (player) {
            if (player.beforeDestroy) {
              player.beforeDestroy();
            }
          });
        }
        /**
         * \@internal
         * @param {?} phaseName
         * @return {?}
         */

      }, {
        key: "triggerCallback",
        value: function triggerCallback(phaseName) {
          /** @type {?} */
          var methods = phaseName == 'start' ? this._onStartFns : this._onDoneFns;
          methods.forEach(
          /**
          * @param {?} fn
          * @return {?}
          */
          function (fn) {
            return fn();
          });
          methods.length = 0;
        }
      }]);

      return AnimationGroupPlayer;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/src/private_export.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var ɵPRE_STYLE = '!';
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/src/animations.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/public_api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=animations.js.map

    /***/
  },

  /***/
  "./node_modules/@angular/animations/__ivy_ngcc__/fesm2015/browser.js":
  /*!***************************************************************************!*\
    !*** ./node_modules/@angular/animations/__ivy_ngcc__/fesm2015/browser.js ***!
    \***************************************************************************/

  /*! exports provided: AnimationDriver, ɵAnimation, ɵAnimationEngine, ɵAnimationStyleNormalizer, ɵCssKeyframesDriver, ɵCssKeyframesPlayer, ɵNoopAnimationDriver, ɵNoopAnimationStyleNormalizer, ɵWebAnimationsDriver, ɵWebAnimationsPlayer, ɵWebAnimationsStyleNormalizer, ɵallowPreviousPlayerStylesMerge, ɵangular_packages_animations_browser_browser_a, ɵcontainsElement, ɵinvokeQuery, ɵmatchesElement, ɵsupportsWebAnimations, ɵvalidateStyleProperty */

  /***/
  function node_modulesAngularAnimations__ivy_ngcc__Fesm2015BrowserJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AnimationDriver", function () {
      return AnimationDriver;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵAnimation", function () {
      return Animation;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵAnimationEngine", function () {
      return AnimationEngine;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵAnimationStyleNormalizer", function () {
      return AnimationStyleNormalizer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵCssKeyframesDriver", function () {
      return CssKeyframesDriver;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵCssKeyframesPlayer", function () {
      return CssKeyframesPlayer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵNoopAnimationDriver", function () {
      return NoopAnimationDriver;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵNoopAnimationStyleNormalizer", function () {
      return NoopAnimationStyleNormalizer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵWebAnimationsDriver", function () {
      return WebAnimationsDriver;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵWebAnimationsPlayer", function () {
      return WebAnimationsPlayer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵWebAnimationsStyleNormalizer", function () {
      return WebAnimationsStyleNormalizer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵallowPreviousPlayerStylesMerge", function () {
      return allowPreviousPlayerStylesMerge;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_animations_browser_browser_a", function () {
      return SpecialCasedStyles;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵcontainsElement", function () {
      return _containsElement;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵinvokeQuery", function () {
      return invokeQuery;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵmatchesElement", function () {
      return _matchesElement;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵsupportsWebAnimations", function () {
      return supportsWebAnimations;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵvalidateStyleProperty", function () {
      return _validateStyleProperty;
    });
    /* harmony import */


    var _angular_animations__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/animations */
    "./node_modules/@angular/animations/__ivy_ngcc__/fesm2015/animations.js");
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /**
     * @license Angular v9.1.4
     * (c) 2010-2020 Google LLC. https://angular.io/
     * License: MIT
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/render/shared.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @return {?}
     */


    function isBrowser() {
      return typeof window !== 'undefined' && typeof window.document !== 'undefined';
    }
    /**
     * @return {?}
     */


    function isNode() {
      // Checking only for `process` isn't enough to identify whether or not we're in a Node
      // environment, because Webpack by default will polyfill the `process`. While we can discern
      // that Webpack polyfilled it by looking at `process.browser`, it's very Webpack-specific and
      // might not be future-proof. Instead we look at the stringified version of `process` which
      // is `[object process]` in Node and `[object Object]` when polyfilled.
      return typeof process !== 'undefined' && {}.toString.call(process) === '[object process]';
    }
    /**
     * @param {?} players
     * @return {?}
     */


    function optimizeGroupPlayer(players) {
      switch (players.length) {
        case 0:
          return new _angular_animations__WEBPACK_IMPORTED_MODULE_0__["NoopAnimationPlayer"]();

        case 1:
          return players[0];

        default:
          return new _angular_animations__WEBPACK_IMPORTED_MODULE_0__["ɵAnimationGroupPlayer"](players);
      }
    }
    /**
     * @param {?} driver
     * @param {?} normalizer
     * @param {?} element
     * @param {?} keyframes
     * @param {?=} preStyles
     * @param {?=} postStyles
     * @return {?}
     */


    function normalizeKeyframes(driver, normalizer, element, keyframes) {
      var preStyles = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : {};
      var postStyles = arguments.length > 5 && arguments[5] !== undefined ? arguments[5] : {};

      /** @type {?} */
      var errors = [];
      /** @type {?} */

      var normalizedKeyframes = [];
      /** @type {?} */

      var previousOffset = -1;
      /** @type {?} */

      var previousKeyframe = null;
      keyframes.forEach(
      /**
      * @param {?} kf
      * @return {?}
      */
      function (kf) {
        /** @type {?} */
        var offset =
        /** @type {?} */
        kf['offset'];
        /** @type {?} */

        var isSameOffset = offset == previousOffset;
        /** @type {?} */

        var normalizedKeyframe = isSameOffset && previousKeyframe || {};
        Object.keys(kf).forEach(
        /**
        * @param {?} prop
        * @return {?}
        */
        function (prop) {
          /** @type {?} */
          var normalizedProp = prop;
          /** @type {?} */

          var normalizedValue = kf[prop];

          if (prop !== 'offset') {
            normalizedProp = normalizer.normalizePropertyName(normalizedProp, errors);

            switch (normalizedValue) {
              case _angular_animations__WEBPACK_IMPORTED_MODULE_0__["ɵPRE_STYLE"]:
                normalizedValue = preStyles[prop];
                break;

              case _angular_animations__WEBPACK_IMPORTED_MODULE_0__["AUTO_STYLE"]:
                normalizedValue = postStyles[prop];
                break;

              default:
                normalizedValue = normalizer.normalizeStyleValue(prop, normalizedProp, normalizedValue, errors);
                break;
            }
          }

          normalizedKeyframe[normalizedProp] = normalizedValue;
        });

        if (!isSameOffset) {
          normalizedKeyframes.push(normalizedKeyframe);
        }

        previousKeyframe = normalizedKeyframe;
        previousOffset = offset;
      });

      if (errors.length) {
        /** @type {?} */
        var LINE_START = '\n - ';
        throw new Error("Unable to animate due to the following errors:".concat(LINE_START).concat(errors.join(LINE_START)));
      }

      return normalizedKeyframes;
    }
    /**
     * @param {?} player
     * @param {?} eventName
     * @param {?} event
     * @param {?} callback
     * @return {?}
     */


    function listenOnPlayer(player, eventName, event, callback) {
      switch (eventName) {
        case 'start':
          player.onStart(
          /**
          * @return {?}
          */
          function () {
            return callback(event && copyAnimationEvent(event, 'start', player));
          });
          break;

        case 'done':
          player.onDone(
          /**
          * @return {?}
          */
          function () {
            return callback(event && copyAnimationEvent(event, 'done', player));
          });
          break;

        case 'destroy':
          player.onDestroy(
          /**
          * @return {?}
          */
          function () {
            return callback(event && copyAnimationEvent(event, 'destroy', player));
          });
          break;
      }
    }
    /**
     * @param {?} e
     * @param {?} phaseName
     * @param {?} player
     * @return {?}
     */


    function copyAnimationEvent(e, phaseName, player) {
      /** @type {?} */
      var totalTime = player.totalTime;
      /** @type {?} */

      var disabled =
      /** @type {?} */
      player.disabled ? true : false;
      /** @type {?} */

      var event = makeAnimationEvent(e.element, e.triggerName, e.fromState, e.toState, phaseName || e.phaseName, totalTime == undefined ? e.totalTime : totalTime, disabled);
      /** @type {?} */

      var data =
      /** @type {?} */
      e['_data'];

      if (data != null) {
        /** @type {?} */
        event['_data'] = data;
      }

      return event;
    }
    /**
     * @param {?} element
     * @param {?} triggerName
     * @param {?} fromState
     * @param {?} toState
     * @param {?=} phaseName
     * @param {?=} totalTime
     * @param {?=} disabled
     * @return {?}
     */


    function makeAnimationEvent(element, triggerName, fromState, toState) {
      var phaseName = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : '';
      var totalTime = arguments.length > 5 && arguments[5] !== undefined ? arguments[5] : 0;
      var disabled = arguments.length > 6 ? arguments[6] : undefined;
      return {
        element: element,
        triggerName: triggerName,
        fromState: fromState,
        toState: toState,
        phaseName: phaseName,
        totalTime: totalTime,
        disabled: !!disabled
      };
    }
    /**
     * @param {?} map
     * @param {?} key
     * @param {?} defaultValue
     * @return {?}
     */


    function getOrSetAsInMap(map, key, defaultValue) {
      /** @type {?} */
      var value;

      if (map instanceof Map) {
        value = map.get(key);

        if (!value) {
          map.set(key, value = defaultValue);
        }
      } else {
        value = map[key];

        if (!value) {
          value = map[key] = defaultValue;
        }
      }

      return value;
    }
    /**
     * @param {?} command
     * @return {?}
     */


    function parseTimelineCommand(command) {
      /** @type {?} */
      var separatorPos = command.indexOf(':');
      /** @type {?} */

      var id = command.substring(1, separatorPos);
      /** @type {?} */

      var action = command.substr(separatorPos + 1);
      return [id, action];
    }
    /** @type {?} */


    var _contains =
    /**
    * @param {?} elm1
    * @param {?} elm2
    * @return {?}
    */
    function _contains(elm1, elm2) {
      return false;
    };

    var ɵ0 = _contains;
    /** @type {?} */

    var _matches =
    /**
    * @param {?} element
    * @param {?} selector
    * @return {?}
    */
    function _matches(element, selector) {
      return false;
    };

    var ɵ1 = _matches;
    /** @type {?} */

    var _query =
    /**
    * @param {?} element
    * @param {?} selector
    * @param {?} multi
    * @return {?}
    */
    function _query(element, selector, multi) {
      return [];
    };

    var ɵ2 = _query; // Define utility methods for browsers and platform-server(domino) where Element
    // and utility methods exist.

    /** @type {?} */

    var _isNode = isNode();

    if (_isNode || typeof Element !== 'undefined') {
      // this is well supported in all browsers
      _contains =
      /**
      * @param {?} elm1
      * @param {?} elm2
      * @return {?}
      */
      function _contains(elm1, elm2) {
        return (
          /** @type {?} */
          elm1.contains(elm2)
        );
      };

      _matches =
      /**
      * @return {?}
      */
      function () {
        if (_isNode || Element.prototype.matches) {
          return (
            /**
            * @param {?} element
            * @param {?} selector
            * @return {?}
            */
            function (element, selector) {
              return element.matches(selector);
            }
          );
        } else {
          /** @type {?} */
          var proto =
          /** @type {?} */
          Element.prototype;
          /** @type {?} */

          var fn = proto.matchesSelector || proto.mozMatchesSelector || proto.msMatchesSelector || proto.oMatchesSelector || proto.webkitMatchesSelector;

          if (fn) {
            return (
              /**
              * @param {?} element
              * @param {?} selector
              * @return {?}
              */
              function (element, selector) {
                return fn.apply(element, [selector]);
              }
            );
          } else {
            return _matches;
          }
        }
      }();

      _query =
      /**
      * @param {?} element
      * @param {?} selector
      * @param {?} multi
      * @return {?}
      */
      function _query(element, selector, multi) {
        /** @type {?} */
        var results = [];

        if (multi) {
          results.push.apply(results, _toConsumableArray(element.querySelectorAll(selector)));
        } else {
          /** @type {?} */
          var elm = element.querySelector(selector);

          if (elm) {
            results.push(elm);
          }
        }

        return results;
      };
    }
    /**
     * @param {?} prop
     * @return {?}
     */


    function containsVendorPrefix(prop) {
      // Webkit is the only real popular vendor prefix nowadays
      // cc: http://shouldiprefix.com/
      return prop.substring(1, 6) == 'ebkit'; // webkit or Webkit
    }
    /** @type {?} */


    var _CACHED_BODY = null;
    /** @type {?} */

    var _IS_WEBKIT = false;
    /**
     * @param {?} prop
     * @return {?}
     */

    function _validateStyleProperty(prop) {
      if (!_CACHED_BODY) {
        _CACHED_BODY = getBodyNode() || {};
        _IS_WEBKIT =
        /** @type {?} */
        _CACHED_BODY.style ? 'WebkitAppearance' in
        /** @type {?} */
        _CACHED_BODY.style : false;
      }
      /** @type {?} */


      var result = true;

      if (
      /** @type {?} */
      _CACHED_BODY.style && !containsVendorPrefix(prop)) {
        result = prop in
        /** @type {?} */
        _CACHED_BODY.style;

        if (!result && _IS_WEBKIT) {
          /** @type {?} */
          var camelProp = 'Webkit' + prop.charAt(0).toUpperCase() + prop.substr(1);
          result = camelProp in
          /** @type {?} */
          _CACHED_BODY.style;
        }
      }

      return result;
    }
    /**
     * @return {?}
     */


    function getBodyNode() {
      if (typeof document != 'undefined') {
        return document.body;
      }

      return null;
    }
    /** @type {?} */


    var _matchesElement = _matches;
    /** @type {?} */

    var _containsElement = _contains;
    /** @type {?} */

    var invokeQuery = _query;
    /**
     * @param {?} object
     * @return {?}
     */

    function hypenatePropsObject(object) {
      /** @type {?} */
      var newObj = {};
      Object.keys(object).forEach(
      /**
      * @param {?} prop
      * @return {?}
      */
      function (prop) {
        /** @type {?} */
        var newProp = prop.replace(/([a-z])([A-Z])/g, '$1-$2');
        newObj[newProp] = object[prop];
      });
      return newObj;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/render/animation_driver.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@publicApi
     */


    var NoopAnimationDriver = /*#__PURE__*/function () {
      function NoopAnimationDriver() {
        _classCallCheck(this, NoopAnimationDriver);
      }

      _createClass2(NoopAnimationDriver, [{
        key: "validateStyleProperty",

        /**
         * @param {?} prop
         * @return {?}
         */
        value: function validateStyleProperty(prop) {
          return _validateStyleProperty(prop);
        }
        /**
         * @param {?} element
         * @param {?} selector
         * @return {?}
         */

      }, {
        key: "matchesElement",
        value: function matchesElement(element, selector) {
          return _matchesElement(element, selector);
        }
        /**
         * @param {?} elm1
         * @param {?} elm2
         * @return {?}
         */

      }, {
        key: "containsElement",
        value: function containsElement(elm1, elm2) {
          return _containsElement(elm1, elm2);
        }
        /**
         * @param {?} element
         * @param {?} selector
         * @param {?} multi
         * @return {?}
         */

      }, {
        key: "query",
        value: function query(element, selector, multi) {
          return invokeQuery(element, selector, multi);
        }
        /**
         * @param {?} element
         * @param {?} prop
         * @param {?=} defaultValue
         * @return {?}
         */

      }, {
        key: "computeStyle",
        value: function computeStyle(element, prop, defaultValue) {
          return defaultValue || '';
        }
        /**
         * @param {?} element
         * @param {?} keyframes
         * @param {?} duration
         * @param {?} delay
         * @param {?} easing
         * @param {?=} previousPlayers
         * @param {?=} scrubberAccessRequested
         * @return {?}
         */

      }, {
        key: "animate",
        value: function animate(element, keyframes, duration, delay, easing) {
          var previousPlayers = arguments.length > 5 && arguments[5] !== undefined ? arguments[5] : [];
          var scrubberAccessRequested = arguments.length > 6 ? arguments[6] : undefined;
          return new _angular_animations__WEBPACK_IMPORTED_MODULE_0__["NoopAnimationPlayer"](duration, delay);
        }
      }]);

      return NoopAnimationDriver;
    }();

    NoopAnimationDriver.ɵfac = function NoopAnimationDriver_Factory(t) {
      return new (t || NoopAnimationDriver)();
    };

    NoopAnimationDriver.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"]({
      token: NoopAnimationDriver,
      factory: NoopAnimationDriver.ɵfac
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](NoopAnimationDriver, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"]
      }], null, null);
    })();
    /**
     * \@publicApi
     * @abstract
     */


    var AnimationDriver = function AnimationDriver() {
      _classCallCheck(this, AnimationDriver);
    };

    AnimationDriver.NOOP = new NoopAnimationDriver();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/util.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var ONE_SECOND = 1000;
    /** @type {?} */

    var SUBSTITUTION_EXPR_START = '{{';
    /** @type {?} */

    var SUBSTITUTION_EXPR_END = '}}';
    /** @type {?} */

    var ENTER_CLASSNAME = 'ng-enter';
    /** @type {?} */

    var LEAVE_CLASSNAME = 'ng-leave';
    /** @type {?} */

    var ENTER_SELECTOR = '.ng-enter';
    /** @type {?} */

    var LEAVE_SELECTOR = '.ng-leave';
    /** @type {?} */

    var NG_TRIGGER_CLASSNAME = 'ng-trigger';
    /** @type {?} */

    var NG_TRIGGER_SELECTOR = '.ng-trigger';
    /** @type {?} */

    var NG_ANIMATING_CLASSNAME = 'ng-animating';
    /** @type {?} */

    var NG_ANIMATING_SELECTOR = '.ng-animating';
    /**
     * @param {?} value
     * @return {?}
     */

    function resolveTimingValue(value) {
      if (typeof value == 'number') return value;
      /** @type {?} */

      var matches = value.match(/^(-?[\.\d]+)(m?s)/);
      if (!matches || matches.length < 2) return 0;
      return _convertTimeValueToMS(parseFloat(matches[1]), matches[2]);
    }
    /**
     * @param {?} value
     * @param {?} unit
     * @return {?}
     */


    function _convertTimeValueToMS(value, unit) {
      switch (unit) {
        case 's':
          return value * ONE_SECOND;

        default:
          // ms or something else
          return value;
      }
    }
    /**
     * @param {?} timings
     * @param {?} errors
     * @param {?=} allowNegativeValues
     * @return {?}
     */


    function resolveTiming(timings, errors, allowNegativeValues) {
      return timings.hasOwnProperty('duration') ?
      /** @type {?} */
      timings : parseTimeExpression(
      /** @type {?} */
      timings, errors, allowNegativeValues);
    }
    /**
     * @param {?} exp
     * @param {?} errors
     * @param {?=} allowNegativeValues
     * @return {?}
     */


    function parseTimeExpression(exp, errors, allowNegativeValues) {
      /** @type {?} */
      var regex = /^(-?[\.\d]+)(m?s)(?:\s+(-?[\.\d]+)(m?s))?(?:\s+([-a-z]+(?:\(.+?\))?))?$/i;
      /** @type {?} */

      var duration;
      /** @type {?} */

      var delay = 0;
      /** @type {?} */

      var easing = '';

      if (typeof exp === 'string') {
        /** @type {?} */
        var matches = exp.match(regex);

        if (matches === null) {
          errors.push("The provided timing value \"".concat(exp, "\" is invalid."));
          return {
            duration: 0,
            delay: 0,
            easing: ''
          };
        }

        duration = _convertTimeValueToMS(parseFloat(matches[1]), matches[2]);
        /** @type {?} */

        var delayMatch = matches[3];

        if (delayMatch != null) {
          delay = _convertTimeValueToMS(parseFloat(delayMatch), matches[4]);
        }
        /** @type {?} */


        var easingVal = matches[5];

        if (easingVal) {
          easing = easingVal;
        }
      } else {
        duration = exp;
      }

      if (!allowNegativeValues) {
        /** @type {?} */
        var containsErrors = false;
        /** @type {?} */

        var startIndex = errors.length;

        if (duration < 0) {
          errors.push("Duration values below 0 are not allowed for this animation step.");
          containsErrors = true;
        }

        if (delay < 0) {
          errors.push("Delay values below 0 are not allowed for this animation step.");
          containsErrors = true;
        }

        if (containsErrors) {
          errors.splice(startIndex, 0, "The provided timing value \"".concat(exp, "\" is invalid."));
        }
      }

      return {
        duration: duration,
        delay: delay,
        easing: easing
      };
    }
    /**
     * @param {?} obj
     * @param {?=} destination
     * @return {?}
     */


    function copyObj(obj) {
      var destination = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
      Object.keys(obj).forEach(
      /**
      * @param {?} prop
      * @return {?}
      */
      function (prop) {
        destination[prop] = obj[prop];
      });
      return destination;
    }
    /**
     * @param {?} styles
     * @return {?}
     */


    function normalizeStyles(styles) {
      /** @type {?} */
      var normalizedStyles = {};

      if (Array.isArray(styles)) {
        styles.forEach(
        /**
        * @param {?} data
        * @return {?}
        */
        function (data) {
          return copyStyles(data, false, normalizedStyles);
        });
      } else {
        copyStyles(styles, false, normalizedStyles);
      }

      return normalizedStyles;
    }
    /**
     * @param {?} styles
     * @param {?} readPrototype
     * @param {?=} destination
     * @return {?}
     */


    function copyStyles(styles, readPrototype) {
      var destination = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};

      if (readPrototype) {
        // we make use of a for-in loop so that the
        // prototypically inherited properties are
        // revealed from the backFill map
        for (var prop in styles) {
          destination[prop] = styles[prop];
        }
      } else {
        copyObj(styles, destination);
      }

      return destination;
    }
    /**
     * @param {?} element
     * @param {?} key
     * @param {?} value
     * @return {?}
     */


    function getStyleAttributeString(element, key, value) {
      // Return the key-value pair string to be added to the style attribute for the
      // given CSS style key.
      if (value) {
        return key + ':' + value + ';';
      } else {
        return '';
      }
    }
    /**
     * @param {?} element
     * @return {?}
     */


    function writeStyleAttribute(element) {
      // Read the style property of the element and manually reflect it to the
      // style attribute. This is needed because Domino on platform-server doesn't
      // understand the full set of allowed CSS properties and doesn't reflect some
      // of them automatically.

      /** @type {?} */
      var styleAttrValue = '';

      for (var i = 0; i < element.style.length; i++) {
        /** @type {?} */
        var key = element.style.item(i);
        styleAttrValue += getStyleAttributeString(element, key, element.style.getPropertyValue(key));
      }

      for (var _key in element.style) {
        // Skip internal Domino properties that don't need to be reflected.
        if (!element.style.hasOwnProperty(_key) || _key.startsWith('_')) {
          continue;
        }
        /** @type {?} */


        var dashKey = camelCaseToDashCase(_key);
        styleAttrValue += getStyleAttributeString(element, dashKey, element.style[_key]);
      }

      element.setAttribute('style', styleAttrValue);
    }
    /**
     * @param {?} element
     * @param {?} styles
     * @param {?=} formerStyles
     * @return {?}
     */


    function setStyles(element, styles, formerStyles) {
      if (element['style']) {
        Object.keys(styles).forEach(
        /**
        * @param {?} prop
        * @return {?}
        */
        function (prop) {
          /** @type {?} */
          var camelProp = dashCaseToCamelCase(prop);

          if (formerStyles && !formerStyles.hasOwnProperty(prop)) {
            formerStyles[prop] = element.style[camelProp];
          }

          element.style[camelProp] = styles[prop];
        }); // On the server set the 'style' attribute since it's not automatically reflected.

        if (isNode()) {
          writeStyleAttribute(element);
        }
      }
    }
    /**
     * @param {?} element
     * @param {?} styles
     * @return {?}
     */


    function eraseStyles(element, styles) {
      if (element['style']) {
        Object.keys(styles).forEach(
        /**
        * @param {?} prop
        * @return {?}
        */
        function (prop) {
          /** @type {?} */
          var camelProp = dashCaseToCamelCase(prop);
          element.style[camelProp] = '';
        }); // On the server set the 'style' attribute since it's not automatically reflected.

        if (isNode()) {
          writeStyleAttribute(element);
        }
      }
    }
    /**
     * @param {?} steps
     * @return {?}
     */


    function normalizeAnimationEntry(steps) {
      if (Array.isArray(steps)) {
        if (steps.length == 1) return steps[0];
        return Object(_angular_animations__WEBPACK_IMPORTED_MODULE_0__["sequence"])(steps);
      }

      return (
        /** @type {?} */
        steps
      );
    }
    /**
     * @param {?} value
     * @param {?} options
     * @param {?} errors
     * @return {?}
     */


    function validateStyleParams(value, options, errors) {
      /** @type {?} */
      var params = options.params || {};
      /** @type {?} */

      var matches = extractStyleParams(value);

      if (matches.length) {
        matches.forEach(
        /**
        * @param {?} varName
        * @return {?}
        */
        function (varName) {
          if (!params.hasOwnProperty(varName)) {
            errors.push("Unable to resolve the local animation param ".concat(varName, " in the given list of values"));
          }
        });
      }
    }
    /** @type {?} */


    var PARAM_REGEX = new RegExp("".concat(SUBSTITUTION_EXPR_START, "\\s*(.+?)\\s*").concat(SUBSTITUTION_EXPR_END), 'g');
    /**
     * @param {?} value
     * @return {?}
     */

    function extractStyleParams(value) {
      /** @type {?} */
      var params = [];

      if (typeof value === 'string') {
        /** @type {?} */
        var match;

        while (match = PARAM_REGEX.exec(value)) {
          params.push(
          /** @type {?} */
          match[1]);
        }

        PARAM_REGEX.lastIndex = 0;
      }

      return params;
    }
    /**
     * @param {?} value
     * @param {?} params
     * @param {?} errors
     * @return {?}
     */


    function interpolateParams(value, params, errors) {
      /** @type {?} */
      var original = value.toString();
      /** @type {?} */

      var str = original.replace(PARAM_REGEX,
      /**
      * @param {?} _
      * @param {?} varName
      * @return {?}
      */
      function (_, varName) {
        /** @type {?} */
        var localVal = params[varName]; // this means that the value was never overridden by the data passed in by the user

        if (!params.hasOwnProperty(varName)) {
          errors.push("Please provide a value for the animation param ".concat(varName));
          localVal = '';
        }

        return localVal.toString();
      }); // we do this to assert that numeric values stay as they are

      return str == original ? value : str;
    }
    /**
     * @param {?} iterator
     * @return {?}
     */


    function iteratorToArray(iterator) {
      /** @type {?} */
      var arr = [];
      /** @type {?} */

      var item = iterator.next();

      while (!item.done) {
        arr.push(item.value);
        item = iterator.next();
      }

      return arr;
    }
    /**
     * @param {?} source
     * @param {?} destination
     * @return {?}
     */


    function mergeAnimationOptions(source, destination) {
      if (source.params) {
        /** @type {?} */
        var p0 = source.params;

        if (!destination.params) {
          destination.params = {};
        }
        /** @type {?} */


        var p1 = destination.params;
        Object.keys(p0).forEach(
        /**
        * @param {?} param
        * @return {?}
        */
        function (param) {
          if (!p1.hasOwnProperty(param)) {
            p1[param] = p0[param];
          }
        });
      }

      return destination;
    }
    /** @type {?} */


    var DASH_CASE_REGEXP = /-+([a-z0-9])/g;
    /**
     * @param {?} input
     * @return {?}
     */

    function dashCaseToCamelCase(input) {
      return input.replace(DASH_CASE_REGEXP,
      /**
      * @param {...?} m
      * @return {?}
      */
      function () {
        for (var _len = arguments.length, m = new Array(_len), _key2 = 0; _key2 < _len; _key2++) {
          m[_key2] = arguments[_key2];
        }

        return m[1].toUpperCase();
      });
    }
    /**
     * @param {?} input
     * @return {?}
     */


    function camelCaseToDashCase(input) {
      return input.replace(/([a-z])([A-Z])/g, '$1-$2').toLowerCase();
    }
    /**
     * @param {?} duration
     * @param {?} delay
     * @return {?}
     */


    function allowPreviousPlayerStylesMerge(duration, delay) {
      return duration === 0 || delay === 0;
    }
    /**
     * @param {?} element
     * @param {?} keyframes
     * @param {?} previousStyles
     * @return {?}
     */


    function balancePreviousStylesIntoKeyframes(element, keyframes, previousStyles) {
      /** @type {?} */
      var previousStyleProps = Object.keys(previousStyles);

      if (previousStyleProps.length && keyframes.length) {
        /** @type {?} */
        var startingKeyframe = keyframes[0];
        /** @type {?} */

        var missingStyleProps = [];
        previousStyleProps.forEach(
        /**
        * @param {?} prop
        * @return {?}
        */
        function (prop) {
          if (!startingKeyframe.hasOwnProperty(prop)) {
            missingStyleProps.push(prop);
          }

          startingKeyframe[prop] = previousStyles[prop];
        });

        if (missingStyleProps.length) {
          var _loop = function _loop() {
            /** @type {?} */
            var kf = keyframes[i];
            missingStyleProps.forEach(
            /**
            * @param {?} prop
            * @return {?}
            */
            function (prop) {
              kf[prop] = computeStyle(element, prop);
            });
          };

          // tslint:disable-next-line
          for (var i = 1; i < keyframes.length; i++) {
            _loop();
          }
        }
      }

      return keyframes;
    }
    /**
     * @param {?} visitor
     * @param {?} node
     * @param {?} context
     * @return {?}
     */


    function visitDslNode(visitor, node, context) {
      switch (node.type) {
        case 7
        /* Trigger */
        :
          return visitor.visitTrigger(node, context);

        case 0
        /* State */
        :
          return visitor.visitState(node, context);

        case 1
        /* Transition */
        :
          return visitor.visitTransition(node, context);

        case 2
        /* Sequence */
        :
          return visitor.visitSequence(node, context);

        case 3
        /* Group */
        :
          return visitor.visitGroup(node, context);

        case 4
        /* Animate */
        :
          return visitor.visitAnimate(node, context);

        case 5
        /* Keyframes */
        :
          return visitor.visitKeyframes(node, context);

        case 6
        /* Style */
        :
          return visitor.visitStyle(node, context);

        case 8
        /* Reference */
        :
          return visitor.visitReference(node, context);

        case 9
        /* AnimateChild */
        :
          return visitor.visitAnimateChild(node, context);

        case 10
        /* AnimateRef */
        :
          return visitor.visitAnimateRef(node, context);

        case 11
        /* Query */
        :
          return visitor.visitQuery(node, context);

        case 12
        /* Stagger */
        :
          return visitor.visitStagger(node, context);

        default:
          throw new Error("Unable to resolve animation metadata node #".concat(node.type));
      }
    }
    /**
     * @param {?} element
     * @param {?} prop
     * @return {?}
     */


    function computeStyle(element, prop) {
      return (
        /** @type {?} */
        window.getComputedStyle(element)[prop]
      );
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/dsl/animation_transition_expr.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     * @type {?}
     */


    var ANY_STATE = '*';
    /**
     * @param {?} transitionValue
     * @param {?} errors
     * @return {?}
     */

    function parseTransitionExpr(transitionValue, errors) {
      /** @type {?} */
      var expressions = [];

      if (typeof transitionValue == 'string') {
        transitionValue.split(/\s*,\s*/).forEach(
        /**
        * @param {?} str
        * @return {?}
        */
        function (str) {
          return parseInnerTransitionStr(str, expressions, errors);
        });
      } else {
        expressions.push(
        /** @type {?} */
        transitionValue);
      }

      return expressions;
    }
    /**
     * @param {?} eventStr
     * @param {?} expressions
     * @param {?} errors
     * @return {?}
     */


    function parseInnerTransitionStr(eventStr, expressions, errors) {
      if (eventStr[0] == ':') {
        /** @type {?} */
        var result = parseAnimationAlias(eventStr, errors);

        if (typeof result == 'function') {
          expressions.push(result);
          return;
        }

        eventStr = result;
      }
      /** @type {?} */


      var match = eventStr.match(/^(\*|[-\w]+)\s*(<?[=-]>)\s*(\*|[-\w]+)$/);

      if (match == null || match.length < 4) {
        errors.push("The provided transition expression \"".concat(eventStr, "\" is not supported"));
        return expressions;
      }
      /** @type {?} */


      var fromState = match[1];
      /** @type {?} */

      var separator = match[2];
      /** @type {?} */

      var toState = match[3];
      expressions.push(makeLambdaFromStates(fromState, toState));
      /** @type {?} */

      var isFullAnyStateExpr = fromState == ANY_STATE && toState == ANY_STATE;

      if (separator[0] == '<' && !isFullAnyStateExpr) {
        expressions.push(makeLambdaFromStates(toState, fromState));
      }
    }
    /**
     * @param {?} alias
     * @param {?} errors
     * @return {?}
     */


    function parseAnimationAlias(alias, errors) {
      switch (alias) {
        case ':enter':
          return 'void => *';

        case ':leave':
          return '* => void';

        case ':increment':
          return (
            /**
            * @param {?} fromState
            * @param {?} toState
            * @return {?}
            */
            function (fromState, toState) {
              return parseFloat(toState) > parseFloat(fromState);
            }
          );

        case ':decrement':
          return (
            /**
            * @param {?} fromState
            * @param {?} toState
            * @return {?}
            */
            function (fromState, toState) {
              return parseFloat(toState) < parseFloat(fromState);
            }
          );

        default:
          errors.push("The transition alias value \"".concat(alias, "\" is not supported"));
          return '* => *';
      }
    } // DO NOT REFACTOR ... keep the follow set instantiations
    // with the values intact (closure compiler for some reason
    // removes follow-up lines that add the values outside of
    // the constructor...

    /** @type {?} */


    var TRUE_BOOLEAN_VALUES = new Set(['true', '1']);
    /** @type {?} */

    var FALSE_BOOLEAN_VALUES = new Set(['false', '0']);
    /**
     * @param {?} lhs
     * @param {?} rhs
     * @return {?}
     */

    function makeLambdaFromStates(lhs, rhs) {
      /** @type {?} */
      var LHS_MATCH_BOOLEAN = TRUE_BOOLEAN_VALUES.has(lhs) || FALSE_BOOLEAN_VALUES.has(lhs);
      /** @type {?} */

      var RHS_MATCH_BOOLEAN = TRUE_BOOLEAN_VALUES.has(rhs) || FALSE_BOOLEAN_VALUES.has(rhs);
      return (
        /**
        * @param {?} fromState
        * @param {?} toState
        * @return {?}
        */
        function (fromState, toState) {
          /** @type {?} */
          var lhsMatch = lhs == ANY_STATE || lhs == fromState;
          /** @type {?} */

          var rhsMatch = rhs == ANY_STATE || rhs == toState;

          if (!lhsMatch && LHS_MATCH_BOOLEAN && typeof fromState === 'boolean') {
            lhsMatch = fromState ? TRUE_BOOLEAN_VALUES.has(lhs) : FALSE_BOOLEAN_VALUES.has(lhs);
          }

          if (!rhsMatch && RHS_MATCH_BOOLEAN && typeof toState === 'boolean') {
            rhsMatch = toState ? TRUE_BOOLEAN_VALUES.has(rhs) : FALSE_BOOLEAN_VALUES.has(rhs);
          }

          return lhsMatch && rhsMatch;
        }
      );
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/dsl/animation_ast_builder.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var SELF_TOKEN = ':self';
    /** @type {?} */

    var SELF_TOKEN_REGEX = new RegExp("s*".concat(SELF_TOKEN, "s*,?"), 'g');
    /*
     * [Validation]
     * The visitor code below will traverse the animation AST generated by the animation verb functions
     * (the output is a tree of objects) and attempt to perform a series of validations on the data. The
     * following corner-cases will be validated:
     *
     * 1. Overlap of animations
     * Given that a CSS property cannot be animated in more than one place at the same time, it's
     * important that this behavior is detected and validated. The way in which this occurs is that
     * each time a style property is examined, a string-map containing the property will be updated with
     * the start and end times for when the property is used within an animation step.
     *
     * If there are two or more parallel animations that are currently running (these are invoked by the
     * group()) on the same element then the validator will throw an error. Since the start/end timing
     * values are collected for each property then if the current animation step is animating the same
     * property and its timing values fall anywhere into the window of time that the property is
     * currently being animated within then this is what causes an error.
     *
     * 2. Timing values
     * The validator will validate to see if a timing value of `duration delay easing` or
     * `durationNumber` is valid or not.
     *
     * (note that upon validation the code below will replace the timing data with an object containing
     * {duration,delay,easing}.
     *
     * 3. Offset Validation
     * Each of the style() calls are allowed to have an offset value when placed inside of keyframes().
     * Offsets within keyframes() are considered valid when:
     *
     *   - No offsets are used at all
     *   - Each style() entry contains an offset value
     *   - Each offset is between 0 and 1
     *   - Each offset is greater to or equal than the previous one
     *
     * Otherwise an error will be thrown.
     */

    /**
     * @param {?} driver
     * @param {?} metadata
     * @param {?} errors
     * @return {?}
     */

    function buildAnimationAst(driver, metadata, errors) {
      return new AnimationAstBuilderVisitor(driver).build(metadata, errors);
    }
    /** @type {?} */


    var ROOT_SELECTOR = '';

    var AnimationAstBuilderVisitor = /*#__PURE__*/function () {
      /**
       * @param {?} _driver
       */
      function AnimationAstBuilderVisitor(_driver) {
        _classCallCheck(this, AnimationAstBuilderVisitor);

        this._driver = _driver;
      }
      /**
       * @param {?} metadata
       * @param {?} errors
       * @return {?}
       */


      _createClass2(AnimationAstBuilderVisitor, [{
        key: "build",
        value: function build(metadata, errors) {
          /** @type {?} */
          var context = new AnimationAstBuilderContext(errors);

          this._resetContextStyleTimingState(context);

          return (
            /** @type {?} */
            visitDslNode(this, normalizeAnimationEntry(metadata), context)
          );
        }
        /**
         * @private
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "_resetContextStyleTimingState",
        value: function _resetContextStyleTimingState(context) {
          context.currentQuerySelector = ROOT_SELECTOR;
          context.collectedStyles = {};
          context.collectedStyles[ROOT_SELECTOR] = {};
          context.currentTime = 0;
        }
        /**
         * @param {?} metadata
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitTrigger",
        value: function visitTrigger(metadata, context) {
          var _this3 = this;

          /** @type {?} */
          var queryCount = context.queryCount = 0;
          /** @type {?} */

          var depCount = context.depCount = 0;
          /** @type {?} */

          var states = [];
          /** @type {?} */

          var transitions = [];

          if (metadata.name.charAt(0) == '@') {
            context.errors.push('animation triggers cannot be prefixed with an `@` sign (e.g. trigger(\'@foo\', [...]))');
          }

          metadata.definitions.forEach(
          /**
          * @param {?} def
          * @return {?}
          */
          function (def) {
            _this3._resetContextStyleTimingState(context);

            if (def.type == 0
            /* State */
            ) {
                /** @type {?} */
                var stateDef =
                /** @type {?} */
                def;
                /** @type {?} */

                var name = stateDef.name;
                name.toString().split(/\s*,\s*/).forEach(
                /**
                * @param {?} n
                * @return {?}
                */
                function (n) {
                  stateDef.name = n;
                  states.push(_this3.visitState(stateDef, context));
                });
                stateDef.name = name;
              } else if (def.type == 1
            /* Transition */
            ) {
                /** @type {?} */
                var transition = _this3.visitTransition(
                /** @type {?} */
                def, context);

                queryCount += transition.queryCount;
                depCount += transition.depCount;
                transitions.push(transition);
              } else {
              context.errors.push('only state() and transition() definitions can sit inside of a trigger()');
            }
          });
          return {
            type: 7
            /* Trigger */
            ,
            name: metadata.name,
            states: states,
            transitions: transitions,
            queryCount: queryCount,
            depCount: depCount,
            options: null
          };
        }
        /**
         * @param {?} metadata
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitState",
        value: function visitState(metadata, context) {
          /** @type {?} */
          var styleAst = this.visitStyle(metadata.styles, context);
          /** @type {?} */

          var astParams = metadata.options && metadata.options.params || null;

          if (styleAst.containsDynamicStyles) {
            /** @type {?} */
            var missingSubs = new Set();
            /** @type {?} */

            var params = astParams || {};
            styleAst.styles.forEach(
            /**
            * @param {?} value
            * @return {?}
            */
            function (value) {
              if (isObject(value)) {
                /** @type {?} */
                var stylesObj =
                /** @type {?} */
                value;
                Object.keys(stylesObj).forEach(
                /**
                * @param {?} prop
                * @return {?}
                */
                function (prop) {
                  extractStyleParams(stylesObj[prop]).forEach(
                  /**
                  * @param {?} sub
                  * @return {?}
                  */
                  function (sub) {
                    if (!params.hasOwnProperty(sub)) {
                      missingSubs.add(sub);
                    }
                  });
                });
              }
            });

            if (missingSubs.size) {
              /** @type {?} */
              var missingSubsArr = iteratorToArray(missingSubs.values());
              context.errors.push("state(\"".concat(metadata.name, "\", ...) must define default values for all the following style substitutions: ").concat(missingSubsArr.join(', ')));
            }
          }

          return {
            type: 0
            /* State */
            ,
            name: metadata.name,
            style: styleAst,
            options: astParams ? {
              params: astParams
            } : null
          };
        }
        /**
         * @param {?} metadata
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitTransition",
        value: function visitTransition(metadata, context) {
          context.queryCount = 0;
          context.depCount = 0;
          /** @type {?} */

          var animation = visitDslNode(this, normalizeAnimationEntry(metadata.animation), context);
          /** @type {?} */

          var matchers = parseTransitionExpr(metadata.expr, context.errors);
          return {
            type: 1
            /* Transition */
            ,
            matchers: matchers,
            animation: animation,
            queryCount: context.queryCount,
            depCount: context.depCount,
            options: normalizeAnimationOptions(metadata.options)
          };
        }
        /**
         * @param {?} metadata
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitSequence",
        value: function visitSequence(metadata, context) {
          var _this4 = this;

          return {
            type: 2
            /* Sequence */
            ,
            steps: metadata.steps.map(
            /**
            * @param {?} s
            * @return {?}
            */
            function (s) {
              return visitDslNode(_this4, s, context);
            }),
            options: normalizeAnimationOptions(metadata.options)
          };
        }
        /**
         * @param {?} metadata
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitGroup",
        value: function visitGroup(metadata, context) {
          var _this5 = this;

          /** @type {?} */
          var currentTime = context.currentTime;
          /** @type {?} */

          var furthestTime = 0;
          /** @type {?} */

          var steps = metadata.steps.map(
          /**
          * @param {?} step
          * @return {?}
          */
          function (step) {
            context.currentTime = currentTime;
            /** @type {?} */

            var innerAst = visitDslNode(_this5, step, context);
            furthestTime = Math.max(furthestTime, context.currentTime);
            return innerAst;
          });
          context.currentTime = furthestTime;
          return {
            type: 3
            /* Group */
            ,
            steps: steps,
            options: normalizeAnimationOptions(metadata.options)
          };
        }
        /**
         * @param {?} metadata
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitAnimate",
        value: function visitAnimate(metadata, context) {
          /** @type {?} */
          var timingAst = constructTimingAst(metadata.timings, context.errors);
          context.currentAnimateTimings = timingAst;
          /** @type {?} */

          var styleAst;
          /** @type {?} */

          var styleMetadata = metadata.styles ? metadata.styles : Object(_angular_animations__WEBPACK_IMPORTED_MODULE_0__["style"])({});

          if (styleMetadata.type == 5
          /* Keyframes */
          ) {
              styleAst = this.visitKeyframes(
              /** @type {?} */
              styleMetadata, context);
            } else {
            /** @type {?} */
            var _styleMetadata =
            /** @type {?} */
            metadata.styles;
            /** @type {?} */

            var isEmpty = false;

            if (!_styleMetadata) {
              isEmpty = true;
              /** @type {?} */

              var newStyleData = {};

              if (timingAst.easing) {
                newStyleData['easing'] = timingAst.easing;
              }

              _styleMetadata = Object(_angular_animations__WEBPACK_IMPORTED_MODULE_0__["style"])(newStyleData);
            }

            context.currentTime += timingAst.duration + timingAst.delay;
            /** @type {?} */

            var _styleAst = this.visitStyle(_styleMetadata, context);

            _styleAst.isEmptyStep = isEmpty;
            styleAst = _styleAst;
          }

          context.currentAnimateTimings = null;
          return {
            type: 4
            /* Animate */
            ,
            timings: timingAst,
            style: styleAst,
            options: null
          };
        }
        /**
         * @param {?} metadata
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitStyle",
        value: function visitStyle(metadata, context) {
          /** @type {?} */
          var ast = this._makeStyleAst(metadata, context);

          this._validateStyleAst(ast, context);

          return ast;
        }
        /**
         * @private
         * @param {?} metadata
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "_makeStyleAst",
        value: function _makeStyleAst(metadata, context) {
          /** @type {?} */
          var styles = [];

          if (Array.isArray(metadata.styles)) {
            /** @type {?} */
            metadata.styles.forEach(
            /**
            * @param {?} styleTuple
            * @return {?}
            */
            function (styleTuple) {
              if (typeof styleTuple == 'string') {
                if (styleTuple == _angular_animations__WEBPACK_IMPORTED_MODULE_0__["AUTO_STYLE"]) {
                  styles.push(styleTuple);
                } else {
                  context.errors.push("The provided style string value ".concat(styleTuple, " is not allowed."));
                }
              } else {
                styles.push(styleTuple);
              }
            });
          } else {
            styles.push(metadata.styles);
          }
          /** @type {?} */


          var containsDynamicStyles = false;
          /** @type {?} */

          var collectedEasing = null;
          styles.forEach(
          /**
          * @param {?} styleData
          * @return {?}
          */
          function (styleData) {
            if (isObject(styleData)) {
              /** @type {?} */
              var styleMap =
              /** @type {?} */
              styleData;
              /** @type {?} */

              var easing = styleMap['easing'];

              if (easing) {
                collectedEasing =
                /** @type {?} */
                easing;
                delete styleMap['easing'];
              }

              if (!containsDynamicStyles) {
                for (var prop in styleMap) {
                  /** @type {?} */
                  var value = styleMap[prop];

                  if (value.toString().indexOf(SUBSTITUTION_EXPR_START) >= 0) {
                    containsDynamicStyles = true;
                    break;
                  }
                }
              }
            }
          });
          return {
            type: 6
            /* Style */
            ,
            styles: styles,
            easing: collectedEasing,
            offset: metadata.offset,
            containsDynamicStyles: containsDynamicStyles,
            options: null
          };
        }
        /**
         * @private
         * @param {?} ast
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "_validateStyleAst",
        value: function _validateStyleAst(ast, context) {
          var _this6 = this;

          /** @type {?} */
          var timings = context.currentAnimateTimings;
          /** @type {?} */

          var endTime = context.currentTime;
          /** @type {?} */

          var startTime = context.currentTime;

          if (timings && startTime > 0) {
            startTime -= timings.duration + timings.delay;
          }

          ast.styles.forEach(
          /**
          * @param {?} tuple
          * @return {?}
          */
          function (tuple) {
            if (typeof tuple == 'string') return;
            Object.keys(tuple).forEach(
            /**
            * @param {?} prop
            * @return {?}
            */
            function (prop) {
              if (!_this6._driver.validateStyleProperty(prop)) {
                context.errors.push("The provided animation property \"".concat(prop, "\" is not a supported CSS property for animations"));
                return;
              }
              /** @type {?} */


              var collectedStyles = context.collectedStyles[
              /** @type {?} */
              context.currentQuerySelector];
              /** @type {?} */

              var collectedEntry = collectedStyles[prop];
              /** @type {?} */

              var updateCollectedStyle = true;

              if (collectedEntry) {
                if (startTime != endTime && startTime >= collectedEntry.startTime && endTime <= collectedEntry.endTime) {
                  context.errors.push("The CSS property \"".concat(prop, "\" that exists between the times of \"").concat(collectedEntry.startTime, "ms\" and \"").concat(collectedEntry.endTime, "ms\" is also being animated in a parallel animation between the times of \"").concat(startTime, "ms\" and \"").concat(endTime, "ms\""));
                  updateCollectedStyle = false;
                } // we always choose the smaller start time value since we
                // want to have a record of the entire animation window where
                // the style property is being animated in between


                startTime = collectedEntry.startTime;
              }

              if (updateCollectedStyle) {
                collectedStyles[prop] = {
                  startTime: startTime,
                  endTime: endTime
                };
              }

              if (context.options) {
                validateStyleParams(tuple[prop], context.options, context.errors);
              }
            });
          });
        }
        /**
         * @param {?} metadata
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitKeyframes",
        value: function visitKeyframes(metadata, context) {
          var _this7 = this;

          /** @type {?} */
          var ast = {
            type: 5
            /* Keyframes */
            ,
            styles: [],
            options: null
          };

          if (!context.currentAnimateTimings) {
            context.errors.push("keyframes() must be placed inside of a call to animate()");
            return ast;
          }
          /** @type {?} */


          var MAX_KEYFRAME_OFFSET = 1;
          /** @type {?} */

          var totalKeyframesWithOffsets = 0;
          /** @type {?} */

          var offsets = [];
          /** @type {?} */

          var offsetsOutOfOrder = false;
          /** @type {?} */

          var keyframesOutOfRange = false;
          /** @type {?} */

          var previousOffset = 0;
          /** @type {?} */

          var keyframes = metadata.steps.map(
          /**
          * @param {?} styles
          * @return {?}
          */
          function (styles) {
            /** @type {?} */
            var style = _this7._makeStyleAst(styles, context);
            /** @type {?} */


            var offsetVal = style.offset != null ? style.offset : consumeOffset(style.styles);
            /** @type {?} */

            var offset = 0;

            if (offsetVal != null) {
              totalKeyframesWithOffsets++;
              offset = style.offset = offsetVal;
            }

            keyframesOutOfRange = keyframesOutOfRange || offset < 0 || offset > 1;
            offsetsOutOfOrder = offsetsOutOfOrder || offset < previousOffset;
            previousOffset = offset;
            offsets.push(offset);
            return style;
          });

          if (keyframesOutOfRange) {
            context.errors.push("Please ensure that all keyframe offsets are between 0 and 1");
          }

          if (offsetsOutOfOrder) {
            context.errors.push("Please ensure that all keyframe offsets are in order");
          }
          /** @type {?} */


          var length = metadata.steps.length;
          /** @type {?} */

          var generatedOffset = 0;

          if (totalKeyframesWithOffsets > 0 && totalKeyframesWithOffsets < length) {
            context.errors.push("Not all style() steps within the declared keyframes() contain offsets");
          } else if (totalKeyframesWithOffsets == 0) {
            generatedOffset = MAX_KEYFRAME_OFFSET / (length - 1);
          }
          /** @type {?} */


          var limit = length - 1;
          /** @type {?} */

          var currentTime = context.currentTime;
          /** @type {?} */

          var currentAnimateTimings =
          /** @type {?} */
          context.currentAnimateTimings;
          /** @type {?} */

          var animateDuration = currentAnimateTimings.duration;
          keyframes.forEach(
          /**
          * @param {?} kf
          * @param {?} i
          * @return {?}
          */
          function (kf, i) {
            /** @type {?} */
            var offset = generatedOffset > 0 ? i == limit ? 1 : generatedOffset * i : offsets[i];
            /** @type {?} */

            var durationUpToThisFrame = offset * animateDuration;
            context.currentTime = currentTime + currentAnimateTimings.delay + durationUpToThisFrame;
            currentAnimateTimings.duration = durationUpToThisFrame;

            _this7._validateStyleAst(kf, context);

            kf.offset = offset;
            ast.styles.push(kf);
          });
          return ast;
        }
        /**
         * @param {?} metadata
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitReference",
        value: function visitReference(metadata, context) {
          return {
            type: 8
            /* Reference */
            ,
            animation: visitDslNode(this, normalizeAnimationEntry(metadata.animation), context),
            options: normalizeAnimationOptions(metadata.options)
          };
        }
        /**
         * @param {?} metadata
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitAnimateChild",
        value: function visitAnimateChild(metadata, context) {
          context.depCount++;
          return {
            type: 9
            /* AnimateChild */
            ,
            options: normalizeAnimationOptions(metadata.options)
          };
        }
        /**
         * @param {?} metadata
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitAnimateRef",
        value: function visitAnimateRef(metadata, context) {
          return {
            type: 10
            /* AnimateRef */
            ,
            animation: this.visitReference(metadata.animation, context),
            options: normalizeAnimationOptions(metadata.options)
          };
        }
        /**
         * @param {?} metadata
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitQuery",
        value: function visitQuery(metadata, context) {
          /** @type {?} */
          var parentSelector =
          /** @type {?} */
          context.currentQuerySelector;
          /** @type {?} */

          var options =
          /** @type {?} */
          metadata.options || {};
          context.queryCount++;
          context.currentQuery = metadata;

          var _normalizeSelector = normalizeSelector(metadata.selector),
              _normalizeSelector2 = _slicedToArray(_normalizeSelector, 2),
              selector = _normalizeSelector2[0],
              includeSelf = _normalizeSelector2[1];

          context.currentQuerySelector = parentSelector.length ? parentSelector + ' ' + selector : selector;
          getOrSetAsInMap(context.collectedStyles, context.currentQuerySelector, {});
          /** @type {?} */

          var animation = visitDslNode(this, normalizeAnimationEntry(metadata.animation), context);
          context.currentQuery = null;
          context.currentQuerySelector = parentSelector;
          return {
            type: 11
            /* Query */
            ,
            selector: selector,
            limit: options.limit || 0,
            optional: !!options.optional,
            includeSelf: includeSelf,
            animation: animation,
            originalSelector: metadata.selector,
            options: normalizeAnimationOptions(metadata.options)
          };
        }
        /**
         * @param {?} metadata
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitStagger",
        value: function visitStagger(metadata, context) {
          if (!context.currentQuery) {
            context.errors.push("stagger() can only be used inside of query()");
          }
          /** @type {?} */


          var timings = metadata.timings === 'full' ? {
            duration: 0,
            delay: 0,
            easing: 'full'
          } : resolveTiming(metadata.timings, context.errors, true);
          return {
            type: 12
            /* Stagger */
            ,
            animation: visitDslNode(this, normalizeAnimationEntry(metadata.animation), context),
            timings: timings,
            options: null
          };
        }
      }]);

      return AnimationAstBuilderVisitor;
    }();

    if (false) {}
    /**
     * @param {?} selector
     * @return {?}
     */


    function normalizeSelector(selector) {
      /** @type {?} */
      var hasAmpersand = selector.split(/\s*,\s*/).find(
      /**
      * @param {?} token
      * @return {?}
      */
      function (token) {
        return token == SELF_TOKEN;
      }) ? true : false;

      if (hasAmpersand) {
        selector = selector.replace(SELF_TOKEN_REGEX, '');
      } // the :enter and :leave selectors are filled in at runtime during timeline building


      selector = selector.replace(/@\*/g, NG_TRIGGER_SELECTOR).replace(/@\w+/g,
      /**
      * @param {?} match
      * @return {?}
      */
      function (match) {
        return NG_TRIGGER_SELECTOR + '-' + match.substr(1);
      }).replace(/:animating/g, NG_ANIMATING_SELECTOR);
      return [selector, hasAmpersand];
    }
    /**
     * @param {?} obj
     * @return {?}
     */


    function normalizeParams(obj) {
      return obj ? copyObj(obj) : null;
    }

    var AnimationAstBuilderContext =
    /**
     * @param {?} errors
     */
    function AnimationAstBuilderContext(errors) {
      _classCallCheck(this, AnimationAstBuilderContext);

      this.errors = errors;
      this.queryCount = 0;
      this.depCount = 0;
      this.currentTransition = null;
      this.currentQuery = null;
      this.currentQuerySelector = null;
      this.currentAnimateTimings = null;
      this.currentTime = 0;
      this.collectedStyles = {};
      this.options = null;
    };

    if (false) {}
    /**
     * @param {?} styles
     * @return {?}
     */


    function consumeOffset(styles) {
      if (typeof styles == 'string') return null;
      /** @type {?} */

      var offset = null;

      if (Array.isArray(styles)) {
        styles.forEach(
        /**
        * @param {?} styleTuple
        * @return {?}
        */
        function (styleTuple) {
          if (isObject(styleTuple) && styleTuple.hasOwnProperty('offset')) {
            /** @type {?} */
            var obj =
            /** @type {?} */
            styleTuple;
            offset = parseFloat(
            /** @type {?} */
            obj['offset']);
            delete obj['offset'];
          }
        });
      } else if (isObject(styles) && styles.hasOwnProperty('offset')) {
        /** @type {?} */
        var obj = styles;
        offset = parseFloat(
        /** @type {?} */
        obj['offset']);
        delete obj['offset'];
      }

      return offset;
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function isObject(value) {
      return !Array.isArray(value) && typeof value == 'object';
    }
    /**
     * @param {?} value
     * @param {?} errors
     * @return {?}
     */


    function constructTimingAst(value, errors) {
      /** @type {?} */
      var timings = null;

      if (value.hasOwnProperty('duration')) {
        timings =
        /** @type {?} */
        value;
      } else if (typeof value == 'number') {
        /** @type {?} */
        var duration = resolveTiming(value, errors).duration;
        return makeTimingAst(duration, 0, '');
      }
      /** @type {?} */


      var strValue =
      /** @type {?} */
      value;
      /** @type {?} */

      var isDynamic = strValue.split(/\s+/).some(
      /**
      * @param {?} v
      * @return {?}
      */
      function (v) {
        return v.charAt(0) == '{' && v.charAt(1) == '{';
      });

      if (isDynamic) {
        /** @type {?} */
        var ast =
        /** @type {?} */
        makeTimingAst(0, 0, '');
        ast.dynamic = true;
        ast.strValue = strValue;
        return (
          /** @type {?} */
          ast
        );
      }

      timings = timings || resolveTiming(strValue, errors);
      return makeTimingAst(timings.duration, timings.delay, timings.easing);
    }
    /**
     * @param {?} options
     * @return {?}
     */


    function normalizeAnimationOptions(options) {
      if (options) {
        options = copyObj(options);

        if (options['params']) {
          options['params'] =
          /** @type {?} */
          normalizeParams(options['params']);
        }
      } else {
        options = {};
      }

      return options;
    }
    /**
     * @param {?} duration
     * @param {?} delay
     * @param {?} easing
     * @return {?}
     */


    function makeTimingAst(duration, delay, easing) {
      return {
        duration: duration,
        delay: delay,
        easing: easing
      };
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/dsl/animation_timeline_instruction.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @record
     */


    function AnimationTimelineInstruction() {}

    if (false) {}
    /**
     * @param {?} element
     * @param {?} keyframes
     * @param {?} preStyleProps
     * @param {?} postStyleProps
     * @param {?} duration
     * @param {?} delay
     * @param {?=} easing
     * @param {?=} subTimeline
     * @return {?}
     */


    function createTimelineInstruction(element, keyframes, preStyleProps, postStyleProps, duration, delay) {
      var easing = arguments.length > 6 && arguments[6] !== undefined ? arguments[6] : null;
      var subTimeline = arguments.length > 7 && arguments[7] !== undefined ? arguments[7] : false;
      return {
        type: 1
        /* TimelineAnimation */
        ,
        element: element,
        keyframes: keyframes,
        preStyleProps: preStyleProps,
        postStyleProps: postStyleProps,
        duration: duration,
        delay: delay,
        totalTime: duration + delay,
        easing: easing,
        subTimeline: subTimeline
      };
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/dsl/element_instruction_map.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var ElementInstructionMap = /*#__PURE__*/function () {
      function ElementInstructionMap() {
        _classCallCheck(this, ElementInstructionMap);

        this._map = new Map();
      }
      /**
       * @param {?} element
       * @return {?}
       */


      _createClass2(ElementInstructionMap, [{
        key: "consume",
        value: function consume(element) {
          /** @type {?} */
          var instructions = this._map.get(element);

          if (instructions) {
            this._map["delete"](element);
          } else {
            instructions = [];
          }

          return instructions;
        }
        /**
         * @param {?} element
         * @param {?} instructions
         * @return {?}
         */

      }, {
        key: "append",
        value: function append(element, instructions) {
          var _existingInstructions;

          /** @type {?} */
          var existingInstructions = this._map.get(element);

          if (!existingInstructions) {
            this._map.set(element, existingInstructions = []);
          }

          (_existingInstructions = existingInstructions).push.apply(_existingInstructions, _toConsumableArray(instructions));
        }
        /**
         * @param {?} element
         * @return {?}
         */

      }, {
        key: "has",
        value: function has(element) {
          return this._map.has(element);
        }
        /**
         * @return {?}
         */

      }, {
        key: "clear",
        value: function clear() {
          this._map.clear();
        }
      }]);

      return ElementInstructionMap;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/dsl/animation_timeline_builder.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var ONE_FRAME_IN_MILLISECONDS = 1;
    /** @type {?} */

    var ENTER_TOKEN = ':enter';
    /** @type {?} */

    var ENTER_TOKEN_REGEX = new RegExp(ENTER_TOKEN, 'g');
    /** @type {?} */

    var LEAVE_TOKEN = ':leave';
    /** @type {?} */

    var LEAVE_TOKEN_REGEX = new RegExp(LEAVE_TOKEN, 'g');
    /*
     * The code within this file aims to generate web-animations-compatible keyframes from Angular's
     * animation DSL code.
     *
     * The code below will be converted from:
     *
     * ```
     * sequence([
     *   style({ opacity: 0 }),
     *   animate(1000, style({ opacity: 0 }))
     * ])
     * ```
     *
     * To:
     * ```
     * keyframes = [{ opacity: 0, offset: 0 }, { opacity: 1, offset: 1 }]
     * duration = 1000
     * delay = 0
     * easing = ''
     * ```
     *
     * For this operation to cover the combination of animation verbs (style, animate, group, etc...) a
     * combination of prototypical inheritance, AST traversal and merge-sort-like algorithms are used.
     *
     * [AST Traversal]
     * Each of the animation verbs, when executed, will return an string-map object representing what
     * type of action it is (style, animate, group, etc...) and the data associated with it. This means
     * that when functional composition mix of these functions is evaluated (like in the example above)
     * then it will end up producing a tree of objects representing the animation itself.
     *
     * When this animation object tree is processed by the visitor code below it will visit each of the
     * verb statements within the visitor. And during each visit it will build the context of the
     * animation keyframes by interacting with the `TimelineBuilder`.
     *
     * [TimelineBuilder]
     * This class is responsible for tracking the styles and building a series of keyframe objects for a
     * timeline between a start and end time. The builder starts off with an initial timeline and each
     * time the AST comes across a `group()`, `keyframes()` or a combination of the two wihtin a
     * `sequence()` then it will generate a sub timeline for each step as well as a new one after
     * they are complete.
     *
     * As the AST is traversed, the timing state on each of the timelines will be incremented. If a sub
     * timeline was created (based on one of the cases above) then the parent timeline will attempt to
     * merge the styles used within the sub timelines into itself (only with group() this will happen).
     * This happens with a merge operation (much like how the merge works in mergesort) and it will only
     * copy the most recently used styles from the sub timelines into the parent timeline. This ensures
     * that if the styles are used later on in another phase of the animation then they will be the most
     * up-to-date values.
     *
     * [How Missing Styles Are Updated]
     * Each timeline has a `backFill` property which is responsible for filling in new styles into
     * already processed keyframes if a new style shows up later within the animation sequence.
     *
     * ```
     * sequence([
     *   style({ width: 0 }),
     *   animate(1000, style({ width: 100 })),
     *   animate(1000, style({ width: 200 })),
     *   animate(1000, style({ width: 300 }))
     *   animate(1000, style({ width: 400, height: 400 })) // notice how `height` doesn't exist anywhere
     * else
     * ])
     * ```
     *
     * What is happening here is that the `height` value is added later in the sequence, but is missing
     * from all previous animation steps. Therefore when a keyframe is created it would also be missing
     * from all previous keyframes up until where it is first used. For the timeline keyframe generation
     * to properly fill in the style it will place the previous value (the value from the parent
     * timeline) or a default value of `*` into the backFill object. Given that each of the keyframe
     * styles are objects that prototypically inhert from the backFill object, this means that if a
     * value is added into the backFill then it will automatically propagate any missing values to all
     * keyframes. Therefore the missing `height` value will be properly filled into the already
     * processed keyframes.
     *
     * When a sub-timeline is created it will have its own backFill property. This is done so that
     * styles present within the sub-timeline do not accidentally seep into the previous/future timeline
     * keyframes
     *
     * (For prototypically-inherited contents to be detected a `for(i in obj)` loop must be used.)
     *
     * [Validation]
     * The code in this file is not responsible for validation. That functionality happens with within
     * the `AnimationValidatorVisitor` code.
     */

    /**
     * @param {?} driver
     * @param {?} rootElement
     * @param {?} ast
     * @param {?} enterClassName
     * @param {?} leaveClassName
     * @param {?=} startingStyles
     * @param {?=} finalStyles
     * @param {?=} options
     * @param {?=} subInstructions
     * @param {?=} errors
     * @return {?}
     */

    function buildAnimationTimelines(driver, rootElement, ast, enterClassName, leaveClassName) {
      var startingStyles = arguments.length > 5 && arguments[5] !== undefined ? arguments[5] : {};
      var finalStyles = arguments.length > 6 && arguments[6] !== undefined ? arguments[6] : {};
      var options = arguments.length > 7 ? arguments[7] : undefined;
      var subInstructions = arguments.length > 8 ? arguments[8] : undefined;
      var errors = arguments.length > 9 && arguments[9] !== undefined ? arguments[9] : [];
      return new AnimationTimelineBuilderVisitor().buildKeyframes(driver, rootElement, ast, enterClassName, leaveClassName, startingStyles, finalStyles, options, subInstructions, errors);
    }

    var AnimationTimelineBuilderVisitor = /*#__PURE__*/function () {
      function AnimationTimelineBuilderVisitor() {
        _classCallCheck(this, AnimationTimelineBuilderVisitor);
      }

      _createClass2(AnimationTimelineBuilderVisitor, [{
        key: "buildKeyframes",

        /**
         * @param {?} driver
         * @param {?} rootElement
         * @param {?} ast
         * @param {?} enterClassName
         * @param {?} leaveClassName
         * @param {?} startingStyles
         * @param {?} finalStyles
         * @param {?} options
         * @param {?=} subInstructions
         * @param {?=} errors
         * @return {?}
         */
        value: function buildKeyframes(driver, rootElement, ast, enterClassName, leaveClassName, startingStyles, finalStyles, options, subInstructions) {
          var errors = arguments.length > 9 && arguments[9] !== undefined ? arguments[9] : [];
          subInstructions = subInstructions || new ElementInstructionMap();
          /** @type {?} */

          var context = new AnimationTimelineContext(driver, rootElement, subInstructions, enterClassName, leaveClassName, errors, []);
          context.options = options;
          context.currentTimeline.setStyles([startingStyles], null, context.errors, options);
          visitDslNode(this, ast, context); // this checks to see if an actual animation happened

          /** @type {?} */

          var timelines = context.timelines.filter(
          /**
          * @param {?} timeline
          * @return {?}
          */
          function (timeline) {
            return timeline.containsAnimation();
          });

          if (timelines.length && Object.keys(finalStyles).length) {
            /** @type {?} */
            var tl = timelines[timelines.length - 1];

            if (!tl.allowOnlyTimelineStyles()) {
              tl.setStyles([finalStyles], null, context.errors, options);
            }
          }

          return timelines.length ? timelines.map(
          /**
          * @param {?} timeline
          * @return {?}
          */
          function (timeline) {
            return timeline.buildKeyframes();
          }) : [createTimelineInstruction(rootElement, [], [], [], 0, 0, '', false)];
        }
        /**
         * @param {?} ast
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitTrigger",
        value: function visitTrigger(ast, context) {} // these values are not visited in this AST

        /**
         * @param {?} ast
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitState",
        value: function visitState(ast, context) {} // these values are not visited in this AST

        /**
         * @param {?} ast
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitTransition",
        value: function visitTransition(ast, context) {} // these values are not visited in this AST

        /**
         * @param {?} ast
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitAnimateChild",
        value: function visitAnimateChild(ast, context) {
          /** @type {?} */
          var elementInstructions = context.subInstructions.consume(context.element);

          if (elementInstructions) {
            /** @type {?} */
            var innerContext = context.createSubContext(ast.options);
            /** @type {?} */

            var startTime = context.currentTimeline.currentTime;
            /** @type {?} */

            var endTime = this._visitSubInstructions(elementInstructions, innerContext,
            /** @type {?} */
            innerContext.options);

            if (startTime != endTime) {
              // we do this on the upper context because we created a sub context for
              // the sub child animations
              context.transformIntoNewTimeline(endTime);
            }
          }

          context.previousNode = ast;
        }
        /**
         * @param {?} ast
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitAnimateRef",
        value: function visitAnimateRef(ast, context) {
          /** @type {?} */
          var innerContext = context.createSubContext(ast.options);
          innerContext.transformIntoNewTimeline();
          this.visitReference(ast.animation, innerContext);
          context.transformIntoNewTimeline(innerContext.currentTimeline.currentTime);
          context.previousNode = ast;
        }
        /**
         * @private
         * @param {?} instructions
         * @param {?} context
         * @param {?} options
         * @return {?}
         */

      }, {
        key: "_visitSubInstructions",
        value: function _visitSubInstructions(instructions, context, options) {
          /** @type {?} */
          var startTime = context.currentTimeline.currentTime;
          /** @type {?} */

          var furthestTime = startTime; // this is a special-case for when a user wants to skip a sub
          // animation from being fired entirely.

          /** @type {?} */

          var duration = options.duration != null ? resolveTimingValue(options.duration) : null;
          /** @type {?} */

          var delay = options.delay != null ? resolveTimingValue(options.delay) : null;

          if (duration !== 0) {
            instructions.forEach(
            /**
            * @param {?} instruction
            * @return {?}
            */
            function (instruction) {
              /** @type {?} */
              var instructionTimings = context.appendInstructionToTimeline(instruction, duration, delay);
              furthestTime = Math.max(furthestTime, instructionTimings.duration + instructionTimings.delay);
            });
          }

          return furthestTime;
        }
        /**
         * @param {?} ast
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitReference",
        value: function visitReference(ast, context) {
          context.updateOptions(ast.options, true);
          visitDslNode(this, ast.animation, context);
          context.previousNode = ast;
        }
        /**
         * @param {?} ast
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitSequence",
        value: function visitSequence(ast, context) {
          var _this8 = this;

          /** @type {?} */
          var subContextCount = context.subContextCount;
          /** @type {?} */

          var ctx = context;
          /** @type {?} */

          var options = ast.options;

          if (options && (options.params || options.delay)) {
            ctx = context.createSubContext(options);
            ctx.transformIntoNewTimeline();

            if (options.delay != null) {
              if (ctx.previousNode.type == 6
              /* Style */
              ) {
                  ctx.currentTimeline.snapshotCurrentStyles();
                  ctx.previousNode = DEFAULT_NOOP_PREVIOUS_NODE;
                }
              /** @type {?} */


              var delay = resolveTimingValue(options.delay);
              ctx.delayNextStep(delay);
            }
          }

          if (ast.steps.length) {
            ast.steps.forEach(
            /**
            * @param {?} s
            * @return {?}
            */
            function (s) {
              return visitDslNode(_this8, s, ctx);
            }); // this is here just incase the inner steps only contain or end with a style() call

            ctx.currentTimeline.applyStylesToKeyframe(); // this means that some animation function within the sequence
            // ended up creating a sub timeline (which means the current
            // timeline cannot overlap with the contents of the sequence)

            if (ctx.subContextCount > subContextCount) {
              ctx.transformIntoNewTimeline();
            }
          }

          context.previousNode = ast;
        }
        /**
         * @param {?} ast
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitGroup",
        value: function visitGroup(ast, context) {
          var _this9 = this;

          /** @type {?} */
          var innerTimelines = [];
          /** @type {?} */

          var furthestTime = context.currentTimeline.currentTime;
          /** @type {?} */

          var delay = ast.options && ast.options.delay ? resolveTimingValue(ast.options.delay) : 0;
          ast.steps.forEach(
          /**
          * @param {?} s
          * @return {?}
          */
          function (s) {
            /** @type {?} */
            var innerContext = context.createSubContext(ast.options);

            if (delay) {
              innerContext.delayNextStep(delay);
            }

            visitDslNode(_this9, s, innerContext);
            furthestTime = Math.max(furthestTime, innerContext.currentTimeline.currentTime);
            innerTimelines.push(innerContext.currentTimeline);
          }); // this operation is run after the AST loop because otherwise
          // if the parent timeline's collected styles were updated then
          // it would pass in invalid data into the new-to-be forked items

          innerTimelines.forEach(
          /**
          * @param {?} timeline
          * @return {?}
          */
          function (timeline) {
            return context.currentTimeline.mergeTimelineCollectedStyles(timeline);
          });
          context.transformIntoNewTimeline(furthestTime);
          context.previousNode = ast;
        }
        /**
         * @private
         * @param {?} ast
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "_visitTiming",
        value: function _visitTiming(ast, context) {
          if (
          /** @type {?} */
          ast.dynamic) {
            /** @type {?} */
            var strValue =
            /** @type {?} */
            ast.strValue;
            /** @type {?} */

            var timingValue = context.params ? interpolateParams(strValue, context.params, context.errors) : strValue;
            return resolveTiming(timingValue, context.errors);
          } else {
            return {
              duration: ast.duration,
              delay: ast.delay,
              easing: ast.easing
            };
          }
        }
        /**
         * @param {?} ast
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitAnimate",
        value: function visitAnimate(ast, context) {
          /** @type {?} */
          var timings = context.currentAnimateTimings = this._visitTiming(ast.timings, context);
          /** @type {?} */


          var timeline = context.currentTimeline;

          if (timings.delay) {
            context.incrementTime(timings.delay);
            timeline.snapshotCurrentStyles();
          }
          /** @type {?} */


          var style = ast.style;

          if (style.type == 5
          /* Keyframes */
          ) {
              this.visitKeyframes(style, context);
            } else {
            context.incrementTime(timings.duration);
            this.visitStyle(
            /** @type {?} */
            style, context);
            timeline.applyStylesToKeyframe();
          }

          context.currentAnimateTimings = null;
          context.previousNode = ast;
        }
        /**
         * @param {?} ast
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitStyle",
        value: function visitStyle(ast, context) {
          /** @type {?} */
          var timeline = context.currentTimeline;
          /** @type {?} */

          var timings =
          /** @type {?} */
          context.currentAnimateTimings; // this is a special case for when a style() call
          // directly follows  an animate() call (but not inside of an animate() call)

          if (!timings && timeline.getCurrentStyleProperties().length) {
            timeline.forwardFrame();
          }
          /** @type {?} */


          var easing = timings && timings.easing || ast.easing;

          if (ast.isEmptyStep) {
            timeline.applyEmptyStep(easing);
          } else {
            timeline.setStyles(ast.styles, easing, context.errors, context.options);
          }

          context.previousNode = ast;
        }
        /**
         * @param {?} ast
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitKeyframes",
        value: function visitKeyframes(ast, context) {
          /** @type {?} */
          var currentAnimateTimings =
          /** @type {?} */
          context.currentAnimateTimings;
          /** @type {?} */

          var startTime =
          /** @type {?} */
          context.currentTimeline.duration;
          /** @type {?} */

          var duration = currentAnimateTimings.duration;
          /** @type {?} */

          var innerContext = context.createSubContext();
          /** @type {?} */

          var innerTimeline = innerContext.currentTimeline;
          innerTimeline.easing = currentAnimateTimings.easing;
          ast.styles.forEach(
          /**
          * @param {?} step
          * @return {?}
          */
          function (step) {
            /** @type {?} */
            var offset = step.offset || 0;
            innerTimeline.forwardTime(offset * duration);
            innerTimeline.setStyles(step.styles, step.easing, context.errors, context.options);
            innerTimeline.applyStylesToKeyframe();
          }); // this will ensure that the parent timeline gets all the styles from
          // the child even if the new timeline below is not used

          context.currentTimeline.mergeTimelineCollectedStyles(innerTimeline); // we do this because the window between this timeline and the sub timeline
          // should ensure that the styles within are exactly the same as they were before

          context.transformIntoNewTimeline(startTime + duration);
          context.previousNode = ast;
        }
        /**
         * @param {?} ast
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitQuery",
        value: function visitQuery(ast, context) {
          var _this10 = this;

          // in the event that the first step before this is a style step we need
          // to ensure the styles are applied before the children are animated

          /** @type {?} */
          var startTime = context.currentTimeline.currentTime;
          /** @type {?} */

          var options =
          /** @type {?} */
          ast.options || {};
          /** @type {?} */

          var delay = options.delay ? resolveTimingValue(options.delay) : 0;

          if (delay && (context.previousNode.type === 6
          /* Style */
          || startTime == 0 && context.currentTimeline.getCurrentStyleProperties().length)) {
            context.currentTimeline.snapshotCurrentStyles();
            context.previousNode = DEFAULT_NOOP_PREVIOUS_NODE;
          }
          /** @type {?} */


          var furthestTime = startTime;
          /** @type {?} */

          var elms = context.invokeQuery(ast.selector, ast.originalSelector, ast.limit, ast.includeSelf, options.optional ? true : false, context.errors);
          context.currentQueryTotal = elms.length;
          /** @type {?} */

          var sameElementTimeline = null;
          elms.forEach(
          /**
          * @param {?} element
          * @param {?} i
          * @return {?}
          */
          function (element, i) {
            context.currentQueryIndex = i;
            /** @type {?} */

            var innerContext = context.createSubContext(ast.options, element);

            if (delay) {
              innerContext.delayNextStep(delay);
            }

            if (element === context.element) {
              sameElementTimeline = innerContext.currentTimeline;
            }

            visitDslNode(_this10, ast.animation, innerContext); // this is here just incase the inner steps only contain or end
            // with a style() call (which is here to signal that this is a preparatory
            // call to style an element before it is animated again)

            innerContext.currentTimeline.applyStylesToKeyframe();
            /** @type {?} */

            var endTime = innerContext.currentTimeline.currentTime;
            furthestTime = Math.max(furthestTime, endTime);
          });
          context.currentQueryIndex = 0;
          context.currentQueryTotal = 0;
          context.transformIntoNewTimeline(furthestTime);

          if (sameElementTimeline) {
            context.currentTimeline.mergeTimelineCollectedStyles(sameElementTimeline);
            context.currentTimeline.snapshotCurrentStyles();
          }

          context.previousNode = ast;
        }
        /**
         * @param {?} ast
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "visitStagger",
        value: function visitStagger(ast, context) {
          /** @type {?} */
          var parentContext =
          /** @type {?} */
          context.parentContext;
          /** @type {?} */

          var tl = context.currentTimeline;
          /** @type {?} */

          var timings = ast.timings;
          /** @type {?} */

          var duration = Math.abs(timings.duration);
          /** @type {?} */

          var maxTime = duration * (context.currentQueryTotal - 1);
          /** @type {?} */

          var delay = duration * context.currentQueryIndex;
          /** @type {?} */

          var staggerTransformer = timings.duration < 0 ? 'reverse' : timings.easing;

          switch (staggerTransformer) {
            case 'reverse':
              delay = maxTime - delay;
              break;

            case 'full':
              delay = parentContext.currentStaggerTime;
              break;
          }
          /** @type {?} */


          var timeline = context.currentTimeline;

          if (delay) {
            timeline.delayNextStep(delay);
          }
          /** @type {?} */


          var startingTime = timeline.currentTime;
          visitDslNode(this, ast.animation, context);
          context.previousNode = ast; // time = duration + delay
          // the reason why this computation is so complex is because
          // the inner timeline may either have a delay value or a stretched
          // keyframe depending on if a subtimeline is not used or is used.

          parentContext.currentStaggerTime = tl.currentTime - startingTime + (tl.startTime - parentContext.currentTimeline.startTime);
        }
      }]);

      return AnimationTimelineBuilderVisitor;
    }();
    /** @type {?} */


    var DEFAULT_NOOP_PREVIOUS_NODE =
    /** @type {?} */
    {};

    var AnimationTimelineContext = /*#__PURE__*/function () {
      /**
       * @param {?} _driver
       * @param {?} element
       * @param {?} subInstructions
       * @param {?} _enterClassName
       * @param {?} _leaveClassName
       * @param {?} errors
       * @param {?} timelines
       * @param {?=} initialTimeline
       */
      function AnimationTimelineContext(_driver, element, subInstructions, _enterClassName, _leaveClassName, errors, timelines, initialTimeline) {
        _classCallCheck(this, AnimationTimelineContext);

        this._driver = _driver;
        this.element = element;
        this.subInstructions = subInstructions;
        this._enterClassName = _enterClassName;
        this._leaveClassName = _leaveClassName;
        this.errors = errors;
        this.timelines = timelines;
        this.parentContext = null;
        this.currentAnimateTimings = null;
        this.previousNode = DEFAULT_NOOP_PREVIOUS_NODE;
        this.subContextCount = 0;
        this.options = {};
        this.currentQueryIndex = 0;
        this.currentQueryTotal = 0;
        this.currentStaggerTime = 0;
        this.currentTimeline = initialTimeline || new TimelineBuilder(this._driver, element, 0);
        timelines.push(this.currentTimeline);
      }
      /**
       * @return {?}
       */


      _createClass2(AnimationTimelineContext, [{
        key: "updateOptions",

        /**
         * @param {?} options
         * @param {?=} skipIfExists
         * @return {?}
         */
        value: function updateOptions(options, skipIfExists) {
          var _this11 = this;

          if (!options) return;
          /** @type {?} */

          var newOptions =
          /** @type {?} */
          options;
          /** @type {?} */

          var optionsToUpdate = this.options; // NOTE: this will get patched up when other animation methods support duration overrides

          if (newOptions.duration != null) {
            /** @type {?} */
            optionsToUpdate.duration = resolveTimingValue(newOptions.duration);
          }

          if (newOptions.delay != null) {
            optionsToUpdate.delay = resolveTimingValue(newOptions.delay);
          }
          /** @type {?} */


          var newParams = newOptions.params;

          if (newParams) {
            /** @type {?} */
            var paramsToUpdate =
            /** @type {?} */
            optionsToUpdate.params;

            if (!paramsToUpdate) {
              paramsToUpdate = this.options.params = {};
            }

            Object.keys(newParams).forEach(
            /**
            * @param {?} name
            * @return {?}
            */
            function (name) {
              if (!skipIfExists || !paramsToUpdate.hasOwnProperty(name)) {
                paramsToUpdate[name] = interpolateParams(newParams[name], paramsToUpdate, _this11.errors);
              }
            });
          }
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_copyOptions",
        value: function _copyOptions() {
          /** @type {?} */
          var options = {};

          if (this.options) {
            /** @type {?} */
            var oldParams = this.options.params;

            if (oldParams) {
              /** @type {?} */
              var params = options['params'] = {};
              Object.keys(oldParams).forEach(
              /**
              * @param {?} name
              * @return {?}
              */
              function (name) {
                params[name] = oldParams[name];
              });
            }
          }

          return options;
        }
        /**
         * @param {?=} options
         * @param {?=} element
         * @param {?=} newTime
         * @return {?}
         */

      }, {
        key: "createSubContext",
        value: function createSubContext() {
          var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
          var element = arguments.length > 1 ? arguments[1] : undefined;
          var newTime = arguments.length > 2 ? arguments[2] : undefined;

          /** @type {?} */
          var target = element || this.element;
          /** @type {?} */

          var context = new AnimationTimelineContext(this._driver, target, this.subInstructions, this._enterClassName, this._leaveClassName, this.errors, this.timelines, this.currentTimeline.fork(target, newTime || 0));
          context.previousNode = this.previousNode;
          context.currentAnimateTimings = this.currentAnimateTimings;
          context.options = this._copyOptions();
          context.updateOptions(options);
          context.currentQueryIndex = this.currentQueryIndex;
          context.currentQueryTotal = this.currentQueryTotal;
          context.parentContext = this;
          this.subContextCount++;
          return context;
        }
        /**
         * @param {?=} newTime
         * @return {?}
         */

      }, {
        key: "transformIntoNewTimeline",
        value: function transformIntoNewTimeline(newTime) {
          this.previousNode = DEFAULT_NOOP_PREVIOUS_NODE;
          this.currentTimeline = this.currentTimeline.fork(this.element, newTime);
          this.timelines.push(this.currentTimeline);
          return this.currentTimeline;
        }
        /**
         * @param {?} instruction
         * @param {?} duration
         * @param {?} delay
         * @return {?}
         */

      }, {
        key: "appendInstructionToTimeline",
        value: function appendInstructionToTimeline(instruction, duration, delay) {
          /** @type {?} */
          var updatedTimings = {
            duration: duration != null ? duration : instruction.duration,
            delay: this.currentTimeline.currentTime + (delay != null ? delay : 0) + instruction.delay,
            easing: ''
          };
          /** @type {?} */

          var builder = new SubTimelineBuilder(this._driver, instruction.element, instruction.keyframes, instruction.preStyleProps, instruction.postStyleProps, updatedTimings, instruction.stretchStartingKeyframe);
          this.timelines.push(builder);
          return updatedTimings;
        }
        /**
         * @param {?} time
         * @return {?}
         */

      }, {
        key: "incrementTime",
        value: function incrementTime(time) {
          this.currentTimeline.forwardTime(this.currentTimeline.duration + time);
        }
        /**
         * @param {?} delay
         * @return {?}
         */

      }, {
        key: "delayNextStep",
        value: function delayNextStep(delay) {
          // negative delays are not yet supported
          if (delay > 0) {
            this.currentTimeline.delayNextStep(delay);
          }
        }
        /**
         * @param {?} selector
         * @param {?} originalSelector
         * @param {?} limit
         * @param {?} includeSelf
         * @param {?} optional
         * @param {?} errors
         * @return {?}
         */

      }, {
        key: "invokeQuery",
        value: function invokeQuery(selector, originalSelector, limit, includeSelf, optional, errors) {
          /** @type {?} */
          var results = [];

          if (includeSelf) {
            results.push(this.element);
          }

          if (selector.length > 0) {
            // if :self is only used then the selector is empty
            selector = selector.replace(ENTER_TOKEN_REGEX, '.' + this._enterClassName);
            selector = selector.replace(LEAVE_TOKEN_REGEX, '.' + this._leaveClassName);
            /** @type {?} */

            var multi = limit != 1;
            /** @type {?} */

            var elements = this._driver.query(this.element, selector, multi);

            if (limit !== 0) {
              elements = limit < 0 ? elements.slice(elements.length + limit, elements.length) : elements.slice(0, limit);
            }

            results.push.apply(results, _toConsumableArray(elements));
          }

          if (!optional && results.length == 0) {
            errors.push("`query(\"".concat(originalSelector, "\")` returned zero elements. (Use `query(\"").concat(originalSelector, "\", { optional: true })` if you wish to allow this.)"));
          }

          return results;
        }
      }, {
        key: "params",
        get: function get() {
          return this.options.params;
        }
      }]);

      return AnimationTimelineContext;
    }();

    if (false) {}

    var TimelineBuilder = /*#__PURE__*/function () {
      /**
       * @param {?} _driver
       * @param {?} element
       * @param {?} startTime
       * @param {?=} _elementTimelineStylesLookup
       */
      function TimelineBuilder(_driver, element, startTime, _elementTimelineStylesLookup) {
        _classCallCheck(this, TimelineBuilder);

        this._driver = _driver;
        this.element = element;
        this.startTime = startTime;
        this._elementTimelineStylesLookup = _elementTimelineStylesLookup;
        this.duration = 0;
        this._previousKeyframe = {};
        this._currentKeyframe = {};
        this._keyframes = new Map();
        this._styleSummary = {};
        this._pendingStyles = {};
        this._backFill = {};
        this._currentEmptyStepKeyframe = null;

        if (!this._elementTimelineStylesLookup) {
          this._elementTimelineStylesLookup = new Map();
        }

        this._localTimelineStyles = Object.create(this._backFill, {});
        this._globalTimelineStyles =
        /** @type {?} */
        this._elementTimelineStylesLookup.get(element);

        if (!this._globalTimelineStyles) {
          this._globalTimelineStyles = this._localTimelineStyles;

          this._elementTimelineStylesLookup.set(element, this._localTimelineStyles);
        }

        this._loadKeyframe();
      }
      /**
       * @return {?}
       */


      _createClass2(TimelineBuilder, [{
        key: "containsAnimation",
        value: function containsAnimation() {
          switch (this._keyframes.size) {
            case 0:
              return false;

            case 1:
              return this.getCurrentStyleProperties().length > 0;

            default:
              return true;
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "getCurrentStyleProperties",
        value: function getCurrentStyleProperties() {
          return Object.keys(this._currentKeyframe);
        }
        /**
         * @return {?}
         */

      }, {
        key: "delayNextStep",

        /**
         * @param {?} delay
         * @return {?}
         */
        value: function delayNextStep(delay) {
          // in the event that a style() step is placed right before a stagger()
          // and that style() step is the very first style() value in the animation
          // then we need to make a copy of the keyframe [0, copy, 1] so that the delay
          // properly applies the style() values to work with the stagger...

          /** @type {?} */
          var hasPreStyleStep = this._keyframes.size == 1 && Object.keys(this._pendingStyles).length;

          if (this.duration || hasPreStyleStep) {
            this.forwardTime(this.currentTime + delay);

            if (hasPreStyleStep) {
              this.snapshotCurrentStyles();
            }
          } else {
            this.startTime += delay;
          }
        }
        /**
         * @param {?} element
         * @param {?=} currentTime
         * @return {?}
         */

      }, {
        key: "fork",
        value: function fork(element, currentTime) {
          this.applyStylesToKeyframe();
          return new TimelineBuilder(this._driver, element, currentTime || this.currentTime, this._elementTimelineStylesLookup);
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_loadKeyframe",
        value: function _loadKeyframe() {
          if (this._currentKeyframe) {
            this._previousKeyframe = this._currentKeyframe;
          }

          this._currentKeyframe =
          /** @type {?} */
          this._keyframes.get(this.duration);

          if (!this._currentKeyframe) {
            this._currentKeyframe = Object.create(this._backFill, {});

            this._keyframes.set(this.duration, this._currentKeyframe);
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "forwardFrame",
        value: function forwardFrame() {
          this.duration += ONE_FRAME_IN_MILLISECONDS;

          this._loadKeyframe();
        }
        /**
         * @param {?} time
         * @return {?}
         */

      }, {
        key: "forwardTime",
        value: function forwardTime(time) {
          this.applyStylesToKeyframe();
          this.duration = time;

          this._loadKeyframe();
        }
        /**
         * @private
         * @param {?} prop
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "_updateStyle",
        value: function _updateStyle(prop, value) {
          this._localTimelineStyles[prop] = value;
          this._globalTimelineStyles[prop] = value;
          this._styleSummary[prop] = {
            time: this.currentTime,
            value: value
          };
        }
        /**
         * @return {?}
         */

      }, {
        key: "allowOnlyTimelineStyles",
        value: function allowOnlyTimelineStyles() {
          return this._currentEmptyStepKeyframe !== this._currentKeyframe;
        }
        /**
         * @param {?} easing
         * @return {?}
         */

      }, {
        key: "applyEmptyStep",
        value: function applyEmptyStep(easing) {
          var _this12 = this;

          if (easing) {
            this._previousKeyframe['easing'] = easing;
          } // special case for animate(duration):
          // all missing styles are filled with a `*` value then
          // if any destination styles are filled in later on the same
          // keyframe then they will override the overridden styles
          // We use `_globalTimelineStyles` here because there may be
          // styles in previous keyframes that are not present in this timeline


          Object.keys(this._globalTimelineStyles).forEach(
          /**
          * @param {?} prop
          * @return {?}
          */
          function (prop) {
            _this12._backFill[prop] = _this12._globalTimelineStyles[prop] || _angular_animations__WEBPACK_IMPORTED_MODULE_0__["AUTO_STYLE"];
            _this12._currentKeyframe[prop] = _angular_animations__WEBPACK_IMPORTED_MODULE_0__["AUTO_STYLE"];
          });
          this._currentEmptyStepKeyframe = this._currentKeyframe;
        }
        /**
         * @param {?} input
         * @param {?} easing
         * @param {?} errors
         * @param {?=} options
         * @return {?}
         */

      }, {
        key: "setStyles",
        value: function setStyles(input, easing, errors, options) {
          var _this13 = this;

          if (easing) {
            this._previousKeyframe['easing'] = easing;
          }
          /** @type {?} */


          var params = options && options.params || {};
          /** @type {?} */

          var styles = flattenStyles(input, this._globalTimelineStyles);
          Object.keys(styles).forEach(
          /**
          * @param {?} prop
          * @return {?}
          */
          function (prop) {
            /** @type {?} */
            var val = interpolateParams(styles[prop], params, errors);
            _this13._pendingStyles[prop] = val;

            if (!_this13._localTimelineStyles.hasOwnProperty(prop)) {
              _this13._backFill[prop] = _this13._globalTimelineStyles.hasOwnProperty(prop) ? _this13._globalTimelineStyles[prop] : _angular_animations__WEBPACK_IMPORTED_MODULE_0__["AUTO_STYLE"];
            }

            _this13._updateStyle(prop, val);
          });
        }
        /**
         * @return {?}
         */

      }, {
        key: "applyStylesToKeyframe",
        value: function applyStylesToKeyframe() {
          var _this14 = this;

          /** @type {?} */
          var styles = this._pendingStyles;
          /** @type {?} */

          var props = Object.keys(styles);
          if (props.length == 0) return;
          this._pendingStyles = {};
          props.forEach(
          /**
          * @param {?} prop
          * @return {?}
          */
          function (prop) {
            /** @type {?} */
            var val = styles[prop];
            _this14._currentKeyframe[prop] = val;
          });
          Object.keys(this._localTimelineStyles).forEach(
          /**
          * @param {?} prop
          * @return {?}
          */
          function (prop) {
            if (!_this14._currentKeyframe.hasOwnProperty(prop)) {
              _this14._currentKeyframe[prop] = _this14._localTimelineStyles[prop];
            }
          });
        }
        /**
         * @return {?}
         */

      }, {
        key: "snapshotCurrentStyles",
        value: function snapshotCurrentStyles() {
          var _this15 = this;

          Object.keys(this._localTimelineStyles).forEach(
          /**
          * @param {?} prop
          * @return {?}
          */
          function (prop) {
            /** @type {?} */
            var val = _this15._localTimelineStyles[prop];
            _this15._pendingStyles[prop] = val;

            _this15._updateStyle(prop, val);
          });
        }
        /**
         * @return {?}
         */

      }, {
        key: "getFinalKeyframe",
        value: function getFinalKeyframe() {
          return this._keyframes.get(this.duration);
        }
        /**
         * @return {?}
         */

      }, {
        key: "mergeTimelineCollectedStyles",

        /**
         * @param {?} timeline
         * @return {?}
         */
        value: function mergeTimelineCollectedStyles(timeline) {
          var _this16 = this;

          Object.keys(timeline._styleSummary).forEach(
          /**
          * @param {?} prop
          * @return {?}
          */
          function (prop) {
            /** @type {?} */
            var details0 = _this16._styleSummary[prop];
            /** @type {?} */

            var details1 = timeline._styleSummary[prop];

            if (!details0 || details1.time > details0.time) {
              _this16._updateStyle(prop, details1.value);
            }
          });
        }
        /**
         * @return {?}
         */

      }, {
        key: "buildKeyframes",
        value: function buildKeyframes() {
          var _this17 = this;

          this.applyStylesToKeyframe();
          /** @type {?} */

          var preStyleProps = new Set();
          /** @type {?} */

          var postStyleProps = new Set();
          /** @type {?} */

          var isEmpty = this._keyframes.size === 1 && this.duration === 0;
          /** @type {?} */

          var finalKeyframes = [];

          this._keyframes.forEach(
          /**
          * @param {?} keyframe
          * @param {?} time
          * @return {?}
          */
          function (keyframe, time) {
            /** @type {?} */
            var finalKeyframe = copyStyles(keyframe, true);
            Object.keys(finalKeyframe).forEach(
            /**
            * @param {?} prop
            * @return {?}
            */
            function (prop) {
              /** @type {?} */
              var value = finalKeyframe[prop];

              if (value == _angular_animations__WEBPACK_IMPORTED_MODULE_0__["ɵPRE_STYLE"]) {
                preStyleProps.add(prop);
              } else if (value == _angular_animations__WEBPACK_IMPORTED_MODULE_0__["AUTO_STYLE"]) {
                postStyleProps.add(prop);
              }
            });

            if (!isEmpty) {
              finalKeyframe['offset'] = time / _this17.duration;
            }

            finalKeyframes.push(finalKeyframe);
          });
          /** @type {?} */


          var preProps = preStyleProps.size ? iteratorToArray(preStyleProps.values()) : [];
          /** @type {?} */

          var postProps = postStyleProps.size ? iteratorToArray(postStyleProps.values()) : []; // special case for a 0-second animation (which is designed just to place styles onscreen)

          if (isEmpty) {
            /** @type {?} */
            var kf0 = finalKeyframes[0];
            /** @type {?} */

            var kf1 = copyObj(kf0);
            kf0['offset'] = 0;
            kf1['offset'] = 1;
            finalKeyframes = [kf0, kf1];
          }

          return createTimelineInstruction(this.element, finalKeyframes, preProps, postProps, this.duration, this.startTime, this.easing, false);
        }
      }, {
        key: "currentTime",
        get: function get() {
          return this.startTime + this.duration;
        }
      }, {
        key: "properties",
        get: function get() {
          /** @type {?} */
          var properties = [];

          for (var prop in this._currentKeyframe) {
            properties.push(prop);
          }

          return properties;
        }
      }]);

      return TimelineBuilder;
    }();

    if (false) {}

    var SubTimelineBuilder = /*#__PURE__*/function (_TimelineBuilder) {
      _inherits(SubTimelineBuilder, _TimelineBuilder);

      var _super = _createSuper(SubTimelineBuilder);

      /**
       * @param {?} driver
       * @param {?} element
       * @param {?} keyframes
       * @param {?} preStyleProps
       * @param {?} postStyleProps
       * @param {?} timings
       * @param {?=} _stretchStartingKeyframe
       */
      function SubTimelineBuilder(driver, element, keyframes, preStyleProps, postStyleProps, timings) {
        var _this18;

        var _stretchStartingKeyframe = arguments.length > 6 && arguments[6] !== undefined ? arguments[6] : false;

        _classCallCheck(this, SubTimelineBuilder);

        _this18 = _super.call(this, driver, element, timings.delay);
        _this18.element = element;
        _this18.keyframes = keyframes;
        _this18.preStyleProps = preStyleProps;
        _this18.postStyleProps = postStyleProps;
        _this18._stretchStartingKeyframe = _stretchStartingKeyframe;
        _this18.timings = {
          duration: timings.duration,
          delay: timings.delay,
          easing: timings.easing
        };
        return _this18;
      }
      /**
       * @return {?}
       */


      _createClass2(SubTimelineBuilder, [{
        key: "containsAnimation",
        value: function containsAnimation() {
          return this.keyframes.length > 1;
        }
        /**
         * @return {?}
         */

      }, {
        key: "buildKeyframes",
        value: function buildKeyframes() {
          /** @type {?} */
          var keyframes = this.keyframes;
          var _this$timings = this.timings,
              delay = _this$timings.delay,
              duration = _this$timings.duration,
              easing = _this$timings.easing;

          if (this._stretchStartingKeyframe && delay) {
            /** @type {?} */
            var newKeyframes = [];
            /** @type {?} */

            var totalTime = duration + delay;
            /** @type {?} */

            var startingGap = delay / totalTime; // the original starting keyframe now starts once the delay is done

            /** @type {?} */

            var newFirstKeyframe = copyStyles(keyframes[0], false);
            newFirstKeyframe['offset'] = 0;
            newKeyframes.push(newFirstKeyframe);
            /** @type {?} */

            var oldFirstKeyframe = copyStyles(keyframes[0], false);
            oldFirstKeyframe['offset'] = roundOffset(startingGap);
            newKeyframes.push(oldFirstKeyframe);
            /*
                    When the keyframe is stretched then it means that the delay before the animation
                    starts is gone. Instead the first keyframe is placed at the start of the animation
                    and it is then copied to where it starts when the original delay is over. This basically
                    means nothing animates during that delay, but the styles are still renderered. For this
                    to work the original offset values that exist in the original keyframes must be "warped"
                    so that they can take the new keyframe + delay into account.
            
                    delay=1000, duration=1000, keyframes = 0 .5 1
            
                    turns into
            
                    delay=0, duration=2000, keyframes = 0 .33 .66 1
                   */
            // offsets between 1 ... n -1 are all warped by the keyframe stretch

            /** @type {?} */

            var limit = keyframes.length - 1;

            for (var i = 1; i <= limit; i++) {
              /** @type {?} */
              var kf = copyStyles(keyframes[i], false);
              /** @type {?} */

              var oldOffset =
              /** @type {?} */
              kf['offset'];
              /** @type {?} */

              var timeAtKeyframe = delay + oldOffset * duration;
              kf['offset'] = roundOffset(timeAtKeyframe / totalTime);
              newKeyframes.push(kf);
            } // the new starting keyframe should be added at the start


            duration = totalTime;
            delay = 0;
            easing = '';
            keyframes = newKeyframes;
          }

          return createTimelineInstruction(this.element, keyframes, this.preStyleProps, this.postStyleProps, duration, delay, easing, true);
        }
      }]);

      return SubTimelineBuilder;
    }(TimelineBuilder);

    if (false) {}
    /**
     * @param {?} offset
     * @param {?=} decimalPoints
     * @return {?}
     */


    function roundOffset(offset) {
      var decimalPoints = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 3;

      /** @type {?} */
      var mult = Math.pow(10, decimalPoints - 1);
      return Math.round(offset * mult) / mult;
    }
    /**
     * @param {?} input
     * @param {?} allStyles
     * @return {?}
     */


    function flattenStyles(input, allStyles) {
      /** @type {?} */
      var styles = {};
      /** @type {?} */

      var allProperties;
      input.forEach(
      /**
      * @param {?} token
      * @return {?}
      */
      function (token) {
        if (token === '*') {
          allProperties = allProperties || Object.keys(allStyles);
          allProperties.forEach(
          /**
          * @param {?} prop
          * @return {?}
          */
          function (prop) {
            styles[prop] = _angular_animations__WEBPACK_IMPORTED_MODULE_0__["AUTO_STYLE"];
          });
        } else {
          copyStyles(
          /** @type {?} */
          token, false, styles);
        }
      });
      return styles;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/dsl/animation.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var Animation = /*#__PURE__*/function () {
      /**
       * @param {?} _driver
       * @param {?} input
       */
      function Animation(_driver, input) {
        _classCallCheck(this, Animation);

        this._driver = _driver;
        /** @type {?} */

        var errors = [];
        /** @type {?} */

        var ast = buildAnimationAst(_driver, input, errors);

        if (errors.length) {
          /** @type {?} */
          var errorMessage = "animation validation failed:\n".concat(errors.join('\n'));
          throw new Error(errorMessage);
        }

        this._animationAst = ast;
      }
      /**
       * @param {?} element
       * @param {?} startingStyles
       * @param {?} destinationStyles
       * @param {?} options
       * @param {?=} subInstructions
       * @return {?}
       */


      _createClass2(Animation, [{
        key: "buildTimelines",
        value: function buildTimelines(element, startingStyles, destinationStyles, options, subInstructions) {
          /** @type {?} */
          var start = Array.isArray(startingStyles) ? normalizeStyles(startingStyles) :
          /** @type {?} */
          startingStyles;
          /** @type {?} */

          var dest = Array.isArray(destinationStyles) ? normalizeStyles(destinationStyles) :
          /** @type {?} */
          destinationStyles;
          /** @type {?} */

          var errors = [];
          subInstructions = subInstructions || new ElementInstructionMap();
          /** @type {?} */

          var result = buildAnimationTimelines(this._driver, element, this._animationAst, ENTER_CLASSNAME, LEAVE_CLASSNAME, start, dest, options, subInstructions, errors);

          if (errors.length) {
            /** @type {?} */
            var errorMessage = "animation building failed:\n".concat(errors.join('\n'));
            throw new Error(errorMessage);
          }

          return result;
        }
      }]);

      return Animation;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/dsl/style_normalization/animation_style_normalizer.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * \@publicApi
     * @abstract
     */


    var AnimationStyleNormalizer = function AnimationStyleNormalizer() {
      _classCallCheck(this, AnimationStyleNormalizer);
    };

    if (false) {}
    /**
     * \@publicApi
     */


    var NoopAnimationStyleNormalizer = /*#__PURE__*/function () {
      function NoopAnimationStyleNormalizer() {
        _classCallCheck(this, NoopAnimationStyleNormalizer);
      }

      _createClass2(NoopAnimationStyleNormalizer, [{
        key: "normalizePropertyName",

        /**
         * @param {?} propertyName
         * @param {?} errors
         * @return {?}
         */
        value: function normalizePropertyName(propertyName, errors) {
          return propertyName;
        }
        /**
         * @param {?} userProvidedProperty
         * @param {?} normalizedProperty
         * @param {?} value
         * @param {?} errors
         * @return {?}
         */

      }, {
        key: "normalizeStyleValue",
        value: function normalizeStyleValue(userProvidedProperty, normalizedProperty, value, errors) {
          return (
            /** @type {?} */
            value
          );
        }
      }]);

      return NoopAnimationStyleNormalizer;
    }();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/dsl/style_normalization/web_animations_style_normalizer.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var WebAnimationsStyleNormalizer = /*#__PURE__*/function (_AnimationStyleNormal) {
      _inherits(WebAnimationsStyleNormalizer, _AnimationStyleNormal);

      var _super2 = _createSuper(WebAnimationsStyleNormalizer);

      function WebAnimationsStyleNormalizer() {
        _classCallCheck(this, WebAnimationsStyleNormalizer);

        return _super2.apply(this, arguments);
      }

      _createClass2(WebAnimationsStyleNormalizer, [{
        key: "normalizePropertyName",

        /**
         * @param {?} propertyName
         * @param {?} errors
         * @return {?}
         */
        value: function normalizePropertyName(propertyName, errors) {
          return dashCaseToCamelCase(propertyName);
        }
        /**
         * @param {?} userProvidedProperty
         * @param {?} normalizedProperty
         * @param {?} value
         * @param {?} errors
         * @return {?}
         */

      }, {
        key: "normalizeStyleValue",
        value: function normalizeStyleValue(userProvidedProperty, normalizedProperty, value, errors) {
          /** @type {?} */
          var unit = '';
          /** @type {?} */

          var strVal = value.toString().trim();

          if (DIMENSIONAL_PROP_MAP[normalizedProperty] && value !== 0 && value !== '0') {
            if (typeof value === 'number') {
              unit = 'px';
            } else {
              /** @type {?} */
              var valAndSuffixMatch = value.match(/^[+-]?[\d\.]+([a-z]*)$/);

              if (valAndSuffixMatch && valAndSuffixMatch[1].length == 0) {
                errors.push("Please provide a CSS unit value for ".concat(userProvidedProperty, ":").concat(value));
              }
            }
          }

          return strVal + unit;
        }
      }]);

      return WebAnimationsStyleNormalizer;
    }(AnimationStyleNormalizer);

    var ɵ0$1 =
    /**
    * @return {?}
    */
    function ɵ0$1() {
      return makeBooleanMap('width,height,minWidth,minHeight,maxWidth,maxHeight,left,top,bottom,right,fontSize,outlineWidth,outlineOffset,paddingTop,paddingLeft,paddingBottom,paddingRight,marginTop,marginLeft,marginBottom,marginRight,borderRadius,borderWidth,borderTopWidth,borderLeftWidth,borderRightWidth,borderBottomWidth,textIndent,perspective'.split(','));
    };
    /** @type {?} */


    var DIMENSIONAL_PROP_MAP = ɵ0$1();
    /**
     * @param {?} keys
     * @return {?}
     */

    function makeBooleanMap(keys) {
      /** @type {?} */
      var map = {};
      keys.forEach(
      /**
      * @param {?} key
      * @return {?}
      */
      function (key) {
        return map[key] = true;
      });
      return map;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/dsl/animation_transition_instruction.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @record
     */


    function AnimationTransitionInstruction() {}

    if (false) {}
    /**
     * @param {?} element
     * @param {?} triggerName
     * @param {?} fromState
     * @param {?} toState
     * @param {?} isRemovalTransition
     * @param {?} fromStyles
     * @param {?} toStyles
     * @param {?} timelines
     * @param {?} queriedElements
     * @param {?} preStyleProps
     * @param {?} postStyleProps
     * @param {?} totalTime
     * @param {?=} errors
     * @return {?}
     */


    function createTransitionInstruction(element, triggerName, fromState, toState, isRemovalTransition, fromStyles, toStyles, timelines, queriedElements, preStyleProps, postStyleProps, totalTime, errors) {
      return {
        type: 0
        /* TransitionAnimation */
        ,
        element: element,
        triggerName: triggerName,
        isRemovalTransition: isRemovalTransition,
        fromState: fromState,
        fromStyles: fromStyles,
        toState: toState,
        toStyles: toStyles,
        timelines: timelines,
        queriedElements: queriedElements,
        preStyleProps: preStyleProps,
        postStyleProps: postStyleProps,
        totalTime: totalTime,
        errors: errors
      };
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/dsl/animation_transition_factory.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var EMPTY_OBJECT = {};

    var AnimationTransitionFactory = /*#__PURE__*/function () {
      /**
       * @param {?} _triggerName
       * @param {?} ast
       * @param {?} _stateStyles
       */
      function AnimationTransitionFactory(_triggerName, ast, _stateStyles) {
        _classCallCheck(this, AnimationTransitionFactory);

        this._triggerName = _triggerName;
        this.ast = ast;
        this._stateStyles = _stateStyles;
      }
      /**
       * @param {?} currentState
       * @param {?} nextState
       * @param {?} element
       * @param {?} params
       * @return {?}
       */


      _createClass2(AnimationTransitionFactory, [{
        key: "match",
        value: function match(currentState, nextState, element, params) {
          return oneOrMoreTransitionsMatch(this.ast.matchers, currentState, nextState, element, params);
        }
        /**
         * @param {?} stateName
         * @param {?} params
         * @param {?} errors
         * @return {?}
         */

      }, {
        key: "buildStyles",
        value: function buildStyles(stateName, params, errors) {
          /** @type {?} */
          var backupStateStyler = this._stateStyles['*'];
          /** @type {?} */

          var stateStyler = this._stateStyles[stateName];
          /** @type {?} */

          var backupStyles = backupStateStyler ? backupStateStyler.buildStyles(params, errors) : {};
          return stateStyler ? stateStyler.buildStyles(params, errors) : backupStyles;
        }
        /**
         * @param {?} driver
         * @param {?} element
         * @param {?} currentState
         * @param {?} nextState
         * @param {?} enterClassName
         * @param {?} leaveClassName
         * @param {?=} currentOptions
         * @param {?=} nextOptions
         * @param {?=} subInstructions
         * @param {?=} skipAstBuild
         * @return {?}
         */

      }, {
        key: "build",
        value: function build(driver, element, currentState, nextState, enterClassName, leaveClassName, currentOptions, nextOptions, subInstructions, skipAstBuild) {
          /** @type {?} */
          var errors = [];
          /** @type {?} */

          var transitionAnimationParams = this.ast.options && this.ast.options.params || EMPTY_OBJECT;
          /** @type {?} */

          var currentAnimationParams = currentOptions && currentOptions.params || EMPTY_OBJECT;
          /** @type {?} */

          var currentStateStyles = this.buildStyles(currentState, currentAnimationParams, errors);
          /** @type {?} */

          var nextAnimationParams = nextOptions && nextOptions.params || EMPTY_OBJECT;
          /** @type {?} */

          var nextStateStyles = this.buildStyles(nextState, nextAnimationParams, errors);
          /** @type {?} */

          var queriedElements = new Set();
          /** @type {?} */

          var preStyleMap = new Map();
          /** @type {?} */

          var postStyleMap = new Map();
          /** @type {?} */

          var isRemoval = nextState === 'void';
          /** @type {?} */

          var animationOptions = {
            params: Object.assign(Object.assign({}, transitionAnimationParams), nextAnimationParams)
          };
          /** @type {?} */

          var timelines = skipAstBuild ? [] : buildAnimationTimelines(driver, element, this.ast.animation, enterClassName, leaveClassName, currentStateStyles, nextStateStyles, animationOptions, subInstructions, errors);
          /** @type {?} */

          var totalTime = 0;
          timelines.forEach(
          /**
          * @param {?} tl
          * @return {?}
          */
          function (tl) {
            totalTime = Math.max(tl.duration + tl.delay, totalTime);
          });

          if (errors.length) {
            return createTransitionInstruction(element, this._triggerName, currentState, nextState, isRemoval, currentStateStyles, nextStateStyles, [], [], preStyleMap, postStyleMap, totalTime, errors);
          }

          timelines.forEach(
          /**
          * @param {?} tl
          * @return {?}
          */
          function (tl) {
            /** @type {?} */
            var elm = tl.element;
            /** @type {?} */

            var preProps = getOrSetAsInMap(preStyleMap, elm, {});
            tl.preStyleProps.forEach(
            /**
            * @param {?} prop
            * @return {?}
            */
            function (prop) {
              return preProps[prop] = true;
            });
            /** @type {?} */

            var postProps = getOrSetAsInMap(postStyleMap, elm, {});
            tl.postStyleProps.forEach(
            /**
            * @param {?} prop
            * @return {?}
            */
            function (prop) {
              return postProps[prop] = true;
            });

            if (elm !== element) {
              queriedElements.add(elm);
            }
          });
          /** @type {?} */

          var queriedElementsList = iteratorToArray(queriedElements.values());
          return createTransitionInstruction(element, this._triggerName, currentState, nextState, isRemoval, currentStateStyles, nextStateStyles, timelines, queriedElementsList, preStyleMap, postStyleMap, totalTime);
        }
      }]);

      return AnimationTransitionFactory;
    }();

    if (false) {}
    /**
     * @param {?} matchFns
     * @param {?} currentState
     * @param {?} nextState
     * @param {?} element
     * @param {?} params
     * @return {?}
     */


    function oneOrMoreTransitionsMatch(matchFns, currentState, nextState, element, params) {
      return matchFns.some(
      /**
      * @param {?} fn
      * @return {?}
      */
      function (fn) {
        return fn(currentState, nextState, element, params);
      });
    }

    var AnimationStateStyles = /*#__PURE__*/function () {
      /**
       * @param {?} styles
       * @param {?} defaultParams
       */
      function AnimationStateStyles(styles, defaultParams) {
        _classCallCheck(this, AnimationStateStyles);

        this.styles = styles;
        this.defaultParams = defaultParams;
      }
      /**
       * @param {?} params
       * @param {?} errors
       * @return {?}
       */


      _createClass2(AnimationStateStyles, [{
        key: "buildStyles",
        value: function buildStyles(params, errors) {
          /** @type {?} */
          var finalStyles = {};
          /** @type {?} */

          var combinedParams = copyObj(this.defaultParams);
          Object.keys(params).forEach(
          /**
          * @param {?} key
          * @return {?}
          */
          function (key) {
            /** @type {?} */
            var value = params[key];

            if (value != null) {
              combinedParams[key] = value;
            }
          });
          this.styles.styles.forEach(
          /**
          * @param {?} value
          * @return {?}
          */
          function (value) {
            if (typeof value !== 'string') {
              /** @type {?} */
              var styleObj =
              /** @type {?} */
              value;
              Object.keys(styleObj).forEach(
              /**
              * @param {?} prop
              * @return {?}
              */
              function (prop) {
                /** @type {?} */
                var val = styleObj[prop];

                if (val.length > 1) {
                  val = interpolateParams(val, combinedParams, errors);
                }

                finalStyles[prop] = val;
              });
            }
          });
          return finalStyles;
        }
      }]);

      return AnimationStateStyles;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/dsl/animation_trigger.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@publicApi
     * @param {?} name
     * @param {?} ast
     * @return {?}
     */


    function buildTrigger(name, ast) {
      return new AnimationTrigger(name, ast);
    }
    /**
     * \@publicApi
     */


    var AnimationTrigger = /*#__PURE__*/function () {
      /**
       * @param {?} name
       * @param {?} ast
       */
      function AnimationTrigger(name, ast) {
        var _this19 = this;

        _classCallCheck(this, AnimationTrigger);

        this.name = name;
        this.ast = ast;
        this.transitionFactories = [];
        this.states = {};
        ast.states.forEach(
        /**
        * @param {?} ast
        * @return {?}
        */
        function (ast) {
          /** @type {?} */
          var defaultParams = ast.options && ast.options.params || {};
          _this19.states[ast.name] = new AnimationStateStyles(ast.style, defaultParams);
        });
        balanceProperties(this.states, 'true', '1');
        balanceProperties(this.states, 'false', '0');
        ast.transitions.forEach(
        /**
        * @param {?} ast
        * @return {?}
        */
        function (ast) {
          _this19.transitionFactories.push(new AnimationTransitionFactory(name, ast, _this19.states));
        });
        this.fallbackTransition = createFallbackTransition(name, this.states);
      }
      /**
       * @return {?}
       */


      _createClass2(AnimationTrigger, [{
        key: "matchTransition",

        /**
         * @param {?} currentState
         * @param {?} nextState
         * @param {?} element
         * @param {?} params
         * @return {?}
         */
        value: function matchTransition(currentState, nextState, element, params) {
          /** @type {?} */
          var entry = this.transitionFactories.find(
          /**
          * @param {?} f
          * @return {?}
          */
          function (f) {
            return f.match(currentState, nextState, element, params);
          });
          return entry || null;
        }
        /**
         * @param {?} currentState
         * @param {?} params
         * @param {?} errors
         * @return {?}
         */

      }, {
        key: "matchStyles",
        value: function matchStyles(currentState, params, errors) {
          return this.fallbackTransition.buildStyles(currentState, params, errors);
        }
      }, {
        key: "containsQueries",
        get: function get() {
          return this.ast.queryCount > 0;
        }
      }]);

      return AnimationTrigger;
    }();

    if (false) {}
    /**
     * @param {?} triggerName
     * @param {?} states
     * @return {?}
     */


    function createFallbackTransition(triggerName, states) {
      /** @type {?} */
      var matchers = [
      /**
      * @param {?} fromState
      * @param {?} toState
      * @return {?}
      */
      function (fromState, toState) {
        return true;
      }];
      /** @type {?} */

      var animation = {
        type: 2
        /* Sequence */
        ,
        steps: [],
        options: null
      };
      /** @type {?} */

      var transition = {
        type: 1
        /* Transition */
        ,
        animation: animation,
        matchers: matchers,
        options: null,
        queryCount: 0,
        depCount: 0
      };
      return new AnimationTransitionFactory(triggerName, transition, states);
    }
    /**
     * @param {?} obj
     * @param {?} key1
     * @param {?} key2
     * @return {?}
     */


    function balanceProperties(obj, key1, key2) {
      if (obj.hasOwnProperty(key1)) {
        if (!obj.hasOwnProperty(key2)) {
          obj[key2] = obj[key1];
        }
      } else if (obj.hasOwnProperty(key2)) {
        obj[key1] = obj[key2];
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/render/timeline_animation_engine.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var EMPTY_INSTRUCTION_MAP = new ElementInstructionMap();

    var TimelineAnimationEngine = /*#__PURE__*/function () {
      /**
       * @param {?} bodyNode
       * @param {?} _driver
       * @param {?} _normalizer
       */
      function TimelineAnimationEngine(bodyNode, _driver, _normalizer) {
        _classCallCheck(this, TimelineAnimationEngine);

        this.bodyNode = bodyNode;
        this._driver = _driver;
        this._normalizer = _normalizer;
        this._animations = {};
        this._playersById = {};
        this.players = [];
      }
      /**
       * @param {?} id
       * @param {?} metadata
       * @return {?}
       */


      _createClass2(TimelineAnimationEngine, [{
        key: "register",
        value: function register(id, metadata) {
          /** @type {?} */
          var errors = [];
          /** @type {?} */

          var ast = buildAnimationAst(this._driver, metadata, errors);

          if (errors.length) {
            throw new Error("Unable to build the animation due to the following errors: ".concat(errors.join('\n')));
          } else {
            this._animations[id] = ast;
          }
        }
        /**
         * @private
         * @param {?} i
         * @param {?} preStyles
         * @param {?=} postStyles
         * @return {?}
         */

      }, {
        key: "_buildPlayer",
        value: function _buildPlayer(i, preStyles, postStyles) {
          /** @type {?} */
          var element = i.element;
          /** @type {?} */

          var keyframes = normalizeKeyframes(this._driver, this._normalizer, element, i.keyframes, preStyles, postStyles);
          return this._driver.animate(element, keyframes, i.duration, i.delay, i.easing, [], true);
        }
        /**
         * @param {?} id
         * @param {?} element
         * @param {?=} options
         * @return {?}
         */

      }, {
        key: "create",
        value: function create(id, element) {
          var _this20 = this;

          var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};

          /** @type {?} */
          var errors = [];
          /** @type {?} */

          var ast = this._animations[id];
          /** @type {?} */

          var instructions;
          /** @type {?} */

          var autoStylesMap = new Map();

          if (ast) {
            instructions = buildAnimationTimelines(this._driver, element, ast, ENTER_CLASSNAME, LEAVE_CLASSNAME, {}, {}, options, EMPTY_INSTRUCTION_MAP, errors);
            instructions.forEach(
            /**
            * @param {?} inst
            * @return {?}
            */
            function (inst) {
              /** @type {?} */
              var styles = getOrSetAsInMap(autoStylesMap, inst.element, {});
              inst.postStyleProps.forEach(
              /**
              * @param {?} prop
              * @return {?}
              */
              function (prop) {
                return styles[prop] = null;
              });
            });
          } else {
            errors.push('The requested animation doesn\'t exist or has already been destroyed');
            instructions = [];
          }

          if (errors.length) {
            throw new Error("Unable to create the animation due to the following errors: ".concat(errors.join('\n')));
          }

          autoStylesMap.forEach(
          /**
          * @param {?} styles
          * @param {?} element
          * @return {?}
          */
          function (styles, element) {
            Object.keys(styles).forEach(
            /**
            * @param {?} prop
            * @return {?}
            */
            function (prop) {
              styles[prop] = _this20._driver.computeStyle(element, prop, _angular_animations__WEBPACK_IMPORTED_MODULE_0__["AUTO_STYLE"]);
            });
          });
          /** @type {?} */

          var players = instructions.map(
          /**
          * @param {?} i
          * @return {?}
          */
          function (i) {
            /** @type {?} */
            var styles = autoStylesMap.get(i.element);
            return _this20._buildPlayer(i, {}, styles);
          });
          /** @type {?} */

          var player = optimizeGroupPlayer(players);
          this._playersById[id] = player;
          player.onDestroy(
          /**
          * @return {?}
          */
          function () {
            return _this20.destroy(id);
          });
          this.players.push(player);
          return player;
        }
        /**
         * @param {?} id
         * @return {?}
         */

      }, {
        key: "destroy",
        value: function destroy(id) {
          /** @type {?} */
          var player = this._getPlayer(id);

          player.destroy();
          delete this._playersById[id];
          /** @type {?} */

          var index = this.players.indexOf(player);

          if (index >= 0) {
            this.players.splice(index, 1);
          }
        }
        /**
         * @private
         * @param {?} id
         * @return {?}
         */

      }, {
        key: "_getPlayer",
        value: function _getPlayer(id) {
          /** @type {?} */
          var player = this._playersById[id];

          if (!player) {
            throw new Error("Unable to find the timeline player referenced by ".concat(id));
          }

          return player;
        }
        /**
         * @param {?} id
         * @param {?} element
         * @param {?} eventName
         * @param {?} callback
         * @return {?}
         */

      }, {
        key: "listen",
        value: function listen(id, element, eventName, callback) {
          // triggerName, fromState, toState are all ignored for timeline animations

          /** @type {?} */
          var baseEvent = makeAnimationEvent(element, '', '', '');
          listenOnPlayer(this._getPlayer(id), eventName, baseEvent, callback);
          return (
            /**
            * @return {?}
            */
            function () {}
          );
        }
        /**
         * @param {?} id
         * @param {?} element
         * @param {?} command
         * @param {?} args
         * @return {?}
         */

      }, {
        key: "command",
        value: function command(id, element, _command, args) {
          if (_command == 'register') {
            this.register(id,
            /** @type {?} */
            args[0]);
            return;
          }

          if (_command == 'create') {
            /** @type {?} */
            var options =
            /** @type {?} */
            args[0] || {};
            this.create(id, element, options);
            return;
          }
          /** @type {?} */


          var player = this._getPlayer(id);

          switch (_command) {
            case 'play':
              player.play();
              break;

            case 'pause':
              player.pause();
              break;

            case 'reset':
              player.reset();
              break;

            case 'restart':
              player.restart();
              break;

            case 'finish':
              player.finish();
              break;

            case 'init':
              player.init();
              break;

            case 'setPosition':
              player.setPosition(parseFloat(
              /** @type {?} */
              args[0]));
              break;

            case 'destroy':
              this.destroy(id);
              break;
          }
        }
      }]);

      return TimelineAnimationEngine;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/render/transition_animation_engine.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var QUEUED_CLASSNAME = 'ng-animate-queued';
    /** @type {?} */

    var QUEUED_SELECTOR = '.ng-animate-queued';
    /** @type {?} */

    var DISABLED_CLASSNAME = 'ng-animate-disabled';
    /** @type {?} */

    var DISABLED_SELECTOR = '.ng-animate-disabled';
    /** @type {?} */

    var STAR_CLASSNAME = 'ng-star-inserted';
    /** @type {?} */

    var STAR_SELECTOR = '.ng-star-inserted';
    /** @type {?} */

    var EMPTY_PLAYER_ARRAY = [];
    /** @type {?} */

    var NULL_REMOVAL_STATE = {
      namespaceId: '',
      setForRemoval: false,
      setForMove: false,
      hasAnimation: false,
      removedBeforeQueried: false
    };
    /** @type {?} */

    var NULL_REMOVED_QUERIED_STATE = {
      namespaceId: '',
      setForMove: false,
      setForRemoval: false,
      hasAnimation: false,
      removedBeforeQueried: true
    };
    /**
     * @record
     */

    function TriggerListener() {}

    if (false) {}
    /**
     * @record
     */


    function QueueInstruction() {}

    if (false) {}
    /** @type {?} */


    var REMOVAL_FLAG = '__ng_removed';
    /**
     * @record
     */

    function ElementAnimationState() {}

    if (false) {}

    var StateValue = /*#__PURE__*/function () {
      /**
       * @param {?} input
       * @param {?=} namespaceId
       */
      function StateValue(input) {
        var namespaceId = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';

        _classCallCheck(this, StateValue);

        this.namespaceId = namespaceId;
        /** @type {?} */

        var isObj = input && input.hasOwnProperty('value');
        /** @type {?} */

        var value = isObj ? input['value'] : input;
        this.value = normalizeTriggerValue(value);

        if (isObj) {
          /** @type {?} */
          var options = copyObj(
          /** @type {?} */
          input);
          delete options['value'];
          this.options =
          /** @type {?} */
          options;
        } else {
          this.options = {};
        }

        if (!this.options.params) {
          this.options.params = {};
        }
      }
      /**
       * @return {?}
       */


      _createClass2(StateValue, [{
        key: "absorbOptions",

        /**
         * @param {?} options
         * @return {?}
         */
        value: function absorbOptions(options) {
          /** @type {?} */
          var newParams = options.params;

          if (newParams) {
            /** @type {?} */
            var oldParams =
            /** @type {?} */
            this.options.params;
            Object.keys(newParams).forEach(
            /**
            * @param {?} prop
            * @return {?}
            */
            function (prop) {
              if (oldParams[prop] == null) {
                oldParams[prop] = newParams[prop];
              }
            });
          }
        }
      }, {
        key: "params",
        get: function get() {
          return (
            /** @type {?} */
            this.options.params
          );
        }
      }]);

      return StateValue;
    }();

    if (false) {}
    /** @type {?} */


    var VOID_VALUE = 'void';
    /** @type {?} */

    var DEFAULT_STATE_VALUE = new StateValue(VOID_VALUE);

    var AnimationTransitionNamespace = /*#__PURE__*/function () {
      /**
       * @param {?} id
       * @param {?} hostElement
       * @param {?} _engine
       */
      function AnimationTransitionNamespace(id, hostElement, _engine) {
        _classCallCheck(this, AnimationTransitionNamespace);

        this.id = id;
        this.hostElement = hostElement;
        this._engine = _engine;
        this.players = [];
        this._triggers = {};
        this._queue = [];
        this._elementListeners = new Map();
        this._hostClassName = 'ng-tns-' + id;
        addClass(hostElement, this._hostClassName);
      }
      /**
       * @param {?} element
       * @param {?} name
       * @param {?} phase
       * @param {?} callback
       * @return {?}
       */


      _createClass2(AnimationTransitionNamespace, [{
        key: "listen",
        value: function listen(element, name, phase, callback) {
          var _this21 = this;

          if (!this._triggers.hasOwnProperty(name)) {
            throw new Error("Unable to listen on the animation trigger event \"".concat(phase, "\" because the animation trigger \"").concat(name, "\" doesn't exist!"));
          }

          if (phase == null || phase.length == 0) {
            throw new Error("Unable to listen on the animation trigger \"".concat(name, "\" because the provided event is undefined!"));
          }

          if (!isTriggerEventValid(phase)) {
            throw new Error("The provided animation trigger event \"".concat(phase, "\" for the animation trigger \"").concat(name, "\" is not supported!"));
          }
          /** @type {?} */


          var listeners = getOrSetAsInMap(this._elementListeners, element, []);
          /** @type {?} */

          var data = {
            name: name,
            phase: phase,
            callback: callback
          };
          listeners.push(data);
          /** @type {?} */

          var triggersWithStates = getOrSetAsInMap(this._engine.statesByElement, element, {});

          if (!triggersWithStates.hasOwnProperty(name)) {
            addClass(element, NG_TRIGGER_CLASSNAME);
            addClass(element, NG_TRIGGER_CLASSNAME + '-' + name);
            triggersWithStates[name] = DEFAULT_STATE_VALUE;
          }

          return (
            /**
            * @return {?}
            */
            function () {
              // the event listener is removed AFTER the flush has occurred such
              // that leave animations callbacks can fire (otherwise if the node
              // is removed in between then the listeners would be deregistered)
              _this21._engine.afterFlush(
              /**
              * @return {?}
              */
              function () {
                /** @type {?} */
                var index = listeners.indexOf(data);

                if (index >= 0) {
                  listeners.splice(index, 1);
                }

                if (!_this21._triggers[name]) {
                  delete triggersWithStates[name];
                }
              });
            }
          );
        }
        /**
         * @param {?} name
         * @param {?} ast
         * @return {?}
         */

      }, {
        key: "register",
        value: function register(name, ast) {
          if (this._triggers[name]) {
            // throw
            return false;
          } else {
            this._triggers[name] = ast;
            return true;
          }
        }
        /**
         * @private
         * @param {?} name
         * @return {?}
         */

      }, {
        key: "_getTrigger",
        value: function _getTrigger(name) {
          /** @type {?} */
          var trigger = this._triggers[name];

          if (!trigger) {
            throw new Error("The provided animation trigger \"".concat(name, "\" has not been registered!"));
          }

          return trigger;
        }
        /**
         * @param {?} element
         * @param {?} triggerName
         * @param {?} value
         * @param {?=} defaultToFallback
         * @return {?}
         */

      }, {
        key: "trigger",
        value: function trigger(element, triggerName, value) {
          var _this22 = this;

          var defaultToFallback = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : true;

          /** @type {?} */
          var trigger = this._getTrigger(triggerName);
          /** @type {?} */


          var player = new TransitionAnimationPlayer(this.id, triggerName, element);
          /** @type {?} */

          var triggersWithStates = this._engine.statesByElement.get(element);

          if (!triggersWithStates) {
            addClass(element, NG_TRIGGER_CLASSNAME);
            addClass(element, NG_TRIGGER_CLASSNAME + '-' + triggerName);

            this._engine.statesByElement.set(element, triggersWithStates = {});
          }
          /** @type {?} */


          var fromState = triggersWithStates[triggerName];
          /** @type {?} */

          var toState = new StateValue(value, this.id);
          /** @type {?} */

          var isObj = value && value.hasOwnProperty('value');

          if (!isObj && fromState) {
            toState.absorbOptions(fromState.options);
          }

          triggersWithStates[triggerName] = toState;

          if (!fromState) {
            fromState = DEFAULT_STATE_VALUE;
          }
          /** @type {?} */


          var isRemoval = toState.value === VOID_VALUE; // normally this isn't reached by here, however, if an object expression
          // is passed in then it may be a new object each time. Comparing the value
          // is important since that will stay the same despite there being a new object.
          // The removal arc here is special cased because the same element is triggered
          // twice in the event that it contains animations on the outer/inner portions
          // of the host container

          if (!isRemoval && fromState.value === toState.value) {
            // this means that despite the value not changing, some inner params
            // have changed which means that the animation final styles need to be applied
            if (!objEquals(fromState.params, toState.params)) {
              /** @type {?} */
              var errors = [];
              /** @type {?} */

              var fromStyles = trigger.matchStyles(fromState.value, fromState.params, errors);
              /** @type {?} */

              var toStyles = trigger.matchStyles(toState.value, toState.params, errors);

              if (errors.length) {
                this._engine.reportError(errors);
              } else {
                this._engine.afterFlush(
                /**
                * @return {?}
                */
                function () {
                  eraseStyles(element, fromStyles);
                  setStyles(element, toStyles);
                });
              }
            }

            return;
          }
          /** @type {?} */


          var playersOnElement = getOrSetAsInMap(this._engine.playersByElement, element, []);
          playersOnElement.forEach(
          /**
          * @param {?} player
          * @return {?}
          */
          function (player) {
            // only remove the player if it is queued on the EXACT same trigger/namespace
            // we only also deal with queued players here because if the animation has
            // started then we want to keep the player alive until the flush happens
            // (which is where the previousPlayers are passed into the new palyer)
            if (player.namespaceId == _this22.id && player.triggerName == triggerName && player.queued) {
              player.destroy();
            }
          });
          /** @type {?} */

          var transition = trigger.matchTransition(fromState.value, toState.value, element, toState.params);
          /** @type {?} */

          var isFallbackTransition = false;

          if (!transition) {
            if (!defaultToFallback) return;
            transition = trigger.fallbackTransition;
            isFallbackTransition = true;
          }

          this._engine.totalQueuedPlayers++;

          this._queue.push({
            element: element,
            triggerName: triggerName,
            transition: transition,
            fromState: fromState,
            toState: toState,
            player: player,
            isFallbackTransition: isFallbackTransition
          });

          if (!isFallbackTransition) {
            addClass(element, QUEUED_CLASSNAME);
            player.onStart(
            /**
            * @return {?}
            */
            function () {
              removeClass(element, QUEUED_CLASSNAME);
            });
          }

          player.onDone(
          /**
          * @return {?}
          */
          function () {
            /** @type {?} */
            var index = _this22.players.indexOf(player);

            if (index >= 0) {
              _this22.players.splice(index, 1);
            }
            /** @type {?} */


            var players = _this22._engine.playersByElement.get(element);

            if (players) {
              /** @type {?} */
              var _index = players.indexOf(player);

              if (_index >= 0) {
                players.splice(_index, 1);
              }
            }
          });
          this.players.push(player);
          playersOnElement.push(player);
          return player;
        }
        /**
         * @param {?} name
         * @return {?}
         */

      }, {
        key: "deregister",
        value: function deregister(name) {
          var _this23 = this;

          delete this._triggers[name];

          this._engine.statesByElement.forEach(
          /**
          * @param {?} stateMap
          * @param {?} element
          * @return {?}
          */
          function (stateMap, element) {
            delete stateMap[name];
          });

          this._elementListeners.forEach(
          /**
          * @param {?} listeners
          * @param {?} element
          * @return {?}
          */
          function (listeners, element) {
            _this23._elementListeners.set(element, listeners.filter(
            /**
            * @param {?} entry
            * @return {?}
            */
            function (entry) {
              return entry.name != name;
            }));
          });
        }
        /**
         * @param {?} element
         * @return {?}
         */

      }, {
        key: "clearElementCache",
        value: function clearElementCache(element) {
          this._engine.statesByElement["delete"](element);

          this._elementListeners["delete"](element);
          /** @type {?} */


          var elementPlayers = this._engine.playersByElement.get(element);

          if (elementPlayers) {
            elementPlayers.forEach(
            /**
            * @param {?} player
            * @return {?}
            */
            function (player) {
              return player.destroy();
            });

            this._engine.playersByElement["delete"](element);
          }
        }
        /**
         * @private
         * @param {?} rootElement
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "_signalRemovalForInnerTriggers",
        value: function _signalRemovalForInnerTriggers(rootElement, context) {
          var _this24 = this;

          /** @type {?} */
          var elements = this._engine.driver.query(rootElement, NG_TRIGGER_SELECTOR, true); // emulate a leave animation for all inner nodes within this node.
          // If there are no animations found for any of the nodes then clear the cache
          // for the element.


          elements.forEach(
          /**
          * @param {?} elm
          * @return {?}
          */
          function (elm) {
            // this means that an inner remove() operation has already kicked off
            // the animation on this element...
            if (elm[REMOVAL_FLAG]) return;
            /** @type {?} */

            var namespaces = _this24._engine.fetchNamespacesByElement(elm);

            if (namespaces.size) {
              namespaces.forEach(
              /**
              * @param {?} ns
              * @return {?}
              */
              function (ns) {
                return ns.triggerLeaveAnimation(elm, context, false, true);
              });
            } else {
              _this24.clearElementCache(elm);
            }
          }); // If the child elements were removed along with the parent, their animations might not
          // have completed. Clear all the elements from the cache so we don't end up with a memory leak.

          this._engine.afterFlushAnimationsDone(
          /**
          * @return {?}
          */
          function () {
            return elements.forEach(
            /**
            * @param {?} elm
            * @return {?}
            */
            function (elm) {
              return _this24.clearElementCache(elm);
            });
          });
        }
        /**
         * @param {?} element
         * @param {?} context
         * @param {?=} destroyAfterComplete
         * @param {?=} defaultToFallback
         * @return {?}
         */

      }, {
        key: "triggerLeaveAnimation",
        value: function triggerLeaveAnimation(element, context, destroyAfterComplete, defaultToFallback) {
          var _this25 = this;

          /** @type {?} */
          var triggerStates = this._engine.statesByElement.get(element);

          if (triggerStates) {
            /** @type {?} */
            var players = [];
            Object.keys(triggerStates).forEach(
            /**
            * @param {?} triggerName
            * @return {?}
            */
            function (triggerName) {
              // this check is here in the event that an element is removed
              // twice (both on the host level and the component level)
              if (_this25._triggers[triggerName]) {
                /** @type {?} */
                var player = _this25.trigger(element, triggerName, VOID_VALUE, defaultToFallback);

                if (player) {
                  players.push(player);
                }
              }
            });

            if (players.length) {
              this._engine.markElementAsRemoved(this.id, element, true, context);

              if (destroyAfterComplete) {
                optimizeGroupPlayer(players).onDone(
                /**
                * @return {?}
                */
                function () {
                  return _this25._engine.processLeaveNode(element);
                });
              }

              return true;
            }
          }

          return false;
        }
        /**
         * @param {?} element
         * @return {?}
         */

      }, {
        key: "prepareLeaveAnimationListeners",
        value: function prepareLeaveAnimationListeners(element) {
          var _this26 = this;

          /** @type {?} */
          var listeners = this._elementListeners.get(element);

          if (listeners) {
            /** @type {?} */
            var visitedTriggers = new Set();
            listeners.forEach(
            /**
            * @param {?} listener
            * @return {?}
            */
            function (listener) {
              /** @type {?} */
              var triggerName = listener.name;
              if (visitedTriggers.has(triggerName)) return;
              visitedTriggers.add(triggerName);
              /** @type {?} */

              var trigger = _this26._triggers[triggerName];
              /** @type {?} */

              var transition = trigger.fallbackTransition;
              /** @type {?} */

              var elementStates =
              /** @type {?} */
              _this26._engine.statesByElement.get(element);
              /** @type {?} */


              var fromState = elementStates[triggerName] || DEFAULT_STATE_VALUE;
              /** @type {?} */

              var toState = new StateValue(VOID_VALUE);
              /** @type {?} */

              var player = new TransitionAnimationPlayer(_this26.id, triggerName, element);
              _this26._engine.totalQueuedPlayers++;

              _this26._queue.push({
                element: element,
                triggerName: triggerName,
                transition: transition,
                fromState: fromState,
                toState: toState,
                player: player,
                isFallbackTransition: true
              });
            });
          }
        }
        /**
         * @param {?} element
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "removeNode",
        value: function removeNode(element, context) {
          var _this27 = this;

          /** @type {?} */
          var engine = this._engine;

          if (element.childElementCount) {
            this._signalRemovalForInnerTriggers(element, context);
          } // this means that a * => VOID animation was detected and kicked off


          if (this.triggerLeaveAnimation(element, context, true)) return; // find the player that is animating and make sure that the
          // removal is delayed until that player has completed

          /** @type {?} */

          var containsPotentialParentTransition = false;

          if (engine.totalAnimations) {
            /** @type {?} */
            var currentPlayers = engine.players.length ? engine.playersByQueriedElement.get(element) : []; // when this `if statement` does not continue forward it means that
            // a previous animation query has selected the current element and
            // is animating it. In this situation want to continue forwards and
            // allow the element to be queued up for animation later.

            if (currentPlayers && currentPlayers.length) {
              containsPotentialParentTransition = true;
            } else {
              /** @type {?} */
              var parent = element;

              while (parent = parent.parentNode) {
                /** @type {?} */
                var triggers = engine.statesByElement.get(parent);

                if (triggers) {
                  containsPotentialParentTransition = true;
                  break;
                }
              }
            }
          } // at this stage we know that the element will either get removed
          // during flush or will be picked up by a parent query. Either way
          // we need to fire the listeners for this element when it DOES get
          // removed (once the query parent animation is done or after flush)


          this.prepareLeaveAnimationListeners(element); // whether or not a parent has an animation we need to delay the deferral of the leave
          // operation until we have more information (which we do after flush() has been called)

          if (containsPotentialParentTransition) {
            engine.markElementAsRemoved(this.id, element, false, context);
          } else {
            /** @type {?} */
            var removalFlag = element[REMOVAL_FLAG];

            if (!removalFlag || removalFlag === NULL_REMOVAL_STATE) {
              // we do this after the flush has occurred such
              // that the callbacks can be fired
              engine.afterFlush(
              /**
              * @return {?}
              */
              function () {
                return _this27.clearElementCache(element);
              });
              engine.destroyInnerAnimations(element);

              engine._onRemovalComplete(element, context);
            }
          }
        }
        /**
         * @param {?} element
         * @param {?} parent
         * @return {?}
         */

      }, {
        key: "insertNode",
        value: function insertNode(element, parent) {
          addClass(element, this._hostClassName);
        }
        /**
         * @param {?} microtaskId
         * @return {?}
         */

      }, {
        key: "drainQueuedTransitions",
        value: function drainQueuedTransitions(microtaskId) {
          var _this28 = this;

          /** @type {?} */
          var instructions = [];

          this._queue.forEach(
          /**
          * @param {?} entry
          * @return {?}
          */
          function (entry) {
            /** @type {?} */
            var player = entry.player;
            if (player.destroyed) return;
            /** @type {?} */

            var element = entry.element;
            /** @type {?} */

            var listeners = _this28._elementListeners.get(element);

            if (listeners) {
              listeners.forEach(
              /**
              * @param {?} listener
              * @return {?}
              */
              function (listener) {
                if (listener.name == entry.triggerName) {
                  /** @type {?} */
                  var baseEvent = makeAnimationEvent(element, entry.triggerName, entry.fromState.value, entry.toState.value);

                  /** @type {?} */
                  baseEvent['_data'] = microtaskId;
                  listenOnPlayer(entry.player, listener.phase, baseEvent, listener.callback);
                }
              });
            }

            if (player.markedForDestroy) {
              _this28._engine.afterFlush(
              /**
              * @return {?}
              */
              function () {
                // now we can destroy the element properly since the event listeners have
                // been bound to the player
                player.destroy();
              });
            } else {
              instructions.push(entry);
            }
          });

          this._queue = [];
          return instructions.sort(
          /**
          * @param {?} a
          * @param {?} b
          * @return {?}
          */
          function (a, b) {
            // if depCount == 0 them move to front
            // otherwise if a contains b then move back

            /** @type {?} */
            var d0 = a.transition.ast.depCount;
            /** @type {?} */

            var d1 = b.transition.ast.depCount;

            if (d0 == 0 || d1 == 0) {
              return d0 - d1;
            }

            return _this28._engine.driver.containsElement(a.element, b.element) ? 1 : -1;
          });
        }
        /**
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "destroy",
        value: function destroy(context) {
          this.players.forEach(
          /**
          * @param {?} p
          * @return {?}
          */
          function (p) {
            return p.destroy();
          });

          this._signalRemovalForInnerTriggers(this.hostElement, context);
        }
        /**
         * @param {?} element
         * @return {?}
         */

      }, {
        key: "elementContainsData",
        value: function elementContainsData(element) {
          /** @type {?} */
          var containsData = false;
          if (this._elementListeners.has(element)) containsData = true;
          containsData = (this._queue.find(
          /**
          * @param {?} entry
          * @return {?}
          */
          function (entry) {
            return entry.element === element;
          }) ? true : false) || containsData;
          return containsData;
        }
      }]);

      return AnimationTransitionNamespace;
    }();

    if (false) {}
    /**
     * @record
     */


    function QueuedTransition() {}

    if (false) {}

    var TransitionAnimationEngine = /*#__PURE__*/function () {
      /**
       * @param {?} bodyNode
       * @param {?} driver
       * @param {?} _normalizer
       */
      function TransitionAnimationEngine(bodyNode, driver, _normalizer) {
        _classCallCheck(this, TransitionAnimationEngine);

        this.bodyNode = bodyNode;
        this.driver = driver;
        this._normalizer = _normalizer;
        this.players = [];
        this.newHostElements = new Map();
        this.playersByElement = new Map();
        this.playersByQueriedElement = new Map();
        this.statesByElement = new Map();
        this.disabledNodes = new Set();
        this.totalAnimations = 0;
        this.totalQueuedPlayers = 0;
        this._namespaceLookup = {};
        this._namespaceList = [];
        this._flushFns = [];
        this._whenQuietFns = [];
        this.namespacesByHostElement = new Map();
        this.collectedEnterElements = [];
        this.collectedLeaveElements = []; // this method is designed to be overridden by the code that uses this engine

        this.onRemovalComplete =
        /**
        * @param {?} element
        * @param {?} context
        * @return {?}
        */
        function (element, context) {};
      }
      /**
       * \@internal
       * @param {?} element
       * @param {?} context
       * @return {?}
       */


      _createClass2(TransitionAnimationEngine, [{
        key: "_onRemovalComplete",
        value: function _onRemovalComplete(element, context) {
          this.onRemovalComplete(element, context);
        }
        /**
         * @return {?}
         */

      }, {
        key: "createNamespace",

        /**
         * @param {?} namespaceId
         * @param {?} hostElement
         * @return {?}
         */
        value: function createNamespace(namespaceId, hostElement) {
          /** @type {?} */
          var ns = new AnimationTransitionNamespace(namespaceId, hostElement, this);

          if (hostElement.parentNode) {
            this._balanceNamespaceList(ns, hostElement);
          } else {
            // defer this later until flush during when the host element has
            // been inserted so that we know exactly where to place it in
            // the namespace list
            this.newHostElements.set(hostElement, ns); // given that this host element is apart of the animation code, it
            // may or may not be inserted by a parent node that is an of an
            // animation renderer type. If this happens then we can still have
            // access to this item when we query for :enter nodes. If the parent
            // is a renderer then the set data-structure will normalize the entry

            this.collectEnterElement(hostElement);
          }

          return this._namespaceLookup[namespaceId] = ns;
        }
        /**
         * @private
         * @param {?} ns
         * @param {?} hostElement
         * @return {?}
         */

      }, {
        key: "_balanceNamespaceList",
        value: function _balanceNamespaceList(ns, hostElement) {
          /** @type {?} */
          var limit = this._namespaceList.length - 1;

          if (limit >= 0) {
            /** @type {?} */
            var found = false;

            for (var i = limit; i >= 0; i--) {
              /** @type {?} */
              var nextNamespace = this._namespaceList[i];

              if (this.driver.containsElement(nextNamespace.hostElement, hostElement)) {
                this._namespaceList.splice(i + 1, 0, ns);

                found = true;
                break;
              }
            }

            if (!found) {
              this._namespaceList.splice(0, 0, ns);
            }
          } else {
            this._namespaceList.push(ns);
          }

          this.namespacesByHostElement.set(hostElement, ns);
          return ns;
        }
        /**
         * @param {?} namespaceId
         * @param {?} hostElement
         * @return {?}
         */

      }, {
        key: "register",
        value: function register(namespaceId, hostElement) {
          /** @type {?} */
          var ns = this._namespaceLookup[namespaceId];

          if (!ns) {
            ns = this.createNamespace(namespaceId, hostElement);
          }

          return ns;
        }
        /**
         * @param {?} namespaceId
         * @param {?} name
         * @param {?} trigger
         * @return {?}
         */

      }, {
        key: "registerTrigger",
        value: function registerTrigger(namespaceId, name, trigger) {
          /** @type {?} */
          var ns = this._namespaceLookup[namespaceId];

          if (ns && ns.register(name, trigger)) {
            this.totalAnimations++;
          }
        }
        /**
         * @param {?} namespaceId
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "destroy",
        value: function destroy(namespaceId, context) {
          var _this29 = this;

          if (!namespaceId) return;
          /** @type {?} */

          var ns = this._fetchNamespace(namespaceId);

          this.afterFlush(
          /**
          * @return {?}
          */
          function () {
            _this29.namespacesByHostElement["delete"](ns.hostElement);

            delete _this29._namespaceLookup[namespaceId];
            /** @type {?} */

            var index = _this29._namespaceList.indexOf(ns);

            if (index >= 0) {
              _this29._namespaceList.splice(index, 1);
            }
          });
          this.afterFlushAnimationsDone(
          /**
          * @return {?}
          */
          function () {
            return ns.destroy(context);
          });
        }
        /**
         * @private
         * @param {?} id
         * @return {?}
         */

      }, {
        key: "_fetchNamespace",
        value: function _fetchNamespace(id) {
          return this._namespaceLookup[id];
        }
        /**
         * @param {?} element
         * @return {?}
         */

      }, {
        key: "fetchNamespacesByElement",
        value: function fetchNamespacesByElement(element) {
          // normally there should only be one namespace per element, however
          // if @triggers are placed on both the component element and then
          // its host element (within the component code) then there will be
          // two namespaces returned. We use a set here to simply the dedupe
          // of namespaces incase there are multiple triggers both the elm and host

          /** @type {?} */
          var namespaces = new Set();
          /** @type {?} */

          var elementStates = this.statesByElement.get(element);

          if (elementStates) {
            /** @type {?} */
            var keys = Object.keys(elementStates);

            for (var i = 0; i < keys.length; i++) {
              /** @type {?} */
              var nsId = elementStates[keys[i]].namespaceId;

              if (nsId) {
                /** @type {?} */
                var ns = this._fetchNamespace(nsId);

                if (ns) {
                  namespaces.add(ns);
                }
              }
            }
          }

          return namespaces;
        }
        /**
         * @param {?} namespaceId
         * @param {?} element
         * @param {?} name
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "trigger",
        value: function trigger(namespaceId, element, name, value) {
          if (isElementNode(element)) {
            /** @type {?} */
            var ns = this._fetchNamespace(namespaceId);

            if (ns) {
              ns.trigger(element, name, value);
              return true;
            }
          }

          return false;
        }
        /**
         * @param {?} namespaceId
         * @param {?} element
         * @param {?} parent
         * @param {?} insertBefore
         * @return {?}
         */

      }, {
        key: "insertNode",
        value: function insertNode(namespaceId, element, parent, insertBefore) {
          if (!isElementNode(element)) return; // special case for when an element is removed and reinserted (move operation)
          // when this occurs we do not want to use the element for deletion later

          /** @type {?} */

          var details =
          /** @type {?} */
          element[REMOVAL_FLAG];

          if (details && details.setForRemoval) {
            details.setForRemoval = false;
            details.setForMove = true;
            /** @type {?} */

            var index = this.collectedLeaveElements.indexOf(element);

            if (index >= 0) {
              this.collectedLeaveElements.splice(index, 1);
            }
          } // in the event that the namespaceId is blank then the caller
          // code does not contain any animation code in it, but it is
          // just being called so that the node is marked as being inserted


          if (namespaceId) {
            /** @type {?} */
            var ns = this._fetchNamespace(namespaceId); // This if-statement is a workaround for router issue #21947.
            // The router sometimes hits a race condition where while a route
            // is being instantiated a new navigation arrives, triggering leave
            // animation of DOM that has not been fully initialized, until this
            // is resolved, we need to handle the scenario when DOM is not in a
            // consistent state during the animation.


            if (ns) {
              ns.insertNode(element, parent);
            }
          } // only *directives and host elements are inserted before


          if (insertBefore) {
            this.collectEnterElement(element);
          }
        }
        /**
         * @param {?} element
         * @return {?}
         */

      }, {
        key: "collectEnterElement",
        value: function collectEnterElement(element) {
          this.collectedEnterElements.push(element);
        }
        /**
         * @param {?} element
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "markElementAsDisabled",
        value: function markElementAsDisabled(element, value) {
          if (value) {
            if (!this.disabledNodes.has(element)) {
              this.disabledNodes.add(element);
              addClass(element, DISABLED_CLASSNAME);
            }
          } else if (this.disabledNodes.has(element)) {
            this.disabledNodes["delete"](element);
            removeClass(element, DISABLED_CLASSNAME);
          }
        }
        /**
         * @param {?} namespaceId
         * @param {?} element
         * @param {?} isHostElement
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "removeNode",
        value: function removeNode(namespaceId, element, isHostElement, context) {
          if (isElementNode(element)) {
            /** @type {?} */
            var ns = namespaceId ? this._fetchNamespace(namespaceId) : null;

            if (ns) {
              ns.removeNode(element, context);
            } else {
              this.markElementAsRemoved(namespaceId, element, false, context);
            }

            if (isHostElement) {
              /** @type {?} */
              var hostNS = this.namespacesByHostElement.get(element);

              if (hostNS && hostNS.id !== namespaceId) {
                hostNS.removeNode(element, context);
              }
            }
          } else {
            this._onRemovalComplete(element, context);
          }
        }
        /**
         * @param {?} namespaceId
         * @param {?} element
         * @param {?=} hasAnimation
         * @param {?=} context
         * @return {?}
         */

      }, {
        key: "markElementAsRemoved",
        value: function markElementAsRemoved(namespaceId, element, hasAnimation, context) {
          this.collectedLeaveElements.push(element);
          element[REMOVAL_FLAG] = {
            namespaceId: namespaceId,
            setForRemoval: context,
            hasAnimation: hasAnimation,
            removedBeforeQueried: false
          };
        }
        /**
         * @param {?} namespaceId
         * @param {?} element
         * @param {?} name
         * @param {?} phase
         * @param {?} callback
         * @return {?}
         */

      }, {
        key: "listen",
        value: function listen(namespaceId, element, name, phase, callback) {
          if (isElementNode(element)) {
            return this._fetchNamespace(namespaceId).listen(element, name, phase, callback);
          }

          return (
            /**
            * @return {?}
            */
            function () {}
          );
        }
        /**
         * @private
         * @param {?} entry
         * @param {?} subTimelines
         * @param {?} enterClassName
         * @param {?} leaveClassName
         * @param {?=} skipBuildAst
         * @return {?}
         */

      }, {
        key: "_buildInstruction",
        value: function _buildInstruction(entry, subTimelines, enterClassName, leaveClassName, skipBuildAst) {
          return entry.transition.build(this.driver, entry.element, entry.fromState.value, entry.toState.value, enterClassName, leaveClassName, entry.fromState.options, entry.toState.options, subTimelines, skipBuildAst);
        }
        /**
         * @param {?} containerElement
         * @return {?}
         */

      }, {
        key: "destroyInnerAnimations",
        value: function destroyInnerAnimations(containerElement) {
          var _this30 = this;

          /** @type {?} */
          var elements = this.driver.query(containerElement, NG_TRIGGER_SELECTOR, true);
          elements.forEach(
          /**
          * @param {?} element
          * @return {?}
          */
          function (element) {
            return _this30.destroyActiveAnimationsForElement(element);
          });
          if (this.playersByQueriedElement.size == 0) return;
          elements = this.driver.query(containerElement, NG_ANIMATING_SELECTOR, true);
          elements.forEach(
          /**
          * @param {?} element
          * @return {?}
          */
          function (element) {
            return _this30.finishActiveQueriedAnimationOnElement(element);
          });
        }
        /**
         * @param {?} element
         * @return {?}
         */

      }, {
        key: "destroyActiveAnimationsForElement",
        value: function destroyActiveAnimationsForElement(element) {
          /** @type {?} */
          var players = this.playersByElement.get(element);

          if (players) {
            players.forEach(
            /**
            * @param {?} player
            * @return {?}
            */
            function (player) {
              // special case for when an element is set for destruction, but hasn't started.
              // in this situation we want to delay the destruction until the flush occurs
              // so that any event listeners attached to the player are triggered.
              if (player.queued) {
                player.markedForDestroy = true;
              } else {
                player.destroy();
              }
            });
          }
        }
        /**
         * @param {?} element
         * @return {?}
         */

      }, {
        key: "finishActiveQueriedAnimationOnElement",
        value: function finishActiveQueriedAnimationOnElement(element) {
          /** @type {?} */
          var players = this.playersByQueriedElement.get(element);

          if (players) {
            players.forEach(
            /**
            * @param {?} player
            * @return {?}
            */
            function (player) {
              return player.finish();
            });
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "whenRenderingDone",
        value: function whenRenderingDone() {
          var _this31 = this;

          return new Promise(
          /**
          * @param {?} resolve
          * @return {?}
          */
          function (resolve) {
            if (_this31.players.length) {
              return optimizeGroupPlayer(_this31.players).onDone(
              /**
              * @return {?}
              */
              function () {
                return resolve();
              });
            } else {
              resolve();
            }
          });
        }
        /**
         * @param {?} element
         * @return {?}
         */

      }, {
        key: "processLeaveNode",
        value: function processLeaveNode(element) {
          var _this32 = this;

          /** @type {?} */
          var details =
          /** @type {?} */
          element[REMOVAL_FLAG];

          if (details && details.setForRemoval) {
            // this will prevent it from removing it twice
            element[REMOVAL_FLAG] = NULL_REMOVAL_STATE;

            if (details.namespaceId) {
              this.destroyInnerAnimations(element);
              /** @type {?} */

              var ns = this._fetchNamespace(details.namespaceId);

              if (ns) {
                ns.clearElementCache(element);
              }
            }

            this._onRemovalComplete(element, details.setForRemoval);
          }

          if (this.driver.matchesElement(element, DISABLED_SELECTOR)) {
            this.markElementAsDisabled(element, false);
          }

          this.driver.query(element, DISABLED_SELECTOR, true).forEach(
          /**
          * @param {?} node
          * @return {?}
          */
          function (node) {
            _this32.markElementAsDisabled(node, false);
          });
        }
        /**
         * @param {?=} microtaskId
         * @return {?}
         */

      }, {
        key: "flush",
        value: function flush() {
          var _this33 = this;

          var microtaskId = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : -1;

          /** @type {?} */
          var players = [];

          if (this.newHostElements.size) {
            this.newHostElements.forEach(
            /**
            * @param {?} ns
            * @param {?} element
            * @return {?}
            */
            function (ns, element) {
              return _this33._balanceNamespaceList(ns, element);
            });
            this.newHostElements.clear();
          }

          if (this.totalAnimations && this.collectedEnterElements.length) {
            for (var i = 0; i < this.collectedEnterElements.length; i++) {
              /** @type {?} */
              var elm = this.collectedEnterElements[i];
              addClass(elm, STAR_CLASSNAME);
            }
          }

          if (this._namespaceList.length && (this.totalQueuedPlayers || this.collectedLeaveElements.length)) {
            /** @type {?} */
            var cleanupFns = [];

            try {
              players = this._flushAnimations(cleanupFns, microtaskId);
            } finally {
              for (var _i2 = 0; _i2 < cleanupFns.length; _i2++) {
                cleanupFns[_i2]();
              }
            }
          } else {
            for (var _i3 = 0; _i3 < this.collectedLeaveElements.length; _i3++) {
              /** @type {?} */
              var element = this.collectedLeaveElements[_i3];
              this.processLeaveNode(element);
            }
          }

          this.totalQueuedPlayers = 0;
          this.collectedEnterElements.length = 0;
          this.collectedLeaveElements.length = 0;

          this._flushFns.forEach(
          /**
          * @param {?} fn
          * @return {?}
          */
          function (fn) {
            return fn();
          });

          this._flushFns = [];

          if (this._whenQuietFns.length) {
            // we move these over to a variable so that
            // if any new callbacks are registered in another
            // flush they do not populate the existing set

            /** @type {?} */
            var quietFns = this._whenQuietFns;
            this._whenQuietFns = [];

            if (players.length) {
              optimizeGroupPlayer(players).onDone(
              /**
              * @return {?}
              */
              function () {
                quietFns.forEach(
                /**
                * @param {?} fn
                * @return {?}
                */
                function (fn) {
                  return fn();
                });
              });
            } else {
              quietFns.forEach(
              /**
              * @param {?} fn
              * @return {?}
              */
              function (fn) {
                return fn();
              });
            }
          }
        }
        /**
         * @param {?} errors
         * @return {?}
         */

      }, {
        key: "reportError",
        value: function reportError(errors) {
          throw new Error("Unable to process animations due to the following failed trigger transitions\n ".concat(errors.join('\n')));
        }
        /**
         * @private
         * @param {?} cleanupFns
         * @param {?} microtaskId
         * @return {?}
         */

      }, {
        key: "_flushAnimations",
        value: function _flushAnimations(cleanupFns, microtaskId) {
          var _this34 = this;

          /** @type {?} */
          var subTimelines = new ElementInstructionMap();
          /** @type {?} */

          var skippedPlayers = [];
          /** @type {?} */

          var skippedPlayersMap = new Map();
          /** @type {?} */

          var queuedInstructions = [];
          /** @type {?} */

          var queriedElements = new Map();
          /** @type {?} */

          var allPreStyleElements = new Map();
          /** @type {?} */

          var allPostStyleElements = new Map();
          /** @type {?} */

          var disabledElementsSet = new Set();
          this.disabledNodes.forEach(
          /**
          * @param {?} node
          * @return {?}
          */
          function (node) {
            disabledElementsSet.add(node);
            /** @type {?} */

            var nodesThatAreDisabled = _this34.driver.query(node, QUEUED_SELECTOR, true);

            for (var _i4 = 0; _i4 < nodesThatAreDisabled.length; _i4++) {
              disabledElementsSet.add(nodesThatAreDisabled[_i4]);
            }
          });
          /** @type {?} */

          var bodyNode = this.bodyNode;
          /** @type {?} */

          var allTriggerElements = Array.from(this.statesByElement.keys());
          /** @type {?} */

          var enterNodeMap = buildRootMap(allTriggerElements, this.collectedEnterElements); // this must occur before the instructions are built below such that
          // the :enter queries match the elements (since the timeline queries
          // are fired during instruction building).

          /** @type {?} */

          var enterNodeMapIds = new Map();
          /** @type {?} */

          var i = 0;
          enterNodeMap.forEach(
          /**
          * @param {?} nodes
          * @param {?} root
          * @return {?}
          */
          function (nodes, root) {
            /** @type {?} */
            var className = ENTER_CLASSNAME + i++;
            enterNodeMapIds.set(root, className);
            nodes.forEach(
            /**
            * @param {?} node
            * @return {?}
            */
            function (node) {
              return addClass(node, className);
            });
          });
          /** @type {?} */

          var allLeaveNodes = [];
          /** @type {?} */

          var mergedLeaveNodes = new Set();
          /** @type {?} */

          var leaveNodesWithoutAnimations = new Set();

          for (var _i5 = 0; _i5 < this.collectedLeaveElements.length; _i5++) {
            /** @type {?} */
            var element = this.collectedLeaveElements[_i5];
            /** @type {?} */

            var details =
            /** @type {?} */
            element[REMOVAL_FLAG];

            if (details && details.setForRemoval) {
              allLeaveNodes.push(element);
              mergedLeaveNodes.add(element);

              if (details.hasAnimation) {
                this.driver.query(element, STAR_SELECTOR, true).forEach(
                /**
                * @param {?} elm
                * @return {?}
                */
                function (elm) {
                  return mergedLeaveNodes.add(elm);
                });
              } else {
                leaveNodesWithoutAnimations.add(element);
              }
            }
          }
          /** @type {?} */


          var leaveNodeMapIds = new Map();
          /** @type {?} */

          var leaveNodeMap = buildRootMap(allTriggerElements, Array.from(mergedLeaveNodes));
          leaveNodeMap.forEach(
          /**
          * @param {?} nodes
          * @param {?} root
          * @return {?}
          */
          function (nodes, root) {
            /** @type {?} */
            var className = LEAVE_CLASSNAME + i++;
            leaveNodeMapIds.set(root, className);
            nodes.forEach(
            /**
            * @param {?} node
            * @return {?}
            */
            function (node) {
              return addClass(node, className);
            });
          });
          cleanupFns.push(
          /**
          * @return {?}
          */
          function () {
            enterNodeMap.forEach(
            /**
            * @param {?} nodes
            * @param {?} root
            * @return {?}
            */
            function (nodes, root) {
              /** @type {?} */
              var className =
              /** @type {?} */
              enterNodeMapIds.get(root);
              nodes.forEach(
              /**
              * @param {?} node
              * @return {?}
              */
              function (node) {
                return removeClass(node, className);
              });
            });
            leaveNodeMap.forEach(
            /**
            * @param {?} nodes
            * @param {?} root
            * @return {?}
            */
            function (nodes, root) {
              /** @type {?} */
              var className =
              /** @type {?} */
              leaveNodeMapIds.get(root);
              nodes.forEach(
              /**
              * @param {?} node
              * @return {?}
              */
              function (node) {
                return removeClass(node, className);
              });
            });
            allLeaveNodes.forEach(
            /**
            * @param {?} element
            * @return {?}
            */
            function (element) {
              _this34.processLeaveNode(element);
            });
          });
          /** @type {?} */

          var allPlayers = [];
          /** @type {?} */

          var erroneousTransitions = [];

          for (var _i6 = this._namespaceList.length - 1; _i6 >= 0; _i6--) {
            /** @type {?} */
            var ns = this._namespaceList[_i6];
            ns.drainQueuedTransitions(microtaskId).forEach(
            /**
            * @param {?} entry
            * @return {?}
            */
            function (entry) {
              /** @type {?} */
              var player = entry.player;
              /** @type {?} */

              var element = entry.element;
              allPlayers.push(player);

              if (_this34.collectedEnterElements.length) {
                /** @type {?} */
                var _details =
                /** @type {?} */
                element[REMOVAL_FLAG]; // move animations are currently not supported...

                if (_details && _details.setForMove) {
                  player.destroy();
                  return;
                }
              }
              /** @type {?} */


              var nodeIsOrphaned = !bodyNode || !_this34.driver.containsElement(bodyNode, element);
              /** @type {?} */

              var leaveClassName =
              /** @type {?} */
              leaveNodeMapIds.get(element);
              /** @type {?} */

              var enterClassName =
              /** @type {?} */
              enterNodeMapIds.get(element);
              /** @type {?} */

              var instruction =
              /** @type {?} */
              _this34._buildInstruction(entry, subTimelines, enterClassName, leaveClassName, nodeIsOrphaned);

              if (instruction.errors && instruction.errors.length) {
                erroneousTransitions.push(instruction);
                return;
              } // even though the element may not be apart of the DOM, it may
              // still be added at a later point (due to the mechanics of content
              // projection and/or dynamic component insertion) therefore it's
              // important we still style the element.


              if (nodeIsOrphaned) {
                player.onStart(
                /**
                * @return {?}
                */
                function () {
                  return eraseStyles(element, instruction.fromStyles);
                });
                player.onDestroy(
                /**
                * @return {?}
                */
                function () {
                  return setStyles(element, instruction.toStyles);
                });
                skippedPlayers.push(player);
                return;
              } // if a unmatched transition is queued to go then it SHOULD NOT render
              // an animation and cancel the previously running animations.


              if (entry.isFallbackTransition) {
                player.onStart(
                /**
                * @return {?}
                */
                function () {
                  return eraseStyles(element, instruction.fromStyles);
                });
                player.onDestroy(
                /**
                * @return {?}
                */
                function () {
                  return setStyles(element, instruction.toStyles);
                });
                skippedPlayers.push(player);
                return;
              } // this means that if a parent animation uses this animation as a sub trigger
              // then it will instruct the timeline builder to not add a player delay, but
              // instead stretch the first keyframe gap up until the animation starts. The
              // reason this is important is to prevent extra initialization styles from being
              // required by the user in the animation.


              instruction.timelines.forEach(
              /**
              * @param {?} tl
              * @return {?}
              */
              function (tl) {
                return tl.stretchStartingKeyframe = true;
              });
              subTimelines.append(element, instruction.timelines);
              /** @type {?} */

              var tuple = {
                instruction: instruction,
                player: player,
                element: element
              };
              queuedInstructions.push(tuple);
              instruction.queriedElements.forEach(
              /**
              * @param {?} element
              * @return {?}
              */
              function (element) {
                return getOrSetAsInMap(queriedElements, element, []).push(player);
              });
              instruction.preStyleProps.forEach(
              /**
              * @param {?} stringMap
              * @param {?} element
              * @return {?}
              */
              function (stringMap, element) {
                /** @type {?} */
                var props = Object.keys(stringMap);

                if (props.length) {
                  /** @type {?} */
                  var setVal =
                  /** @type {?} */
                  allPreStyleElements.get(element);

                  if (!setVal) {
                    allPreStyleElements.set(element, setVal = new Set());
                  }

                  props.forEach(
                  /**
                  * @param {?} prop
                  * @return {?}
                  */
                  function (prop) {
                    return setVal.add(prop);
                  });
                }
              });
              instruction.postStyleProps.forEach(
              /**
              * @param {?} stringMap
              * @param {?} element
              * @return {?}
              */
              function (stringMap, element) {
                /** @type {?} */
                var props = Object.keys(stringMap);
                /** @type {?} */

                var setVal =
                /** @type {?} */
                allPostStyleElements.get(element);

                if (!setVal) {
                  allPostStyleElements.set(element, setVal = new Set());
                }

                props.forEach(
                /**
                * @param {?} prop
                * @return {?}
                */
                function (prop) {
                  return setVal.add(prop);
                });
              });
            });
          }

          if (erroneousTransitions.length) {
            /** @type {?} */
            var errors = [];
            erroneousTransitions.forEach(
            /**
            * @param {?} instruction
            * @return {?}
            */
            function (instruction) {
              errors.push("@".concat(instruction.triggerName, " has failed due to:\n"));

              /** @type {?} */
              instruction.errors.forEach(
              /**
              * @param {?} error
              * @return {?}
              */
              function (error) {
                return errors.push("- ".concat(error, "\n"));
              });
            });
            allPlayers.forEach(
            /**
            * @param {?} player
            * @return {?}
            */
            function (player) {
              return player.destroy();
            });
            this.reportError(errors);
          }
          /** @type {?} */


          var allPreviousPlayersMap = new Map(); // this map works to tell which element in the DOM tree is contained by
          // which animation. Further down below this map will get populated once
          // the players are built and in doing so it can efficiently figure out
          // if a sub player is skipped due to a parent player having priority.

          /** @type {?} */

          var animationElementMap = new Map();
          queuedInstructions.forEach(
          /**
          * @param {?} entry
          * @return {?}
          */
          function (entry) {
            /** @type {?} */
            var element = entry.element;

            if (subTimelines.has(element)) {
              animationElementMap.set(element, element);

              _this34._beforeAnimationBuild(entry.player.namespaceId, entry.instruction, allPreviousPlayersMap);
            }
          });
          skippedPlayers.forEach(
          /**
          * @param {?} player
          * @return {?}
          */
          function (player) {
            /** @type {?} */
            var element = player.element;
            /** @type {?} */

            var previousPlayers = _this34._getPreviousPlayers(element, false, player.namespaceId, player.triggerName, null);

            previousPlayers.forEach(
            /**
            * @param {?} prevPlayer
            * @return {?}
            */
            function (prevPlayer) {
              getOrSetAsInMap(allPreviousPlayersMap, element, []).push(prevPlayer);
              prevPlayer.destroy();
            });
          }); // this is a special case for nodes that will be removed (either by)
          // having their own leave animations or by being queried in a container
          // that will be removed once a parent animation is complete. The idea
          // here is that * styles must be identical to ! styles because of
          // backwards compatibility (* is also filled in by default in many places).
          // Otherwise * styles will return an empty value or auto since the element
          // that is being getComputedStyle'd will not be visible (since * = destination)

          /** @type {?} */

          var replaceNodes = allLeaveNodes.filter(
          /**
          * @param {?} node
          * @return {?}
          */
          function (node) {
            return replacePostStylesAsPre(node, allPreStyleElements, allPostStyleElements);
          }); // POST STAGE: fill the * styles

          /** @type {?} */

          var postStylesMap = new Map();
          /** @type {?} */

          var allLeaveQueriedNodes = cloakAndComputeStyles(postStylesMap, this.driver, leaveNodesWithoutAnimations, allPostStyleElements, _angular_animations__WEBPACK_IMPORTED_MODULE_0__["AUTO_STYLE"]);
          allLeaveQueriedNodes.forEach(
          /**
          * @param {?} node
          * @return {?}
          */
          function (node) {
            if (replacePostStylesAsPre(node, allPreStyleElements, allPostStyleElements)) {
              replaceNodes.push(node);
            }
          }); // PRE STAGE: fill the ! styles

          /** @type {?} */

          var preStylesMap = new Map();
          enterNodeMap.forEach(
          /**
          * @param {?} nodes
          * @param {?} root
          * @return {?}
          */
          function (nodes, root) {
            cloakAndComputeStyles(preStylesMap, _this34.driver, new Set(nodes), allPreStyleElements, _angular_animations__WEBPACK_IMPORTED_MODULE_0__["ɵPRE_STYLE"]);
          });
          replaceNodes.forEach(
          /**
          * @param {?} node
          * @return {?}
          */
          function (node) {
            /** @type {?} */
            var post = postStylesMap.get(node);
            /** @type {?} */

            var pre = preStylesMap.get(node);
            postStylesMap.set(node,
            /** @type {?} */
            Object.assign(Object.assign({}, post), pre));
          });
          /** @type {?} */

          var rootPlayers = [];
          /** @type {?} */

          var subPlayers = [];
          /** @type {?} */

          var NO_PARENT_ANIMATION_ELEMENT_DETECTED = {};
          queuedInstructions.forEach(
          /**
          * @param {?} entry
          * @return {?}
          */
          function (entry) {
            var element = entry.element,
                player = entry.player,
                instruction = entry.instruction; // this means that it was never consumed by a parent animation which
            // means that it is independent and therefore should be set for animation

            if (subTimelines.has(element)) {
              if (disabledElementsSet.has(element)) {
                player.onDestroy(
                /**
                * @return {?}
                */
                function () {
                  return setStyles(element, instruction.toStyles);
                });
                player.disabled = true;
                player.overrideTotalTime(instruction.totalTime);
                skippedPlayers.push(player);
                return;
              } // this will flow up the DOM and query the map to figure out
              // if a parent animation has priority over it. In the situation
              // that a parent is detected then it will cancel the loop. If
              // nothing is detected, or it takes a few hops to find a parent,
              // then it will fill in the missing nodes and signal them as having
              // a detected parent (or a NO_PARENT value via a special constant).

              /** @type {?} */


              var parentWithAnimation = NO_PARENT_ANIMATION_ELEMENT_DETECTED;

              if (animationElementMap.size > 1) {
                /** @type {?} */
                var elm = element;
                /** @type {?} */

                var parentsToAdd = [];

                while (elm = elm.parentNode) {
                  /** @type {?} */
                  var detectedParent = animationElementMap.get(elm);

                  if (detectedParent) {
                    parentWithAnimation = detectedParent;
                    break;
                  }

                  parentsToAdd.push(elm);
                }

                parentsToAdd.forEach(
                /**
                * @param {?} parent
                * @return {?}
                */
                function (parent) {
                  return animationElementMap.set(parent, parentWithAnimation);
                });
              }
              /** @type {?} */


              var innerPlayer = _this34._buildAnimation(player.namespaceId, instruction, allPreviousPlayersMap, skippedPlayersMap, preStylesMap, postStylesMap);

              player.setRealPlayer(innerPlayer);

              if (parentWithAnimation === NO_PARENT_ANIMATION_ELEMENT_DETECTED) {
                rootPlayers.push(player);
              } else {
                /** @type {?} */
                var parentPlayers = _this34.playersByElement.get(parentWithAnimation);

                if (parentPlayers && parentPlayers.length) {
                  player.parentPlayer = optimizeGroupPlayer(parentPlayers);
                }

                skippedPlayers.push(player);
              }
            } else {
              eraseStyles(element, instruction.fromStyles);
              player.onDestroy(
              /**
              * @return {?}
              */
              function () {
                return setStyles(element, instruction.toStyles);
              }); // there still might be a ancestor player animating this
              // element therefore we will still add it as a sub player
              // even if its animation may be disabled

              subPlayers.push(player);

              if (disabledElementsSet.has(element)) {
                skippedPlayers.push(player);
              }
            }
          }); // find all of the sub players' corresponding inner animation player

          subPlayers.forEach(
          /**
          * @param {?} player
          * @return {?}
          */
          function (player) {
            // even if any players are not found for a sub animation then it
            // will still complete itself after the next tick since it's Noop

            /** @type {?} */
            var playersForElement = skippedPlayersMap.get(player.element);

            if (playersForElement && playersForElement.length) {
              /** @type {?} */
              var innerPlayer = optimizeGroupPlayer(playersForElement);
              player.setRealPlayer(innerPlayer);
            }
          }); // the reason why we don't actually play the animation is
          // because all that a skipped player is designed to do is to
          // fire the start/done transition callback events

          skippedPlayers.forEach(
          /**
          * @param {?} player
          * @return {?}
          */
          function (player) {
            if (player.parentPlayer) {
              player.syncPlayerEvents(player.parentPlayer);
            } else {
              player.destroy();
            }
          }); // run through all of the queued removals and see if they
          // were picked up by a query. If not then perform the removal
          // operation right away unless a parent animation is ongoing.

          for (var _i7 = 0; _i7 < allLeaveNodes.length; _i7++) {
            /** @type {?} */
            var _element2 = allLeaveNodes[_i7];
            /** @type {?} */

            var _details2 =
            /** @type {?} */
            _element2[REMOVAL_FLAG];
            removeClass(_element2, LEAVE_CLASSNAME); // this means the element has a removal animation that is being
            // taken care of and therefore the inner elements will hang around
            // until that animation is over (or the parent queried animation)

            if (_details2 && _details2.hasAnimation) continue;
            /** @type {?} */

            var players = []; // if this element is queried or if it contains queried children
            // then we want for the element not to be removed from the page
            // until the queried animations have finished

            if (queriedElements.size) {
              /** @type {?} */
              var queriedPlayerResults = queriedElements.get(_element2);

              if (queriedPlayerResults && queriedPlayerResults.length) {
                players.push.apply(players, _toConsumableArray(queriedPlayerResults));
              }
              /** @type {?} */


              var queriedInnerElements = this.driver.query(_element2, NG_ANIMATING_SELECTOR, true);

              for (var j = 0; j < queriedInnerElements.length; j++) {
                /** @type {?} */
                var queriedPlayers = queriedElements.get(queriedInnerElements[j]);

                if (queriedPlayers && queriedPlayers.length) {
                  players.push.apply(players, _toConsumableArray(queriedPlayers));
                }
              }
            }
            /** @type {?} */


            var activePlayers = players.filter(
            /**
            * @param {?} p
            * @return {?}
            */
            function (p) {
              return !p.destroyed;
            });

            if (activePlayers.length) {
              removeNodesAfterAnimationDone(this, _element2, activePlayers);
            } else {
              this.processLeaveNode(_element2);
            }
          } // this is required so the cleanup method doesn't remove them


          allLeaveNodes.length = 0;
          rootPlayers.forEach(
          /**
          * @param {?} player
          * @return {?}
          */
          function (player) {
            _this34.players.push(player);

            player.onDone(
            /**
            * @return {?}
            */
            function () {
              player.destroy();
              /** @type {?} */

              var index = _this34.players.indexOf(player);

              _this34.players.splice(index, 1);
            });
            player.play();
          });
          return rootPlayers;
        }
        /**
         * @param {?} namespaceId
         * @param {?} element
         * @return {?}
         */

      }, {
        key: "elementContainsData",
        value: function elementContainsData(namespaceId, element) {
          /** @type {?} */
          var containsData = false;
          /** @type {?} */

          var details =
          /** @type {?} */
          element[REMOVAL_FLAG];
          if (details && details.setForRemoval) containsData = true;
          if (this.playersByElement.has(element)) containsData = true;
          if (this.playersByQueriedElement.has(element)) containsData = true;
          if (this.statesByElement.has(element)) containsData = true;
          return this._fetchNamespace(namespaceId).elementContainsData(element) || containsData;
        }
        /**
         * @param {?} callback
         * @return {?}
         */

      }, {
        key: "afterFlush",
        value: function afterFlush(callback) {
          this._flushFns.push(callback);
        }
        /**
         * @param {?} callback
         * @return {?}
         */

      }, {
        key: "afterFlushAnimationsDone",
        value: function afterFlushAnimationsDone(callback) {
          this._whenQuietFns.push(callback);
        }
        /**
         * @private
         * @param {?} element
         * @param {?} isQueriedElement
         * @param {?=} namespaceId
         * @param {?=} triggerName
         * @param {?=} toStateValue
         * @return {?}
         */

      }, {
        key: "_getPreviousPlayers",
        value: function _getPreviousPlayers(element, isQueriedElement, namespaceId, triggerName, toStateValue) {
          /** @type {?} */
          var players = [];

          if (isQueriedElement) {
            /** @type {?} */
            var queriedElementPlayers = this.playersByQueriedElement.get(element);

            if (queriedElementPlayers) {
              players = queriedElementPlayers;
            }
          } else {
            /** @type {?} */
            var elementPlayers = this.playersByElement.get(element);

            if (elementPlayers) {
              /** @type {?} */
              var isRemovalAnimation = !toStateValue || toStateValue == VOID_VALUE;
              elementPlayers.forEach(
              /**
              * @param {?} player
              * @return {?}
              */
              function (player) {
                if (player.queued) return;
                if (!isRemovalAnimation && player.triggerName != triggerName) return;
                players.push(player);
              });
            }
          }

          if (namespaceId || triggerName) {
            players = players.filter(
            /**
            * @param {?} player
            * @return {?}
            */
            function (player) {
              if (namespaceId && namespaceId != player.namespaceId) return false;
              if (triggerName && triggerName != player.triggerName) return false;
              return true;
            });
          }

          return players;
        }
        /**
         * @private
         * @param {?} namespaceId
         * @param {?} instruction
         * @param {?} allPreviousPlayersMap
         * @return {?}
         */

      }, {
        key: "_beforeAnimationBuild",
        value: function _beforeAnimationBuild(namespaceId, instruction, allPreviousPlayersMap) {
          var _this35 = this;

          /** @type {?} */
          var triggerName = instruction.triggerName;
          /** @type {?} */

          var rootElement = instruction.element; // when a removal animation occurs, ALL previous players are collected
          // and destroyed (even if they are outside of the current namespace)

          /** @type {?} */

          var targetNameSpaceId = instruction.isRemovalTransition ? undefined : namespaceId;
          /** @type {?} */

          var targetTriggerName = instruction.isRemovalTransition ? undefined : triggerName;

          var _iterator = _createForOfIteratorHelper(instruction.timelines),
              _step;

          try {
            var _loop2 = function _loop2() {
              var timelineInstruction = _step.value;

              /** @type {?} */
              var element = timelineInstruction.element;
              /** @type {?} */

              var isQueriedElement = element !== rootElement;
              /** @type {?} */

              var players = getOrSetAsInMap(allPreviousPlayersMap, element, []);
              /** @type {?} */

              var previousPlayers = _this35._getPreviousPlayers(element, isQueriedElement, targetNameSpaceId, targetTriggerName, instruction.toState);

              previousPlayers.forEach(
              /**
              * @param {?} player
              * @return {?}
              */
              function (player) {
                /** @type {?} */
                var realPlayer =
                /** @type {?} */

                /** @type {?} */
                player.getRealPlayer();

                if (realPlayer.beforeDestroy) {
                  realPlayer.beforeDestroy();
                }

                player.destroy();
                players.push(player);
              });
            };

            for (_iterator.s(); !(_step = _iterator.n()).done;) {
              _loop2();
            } // this needs to be done so that the PRE/POST styles can be
            // computed properly without interfering with the previous animation

          } catch (err) {
            _iterator.e(err);
          } finally {
            _iterator.f();
          }

          eraseStyles(rootElement, instruction.fromStyles);
        }
        /**
         * @private
         * @param {?} namespaceId
         * @param {?} instruction
         * @param {?} allPreviousPlayersMap
         * @param {?} skippedPlayersMap
         * @param {?} preStylesMap
         * @param {?} postStylesMap
         * @return {?}
         */

      }, {
        key: "_buildAnimation",
        value: function _buildAnimation(namespaceId, instruction, allPreviousPlayersMap, skippedPlayersMap, preStylesMap, postStylesMap) {
          var _this36 = this;

          /** @type {?} */
          var triggerName = instruction.triggerName;
          /** @type {?} */

          var rootElement = instruction.element; // we first run this so that the previous animation player
          // data can be passed into the successive animation players

          /** @type {?} */

          var allQueriedPlayers = [];
          /** @type {?} */

          var allConsumedElements = new Set();
          /** @type {?} */

          var allSubElements = new Set();
          /** @type {?} */

          var allNewPlayers = instruction.timelines.map(
          /**
          * @param {?} timelineInstruction
          * @return {?}
          */
          function (timelineInstruction) {
            /** @type {?} */
            var element = timelineInstruction.element;
            allConsumedElements.add(element); // FIXME (matsko): make sure to-be-removed animations are removed properly

            /** @type {?} */

            var details = element[REMOVAL_FLAG];
            if (details && details.removedBeforeQueried) return new _angular_animations__WEBPACK_IMPORTED_MODULE_0__["NoopAnimationPlayer"](timelineInstruction.duration, timelineInstruction.delay);
            /** @type {?} */

            var isQueriedElement = element !== rootElement;
            /** @type {?} */

            var previousPlayers = flattenGroupPlayers((allPreviousPlayersMap.get(element) || EMPTY_PLAYER_ARRAY).map(
            /**
            * @param {?} p
            * @return {?}
            */
            function (p) {
              return p.getRealPlayer();
            })).filter(
            /**
            * @param {?} p
            * @return {?}
            */
            function (p) {
              // the `element` is not apart of the AnimationPlayer definition, but
              // Mock/WebAnimations
              // use the element within their implementation. This will be added in Angular5 to
              // AnimationPlayer

              /** @type {?} */
              var pp =
              /** @type {?} */
              p;
              return pp.element ? pp.element === element : false;
            });
            /** @type {?} */

            var preStyles = preStylesMap.get(element);
            /** @type {?} */

            var postStyles = postStylesMap.get(element);
            /** @type {?} */

            var keyframes = normalizeKeyframes(_this36.driver, _this36._normalizer, element, timelineInstruction.keyframes, preStyles, postStyles);
            /** @type {?} */

            var player = _this36._buildPlayer(timelineInstruction, keyframes, previousPlayers); // this means that this particular player belongs to a sub trigger. It is
            // important that we match this player up with the corresponding (@trigger.listener)


            if (timelineInstruction.subTimeline && skippedPlayersMap) {
              allSubElements.add(element);
            }

            if (isQueriedElement) {
              /** @type {?} */
              var wrappedPlayer = new TransitionAnimationPlayer(namespaceId, triggerName, element);
              wrappedPlayer.setRealPlayer(player);
              allQueriedPlayers.push(wrappedPlayer);
            }

            return player;
          });
          allQueriedPlayers.forEach(
          /**
          * @param {?} player
          * @return {?}
          */
          function (player) {
            getOrSetAsInMap(_this36.playersByQueriedElement, player.element, []).push(player);
            player.onDone(
            /**
            * @return {?}
            */
            function () {
              return deleteOrUnsetInMap(_this36.playersByQueriedElement, player.element, player);
            });
          });
          allConsumedElements.forEach(
          /**
          * @param {?} element
          * @return {?}
          */
          function (element) {
            return addClass(element, NG_ANIMATING_CLASSNAME);
          });
          /** @type {?} */

          var player = optimizeGroupPlayer(allNewPlayers);
          player.onDestroy(
          /**
          * @return {?}
          */
          function () {
            allConsumedElements.forEach(
            /**
            * @param {?} element
            * @return {?}
            */
            function (element) {
              return removeClass(element, NG_ANIMATING_CLASSNAME);
            });
            setStyles(rootElement, instruction.toStyles);
          }); // this basically makes all of the callbacks for sub element animations
          // be dependent on the upper players for when they finish

          allSubElements.forEach(
          /**
          * @param {?} element
          * @return {?}
          */
          function (element) {
            getOrSetAsInMap(skippedPlayersMap, element, []).push(player);
          });
          return player;
        }
        /**
         * @private
         * @param {?} instruction
         * @param {?} keyframes
         * @param {?} previousPlayers
         * @return {?}
         */

      }, {
        key: "_buildPlayer",
        value: function _buildPlayer(instruction, keyframes, previousPlayers) {
          if (keyframes.length > 0) {
            return this.driver.animate(instruction.element, keyframes, instruction.duration, instruction.delay, instruction.easing, previousPlayers);
          } // special case for when an empty transition|definition is provided
          // ... there is no point in rendering an empty animation


          return new _angular_animations__WEBPACK_IMPORTED_MODULE_0__["NoopAnimationPlayer"](instruction.duration, instruction.delay);
        }
      }, {
        key: "queuedPlayers",
        get: function get() {
          /** @type {?} */
          var players = [];

          this._namespaceList.forEach(
          /**
          * @param {?} ns
          * @return {?}
          */
          function (ns) {
            ns.players.forEach(
            /**
            * @param {?} player
            * @return {?}
            */
            function (player) {
              if (player.queued) {
                players.push(player);
              }
            });
          });

          return players;
        }
      }]);

      return TransitionAnimationEngine;
    }();

    if (false) {}

    var TransitionAnimationPlayer = /*#__PURE__*/function () {
      /**
       * @param {?} namespaceId
       * @param {?} triggerName
       * @param {?} element
       */
      function TransitionAnimationPlayer(namespaceId, triggerName, element) {
        _classCallCheck(this, TransitionAnimationPlayer);

        this.namespaceId = namespaceId;
        this.triggerName = triggerName;
        this.element = element;
        this._player = new _angular_animations__WEBPACK_IMPORTED_MODULE_0__["NoopAnimationPlayer"]();
        this._containsRealPlayer = false;
        this._queuedCallbacks = {};
        this.destroyed = false;
        this.markedForDestroy = false;
        this.disabled = false;
        this.queued = true;
        this.totalTime = 0;
      }
      /**
       * @param {?} player
       * @return {?}
       */


      _createClass2(TransitionAnimationPlayer, [{
        key: "setRealPlayer",
        value: function setRealPlayer(player) {
          var _this37 = this;

          if (this._containsRealPlayer) return;
          this._player = player;
          Object.keys(this._queuedCallbacks).forEach(
          /**
          * @param {?} phase
          * @return {?}
          */
          function (phase) {
            _this37._queuedCallbacks[phase].forEach(
            /**
            * @param {?} callback
            * @return {?}
            */
            function (callback) {
              return listenOnPlayer(player, phase, undefined, callback);
            });
          });
          this._queuedCallbacks = {};
          this._containsRealPlayer = true;
          this.overrideTotalTime(player.totalTime);

          /** @type {?} */
          this.queued = false;
        }
        /**
         * @return {?}
         */

      }, {
        key: "getRealPlayer",
        value: function getRealPlayer() {
          return this._player;
        }
        /**
         * @param {?} totalTime
         * @return {?}
         */

      }, {
        key: "overrideTotalTime",
        value: function overrideTotalTime(totalTime) {
          /** @type {?} */
          this.totalTime = totalTime;
        }
        /**
         * @param {?} player
         * @return {?}
         */

      }, {
        key: "syncPlayerEvents",
        value: function syncPlayerEvents(player) {
          var _this38 = this;

          /** @type {?} */
          var p =
          /** @type {?} */
          this._player;

          if (p.triggerCallback) {
            player.onStart(
            /**
            * @return {?}
            */
            function () {
              return (
                /** @type {?} */
                p.triggerCallback('start')
              );
            });
          }

          player.onDone(
          /**
          * @return {?}
          */
          function () {
            return _this38.finish();
          });
          player.onDestroy(
          /**
          * @return {?}
          */
          function () {
            return _this38.destroy();
          });
        }
        /**
         * @private
         * @param {?} name
         * @param {?} callback
         * @return {?}
         */

      }, {
        key: "_queueEvent",
        value: function _queueEvent(name, callback) {
          getOrSetAsInMap(this._queuedCallbacks, name, []).push(callback);
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "onDone",
        value: function onDone(fn) {
          if (this.queued) {
            this._queueEvent('done', fn);
          }

          this._player.onDone(fn);
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "onStart",
        value: function onStart(fn) {
          if (this.queued) {
            this._queueEvent('start', fn);
          }

          this._player.onStart(fn);
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "onDestroy",
        value: function onDestroy(fn) {
          if (this.queued) {
            this._queueEvent('destroy', fn);
          }

          this._player.onDestroy(fn);
        }
        /**
         * @return {?}
         */

      }, {
        key: "init",
        value: function init() {
          this._player.init();
        }
        /**
         * @return {?}
         */

      }, {
        key: "hasStarted",
        value: function hasStarted() {
          return this.queued ? false : this._player.hasStarted();
        }
        /**
         * @return {?}
         */

      }, {
        key: "play",
        value: function play() {
          !this.queued && this._player.play();
        }
        /**
         * @return {?}
         */

      }, {
        key: "pause",
        value: function pause() {
          !this.queued && this._player.pause();
        }
        /**
         * @return {?}
         */

      }, {
        key: "restart",
        value: function restart() {
          !this.queued && this._player.restart();
        }
        /**
         * @return {?}
         */

      }, {
        key: "finish",
        value: function finish() {
          this._player.finish();
        }
        /**
         * @return {?}
         */

      }, {
        key: "destroy",
        value: function destroy() {
          /** @type {?} */
          this.destroyed = true;

          this._player.destroy();
        }
        /**
         * @return {?}
         */

      }, {
        key: "reset",
        value: function reset() {
          !this.queued && this._player.reset();
        }
        /**
         * @param {?} p
         * @return {?}
         */

      }, {
        key: "setPosition",
        value: function setPosition(p) {
          if (!this.queued) {
            this._player.setPosition(p);
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "getPosition",
        value: function getPosition() {
          return this.queued ? 0 : this._player.getPosition();
        }
        /**
         * \@internal
         * @param {?} phaseName
         * @return {?}
         */

      }, {
        key: "triggerCallback",
        value: function triggerCallback(phaseName) {
          /** @type {?} */
          var p =
          /** @type {?} */
          this._player;

          if (p.triggerCallback) {
            p.triggerCallback(phaseName);
          }
        }
      }]);

      return TransitionAnimationPlayer;
    }();

    if (false) {}
    /**
     * @param {?} map
     * @param {?} key
     * @param {?} value
     * @return {?}
     */


    function deleteOrUnsetInMap(map, key, value) {
      /** @type {?} */
      var currentValues;

      if (map instanceof Map) {
        currentValues = map.get(key);

        if (currentValues) {
          if (currentValues.length) {
            /** @type {?} */
            var index = currentValues.indexOf(value);
            currentValues.splice(index, 1);
          }

          if (currentValues.length == 0) {
            map["delete"](key);
          }
        }
      } else {
        currentValues = map[key];

        if (currentValues) {
          if (currentValues.length) {
            /** @type {?} */
            var _index2 = currentValues.indexOf(value);

            currentValues.splice(_index2, 1);
          }

          if (currentValues.length == 0) {
            delete map[key];
          }
        }
      }

      return currentValues;
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function normalizeTriggerValue(value) {
      // we use `!= null` here because it's the most simple
      // way to test against a "falsy" value without mixing
      // in empty strings or a zero value. DO NOT OPTIMIZE.
      return value != null ? value : null;
    }
    /**
     * @param {?} node
     * @return {?}
     */


    function isElementNode(node) {
      return node && node['nodeType'] === 1;
    }
    /**
     * @param {?} eventName
     * @return {?}
     */


    function isTriggerEventValid(eventName) {
      return eventName == 'start' || eventName == 'done';
    }
    /**
     * @param {?} element
     * @param {?=} value
     * @return {?}
     */


    function cloakElement(element, value) {
      /** @type {?} */
      var oldValue = element.style.display;
      element.style.display = value != null ? value : 'none';
      return oldValue;
    }
    /**
     * @param {?} valuesMap
     * @param {?} driver
     * @param {?} elements
     * @param {?} elementPropsMap
     * @param {?} defaultStyle
     * @return {?}
     */


    function cloakAndComputeStyles(valuesMap, driver, elements, elementPropsMap, defaultStyle) {
      /** @type {?} */
      var cloakVals = [];
      elements.forEach(
      /**
      * @param {?} element
      * @return {?}
      */
      function (element) {
        return cloakVals.push(cloakElement(element));
      });
      /** @type {?} */

      var failedElements = [];
      elementPropsMap.forEach(
      /**
      * @param {?} props
      * @param {?} element
      * @return {?}
      */
      function (props, element) {
        /** @type {?} */
        var styles = {};
        props.forEach(
        /**
        * @param {?} prop
        * @return {?}
        */
        function (prop) {
          /** @type {?} */
          var value = styles[prop] = driver.computeStyle(element, prop, defaultStyle); // there is no easy way to detect this because a sub element could be removed
          // by a parent animation element being detached.

          if (!value || value.length == 0) {
            element[REMOVAL_FLAG] = NULL_REMOVED_QUERIED_STATE;
            failedElements.push(element);
          }
        });
        valuesMap.set(element, styles);
      }); // we use a index variable here since Set.forEach(a, i) does not return
      // an index value for the closure (but instead just the value)

      /** @type {?} */

      var i = 0;
      elements.forEach(
      /**
      * @param {?} element
      * @return {?}
      */
      function (element) {
        return cloakElement(element, cloakVals[i++]);
      });
      return failedElements;
    }
    /*
    Since the Angular renderer code will return a collection of inserted
    nodes in all areas of a DOM tree, it's up to this algorithm to figure
    out which nodes are roots for each animation @trigger.
    
    By placing each inserted node into a Set and traversing upwards, it
    is possible to find the @trigger elements and well any direct *star
    insertion nodes, if a @trigger root is found then the enter element
    is placed into the Map[@trigger] spot.
     */

    /**
     * @param {?} roots
     * @param {?} nodes
     * @return {?}
     */


    function buildRootMap(roots, nodes) {
      /** @type {?} */
      var rootMap = new Map();
      roots.forEach(
      /**
      * @param {?} root
      * @return {?}
      */
      function (root) {
        return rootMap.set(root, []);
      });
      if (nodes.length == 0) return rootMap;
      /** @type {?} */

      var NULL_NODE = 1;
      /** @type {?} */

      var nodeSet = new Set(nodes);
      /** @type {?} */

      var localRootMap = new Map();
      /**
       * @param {?} node
       * @return {?}
       */

      function getRoot(node) {
        if (!node) return NULL_NODE;
        /** @type {?} */

        var root = localRootMap.get(node);
        if (root) return root;
        /** @type {?} */

        var parent = node.parentNode;

        if (rootMap.has(parent)) {
          // ngIf inside @trigger
          root = parent;
        } else if (nodeSet.has(parent)) {
          // ngIf inside ngIf
          root = NULL_NODE;
        } else {
          // recurse upwards
          root = getRoot(parent);
        }

        localRootMap.set(node, root);
        return root;
      }

      nodes.forEach(
      /**
      * @param {?} node
      * @return {?}
      */
      function (node) {
        /** @type {?} */
        var root = getRoot(node);

        if (root !== NULL_NODE) {
          /** @type {?} */
          rootMap.get(root).push(node);
        }
      });
      return rootMap;
    }
    /** @type {?} */


    var CLASSES_CACHE_KEY = '$$classes';
    /**
     * @param {?} element
     * @param {?} className
     * @return {?}
     */

    function containsClass(element, className) {
      if (element.classList) {
        return element.classList.contains(className);
      } else {
        /** @type {?} */
        var classes = element[CLASSES_CACHE_KEY];
        return classes && classes[className];
      }
    }
    /**
     * @param {?} element
     * @param {?} className
     * @return {?}
     */


    function addClass(element, className) {
      if (element.classList) {
        element.classList.add(className);
      } else {
        /** @type {?} */
        var classes = element[CLASSES_CACHE_KEY];

        if (!classes) {
          classes = element[CLASSES_CACHE_KEY] = {};
        }

        classes[className] = true;
      }
    }
    /**
     * @param {?} element
     * @param {?} className
     * @return {?}
     */


    function removeClass(element, className) {
      if (element.classList) {
        element.classList.remove(className);
      } else {
        /** @type {?} */
        var classes = element[CLASSES_CACHE_KEY];

        if (classes) {
          delete classes[className];
        }
      }
    }
    /**
     * @param {?} engine
     * @param {?} element
     * @param {?} players
     * @return {?}
     */


    function removeNodesAfterAnimationDone(engine, element, players) {
      optimizeGroupPlayer(players).onDone(
      /**
      * @return {?}
      */
      function () {
        return engine.processLeaveNode(element);
      });
    }
    /**
     * @param {?} players
     * @return {?}
     */


    function flattenGroupPlayers(players) {
      /** @type {?} */
      var finalPlayers = [];

      _flattenGroupPlayersRecur(players, finalPlayers);

      return finalPlayers;
    }
    /**
     * @param {?} players
     * @param {?} finalPlayers
     * @return {?}
     */


    function _flattenGroupPlayersRecur(players, finalPlayers) {
      for (var i = 0; i < players.length; i++) {
        /** @type {?} */
        var player = players[i];

        if (player instanceof _angular_animations__WEBPACK_IMPORTED_MODULE_0__["ɵAnimationGroupPlayer"]) {
          _flattenGroupPlayersRecur(player.players, finalPlayers);
        } else {
          finalPlayers.push(player);
        }
      }
    }
    /**
     * @param {?} a
     * @param {?} b
     * @return {?}
     */


    function objEquals(a, b) {
      /** @type {?} */
      var k1 = Object.keys(a);
      /** @type {?} */

      var k2 = Object.keys(b);
      if (k1.length != k2.length) return false;

      for (var i = 0; i < k1.length; i++) {
        /** @type {?} */
        var prop = k1[i];
        if (!b.hasOwnProperty(prop) || a[prop] !== b[prop]) return false;
      }

      return true;
    }
    /**
     * @param {?} element
     * @param {?} allPreStyleElements
     * @param {?} allPostStyleElements
     * @return {?}
     */


    function replacePostStylesAsPre(element, allPreStyleElements, allPostStyleElements) {
      /** @type {?} */
      var postEntry = allPostStyleElements.get(element);
      if (!postEntry) return false;
      /** @type {?} */

      var preEntry = allPreStyleElements.get(element);

      if (preEntry) {
        postEntry.forEach(
        /**
        * @param {?} data
        * @return {?}
        */
        function (data) {
          return (
            /** @type {?} */
            preEntry.add(data)
          );
        });
      } else {
        allPreStyleElements.set(element, postEntry);
      }

      allPostStyleElements["delete"](element);
      return true;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/render/animation_engine_next.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var AnimationEngine = /*#__PURE__*/function () {
      /**
       * @param {?} bodyNode
       * @param {?} _driver
       * @param {?} normalizer
       */
      function AnimationEngine(bodyNode, _driver, normalizer) {
        var _this39 = this;

        _classCallCheck(this, AnimationEngine);

        this.bodyNode = bodyNode;
        this._driver = _driver;
        this._triggerCache = {}; // this method is designed to be overridden by the code that uses this engine

        this.onRemovalComplete =
        /**
        * @param {?} element
        * @param {?} context
        * @return {?}
        */
        function (element, context) {};

        this._transitionEngine = new TransitionAnimationEngine(bodyNode, _driver, normalizer);
        this._timelineEngine = new TimelineAnimationEngine(bodyNode, _driver, normalizer);

        this._transitionEngine.onRemovalComplete =
        /**
        * @param {?} element
        * @param {?} context
        * @return {?}
        */
        function (element, context) {
          return _this39.onRemovalComplete(element, context);
        };
      }
      /**
       * @param {?} componentId
       * @param {?} namespaceId
       * @param {?} hostElement
       * @param {?} name
       * @param {?} metadata
       * @return {?}
       */


      _createClass2(AnimationEngine, [{
        key: "registerTrigger",
        value: function registerTrigger(componentId, namespaceId, hostElement, name, metadata) {
          /** @type {?} */
          var cacheKey = componentId + '-' + name;
          /** @type {?} */

          var trigger = this._triggerCache[cacheKey];

          if (!trigger) {
            /** @type {?} */
            var errors = [];
            /** @type {?} */

            var ast =
            /** @type {?} */
            buildAnimationAst(this._driver,
            /** @type {?} */
            metadata, errors);

            if (errors.length) {
              throw new Error("The animation trigger \"".concat(name, "\" has failed to build due to the following errors:\n - ").concat(errors.join('\n - ')));
            }

            trigger = buildTrigger(name, ast);
            this._triggerCache[cacheKey] = trigger;
          }

          this._transitionEngine.registerTrigger(namespaceId, name, trigger);
        }
        /**
         * @param {?} namespaceId
         * @param {?} hostElement
         * @return {?}
         */

      }, {
        key: "register",
        value: function register(namespaceId, hostElement) {
          this._transitionEngine.register(namespaceId, hostElement);
        }
        /**
         * @param {?} namespaceId
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "destroy",
        value: function destroy(namespaceId, context) {
          this._transitionEngine.destroy(namespaceId, context);
        }
        /**
         * @param {?} namespaceId
         * @param {?} element
         * @param {?} parent
         * @param {?} insertBefore
         * @return {?}
         */

      }, {
        key: "onInsert",
        value: function onInsert(namespaceId, element, parent, insertBefore) {
          this._transitionEngine.insertNode(namespaceId, element, parent, insertBefore);
        }
        /**
         * @param {?} namespaceId
         * @param {?} element
         * @param {?} context
         * @param {?=} isHostElement
         * @return {?}
         */

      }, {
        key: "onRemove",
        value: function onRemove(namespaceId, element, context, isHostElement) {
          this._transitionEngine.removeNode(namespaceId, element, isHostElement || false, context);
        }
        /**
         * @param {?} element
         * @param {?} disable
         * @return {?}
         */

      }, {
        key: "disableAnimations",
        value: function disableAnimations(element, disable) {
          this._transitionEngine.markElementAsDisabled(element, disable);
        }
        /**
         * @param {?} namespaceId
         * @param {?} element
         * @param {?} property
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "process",
        value: function process(namespaceId, element, property, value) {
          if (property.charAt(0) == '@') {
            var _parseTimelineCommand = parseTimelineCommand(property),
                _parseTimelineCommand2 = _slicedToArray(_parseTimelineCommand, 2),
                id = _parseTimelineCommand2[0],
                action = _parseTimelineCommand2[1];
            /** @type {?} */


            var args =
            /** @type {?} */
            value;

            this._timelineEngine.command(id, element, action, args);
          } else {
            this._transitionEngine.trigger(namespaceId, element, property, value);
          }
        }
        /**
         * @param {?} namespaceId
         * @param {?} element
         * @param {?} eventName
         * @param {?} eventPhase
         * @param {?} callback
         * @return {?}
         */

      }, {
        key: "listen",
        value: function listen(namespaceId, element, eventName, eventPhase, callback) {
          // @@listen
          if (eventName.charAt(0) == '@') {
            var _parseTimelineCommand3 = parseTimelineCommand(eventName),
                _parseTimelineCommand4 = _slicedToArray(_parseTimelineCommand3, 2),
                id = _parseTimelineCommand4[0],
                action = _parseTimelineCommand4[1];

            return this._timelineEngine.listen(id, element, action, callback);
          }

          return this._transitionEngine.listen(namespaceId, element, eventName, eventPhase, callback);
        }
        /**
         * @param {?=} microtaskId
         * @return {?}
         */

      }, {
        key: "flush",
        value: function flush() {
          var microtaskId = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : -1;

          this._transitionEngine.flush(microtaskId);
        }
        /**
         * @return {?}
         */

      }, {
        key: "whenRenderingDone",

        /**
         * @return {?}
         */
        value: function whenRenderingDone() {
          return this._transitionEngine.whenRenderingDone();
        }
      }, {
        key: "players",
        get: function get() {
          return (
            /** @type {?} */
            this._transitionEngine.players.concat(
            /** @type {?} */
            this._timelineEngine.players)
          );
        }
      }]);

      return AnimationEngine;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/render/special_cased_styles.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Returns an instance of `SpecialCasedStyles` if and when any special (non animateable) styles are
     * detected.
     *
     * In CSS there exist properties that cannot be animated within a keyframe animation
     * (whether it be via CSS keyframes or web-animations) and the animation implementation
     * will ignore them. This function is designed to detect those special cased styles and
     * return a container that will be executed at the start and end of the animation.
     *
     * @param {?} element
     * @param {?} styles
     * @return {?} an instance of `SpecialCasedStyles` if any special styles are detected otherwise `null`
     */


    function packageNonAnimatableStyles(element, styles) {
      /** @type {?} */
      var startStyles = null;
      /** @type {?} */

      var endStyles = null;

      if (Array.isArray(styles) && styles.length) {
        startStyles = filterNonAnimatableStyles(styles[0]);

        if (styles.length > 1) {
          endStyles = filterNonAnimatableStyles(styles[styles.length - 1]);
        }
      } else if (styles) {
        startStyles = filterNonAnimatableStyles(styles);
      }

      return startStyles || endStyles ? new SpecialCasedStyles(element, startStyles, endStyles) : null;
    }
    /**
     * Designed to be executed during a keyframe-based animation to apply any special-cased styles.
     *
     * When started (when the `start()` method is run) then the provided `startStyles`
     * will be applied. When finished (when the `finish()` method is called) the
     * `endStyles` will be applied as well any any starting styles. Finally when
     * `destroy()` is called then all styles will be removed.
     */


    var SpecialCasedStyles = /*#__PURE__*/function () {
      /**
       * @param {?} _element
       * @param {?} _startStyles
       * @param {?} _endStyles
       */
      function SpecialCasedStyles(_element, _startStyles, _endStyles) {
        _classCallCheck(this, SpecialCasedStyles);

        this._element = _element;
        this._startStyles = _startStyles;
        this._endStyles = _endStyles;
        this._state = 0
        /* Pending */
        ;
        /** @type {?} */

        var initialStyles = SpecialCasedStyles.initialStylesByElement.get(_element);

        if (!initialStyles) {
          SpecialCasedStyles.initialStylesByElement.set(_element, initialStyles = {});
        }

        this._initialStyles = initialStyles;
      }
      /**
       * @return {?}
       */


      _createClass2(SpecialCasedStyles, [{
        key: "start",
        value: function start() {
          if (this._state < 1
          /* Started */
          ) {
              if (this._startStyles) {
                setStyles(this._element, this._startStyles, this._initialStyles);
              }

              this._state = 1
              /* Started */
              ;
            }
        }
        /**
         * @return {?}
         */

      }, {
        key: "finish",
        value: function finish() {
          this.start();

          if (this._state < 2
          /* Finished */
          ) {
              setStyles(this._element, this._initialStyles);

              if (this._endStyles) {
                setStyles(this._element, this._endStyles);
                this._endStyles = null;
              }

              this._state = 1
              /* Started */
              ;
            }
        }
        /**
         * @return {?}
         */

      }, {
        key: "destroy",
        value: function destroy() {
          this.finish();

          if (this._state < 3
          /* Destroyed */
          ) {
              SpecialCasedStyles.initialStylesByElement["delete"](this._element);

              if (this._startStyles) {
                eraseStyles(this._element, this._startStyles);
                this._endStyles = null;
              }

              if (this._endStyles) {
                eraseStyles(this._element, this._endStyles);
                this._endStyles = null;
              }

              setStyles(this._element, this._initialStyles);
              this._state = 3
              /* Destroyed */
              ;
            }
        }
      }]);

      return SpecialCasedStyles;
    }();

    SpecialCasedStyles.initialStylesByElement = new WeakMap();

    if (false) {}
    /** @enum {number} */


    var SpecialCasedStylesState = {
      Pending: 0,
      Started: 1,
      Finished: 2,
      Destroyed: 3
    };
    /**
     * @param {?} styles
     * @return {?}
     */

    function filterNonAnimatableStyles(styles) {
      /** @type {?} */
      var result = null;
      /** @type {?} */

      var props = Object.keys(styles);

      for (var i = 0; i < props.length; i++) {
        /** @type {?} */
        var prop = props[i];

        if (isNonAnimatableStyle(prop)) {
          result = result || {};
          result[prop] = styles[prop];
        }
      }

      return result;
    }
    /**
     * @param {?} prop
     * @return {?}
     */


    function isNonAnimatableStyle(prop) {
      return prop === 'display' || prop === 'position';
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/render/css_keyframes/element_animation_style_handler.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     * @type {?}
     */


    var ELAPSED_TIME_MAX_DECIMAL_PLACES = 3;
    /** @type {?} */

    var ANIMATION_PROP = 'animation';
    /** @type {?} */

    var ANIMATIONEND_EVENT = 'animationend';
    /** @type {?} */

    var ONE_SECOND$1 = 1000;

    var ElementAnimationStyleHandler = /*#__PURE__*/function () {
      /**
       * @param {?} _element
       * @param {?} _name
       * @param {?} _duration
       * @param {?} _delay
       * @param {?} _easing
       * @param {?} _fillMode
       * @param {?} _onDoneFn
       */
      function ElementAnimationStyleHandler(_element, _name, _duration, _delay, _easing, _fillMode, _onDoneFn) {
        var _this40 = this;

        _classCallCheck(this, ElementAnimationStyleHandler);

        this._element = _element;
        this._name = _name;
        this._duration = _duration;
        this._delay = _delay;
        this._easing = _easing;
        this._fillMode = _fillMode;
        this._onDoneFn = _onDoneFn;
        this._finished = false;
        this._destroyed = false;
        this._startTime = 0;
        this._position = 0;

        this._eventFn =
        /**
        * @param {?} e
        * @return {?}
        */
        function (e) {
          return _this40._handleCallback(e);
        };
      }
      /**
       * @return {?}
       */


      _createClass2(ElementAnimationStyleHandler, [{
        key: "apply",
        value: function apply() {
          applyKeyframeAnimation(this._element, "".concat(this._duration, "ms ").concat(this._easing, " ").concat(this._delay, "ms 1 normal ").concat(this._fillMode, " ").concat(this._name));
          addRemoveAnimationEvent(this._element, this._eventFn, false);
          this._startTime = Date.now();
        }
        /**
         * @return {?}
         */

      }, {
        key: "pause",
        value: function pause() {
          playPauseAnimation(this._element, this._name, 'paused');
        }
        /**
         * @return {?}
         */

      }, {
        key: "resume",
        value: function resume() {
          playPauseAnimation(this._element, this._name, 'running');
        }
        /**
         * @param {?} position
         * @return {?}
         */

      }, {
        key: "setPosition",
        value: function setPosition(position) {
          /** @type {?} */
          var index = findIndexForAnimation(this._element, this._name);
          this._position = position * this._duration;
          setAnimationStyle(this._element, 'Delay', "-".concat(this._position, "ms"), index);
        }
        /**
         * @return {?}
         */

      }, {
        key: "getPosition",
        value: function getPosition() {
          return this._position;
        }
        /**
         * @private
         * @param {?} event
         * @return {?}
         */

      }, {
        key: "_handleCallback",
        value: function _handleCallback(event) {
          /** @type {?} */
          var timestamp = event._ngTestManualTimestamp || Date.now();
          /** @type {?} */

          var elapsedTime = parseFloat(event.elapsedTime.toFixed(ELAPSED_TIME_MAX_DECIMAL_PLACES)) * ONE_SECOND$1;

          if (event.animationName == this._name && Math.max(timestamp - this._startTime, 0) >= this._delay && elapsedTime >= this._duration) {
            this.finish();
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "finish",
        value: function finish() {
          if (this._finished) return;
          this._finished = true;

          this._onDoneFn();

          addRemoveAnimationEvent(this._element, this._eventFn, true);
        }
        /**
         * @return {?}
         */

      }, {
        key: "destroy",
        value: function destroy() {
          if (this._destroyed) return;
          this._destroyed = true;
          this.finish();
          removeKeyframeAnimation(this._element, this._name);
        }
      }]);

      return ElementAnimationStyleHandler;
    }();

    if (false) {}
    /**
     * @param {?} element
     * @param {?} name
     * @param {?} status
     * @return {?}
     */


    function playPauseAnimation(element, name, status) {
      /** @type {?} */
      var index = findIndexForAnimation(element, name);
      setAnimationStyle(element, 'PlayState', status, index);
    }
    /**
     * @param {?} element
     * @param {?} value
     * @return {?}
     */


    function applyKeyframeAnimation(element, value) {
      /** @type {?} */
      var anim = getAnimationStyle(element, '').trim();
      /** @type {?} */

      var index = 0;

      if (anim.length) {
        index = countChars(anim, ',') + 1;
        value = "".concat(anim, ", ").concat(value);
      }

      setAnimationStyle(element, '', value);
      return index;
    }
    /**
     * @param {?} element
     * @param {?} name
     * @return {?}
     */


    function removeKeyframeAnimation(element, name) {
      /** @type {?} */
      var anim = getAnimationStyle(element, '');
      /** @type {?} */

      var tokens = anim.split(',');
      /** @type {?} */

      var index = findMatchingTokenIndex(tokens, name);

      if (index >= 0) {
        tokens.splice(index, 1);
        /** @type {?} */

        var newValue = tokens.join(',');
        setAnimationStyle(element, '', newValue);
      }
    }
    /**
     * @param {?} element
     * @param {?} value
     * @return {?}
     */


    function findIndexForAnimation(element, value) {
      /** @type {?} */
      var anim = getAnimationStyle(element, '');

      if (anim.indexOf(',') > 0) {
        /** @type {?} */
        var tokens = anim.split(',');
        return findMatchingTokenIndex(tokens, value);
      }

      return findMatchingTokenIndex([anim], value);
    }
    /**
     * @param {?} tokens
     * @param {?} searchToken
     * @return {?}
     */


    function findMatchingTokenIndex(tokens, searchToken) {
      for (var i = 0; i < tokens.length; i++) {
        if (tokens[i].indexOf(searchToken) >= 0) {
          return i;
        }
      }

      return -1;
    }
    /**
     * @param {?} element
     * @param {?} fn
     * @param {?} doRemove
     * @return {?}
     */


    function addRemoveAnimationEvent(element, fn, doRemove) {
      doRemove ? element.removeEventListener(ANIMATIONEND_EVENT, fn) : element.addEventListener(ANIMATIONEND_EVENT, fn);
    }
    /**
     * @param {?} element
     * @param {?} name
     * @param {?} value
     * @param {?=} index
     * @return {?}
     */


    function setAnimationStyle(element, name, value, index) {
      /** @type {?} */
      var prop = ANIMATION_PROP + name;

      if (index != null) {
        /** @type {?} */
        var oldValue = element.style[prop];

        if (oldValue.length) {
          /** @type {?} */
          var tokens = oldValue.split(',');
          tokens[index] = value;
          value = tokens.join(',');
        }
      }

      element.style[prop] = value;
    }
    /**
     * @param {?} element
     * @param {?} name
     * @return {?}
     */


    function getAnimationStyle(element, name) {
      return element.style[ANIMATION_PROP + name];
    }
    /**
     * @param {?} value
     * @param {?} char
     * @return {?}
     */


    function countChars(value, _char) {
      /** @type {?} */
      var count = 0;

      for (var i = 0; i < value.length; i++) {
        /** @type {?} */
        var c = value.charAt(i);
        if (c === _char) count++;
      }

      return count;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/render/css_keyframes/css_keyframes_player.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var DEFAULT_FILL_MODE = 'forwards';
    /** @type {?} */

    var DEFAULT_EASING = 'linear';
    /** @enum {number} */

    var AnimatorControlState = {
      INITIALIZED: 1,
      STARTED: 2,
      FINISHED: 3,
      DESTROYED: 4
    };

    var CssKeyframesPlayer = /*#__PURE__*/function () {
      /**
       * @param {?} element
       * @param {?} keyframes
       * @param {?} animationName
       * @param {?} _duration
       * @param {?} _delay
       * @param {?} easing
       * @param {?} _finalStyles
       * @param {?=} _specialStyles
       */
      function CssKeyframesPlayer(element, keyframes, animationName, _duration, _delay, easing, _finalStyles, _specialStyles) {
        _classCallCheck(this, CssKeyframesPlayer);

        this.element = element;
        this.keyframes = keyframes;
        this.animationName = animationName;
        this._duration = _duration;
        this._delay = _delay;
        this._finalStyles = _finalStyles;
        this._specialStyles = _specialStyles;
        this._onDoneFns = [];
        this._onStartFns = [];
        this._onDestroyFns = [];
        this._started = false;
        this.currentSnapshot = {};
        this._state = 0;
        this.easing = easing || DEFAULT_EASING;
        this.totalTime = _duration + _delay;

        this._buildStyler();
      }
      /**
       * @param {?} fn
       * @return {?}
       */


      _createClass2(CssKeyframesPlayer, [{
        key: "onStart",
        value: function onStart(fn) {
          this._onStartFns.push(fn);
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "onDone",
        value: function onDone(fn) {
          this._onDoneFns.push(fn);
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "onDestroy",
        value: function onDestroy(fn) {
          this._onDestroyFns.push(fn);
        }
        /**
         * @return {?}
         */

      }, {
        key: "destroy",
        value: function destroy() {
          this.init();
          if (this._state >= 4
          /* DESTROYED */
          ) return;
          this._state = 4
          /* DESTROYED */
          ;

          this._styler.destroy();

          this._flushStartFns();

          this._flushDoneFns();

          if (this._specialStyles) {
            this._specialStyles.destroy();
          }

          this._onDestroyFns.forEach(
          /**
          * @param {?} fn
          * @return {?}
          */
          function (fn) {
            return fn();
          });

          this._onDestroyFns = [];
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_flushDoneFns",
        value: function _flushDoneFns() {
          this._onDoneFns.forEach(
          /**
          * @param {?} fn
          * @return {?}
          */
          function (fn) {
            return fn();
          });

          this._onDoneFns = [];
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_flushStartFns",
        value: function _flushStartFns() {
          this._onStartFns.forEach(
          /**
          * @param {?} fn
          * @return {?}
          */
          function (fn) {
            return fn();
          });

          this._onStartFns = [];
        }
        /**
         * @return {?}
         */

      }, {
        key: "finish",
        value: function finish() {
          this.init();
          if (this._state >= 3
          /* FINISHED */
          ) return;
          this._state = 3
          /* FINISHED */
          ;

          this._styler.finish();

          this._flushStartFns();

          if (this._specialStyles) {
            this._specialStyles.finish();
          }

          this._flushDoneFns();
        }
        /**
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "setPosition",
        value: function setPosition(value) {
          this._styler.setPosition(value);
        }
        /**
         * @return {?}
         */

      }, {
        key: "getPosition",
        value: function getPosition() {
          return this._styler.getPosition();
        }
        /**
         * @return {?}
         */

      }, {
        key: "hasStarted",
        value: function hasStarted() {
          return this._state >= 2
          /* STARTED */
          ;
        }
        /**
         * @return {?}
         */

      }, {
        key: "init",
        value: function init() {
          if (this._state >= 1
          /* INITIALIZED */
          ) return;
          this._state = 1
          /* INITIALIZED */
          ;
          /** @type {?} */

          var elm = this.element;

          this._styler.apply();

          if (this._delay) {
            this._styler.pause();
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "play",
        value: function play() {
          this.init();

          if (!this.hasStarted()) {
            this._flushStartFns();

            this._state = 2
            /* STARTED */
            ;

            if (this._specialStyles) {
              this._specialStyles.start();
            }
          }

          this._styler.resume();
        }
        /**
         * @return {?}
         */

      }, {
        key: "pause",
        value: function pause() {
          this.init();

          this._styler.pause();
        }
        /**
         * @return {?}
         */

      }, {
        key: "restart",
        value: function restart() {
          this.reset();
          this.play();
        }
        /**
         * @return {?}
         */

      }, {
        key: "reset",
        value: function reset() {
          this._styler.destroy();

          this._buildStyler();

          this._styler.apply();
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_buildStyler",
        value: function _buildStyler() {
          var _this41 = this;

          this._styler = new ElementAnimationStyleHandler(this.element, this.animationName, this._duration, this._delay, this.easing, DEFAULT_FILL_MODE,
          /**
          * @return {?}
          */
          function () {
            return _this41.finish();
          });
        }
        /**
         * \@internal
         * @param {?} phaseName
         * @return {?}
         */

      }, {
        key: "triggerCallback",
        value: function triggerCallback(phaseName) {
          /** @type {?} */
          var methods = phaseName == 'start' ? this._onStartFns : this._onDoneFns;
          methods.forEach(
          /**
          * @param {?} fn
          * @return {?}
          */
          function (fn) {
            return fn();
          });
          methods.length = 0;
        }
        /**
         * @return {?}
         */

      }, {
        key: "beforeDestroy",
        value: function beforeDestroy() {
          var _this42 = this;

          this.init();
          /** @type {?} */

          var styles = {};

          if (this.hasStarted()) {
            /** @type {?} */
            var finished = this._state >= 3
            /* FINISHED */
            ;
            Object.keys(this._finalStyles).forEach(
            /**
            * @param {?} prop
            * @return {?}
            */
            function (prop) {
              if (prop != 'offset') {
                styles[prop] = finished ? _this42._finalStyles[prop] : computeStyle(_this42.element, prop);
              }
            });
          }

          this.currentSnapshot = styles;
        }
      }]);

      return CssKeyframesPlayer;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/render/css_keyframes/direct_style_player.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var DirectStylePlayer = /*#__PURE__*/function (_angular_animations__) {
      _inherits(DirectStylePlayer, _angular_animations__);

      var _super3 = _createSuper(DirectStylePlayer);

      /**
       * @param {?} element
       * @param {?} styles
       */
      function DirectStylePlayer(element, styles) {
        var _this43;

        _classCallCheck(this, DirectStylePlayer);

        _this43 = _super3.call(this);
        _this43.element = element;
        _this43._startingStyles = {};
        _this43.__initialized = false;
        _this43._styles = hypenatePropsObject(styles);
        return _this43;
      }
      /**
       * @return {?}
       */


      _createClass2(DirectStylePlayer, [{
        key: "init",
        value: function init() {
          var _this44 = this;

          if (this.__initialized || !this._startingStyles) return;
          this.__initialized = true;
          Object.keys(this._styles).forEach(
          /**
          * @param {?} prop
          * @return {?}
          */
          function (prop) {
            /** @type {?} */
            _this44._startingStyles[prop] = _this44.element.style[prop];
          });

          _get(_getPrototypeOf(DirectStylePlayer.prototype), "init", this).call(this);
        }
        /**
         * @return {?}
         */

      }, {
        key: "play",
        value: function play() {
          var _this45 = this;

          if (!this._startingStyles) return;
          this.init();
          Object.keys(this._styles).forEach(
          /**
          * @param {?} prop
          * @return {?}
          */
          function (prop) {
            return _this45.element.style.setProperty(prop, _this45._styles[prop]);
          });

          _get(_getPrototypeOf(DirectStylePlayer.prototype), "play", this).call(this);
        }
        /**
         * @return {?}
         */

      }, {
        key: "destroy",
        value: function destroy() {
          var _this46 = this;

          if (!this._startingStyles) return;
          Object.keys(this._startingStyles).forEach(
          /**
          * @param {?} prop
          * @return {?}
          */
          function (prop) {
            /** @type {?} */
            var value =
            /** @type {?} */
            _this46._startingStyles[prop];

            if (value) {
              _this46.element.style.setProperty(prop, value);
            } else {
              _this46.element.style.removeProperty(prop);
            }
          });
          this._startingStyles = null;

          _get(_getPrototypeOf(DirectStylePlayer.prototype), "destroy", this).call(this);
        }
      }]);

      return DirectStylePlayer;
    }(_angular_animations__WEBPACK_IMPORTED_MODULE_0__["NoopAnimationPlayer"]);

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/render/css_keyframes/css_keyframes_driver.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var KEYFRAMES_NAME_PREFIX = 'gen_css_kf_';
    /** @type {?} */

    var TAB_SPACE = ' ';

    var CssKeyframesDriver = /*#__PURE__*/function () {
      function CssKeyframesDriver() {
        _classCallCheck(this, CssKeyframesDriver);

        this._count = 0;
        this._head = document.querySelector('head');
        this._warningIssued = false;
      }
      /**
       * @param {?} prop
       * @return {?}
       */


      _createClass2(CssKeyframesDriver, [{
        key: "validateStyleProperty",
        value: function validateStyleProperty(prop) {
          return _validateStyleProperty(prop);
        }
        /**
         * @param {?} element
         * @param {?} selector
         * @return {?}
         */

      }, {
        key: "matchesElement",
        value: function matchesElement(element, selector) {
          return _matchesElement(element, selector);
        }
        /**
         * @param {?} elm1
         * @param {?} elm2
         * @return {?}
         */

      }, {
        key: "containsElement",
        value: function containsElement(elm1, elm2) {
          return _containsElement(elm1, elm2);
        }
        /**
         * @param {?} element
         * @param {?} selector
         * @param {?} multi
         * @return {?}
         */

      }, {
        key: "query",
        value: function query(element, selector, multi) {
          return invokeQuery(element, selector, multi);
        }
        /**
         * @param {?} element
         * @param {?} prop
         * @param {?=} defaultValue
         * @return {?}
         */

      }, {
        key: "computeStyle",
        value: function computeStyle(element, prop, defaultValue) {
          return (
            /** @type {?} */

            /** @type {?} */
            window.getComputedStyle(element)[prop]
          );
        }
        /**
         * @param {?} element
         * @param {?} name
         * @param {?} keyframes
         * @return {?}
         */

      }, {
        key: "buildKeyframeElement",
        value: function buildKeyframeElement(element, name, keyframes) {
          keyframes = keyframes.map(
          /**
          * @param {?} kf
          * @return {?}
          */
          function (kf) {
            return hypenatePropsObject(kf);
          });
          /** @type {?} */

          var keyframeStr = "@keyframes ".concat(name, " {\n");
          /** @type {?} */

          var tab = '';
          keyframes.forEach(
          /**
          * @param {?} kf
          * @return {?}
          */
          function (kf) {
            tab = TAB_SPACE;
            /** @type {?} */

            var offset = parseFloat(kf['offset']);
            keyframeStr += "".concat(tab).concat(offset * 100, "% {\n");
            tab += TAB_SPACE;
            Object.keys(kf).forEach(
            /**
            * @param {?} prop
            * @return {?}
            */
            function (prop) {
              /** @type {?} */
              var value = kf[prop];

              switch (prop) {
                case 'offset':
                  return;

                case 'easing':
                  if (value) {
                    keyframeStr += "".concat(tab, "animation-timing-function: ").concat(value, ";\n");
                  }

                  return;

                default:
                  keyframeStr += "".concat(tab).concat(prop, ": ").concat(value, ";\n");
                  return;
              }
            });
            keyframeStr += "".concat(tab, "}\n");
          });
          keyframeStr += "}\n";
          /** @type {?} */

          var kfElm = document.createElement('style');
          kfElm.innerHTML = keyframeStr;
          return kfElm;
        }
        /**
         * @param {?} element
         * @param {?} keyframes
         * @param {?} duration
         * @param {?} delay
         * @param {?} easing
         * @param {?=} previousPlayers
         * @param {?=} scrubberAccessRequested
         * @return {?}
         */

      }, {
        key: "animate",
        value: function animate(element, keyframes, duration, delay, easing) {
          var previousPlayers = arguments.length > 5 && arguments[5] !== undefined ? arguments[5] : [];
          var scrubberAccessRequested = arguments.length > 6 ? arguments[6] : undefined;

          if (scrubberAccessRequested) {
            this._notifyFaultyScrubber();
          }
          /** @type {?} */


          var previousCssKeyframePlayers =
          /** @type {?} */
          previousPlayers.filter(
          /**
          * @param {?} player
          * @return {?}
          */
          function (player) {
            return player instanceof CssKeyframesPlayer;
          });
          /** @type {?} */

          var previousStyles = {};

          if (allowPreviousPlayerStylesMerge(duration, delay)) {
            previousCssKeyframePlayers.forEach(
            /**
            * @param {?} player
            * @return {?}
            */
            function (player) {
              /** @type {?} */
              var styles = player.currentSnapshot;
              Object.keys(styles).forEach(
              /**
              * @param {?} prop
              * @return {?}
              */
              function (prop) {
                return previousStyles[prop] = styles[prop];
              });
            });
          }

          keyframes = balancePreviousStylesIntoKeyframes(element, keyframes, previousStyles);
          /** @type {?} */

          var finalStyles = flattenKeyframesIntoStyles(keyframes); // if there is no animation then there is no point in applying
          // styles and waiting for an event to get fired. This causes lag.
          // It's better to just directly apply the styles to the element
          // via the direct styling animation player.

          if (duration == 0) {
            return new DirectStylePlayer(element, finalStyles);
          }
          /** @type {?} */


          var animationName = "".concat(KEYFRAMES_NAME_PREFIX).concat(this._count++);
          /** @type {?} */

          var kfElm = this.buildKeyframeElement(element, animationName, keyframes);

          /** @type {?} */
          document.querySelector('head').appendChild(kfElm);
          /** @type {?} */

          var specialStyles = packageNonAnimatableStyles(element, keyframes);
          /** @type {?} */

          var player = new CssKeyframesPlayer(element, keyframes, animationName, duration, delay, easing, finalStyles, specialStyles);
          player.onDestroy(
          /**
          * @return {?}
          */
          function () {
            return removeElement(kfElm);
          });
          return player;
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_notifyFaultyScrubber",
        value: function _notifyFaultyScrubber() {
          if (!this._warningIssued) {
            console.warn('@angular/animations: please load the web-animations.js polyfill to allow programmatic access...\n', '  visit http://bit.ly/IWukam to learn more about using the web-animation-js polyfill.');
            this._warningIssued = true;
          }
        }
      }]);

      return CssKeyframesDriver;
    }();

    if (false) {}
    /**
     * @param {?} keyframes
     * @return {?}
     */


    function flattenKeyframesIntoStyles(keyframes) {
      /** @type {?} */
      var flatKeyframes = {};

      if (keyframes) {
        /** @type {?} */
        var kfs = Array.isArray(keyframes) ? keyframes : [keyframes];
        kfs.forEach(
        /**
        * @param {?} kf
        * @return {?}
        */
        function (kf) {
          Object.keys(kf).forEach(
          /**
          * @param {?} prop
          * @return {?}
          */
          function (prop) {
            if (prop == 'offset' || prop == 'easing') return;
            flatKeyframes[prop] = kf[prop];
          });
        });
      }

      return flatKeyframes;
    }
    /**
     * @param {?} node
     * @return {?}
     */


    function removeElement(node) {
      node.parentNode.removeChild(node);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/render/web_animations/web_animations_player.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var WebAnimationsPlayer = /*#__PURE__*/function () {
      /**
       * @param {?} element
       * @param {?} keyframes
       * @param {?} options
       * @param {?=} _specialStyles
       */
      function WebAnimationsPlayer(element, keyframes, options, _specialStyles) {
        _classCallCheck(this, WebAnimationsPlayer);

        this.element = element;
        this.keyframes = keyframes;
        this.options = options;
        this._specialStyles = _specialStyles;
        this._onDoneFns = [];
        this._onStartFns = [];
        this._onDestroyFns = [];
        this._initialized = false;
        this._finished = false;
        this._started = false;
        this._destroyed = false;
        this.time = 0;
        this.parentPlayer = null;
        this.currentSnapshot = {};
        this._duration =
        /** @type {?} */
        options['duration'];
        this._delay =
        /** @type {?} */
        options['delay'] || 0;
        this.time = this._duration + this._delay;
      }
      /**
       * @private
       * @return {?}
       */


      _createClass2(WebAnimationsPlayer, [{
        key: "_onFinish",
        value: function _onFinish() {
          if (!this._finished) {
            this._finished = true;

            this._onDoneFns.forEach(
            /**
            * @param {?} fn
            * @return {?}
            */
            function (fn) {
              return fn();
            });

            this._onDoneFns = [];
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "init",
        value: function init() {
          this._buildPlayer();

          this._preparePlayerBeforeStart();
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_buildPlayer",
        value: function _buildPlayer() {
          var _this47 = this;

          if (this._initialized) return;
          this._initialized = true;
          /** @type {?} */

          var keyframes = this.keyframes;

          /** @type {?} */
          this.domPlayer = this._triggerWebAnimation(this.element, keyframes, this.options);
          this._finalKeyframe = keyframes.length ? keyframes[keyframes.length - 1] : {};
          this.domPlayer.addEventListener('finish',
          /**
          * @return {?}
          */
          function () {
            return _this47._onFinish();
          });
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_preparePlayerBeforeStart",
        value: function _preparePlayerBeforeStart() {
          // this is required so that the player doesn't start to animate right away
          if (this._delay) {
            this._resetDomPlayerState();
          } else {
            this.domPlayer.pause();
          }
        }
        /**
         * \@internal
         * @param {?} element
         * @param {?} keyframes
         * @param {?} options
         * @return {?}
         */

      }, {
        key: "_triggerWebAnimation",
        value: function _triggerWebAnimation(element, keyframes, options) {
          // jscompiler doesn't seem to know animate is a native property because it's not fully
          // supported yet across common browsers (we polyfill it for Edge/Safari) [CL #143630929]
          return (
            /** @type {?} */
            element['animate'](keyframes, options)
          );
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "onStart",
        value: function onStart(fn) {
          this._onStartFns.push(fn);
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "onDone",
        value: function onDone(fn) {
          this._onDoneFns.push(fn);
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "onDestroy",
        value: function onDestroy(fn) {
          this._onDestroyFns.push(fn);
        }
        /**
         * @return {?}
         */

      }, {
        key: "play",
        value: function play() {
          this._buildPlayer();

          if (!this.hasStarted()) {
            this._onStartFns.forEach(
            /**
            * @param {?} fn
            * @return {?}
            */
            function (fn) {
              return fn();
            });

            this._onStartFns = [];
            this._started = true;

            if (this._specialStyles) {
              this._specialStyles.start();
            }
          }

          this.domPlayer.play();
        }
        /**
         * @return {?}
         */

      }, {
        key: "pause",
        value: function pause() {
          this.init();
          this.domPlayer.pause();
        }
        /**
         * @return {?}
         */

      }, {
        key: "finish",
        value: function finish() {
          this.init();

          if (this._specialStyles) {
            this._specialStyles.finish();
          }

          this._onFinish();

          this.domPlayer.finish();
        }
        /**
         * @return {?}
         */

      }, {
        key: "reset",
        value: function reset() {
          this._resetDomPlayerState();

          this._destroyed = false;
          this._finished = false;
          this._started = false;
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_resetDomPlayerState",
        value: function _resetDomPlayerState() {
          if (this.domPlayer) {
            this.domPlayer.cancel();
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "restart",
        value: function restart() {
          this.reset();
          this.play();
        }
        /**
         * @return {?}
         */

      }, {
        key: "hasStarted",
        value: function hasStarted() {
          return this._started;
        }
        /**
         * @return {?}
         */

      }, {
        key: "destroy",
        value: function destroy() {
          if (!this._destroyed) {
            this._destroyed = true;

            this._resetDomPlayerState();

            this._onFinish();

            if (this._specialStyles) {
              this._specialStyles.destroy();
            }

            this._onDestroyFns.forEach(
            /**
            * @param {?} fn
            * @return {?}
            */
            function (fn) {
              return fn();
            });

            this._onDestroyFns = [];
          }
        }
        /**
         * @param {?} p
         * @return {?}
         */

      }, {
        key: "setPosition",
        value: function setPosition(p) {
          this.domPlayer.currentTime = p * this.time;
        }
        /**
         * @return {?}
         */

      }, {
        key: "getPosition",
        value: function getPosition() {
          return this.domPlayer.currentTime / this.time;
        }
        /**
         * @return {?}
         */

      }, {
        key: "beforeDestroy",

        /**
         * @return {?}
         */
        value: function beforeDestroy() {
          var _this48 = this;

          /** @type {?} */
          var styles = {};

          if (this.hasStarted()) {
            Object.keys(this._finalKeyframe).forEach(
            /**
            * @param {?} prop
            * @return {?}
            */
            function (prop) {
              if (prop != 'offset') {
                styles[prop] = _this48._finished ? _this48._finalKeyframe[prop] : computeStyle(_this48.element, prop);
              }
            });
          }

          this.currentSnapshot = styles;
        }
        /**
         * \@internal
         * @param {?} phaseName
         * @return {?}
         */

      }, {
        key: "triggerCallback",
        value: function triggerCallback(phaseName) {
          /** @type {?} */
          var methods = phaseName == 'start' ? this._onStartFns : this._onDoneFns;
          methods.forEach(
          /**
          * @param {?} fn
          * @return {?}
          */
          function (fn) {
            return fn();
          });
          methods.length = 0;
        }
      }, {
        key: "totalTime",
        get: function get() {
          return this._delay + this._duration;
        }
      }]);

      return WebAnimationsPlayer;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/render/web_animations/web_animations_driver.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var WebAnimationsDriver = /*#__PURE__*/function () {
      function WebAnimationsDriver() {
        _classCallCheck(this, WebAnimationsDriver);

        this._isNativeImpl = /\{\s*\[native\s+code\]\s*\}/.test(getElementAnimateFn().toString());
        this._cssKeyframesDriver = new CssKeyframesDriver();
      }
      /**
       * @param {?} prop
       * @return {?}
       */


      _createClass2(WebAnimationsDriver, [{
        key: "validateStyleProperty",
        value: function validateStyleProperty(prop) {
          return _validateStyleProperty(prop);
        }
        /**
         * @param {?} element
         * @param {?} selector
         * @return {?}
         */

      }, {
        key: "matchesElement",
        value: function matchesElement(element, selector) {
          return _matchesElement(element, selector);
        }
        /**
         * @param {?} elm1
         * @param {?} elm2
         * @return {?}
         */

      }, {
        key: "containsElement",
        value: function containsElement(elm1, elm2) {
          return _containsElement(elm1, elm2);
        }
        /**
         * @param {?} element
         * @param {?} selector
         * @param {?} multi
         * @return {?}
         */

      }, {
        key: "query",
        value: function query(element, selector, multi) {
          return invokeQuery(element, selector, multi);
        }
        /**
         * @param {?} element
         * @param {?} prop
         * @param {?=} defaultValue
         * @return {?}
         */

      }, {
        key: "computeStyle",
        value: function computeStyle(element, prop, defaultValue) {
          return (
            /** @type {?} */

            /** @type {?} */
            window.getComputedStyle(element)[prop]
          );
        }
        /**
         * @param {?} supported
         * @return {?}
         */

      }, {
        key: "overrideWebAnimationsSupport",
        value: function overrideWebAnimationsSupport(supported) {
          this._isNativeImpl = supported;
        }
        /**
         * @param {?} element
         * @param {?} keyframes
         * @param {?} duration
         * @param {?} delay
         * @param {?} easing
         * @param {?=} previousPlayers
         * @param {?=} scrubberAccessRequested
         * @return {?}
         */

      }, {
        key: "animate",
        value: function animate(element, keyframes, duration, delay, easing) {
          var previousPlayers = arguments.length > 5 && arguments[5] !== undefined ? arguments[5] : [];
          var scrubberAccessRequested = arguments.length > 6 ? arguments[6] : undefined;

          /** @type {?} */
          var useKeyframes = !scrubberAccessRequested && !this._isNativeImpl;

          if (useKeyframes) {
            return this._cssKeyframesDriver.animate(element, keyframes, duration, delay, easing, previousPlayers);
          }
          /** @type {?} */


          var fill = delay == 0 ? 'both' : 'forwards';
          /** @type {?} */

          var playerOptions = {
            duration: duration,
            delay: delay,
            fill: fill
          }; // we check for this to avoid having a null|undefined value be present
          // for the easing (which results in an error for certain browsers #9752)

          if (easing) {
            playerOptions['easing'] = easing;
          }
          /** @type {?} */


          var previousStyles = {};
          /** @type {?} */

          var previousWebAnimationPlayers =
          /** @type {?} */
          previousPlayers.filter(
          /**
          * @param {?} player
          * @return {?}
          */
          function (player) {
            return player instanceof WebAnimationsPlayer;
          });

          if (allowPreviousPlayerStylesMerge(duration, delay)) {
            previousWebAnimationPlayers.forEach(
            /**
            * @param {?} player
            * @return {?}
            */
            function (player) {
              /** @type {?} */
              var styles = player.currentSnapshot;
              Object.keys(styles).forEach(
              /**
              * @param {?} prop
              * @return {?}
              */
              function (prop) {
                return previousStyles[prop] = styles[prop];
              });
            });
          }

          keyframes = keyframes.map(
          /**
          * @param {?} styles
          * @return {?}
          */
          function (styles) {
            return copyStyles(styles, false);
          });
          keyframes = balancePreviousStylesIntoKeyframes(element, keyframes, previousStyles);
          /** @type {?} */

          var specialStyles = packageNonAnimatableStyles(element, keyframes);
          return new WebAnimationsPlayer(element, keyframes, playerOptions, specialStyles);
        }
      }]);

      return WebAnimationsDriver;
    }();

    if (false) {}
    /**
     * @return {?}
     */


    function supportsWebAnimations() {
      return typeof getElementAnimateFn() === 'function';
    }
    /**
     * @return {?}
     */


    function getElementAnimateFn() {
      return isBrowser() &&
      /** @type {?} */
      Element.prototype['animate'] || {};
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/private_export.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/src/browser.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/public_api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/animations/browser/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=browser.js.map

    /***/

  },

  /***/
  "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/a11y.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/a11y.js ***!
    \*****************************************************************/

  /*! exports provided: A11yModule, ActiveDescendantKeyManager, AriaDescriber, CDK_DESCRIBEDBY_HOST_ATTRIBUTE, CDK_DESCRIBEDBY_ID_PREFIX, CdkAriaLive, CdkMonitorFocus, CdkTrapFocus, ConfigurableFocusTrap, ConfigurableFocusTrapFactory, EventListenerFocusTrapInertStrategy, FOCUS_MONITOR_DEFAULT_OPTIONS, FOCUS_TRAP_INERT_STRATEGY, FocusKeyManager, FocusMonitor, FocusTrap, FocusTrapFactory, HighContrastModeDetector, InteractivityChecker, LIVE_ANNOUNCER_DEFAULT_OPTIONS, LIVE_ANNOUNCER_ELEMENT_TOKEN, LIVE_ANNOUNCER_ELEMENT_TOKEN_FACTORY, ListKeyManager, LiveAnnouncer, MESSAGES_CONTAINER_ID, TOUCH_BUFFER_MS, isFakeMousedownFromScreenReader, ɵangular_material_src_cdk_a11y_a11y_a, ɵangular_material_src_cdk_a11y_a11y_b */

  /***/
  function node_modulesAngularCdk__ivy_ngcc__Fesm2015A11yJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "A11yModule", function () {
      return A11yModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ActiveDescendantKeyManager", function () {
      return ActiveDescendantKeyManager;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AriaDescriber", function () {
      return AriaDescriber;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CDK_DESCRIBEDBY_HOST_ATTRIBUTE", function () {
      return CDK_DESCRIBEDBY_HOST_ATTRIBUTE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CDK_DESCRIBEDBY_ID_PREFIX", function () {
      return CDK_DESCRIBEDBY_ID_PREFIX;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CdkAriaLive", function () {
      return CdkAriaLive;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CdkMonitorFocus", function () {
      return CdkMonitorFocus;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CdkTrapFocus", function () {
      return CdkTrapFocus;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ConfigurableFocusTrap", function () {
      return ConfigurableFocusTrap;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ConfigurableFocusTrapFactory", function () {
      return ConfigurableFocusTrapFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "EventListenerFocusTrapInertStrategy", function () {
      return EventListenerFocusTrapInertStrategy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FOCUS_MONITOR_DEFAULT_OPTIONS", function () {
      return FOCUS_MONITOR_DEFAULT_OPTIONS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FOCUS_TRAP_INERT_STRATEGY", function () {
      return FOCUS_TRAP_INERT_STRATEGY;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FocusKeyManager", function () {
      return FocusKeyManager;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FocusMonitor", function () {
      return FocusMonitor;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FocusTrap", function () {
      return FocusTrap;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FocusTrapFactory", function () {
      return FocusTrapFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HighContrastModeDetector", function () {
      return HighContrastModeDetector;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "InteractivityChecker", function () {
      return InteractivityChecker;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "LIVE_ANNOUNCER_DEFAULT_OPTIONS", function () {
      return LIVE_ANNOUNCER_DEFAULT_OPTIONS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "LIVE_ANNOUNCER_ELEMENT_TOKEN", function () {
      return LIVE_ANNOUNCER_ELEMENT_TOKEN;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "LIVE_ANNOUNCER_ELEMENT_TOKEN_FACTORY", function () {
      return LIVE_ANNOUNCER_ELEMENT_TOKEN_FACTORY;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ListKeyManager", function () {
      return ListKeyManager;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "LiveAnnouncer", function () {
      return LiveAnnouncer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MESSAGES_CONTAINER_ID", function () {
      return MESSAGES_CONTAINER_ID;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "TOUCH_BUFFER_MS", function () {
      return TOUCH_BUFFER_MS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "isFakeMousedownFromScreenReader", function () {
      return isFakeMousedownFromScreenReader;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_material_src_cdk_a11y_a11y_a", function () {
      return FocusTrapManager;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_material_src_cdk_a11y_a11y_b", function () {
      return ConfigurableFocusTrapConfig;
    });
    /* harmony import */


    var _angular_common__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/common */
    "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/common.js");
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var rxjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! rxjs */
    "./node_modules/rxjs/_esm2015/index.js");
    /* harmony import */


    var _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! @angular/cdk/keycodes */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/keycodes.js");
    /* harmony import */


    var rxjs_operators__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! rxjs/operators */
    "./node_modules/rxjs/_esm2015/operators/index.js");
    /* harmony import */


    var _angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(
    /*! @angular/cdk/coercion */
    "./node_modules/@angular/cdk/fesm2015/coercion.js");
    /* harmony import */


    var _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(
    /*! @angular/cdk/platform */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/platform.js");
    /* harmony import */


    var _angular_cdk_observers__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(
    /*! @angular/cdk/observers */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/observers.js");
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/aria-describer/aria-reference.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * IDs are delimited by an empty space, as per the spec.
     * @type {?}
     */


    var ID_DELIMITER = ' ';
    /**
     * Adds the given ID to the specified ARIA attribute on an element.
     * Used for attributes such as aria-labelledby, aria-owns, etc.
     * @param {?} el
     * @param {?} attr
     * @param {?} id
     * @return {?}
     */

    function addAriaReferencedId(el, attr, id) {
      /** @type {?} */
      var ids = getAriaReferenceIds(el, attr);

      if (ids.some(
      /**
      * @param {?} existingId
      * @return {?}
      */
      function (existingId) {
        return existingId.trim() == id.trim();
      })) {
        return;
      }

      ids.push(id.trim());
      el.setAttribute(attr, ids.join(ID_DELIMITER));
    }
    /**
     * Removes the given ID from the specified ARIA attribute on an element.
     * Used for attributes such as aria-labelledby, aria-owns, etc.
     * @param {?} el
     * @param {?} attr
     * @param {?} id
     * @return {?}
     */


    function removeAriaReferencedId(el, attr, id) {
      /** @type {?} */
      var ids = getAriaReferenceIds(el, attr);
      /** @type {?} */

      var filteredIds = ids.filter(
      /**
      * @param {?} val
      * @return {?}
      */
      function (val) {
        return val != id.trim();
      });

      if (filteredIds.length) {
        el.setAttribute(attr, filteredIds.join(ID_DELIMITER));
      } else {
        el.removeAttribute(attr);
      }
    }
    /**
     * Gets the list of IDs referenced by the given ARIA attribute on an element.
     * Used for attributes such as aria-labelledby, aria-owns, etc.
     * @param {?} el
     * @param {?} attr
     * @return {?}
     */


    function getAriaReferenceIds(el, attr) {
      // Get string array of all individual ids (whitespace delimited) in the attribute value
      return (el.getAttribute(attr) || '').match(/\S+/g) || [];
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/aria-describer/aria-describer.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Interface used to register message elements and keep a count of how many registrations have
     * the same message and the reference to the message element used for the `aria-describedby`.
     * @record
     */


    function RegisteredMessage() {}

    if (false) {}
    /**
     * ID used for the body container where all messages are appended.
     * @type {?}
     */


    var MESSAGES_CONTAINER_ID = 'cdk-describedby-message-container';
    /**
     * ID prefix used for each created message element.
     * @type {?}
     */

    var CDK_DESCRIBEDBY_ID_PREFIX = 'cdk-describedby-message';
    /**
     * Attribute given to each host element that is described by a message element.
     * @type {?}
     */

    var CDK_DESCRIBEDBY_HOST_ATTRIBUTE = 'cdk-describedby-host';
    /**
     * Global incremental identifier for each registered message element.
     * @type {?}
     */

    var nextId = 0;
    /**
     * Global map of all registered message elements that have been placed into the document.
     * @type {?}
     */

    var messageRegistry = new Map();
    /**
     * Container for all registered messages.
     * @type {?}
     */

    var messagesContainer = null;
    /**
     * Utility that creates visually hidden elements with a message content. Useful for elements that
     * want to use aria-describedby to further describe themselves without adding additional visual
     * content.
     */

    var AriaDescriber = /*#__PURE__*/function () {
      /**
       * @param {?} _document
       */
      function AriaDescriber(_document) {
        _classCallCheck(this, AriaDescriber);

        this._document = _document;
      }
      /**
       * Adds to the host element an aria-describedby reference to a hidden element that contains
       * the message. If the same message has already been registered, then it will reuse the created
       * message element.
       * @param {?} hostElement
       * @param {?} message
       * @return {?}
       */


      _createClass2(AriaDescriber, [{
        key: "describe",
        value: function describe(hostElement, message) {
          if (!this._canBeDescribed(hostElement, message)) {
            return;
          }

          if (typeof message !== 'string') {
            // We need to ensure that the element has an ID.
            this._setMessageId(message);

            messageRegistry.set(message, {
              messageElement: message,
              referenceCount: 0
            });
          } else if (!messageRegistry.has(message)) {
            this._createMessageElement(message);
          }

          if (!this._isElementDescribedByMessage(hostElement, message)) {
            this._addMessageReference(hostElement, message);
          }
        }
        /**
         * Removes the host element's aria-describedby reference to the message element.
         * @param {?} hostElement
         * @param {?} message
         * @return {?}
         */

      }, {
        key: "removeDescription",
        value: function removeDescription(hostElement, message) {
          if (!this._isElementNode(hostElement)) {
            return;
          }

          if (this._isElementDescribedByMessage(hostElement, message)) {
            this._removeMessageReference(hostElement, message);
          } // If the message is a string, it means that it's one that we created for the
          // consumer so we can remove it safely, otherwise we should leave it in place.


          if (typeof message === 'string') {
            /** @type {?} */
            var registeredMessage = messageRegistry.get(message);

            if (registeredMessage && registeredMessage.referenceCount === 0) {
              this._deleteMessageElement(message);
            }
          }

          if (messagesContainer && messagesContainer.childNodes.length === 0) {
            this._deleteMessagesContainer();
          }
        }
        /**
         * Unregisters all created message elements and removes the message container.
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          /** @type {?} */
          var describedElements = this._document.querySelectorAll("[".concat(CDK_DESCRIBEDBY_HOST_ATTRIBUTE, "]"));

          for (var i = 0; i < describedElements.length; i++) {
            this._removeCdkDescribedByReferenceIds(describedElements[i]);

            describedElements[i].removeAttribute(CDK_DESCRIBEDBY_HOST_ATTRIBUTE);
          }

          if (messagesContainer) {
            this._deleteMessagesContainer();
          }

          messageRegistry.clear();
        }
        /**
         * Creates a new element in the visually hidden message container element with the message
         * as its content and adds it to the message registry.
         * @private
         * @param {?} message
         * @return {?}
         */

      }, {
        key: "_createMessageElement",
        value: function _createMessageElement(message) {
          /** @type {?} */
          var messageElement = this._document.createElement('div');

          this._setMessageId(messageElement);

          messageElement.textContent = message;

          this._createMessagesContainer();

          /** @type {?} */
          messagesContainer.appendChild(messageElement);
          messageRegistry.set(message, {
            messageElement: messageElement,
            referenceCount: 0
          });
        }
        /**
         * Assigns a unique ID to an element, if it doesn't have one already.
         * @private
         * @param {?} element
         * @return {?}
         */

      }, {
        key: "_setMessageId",
        value: function _setMessageId(element) {
          if (!element.id) {
            element.id = "".concat(CDK_DESCRIBEDBY_ID_PREFIX, "-").concat(nextId++);
          }
        }
        /**
         * Deletes the message element from the global messages container.
         * @private
         * @param {?} message
         * @return {?}
         */

      }, {
        key: "_deleteMessageElement",
        value: function _deleteMessageElement(message) {
          /** @type {?} */
          var registeredMessage = messageRegistry.get(message);
          /** @type {?} */

          var messageElement = registeredMessage && registeredMessage.messageElement;

          if (messagesContainer && messageElement) {
            messagesContainer.removeChild(messageElement);
          }

          messageRegistry["delete"](message);
        }
        /**
         * Creates the global container for all aria-describedby messages.
         * @private
         * @return {?}
         */

      }, {
        key: "_createMessagesContainer",
        value: function _createMessagesContainer() {
          if (!messagesContainer) {
            /** @type {?} */
            var preExistingContainer = this._document.getElementById(MESSAGES_CONTAINER_ID); // When going from the server to the client, we may end up in a situation where there's
            // already a container on the page, but we don't have a reference to it. Clear the
            // old container so we don't get duplicates. Doing this, instead of emptying the previous
            // container, should be slightly faster.


            if (preExistingContainer) {
              /** @type {?} */
              preExistingContainer.parentNode.removeChild(preExistingContainer);
            }

            messagesContainer = this._document.createElement('div');
            messagesContainer.id = MESSAGES_CONTAINER_ID;
            messagesContainer.setAttribute('aria-hidden', 'true');
            messagesContainer.style.display = 'none';

            this._document.body.appendChild(messagesContainer);
          }
        }
        /**
         * Deletes the global messages container.
         * @private
         * @return {?}
         */

      }, {
        key: "_deleteMessagesContainer",
        value: function _deleteMessagesContainer() {
          if (messagesContainer && messagesContainer.parentNode) {
            messagesContainer.parentNode.removeChild(messagesContainer);
            messagesContainer = null;
          }
        }
        /**
         * Removes all cdk-describedby messages that are hosted through the element.
         * @private
         * @param {?} element
         * @return {?}
         */

      }, {
        key: "_removeCdkDescribedByReferenceIds",
        value: function _removeCdkDescribedByReferenceIds(element) {
          // Remove all aria-describedby reference IDs that are prefixed by CDK_DESCRIBEDBY_ID_PREFIX

          /** @type {?} */
          var originalReferenceIds = getAriaReferenceIds(element, 'aria-describedby').filter(
          /**
          * @param {?} id
          * @return {?}
          */
          function (id) {
            return id.indexOf(CDK_DESCRIBEDBY_ID_PREFIX) != 0;
          });
          element.setAttribute('aria-describedby', originalReferenceIds.join(' '));
        }
        /**
         * Adds a message reference to the element using aria-describedby and increments the registered
         * message's reference count.
         * @private
         * @param {?} element
         * @param {?} message
         * @return {?}
         */

      }, {
        key: "_addMessageReference",
        value: function _addMessageReference(element, message) {
          /** @type {?} */
          var registeredMessage =
          /** @type {?} */
          messageRegistry.get(message); // Add the aria-describedby reference and set the
          // describedby_host attribute to mark the element.

          addAriaReferencedId(element, 'aria-describedby', registeredMessage.messageElement.id);
          element.setAttribute(CDK_DESCRIBEDBY_HOST_ATTRIBUTE, '');
          registeredMessage.referenceCount++;
        }
        /**
         * Removes a message reference from the element using aria-describedby
         * and decrements the registered message's reference count.
         * @private
         * @param {?} element
         * @param {?} message
         * @return {?}
         */

      }, {
        key: "_removeMessageReference",
        value: function _removeMessageReference(element, message) {
          /** @type {?} */
          var registeredMessage =
          /** @type {?} */
          messageRegistry.get(message);
          registeredMessage.referenceCount--;
          removeAriaReferencedId(element, 'aria-describedby', registeredMessage.messageElement.id);
          element.removeAttribute(CDK_DESCRIBEDBY_HOST_ATTRIBUTE);
        }
        /**
         * Returns true if the element has been described by the provided message ID.
         * @private
         * @param {?} element
         * @param {?} message
         * @return {?}
         */

      }, {
        key: "_isElementDescribedByMessage",
        value: function _isElementDescribedByMessage(element, message) {
          /** @type {?} */
          var referenceIds = getAriaReferenceIds(element, 'aria-describedby');
          /** @type {?} */

          var registeredMessage = messageRegistry.get(message);
          /** @type {?} */

          var messageId = registeredMessage && registeredMessage.messageElement.id;
          return !!messageId && referenceIds.indexOf(messageId) != -1;
        }
        /**
         * Determines whether a message can be described on a particular element.
         * @private
         * @param {?} element
         * @param {?} message
         * @return {?}
         */

      }, {
        key: "_canBeDescribed",
        value: function _canBeDescribed(element, message) {
          if (!this._isElementNode(element)) {
            return false;
          }

          if (message && typeof message === 'object') {
            // We'd have to make some assumptions about the description element's text, if the consumer
            // passed in an element. Assume that if an element is passed in, the consumer has verified
            // that it can be used as a description.
            return true;
          }
          /** @type {?} */


          var trimmedMessage = message == null ? '' : "".concat(message).trim();
          /** @type {?} */

          var ariaLabel = element.getAttribute('aria-label'); // We shouldn't set descriptions if they're exactly the same as the `aria-label` of the
          // element, because screen readers will end up reading out the same text twice in a row.

          return trimmedMessage ? !ariaLabel || ariaLabel.trim() !== trimmedMessage : false;
        }
        /**
         * Checks whether a node is an Element node.
         * @private
         * @param {?} element
         * @return {?}
         */

      }, {
        key: "_isElementNode",
        value: function _isElementNode(element) {
          return element.nodeType === this._document.ELEMENT_NODE;
        }
      }]);

      return AriaDescriber;
    }();

    AriaDescriber.ɵfac = function AriaDescriber_Factory(t) {
      return new (t || AriaDescriber)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]));
    };
    /** @nocollapse */


    AriaDescriber.ctorParameters = function () {
      return [{
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
        }]
      }];
    };
    /** @nocollapse */


    AriaDescriber.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: function AriaDescriber_Factory() {
        return new AriaDescriber(Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]));
      },
      token: AriaDescriber,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](AriaDescriber, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [{
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/key-manager/list-key-manager.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * This interface is for items that can be passed to a ListKeyManager.
     * @record
     */


    function ListKeyManagerOption() {}

    if (false) {}
    /**
     * This class manages keyboard events for selectable lists. If you pass it a query list
     * of items, it will set the active item correctly when arrow events occur.
     * @template T
     */


    var ListKeyManager = /*#__PURE__*/function () {
      /**
       * @param {?} _items
       */
      function ListKeyManager(_items) {
        var _this49 = this;

        _classCallCheck(this, ListKeyManager);

        this._items = _items;
        this._activeItemIndex = -1;
        this._activeItem = null;
        this._wrap = false;
        this._letterKeyStream = new rxjs__WEBPACK_IMPORTED_MODULE_2__["Subject"]();
        this._typeaheadSubscription = rxjs__WEBPACK_IMPORTED_MODULE_2__["Subscription"].EMPTY;
        this._vertical = true;
        this._allowedModifierKeys = [];
        /**
         * Predicate function that can be used to check whether an item should be skipped
         * by the key manager. By default, disabled items are skipped.
         */

        this._skipPredicateFn =
        /**
        * @param {?} item
        * @return {?}
        */
        function (item) {
          return item.disabled;
        }; // Buffer for the letters that the user has pressed when the typeahead option is turned on.


        this._pressedLetters = [];
        /**
         * Stream that emits any time the TAB key is pressed, so components can react
         * when focus is shifted off of the list.
         */

        this.tabOut = new rxjs__WEBPACK_IMPORTED_MODULE_2__["Subject"]();
        /**
         * Stream that emits whenever the active item of the list manager changes.
         */

        this.change = new rxjs__WEBPACK_IMPORTED_MODULE_2__["Subject"](); // We allow for the items to be an array because, in some cases, the consumer may
        // not have access to a QueryList of the items they want to manage (e.g. when the
        // items aren't being collected via `ViewChildren` or `ContentChildren`).

        if (_items instanceof _angular_core__WEBPACK_IMPORTED_MODULE_1__["QueryList"]) {
          _items.changes.subscribe(
          /**
          * @param {?} newItems
          * @return {?}
          */
          function (newItems) {
            if (_this49._activeItem) {
              /** @type {?} */
              var itemArray = newItems.toArray();
              /** @type {?} */

              var newIndex = itemArray.indexOf(_this49._activeItem);

              if (newIndex > -1 && newIndex !== _this49._activeItemIndex) {
                _this49._activeItemIndex = newIndex;
              }
            }
          });
        }
      }
      /**
       * Sets the predicate function that determines which items should be skipped by the
       * list key manager.
       * @template THIS
       * @this {THIS}
       * @param {?} predicate Function that determines whether the given item should be skipped.
       * @return {THIS}
       */


      _createClass2(ListKeyManager, [{
        key: "skipPredicate",
        value: function skipPredicate(predicate) {
          /** @type {?} */
          this._skipPredicateFn = predicate;
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Configures wrapping mode, which determines whether the active item will wrap to
         * the other end of list when there are no more items in the given direction.
         * @template THIS
         * @this {THIS}
         * @param {?=} shouldWrap Whether the list should wrap when reaching the end.
         * @return {THIS}
         */

      }, {
        key: "withWrap",
        value: function withWrap() {
          var shouldWrap = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;

          /** @type {?} */
          this._wrap = shouldWrap;
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Configures whether the key manager should be able to move the selection vertically.
         * @template THIS
         * @this {THIS}
         * @param {?=} enabled Whether vertical selection should be enabled.
         * @return {THIS}
         */

      }, {
        key: "withVerticalOrientation",
        value: function withVerticalOrientation() {
          var enabled = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;

          /** @type {?} */
          this._vertical = enabled;
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Configures the key manager to move the selection horizontally.
         * Passing in `null` will disable horizontal movement.
         * @template THIS
         * @this {THIS}
         * @param {?} direction Direction in which the selection can be moved.
         * @return {THIS}
         */

      }, {
        key: "withHorizontalOrientation",
        value: function withHorizontalOrientation(direction) {
          /** @type {?} */
          this._horizontal = direction;
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Modifier keys which are allowed to be held down and whose default actions will be prevented
         * as the user is pressing the arrow keys. Defaults to not allowing any modifier keys.
         * @template THIS
         * @this {THIS}
         * @param {?} keys
         * @return {THIS}
         */

      }, {
        key: "withAllowedModifierKeys",
        value: function withAllowedModifierKeys(keys) {
          /** @type {?} */
          this._allowedModifierKeys = keys;
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Turns on typeahead mode which allows users to set the active item by typing.
         * @template THIS
         * @this {THIS}
         * @param {?=} debounceInterval Time to wait after the last keystroke before setting the active item.
         * @return {THIS}
         */

      }, {
        key: "withTypeAhead",
        value: function withTypeAhead() {
          var _this50 = this;

          var debounceInterval = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 200;

          if (
          /** @type {?} */
          this._items.length &&
          /** @type {?} */
          this._items.some(
          /**
          * @param {?} item
          * @return {?}
          */
          function (item) {
            return typeof item.getLabel !== 'function';
          })) {
            throw Error('ListKeyManager items in typeahead mode must implement the `getLabel` method.');
          }

          /** @type {?} */
          this._typeaheadSubscription.unsubscribe(); // Debounce the presses of non-navigational keys, collect the ones that correspond to letters
          // and convert those letters back into a string. Afterwards find the first item that starts
          // with that string and select it.


          /** @type {?} */
          this._typeaheadSubscription =
          /** @type {?} */
          this._letterKeyStream.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_4__["tap"])(
          /**
          * @param {?} letter
          * @return {?}
          */
          function (letter) {
            return (
              /** @type {?} */
              _this50._pressedLetters.push(letter)
            );
          }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_4__["debounceTime"])(debounceInterval), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_4__["filter"])(
          /**
          * @return {?}
          */
          function () {
            return (
              /** @type {?} */
              _this50._pressedLetters.length > 0
            );
          }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_4__["map"])(
          /**
          * @return {?}
          */
          function () {
            return (
              /** @type {?} */
              _this50._pressedLetters.join('')
            );
          })).subscribe(
          /**
          * @param {?} inputString
          * @return {?}
          */
          function (inputString) {
            /** @type {?} */
            var items =
            /** @type {?} */
            _this50._getItemsArray(); // Start at 1 because we want to start searching at the item immediately
            // following the current active item.


            for (var i = 1; i < items.length + 1; i++) {
              /** @type {?} */
              var index = (
              /** @type {?} */
              _this50._activeItemIndex + i) % items.length;
              /** @type {?} */

              var item = items[index];

              if (!
              /** @type {?} */
              _this50._skipPredicateFn(item) &&
              /** @type {?} */
              item.getLabel().toUpperCase().trim().indexOf(inputString) === 0) {
                /** @type {?} */
                _this50.setActiveItem(index);

                break;
              }
            }

            /** @type {?} */
            _this50._pressedLetters = [];
          });
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * @param {?} item
         * @return {?}
         */

      }, {
        key: "setActiveItem",
        value: function setActiveItem(item) {
          /** @type {?} */
          var previousIndex = this._activeItemIndex;
          this.updateActiveItem(item);

          if (this._activeItemIndex !== previousIndex) {
            this.change.next(this._activeItemIndex);
          }
        }
        /**
         * Sets the active item depending on the key event passed in.
         * @param {?} event Keyboard event to be used for determining which element should be active.
         * @return {?}
         */

      }, {
        key: "onKeydown",
        value: function onKeydown(event) {
          var _this51 = this;

          /** @type {?} */
          var keyCode = event.keyCode;
          /** @type {?} */

          var modifiers = ['altKey', 'ctrlKey', 'metaKey', 'shiftKey'];
          /** @type {?} */

          var isModifierAllowed = modifiers.every(
          /**
          * @param {?} modifier
          * @return {?}
          */
          function (modifier) {
            return !event[modifier] || _this51._allowedModifierKeys.indexOf(modifier) > -1;
          });

          switch (keyCode) {
            case _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_3__["TAB"]:
              this.tabOut.next();
              return;

            case _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_3__["DOWN_ARROW"]:
              if (this._vertical && isModifierAllowed) {
                this.setNextItemActive();
                break;
              } else {
                return;
              }

            case _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_3__["UP_ARROW"]:
              if (this._vertical && isModifierAllowed) {
                this.setPreviousItemActive();
                break;
              } else {
                return;
              }

            case _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_3__["RIGHT_ARROW"]:
              if (this._horizontal && isModifierAllowed) {
                this._horizontal === 'rtl' ? this.setPreviousItemActive() : this.setNextItemActive();
                break;
              } else {
                return;
              }

            case _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_3__["LEFT_ARROW"]:
              if (this._horizontal && isModifierAllowed) {
                this._horizontal === 'rtl' ? this.setNextItemActive() : this.setPreviousItemActive();
                break;
              } else {
                return;
              }

            default:
              if (isModifierAllowed || Object(_angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_3__["hasModifierKey"])(event, 'shiftKey')) {
                // Attempt to use the `event.key` which also maps it to the user's keyboard language,
                // otherwise fall back to resolving alphanumeric characters via the keyCode.
                if (event.key && event.key.length === 1) {
                  this._letterKeyStream.next(event.key.toLocaleUpperCase());
                } else if (keyCode >= _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_3__["A"] && keyCode <= _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_3__["Z"] || keyCode >= _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_3__["ZERO"] && keyCode <= _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_3__["NINE"]) {
                  this._letterKeyStream.next(String.fromCharCode(keyCode));
                }
              } // Note that we return here, in order to avoid preventing
              // the default action of non-navigational keys.


              return;
          }

          this._pressedLetters = [];
          event.preventDefault();
        }
        /**
         * Index of the currently active item.
         * @return {?}
         */

      }, {
        key: "isTyping",

        /**
         * Gets whether the user is currently typing into the manager using the typeahead feature.
         * @return {?}
         */
        value: function isTyping() {
          return this._pressedLetters.length > 0;
        }
        /**
         * Sets the active item to the first enabled item in the list.
         * @return {?}
         */

      }, {
        key: "setFirstItemActive",
        value: function setFirstItemActive() {
          this._setActiveItemByIndex(0, 1);
        }
        /**
         * Sets the active item to the last enabled item in the list.
         * @return {?}
         */

      }, {
        key: "setLastItemActive",
        value: function setLastItemActive() {
          this._setActiveItemByIndex(this._items.length - 1, -1);
        }
        /**
         * Sets the active item to the next enabled item in the list.
         * @return {?}
         */

      }, {
        key: "setNextItemActive",
        value: function setNextItemActive() {
          this._activeItemIndex < 0 ? this.setFirstItemActive() : this._setActiveItemByDelta(1);
        }
        /**
         * Sets the active item to a previous enabled item in the list.
         * @return {?}
         */

      }, {
        key: "setPreviousItemActive",
        value: function setPreviousItemActive() {
          this._activeItemIndex < 0 && this._wrap ? this.setLastItemActive() : this._setActiveItemByDelta(-1);
        }
        /**
         * @param {?} item
         * @return {?}
         */

      }, {
        key: "updateActiveItem",
        value: function updateActiveItem(item) {
          /** @type {?} */
          var itemArray = this._getItemsArray();
          /** @type {?} */


          var index = typeof item === 'number' ? item : itemArray.indexOf(item);
          /** @type {?} */

          var activeItem = itemArray[index]; // Explicitly check for `null` and `undefined` because other falsy values are valid.

          this._activeItem = activeItem == null ? null : activeItem;
          this._activeItemIndex = index;
        }
        /**
         * This method sets the active item, given a list of items and the delta between the
         * currently active item and the new active item. It will calculate differently
         * depending on whether wrap mode is turned on.
         * @private
         * @param {?} delta
         * @return {?}
         */

      }, {
        key: "_setActiveItemByDelta",
        value: function _setActiveItemByDelta(delta) {
          this._wrap ? this._setActiveInWrapMode(delta) : this._setActiveInDefaultMode(delta);
        }
        /**
         * Sets the active item properly given "wrap" mode. In other words, it will continue to move
         * down the list until it finds an item that is not disabled, and it will wrap if it
         * encounters either end of the list.
         * @private
         * @param {?} delta
         * @return {?}
         */

      }, {
        key: "_setActiveInWrapMode",
        value: function _setActiveInWrapMode(delta) {
          /** @type {?} */
          var items = this._getItemsArray();

          for (var i = 1; i <= items.length; i++) {
            /** @type {?} */
            var index = (this._activeItemIndex + delta * i + items.length) % items.length;
            /** @type {?} */

            var item = items[index];

            if (!this._skipPredicateFn(item)) {
              this.setActiveItem(index);
              return;
            }
          }
        }
        /**
         * Sets the active item properly given the default mode. In other words, it will
         * continue to move down the list until it finds an item that is not disabled. If
         * it encounters either end of the list, it will stop and not wrap.
         * @private
         * @param {?} delta
         * @return {?}
         */

      }, {
        key: "_setActiveInDefaultMode",
        value: function _setActiveInDefaultMode(delta) {
          this._setActiveItemByIndex(this._activeItemIndex + delta, delta);
        }
        /**
         * Sets the active item to the first enabled item starting at the index specified. If the
         * item is disabled, it will move in the fallbackDelta direction until it either
         * finds an enabled item or encounters the end of the list.
         * @private
         * @param {?} index
         * @param {?} fallbackDelta
         * @return {?}
         */

      }, {
        key: "_setActiveItemByIndex",
        value: function _setActiveItemByIndex(index, fallbackDelta) {
          /** @type {?} */
          var items = this._getItemsArray();

          if (!items[index]) {
            return;
          }

          while (this._skipPredicateFn(items[index])) {
            index += fallbackDelta;

            if (!items[index]) {
              return;
            }
          }

          this.setActiveItem(index);
        }
        /**
         * Returns the items as an array.
         * @private
         * @return {?}
         */

      }, {
        key: "_getItemsArray",
        value: function _getItemsArray() {
          return this._items instanceof _angular_core__WEBPACK_IMPORTED_MODULE_1__["QueryList"] ? this._items.toArray() : this._items;
        }
      }, {
        key: "activeItemIndex",
        get: function get() {
          return this._activeItemIndex;
        }
        /**
         * The active item.
         * @return {?}
         */

      }, {
        key: "activeItem",
        get: function get() {
          return this._activeItem;
        }
      }]);

      return ListKeyManager;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/key-manager/activedescendant-key-manager.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * This is the interface for highlightable items (used by the ActiveDescendantKeyManager).
     * Each item must know how to style itself as active or inactive and whether or not it is
     * currently disabled.
     * @record
     */


    function Highlightable() {}

    if (false) {}
    /**
     * @template T
     */


    var ActiveDescendantKeyManager = /*#__PURE__*/function (_ListKeyManager) {
      _inherits(ActiveDescendantKeyManager, _ListKeyManager);

      var _super4 = _createSuper(ActiveDescendantKeyManager);

      function ActiveDescendantKeyManager() {
        _classCallCheck(this, ActiveDescendantKeyManager);

        return _super4.apply(this, arguments);
      }

      _createClass2(ActiveDescendantKeyManager, [{
        key: "setActiveItem",

        /**
         * @param {?} index
         * @return {?}
         */
        value: function setActiveItem(index) {
          if (this.activeItem) {
            this.activeItem.setInactiveStyles();
          }

          _get(_getPrototypeOf(ActiveDescendantKeyManager.prototype), "setActiveItem", this).call(this, index);

          if (this.activeItem) {
            this.activeItem.setActiveStyles();
          }
        }
      }]);

      return ActiveDescendantKeyManager;
    }(ListKeyManager);
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/key-manager/focus-key-manager.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * This is the interface for focusable items (used by the FocusKeyManager).
     * Each item must know how to focus itself, whether or not it is currently disabled
     * and be able to supply its label.
     * @record
     */


    function FocusableOption() {}

    if (false) {}
    /**
     * @template T
     */


    var FocusKeyManager = /*#__PURE__*/function (_ListKeyManager2) {
      _inherits(FocusKeyManager, _ListKeyManager2);

      var _super5 = _createSuper(FocusKeyManager);

      function FocusKeyManager() {
        var _this52;

        _classCallCheck(this, FocusKeyManager);

        _this52 = _super5.apply(this, arguments);
        _this52._origin = 'program';
        return _this52;
      }
      /**
       * Sets the focus origin that will be passed in to the items for any subsequent `focus` calls.
       * @template THIS
       * @this {THIS}
       * @param {?} origin Focus origin to be used when focusing items.
       * @return {THIS}
       */


      _createClass2(FocusKeyManager, [{
        key: "setFocusOrigin",
        value: function setFocusOrigin(origin) {
          /** @type {?} */
          this._origin = origin;
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * @param {?} item
         * @return {?}
         */

      }, {
        key: "setActiveItem",
        value: function setActiveItem(item) {
          _get(_getPrototypeOf(FocusKeyManager.prototype), "setActiveItem", this).call(this, item);

          if (this.activeItem) {
            this.activeItem.focus(this._origin);
          }
        }
      }]);

      return FocusKeyManager;
    }(ListKeyManager);

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/interactivity-checker/interactivity-checker.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */
    // The InteractivityChecker leans heavily on the ally.js accessibility utilities.
    // Methods like `isTabbable` are only covering specific edge-cases for the browsers which are
    // supported.

    /**
     * Utility for checking the interactivity of an element, such as whether is is focusable or
     * tabbable.
     */


    var InteractivityChecker = /*#__PURE__*/function () {
      /**
       * @param {?} _platform
       */
      function InteractivityChecker(_platform) {
        _classCallCheck(this, InteractivityChecker);

        this._platform = _platform;
      }
      /**
       * Gets whether an element is disabled.
       *
       * @param {?} element Element to be checked.
       * @return {?} Whether the element is disabled.
       */


      _createClass2(InteractivityChecker, [{
        key: "isDisabled",
        value: function isDisabled(element) {
          // This does not capture some cases, such as a non-form control with a disabled attribute or
          // a form control inside of a disabled form, but should capture the most common cases.
          return element.hasAttribute('disabled');
        }
        /**
         * Gets whether an element is visible for the purposes of interactivity.
         *
         * This will capture states like `display: none` and `visibility: hidden`, but not things like
         * being clipped by an `overflow: hidden` parent or being outside the viewport.
         *
         * @param {?} element
         * @return {?} Whether the element is visible.
         */

      }, {
        key: "isVisible",
        value: function isVisible(element) {
          return hasGeometry(element) && getComputedStyle(element).visibility === 'visible';
        }
        /**
         * Gets whether an element can be reached via Tab key.
         * Assumes that the element has already been checked with isFocusable.
         *
         * @param {?} element Element to be checked.
         * @return {?} Whether the element is tabbable.
         */

      }, {
        key: "isTabbable",
        value: function isTabbable(element) {
          // Nothing is tabbable on the server 😎
          if (!this._platform.isBrowser) {
            return false;
          }
          /** @type {?} */


          var frameElement = getFrameElement(getWindow(element));

          if (frameElement) {
            /** @type {?} */
            var frameType = frameElement && frameElement.nodeName.toLowerCase(); // Frame elements inherit their tabindex onto all child elements.

            if (getTabIndexValue(frameElement) === -1) {
              return false;
            } // Webkit and Blink consider anything inside of an <object> element as non-tabbable.


            if ((this._platform.BLINK || this._platform.WEBKIT) && frameType === 'object') {
              return false;
            } // Webkit and Blink disable tabbing to an element inside of an invisible frame.


            if ((this._platform.BLINK || this._platform.WEBKIT) && !this.isVisible(frameElement)) {
              return false;
            }
          }
          /** @type {?} */


          var nodeName = element.nodeName.toLowerCase();
          /** @type {?} */

          var tabIndexValue = getTabIndexValue(element);

          if (element.hasAttribute('contenteditable')) {
            return tabIndexValue !== -1;
          }

          if (nodeName === 'iframe') {
            // The frames may be tabbable depending on content, but it's not possibly to reliably
            // investigate the content of the frames.
            return false;
          }

          if (nodeName === 'audio') {
            if (!element.hasAttribute('controls')) {
              // By default an <audio> element without the controls enabled is not tabbable.
              return false;
            } else if (this._platform.BLINK) {
              // In Blink <audio controls> elements are always tabbable.
              return true;
            }
          }

          if (nodeName === 'video') {
            if (!element.hasAttribute('controls') && this._platform.TRIDENT) {
              // In Trident a <video> element without the controls enabled is not tabbable.
              return false;
            } else if (this._platform.BLINK || this._platform.FIREFOX) {
              // In Chrome and Firefox <video controls> elements are always tabbable.
              return true;
            }
          }

          if (nodeName === 'object' && (this._platform.BLINK || this._platform.WEBKIT)) {
            // In all Blink and WebKit based browsers <object> elements are never tabbable.
            return false;
          } // In iOS the browser only considers some specific elements as tabbable.


          if (this._platform.WEBKIT && this._platform.IOS && !isPotentiallyTabbableIOS(element)) {
            return false;
          }

          return element.tabIndex >= 0;
        }
        /**
         * Gets whether an element can be focused by the user.
         *
         * @param {?} element Element to be checked.
         * @return {?} Whether the element is focusable.
         */

      }, {
        key: "isFocusable",
        value: function isFocusable(element) {
          // Perform checks in order of left to most expensive.
          // Again, naive approach that does not capture many edge cases and browser quirks.
          return isPotentiallyFocusable(element) && !this.isDisabled(element) && this.isVisible(element);
        }
      }]);

      return InteractivityChecker;
    }();

    InteractivityChecker.ɵfac = function InteractivityChecker_Factory(t) {
      return new (t || InteractivityChecker)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_6__["Platform"]));
    };
    /** @nocollapse */


    InteractivityChecker.ctorParameters = function () {
      return [{
        type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_6__["Platform"]
      }];
    };
    /** @nocollapse */


    InteractivityChecker.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: function InteractivityChecker_Factory() {
        return new InteractivityChecker(Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_6__["Platform"]));
      },
      token: InteractivityChecker,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](InteractivityChecker, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [{
          type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_6__["Platform"]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * Returns the frame element from a window object. Since browsers like MS Edge throw errors if
     * the frameElement property is being accessed from a different host address, this property
     * should be accessed carefully.
     * @param {?} window
     * @return {?}
     */


    function getFrameElement(window) {
      try {
        return (
          /** @type {?} */
          window.frameElement
        );
      } catch (_a) {
        return null;
      }
    }
    /**
     * Checks whether the specified element has any geometry / rectangles.
     * @param {?} element
     * @return {?}
     */


    function hasGeometry(element) {
      // Use logic from jQuery to check for an invisible element.
      // See https://github.com/jquery/jquery/blob/master/src/css/hiddenVisibleSelectors.js#L12
      return !!(element.offsetWidth || element.offsetHeight || typeof element.getClientRects === 'function' && element.getClientRects().length);
    }
    /**
     * Gets whether an element's
     * @param {?} element
     * @return {?}
     */


    function isNativeFormElement(element) {
      /** @type {?} */
      var nodeName = element.nodeName.toLowerCase();
      return nodeName === 'input' || nodeName === 'select' || nodeName === 'button' || nodeName === 'textarea';
    }
    /**
     * Gets whether an element is an `<input type="hidden">`.
     * @param {?} element
     * @return {?}
     */


    function isHiddenInput(element) {
      return isInputElement(element) && element.type == 'hidden';
    }
    /**
     * Gets whether an element is an anchor that has an href attribute.
     * @param {?} element
     * @return {?}
     */


    function isAnchorWithHref(element) {
      return isAnchorElement(element) && element.hasAttribute('href');
    }
    /**
     * Gets whether an element is an input element.
     * @param {?} element
     * @return {?}
     */


    function isInputElement(element) {
      return element.nodeName.toLowerCase() == 'input';
    }
    /**
     * Gets whether an element is an anchor element.
     * @param {?} element
     * @return {?}
     */


    function isAnchorElement(element) {
      return element.nodeName.toLowerCase() == 'a';
    }
    /**
     * Gets whether an element has a valid tabindex.
     * @param {?} element
     * @return {?}
     */


    function hasValidTabIndex(element) {
      if (!element.hasAttribute('tabindex') || element.tabIndex === undefined) {
        return false;
      }
      /** @type {?} */


      var tabIndex = element.getAttribute('tabindex'); // IE11 parses tabindex="" as the value "-32768"

      if (tabIndex == '-32768') {
        return false;
      }

      return !!(tabIndex && !isNaN(parseInt(tabIndex, 10)));
    }
    /**
     * Returns the parsed tabindex from the element attributes instead of returning the
     * evaluated tabindex from the browsers defaults.
     * @param {?} element
     * @return {?}
     */


    function getTabIndexValue(element) {
      if (!hasValidTabIndex(element)) {
        return null;
      } // See browser issue in Gecko https://bugzilla.mozilla.org/show_bug.cgi?id=1128054

      /** @type {?} */


      var tabIndex = parseInt(element.getAttribute('tabindex') || '', 10);
      return isNaN(tabIndex) ? -1 : tabIndex;
    }
    /**
     * Checks whether the specified element is potentially tabbable on iOS
     * @param {?} element
     * @return {?}
     */


    function isPotentiallyTabbableIOS(element) {
      /** @type {?} */
      var nodeName = element.nodeName.toLowerCase();
      /** @type {?} */

      var inputType = nodeName === 'input' &&
      /** @type {?} */
      element.type;
      return inputType === 'text' || inputType === 'password' || nodeName === 'select' || nodeName === 'textarea';
    }
    /**
     * Gets whether an element is potentially focusable without taking current visible/disabled state
     * into account.
     * @param {?} element
     * @return {?}
     */


    function isPotentiallyFocusable(element) {
      // Inputs are potentially focusable *unless* they're type="hidden".
      if (isHiddenInput(element)) {
        return false;
      }

      return isNativeFormElement(element) || isAnchorWithHref(element) || element.hasAttribute('contenteditable') || hasValidTabIndex(element);
    }
    /**
     * Gets the parent window of a DOM node with regards of being inside of an iframe.
     * @param {?} node
     * @return {?}
     */


    function getWindow(node) {
      // ownerDocument is null if `node` itself *is* a document.
      return node.ownerDocument && node.ownerDocument.defaultView || window;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/focus-trap/focus-trap.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Class that allows for trapping focus within a DOM element.
     *
     * This class currently uses a relatively simple approach to focus trapping.
     * It assumes that the tab order is the same as DOM order, which is not necessarily true.
     * Things like `tabIndex > 0`, flex `order`, and shadow roots can cause to two to misalign.
     *
     * @deprecated Use `ConfigurableFocusTrap` instead.
     * \@breaking-change for 11.0.0 Remove this class.
     */


    var FocusTrap = /*#__PURE__*/function () {
      /**
       * @param {?} _element
       * @param {?} _checker
       * @param {?} _ngZone
       * @param {?} _document
       * @param {?=} deferAnchors
       */
      function FocusTrap(_element, _checker, _ngZone, _document) {
        var _this53 = this;

        var deferAnchors = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : false;

        _classCallCheck(this, FocusTrap);

        this._element = _element;
        this._checker = _checker;
        this._ngZone = _ngZone;
        this._document = _document;
        this._hasAttached = false; // Event listeners for the anchors. Need to be regular functions so that we can unbind them later.

        this.startAnchorListener =
        /**
        * @return {?}
        */
        function () {
          return _this53.focusLastTabbableElement();
        };

        this.endAnchorListener =
        /**
        * @return {?}
        */
        function () {
          return _this53.focusFirstTabbableElement();
        };

        this._enabled = true;

        if (!deferAnchors) {
          this.attachAnchors();
        }
      }
      /**
       * Whether the focus trap is active.
       * @return {?}
       */


      _createClass2(FocusTrap, [{
        key: "destroy",

        /**
         * Destroys the focus trap by cleaning up the anchors.
         * @return {?}
         */
        value: function destroy() {
          /** @type {?} */
          var startAnchor = this._startAnchor;
          /** @type {?} */

          var endAnchor = this._endAnchor;

          if (startAnchor) {
            startAnchor.removeEventListener('focus', this.startAnchorListener);

            if (startAnchor.parentNode) {
              startAnchor.parentNode.removeChild(startAnchor);
            }
          }

          if (endAnchor) {
            endAnchor.removeEventListener('focus', this.endAnchorListener);

            if (endAnchor.parentNode) {
              endAnchor.parentNode.removeChild(endAnchor);
            }
          }

          this._startAnchor = this._endAnchor = null;
        }
        /**
         * Inserts the anchors into the DOM. This is usually done automatically
         * in the constructor, but can be deferred for cases like directives with `*ngIf`.
         * @return {?} Whether the focus trap managed to attach successfuly. This may not be the case
         * if the target element isn't currently in the DOM.
         */

      }, {
        key: "attachAnchors",
        value: function attachAnchors() {
          var _this54 = this;

          // If we're not on the browser, there can be no focus to trap.
          if (this._hasAttached) {
            return true;
          }

          this._ngZone.runOutsideAngular(
          /**
          * @return {?}
          */
          function () {
            if (!_this54._startAnchor) {
              _this54._startAnchor = _this54._createAnchor();

              /** @type {?} */
              _this54._startAnchor.addEventListener('focus', _this54.startAnchorListener);
            }

            if (!_this54._endAnchor) {
              _this54._endAnchor = _this54._createAnchor();

              /** @type {?} */
              _this54._endAnchor.addEventListener('focus', _this54.endAnchorListener);
            }
          });

          if (this._element.parentNode) {
            this._element.parentNode.insertBefore(
            /** @type {?} */
            this._startAnchor, this._element);

            this._element.parentNode.insertBefore(
            /** @type {?} */
            this._endAnchor, this._element.nextSibling);

            this._hasAttached = true;
          }

          return this._hasAttached;
        }
        /**
         * Waits for the zone to stabilize, then either focuses the first element that the
         * user specified, or the first tabbable element.
         * @return {?} Returns a promise that resolves with a boolean, depending
         * on whether focus was moved successfuly.
         */

      }, {
        key: "focusInitialElementWhenReady",
        value: function focusInitialElementWhenReady() {
          var _this55 = this;

          return new Promise(
          /**
          * @param {?} resolve
          * @return {?}
          */
          function (resolve) {
            _this55._executeOnStable(
            /**
            * @return {?}
            */
            function () {
              return resolve(_this55.focusInitialElement());
            });
          });
        }
        /**
         * Waits for the zone to stabilize, then focuses
         * the first tabbable element within the focus trap region.
         * @return {?} Returns a promise that resolves with a boolean, depending
         * on whether focus was moved successfuly.
         */

      }, {
        key: "focusFirstTabbableElementWhenReady",
        value: function focusFirstTabbableElementWhenReady() {
          var _this56 = this;

          return new Promise(
          /**
          * @param {?} resolve
          * @return {?}
          */
          function (resolve) {
            _this56._executeOnStable(
            /**
            * @return {?}
            */
            function () {
              return resolve(_this56.focusFirstTabbableElement());
            });
          });
        }
        /**
         * Waits for the zone to stabilize, then focuses
         * the last tabbable element within the focus trap region.
         * @return {?} Returns a promise that resolves with a boolean, depending
         * on whether focus was moved successfuly.
         */

      }, {
        key: "focusLastTabbableElementWhenReady",
        value: function focusLastTabbableElementWhenReady() {
          var _this57 = this;

          return new Promise(
          /**
          * @param {?} resolve
          * @return {?}
          */
          function (resolve) {
            _this57._executeOnStable(
            /**
            * @return {?}
            */
            function () {
              return resolve(_this57.focusLastTabbableElement());
            });
          });
        }
        /**
         * Get the specified boundary element of the trapped region.
         * @private
         * @param {?} bound The boundary to get (start or end of trapped region).
         * @return {?} The boundary element.
         */

      }, {
        key: "_getRegionBoundary",
        value: function _getRegionBoundary(bound) {
          // Contains the deprecated version of selector, for temporary backwards comparability.

          /** @type {?} */
          var markers =
          /** @type {?} */
          this._element.querySelectorAll("[cdk-focus-region-".concat(bound, "], ") + "[cdkFocusRegion".concat(bound, "], ") + "[cdk-focus-".concat(bound, "]"));

          for (var i = 0; i < markers.length; i++) {
            // @breaking-change 8.0.0
            if (markers[i].hasAttribute("cdk-focus-".concat(bound))) {
              console.warn("Found use of deprecated attribute 'cdk-focus-".concat(bound, "', ") + "use 'cdkFocusRegion".concat(bound, "' instead. The deprecated ") + "attribute will be removed in 8.0.0.", markers[i]);
            } else if (markers[i].hasAttribute("cdk-focus-region-".concat(bound))) {
              console.warn("Found use of deprecated attribute 'cdk-focus-region-".concat(bound, "', ") + "use 'cdkFocusRegion".concat(bound, "' instead. The deprecated attribute ") + "will be removed in 8.0.0.", markers[i]);
            }
          }

          if (bound == 'start') {
            return markers.length ? markers[0] : this._getFirstTabbableElement(this._element);
          }

          return markers.length ? markers[markers.length - 1] : this._getLastTabbableElement(this._element);
        }
        /**
         * Focuses the element that should be focused when the focus trap is initialized.
         * @return {?} Whether focus was moved successfuly.
         */

      }, {
        key: "focusInitialElement",
        value: function focusInitialElement() {
          // Contains the deprecated version of selector, for temporary backwards comparability.

          /** @type {?} */
          var redirectToElement =
          /** @type {?} */
          this._element.querySelector("[cdk-focus-initial], " + "[cdkFocusInitial]");

          if (redirectToElement) {
            // @breaking-change 8.0.0
            if (redirectToElement.hasAttribute("cdk-focus-initial")) {
              console.warn("Found use of deprecated attribute 'cdk-focus-initial', " + "use 'cdkFocusInitial' instead. The deprecated attribute " + "will be removed in 8.0.0", redirectToElement);
            } // Warn the consumer if the element they've pointed to
            // isn't focusable, when not in production mode.


            if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["isDevMode"])() && !this._checker.isFocusable(redirectToElement)) {
              console.warn("Element matching '[cdkFocusInitial]' is not focusable.", redirectToElement);
            }

            redirectToElement.focus();
            return true;
          }

          return this.focusFirstTabbableElement();
        }
        /**
         * Focuses the first tabbable element within the focus trap region.
         * @return {?} Whether focus was moved successfuly.
         */

      }, {
        key: "focusFirstTabbableElement",
        value: function focusFirstTabbableElement() {
          /** @type {?} */
          var redirectToElement = this._getRegionBoundary('start');

          if (redirectToElement) {
            redirectToElement.focus();
          }

          return !!redirectToElement;
        }
        /**
         * Focuses the last tabbable element within the focus trap region.
         * @return {?} Whether focus was moved successfuly.
         */

      }, {
        key: "focusLastTabbableElement",
        value: function focusLastTabbableElement() {
          /** @type {?} */
          var redirectToElement = this._getRegionBoundary('end');

          if (redirectToElement) {
            redirectToElement.focus();
          }

          return !!redirectToElement;
        }
        /**
         * Checks whether the focus trap has successfuly been attached.
         * @return {?}
         */

      }, {
        key: "hasAttached",
        value: function hasAttached() {
          return this._hasAttached;
        }
        /**
         * Get the first tabbable element from a DOM subtree (inclusive).
         * @private
         * @param {?} root
         * @return {?}
         */

      }, {
        key: "_getFirstTabbableElement",
        value: function _getFirstTabbableElement(root) {
          if (this._checker.isFocusable(root) && this._checker.isTabbable(root)) {
            return root;
          } // Iterate in DOM order. Note that IE doesn't have `children` for SVG so we fall
          // back to `childNodes` which includes text nodes, comments etc.

          /** @type {?} */


          var children = root.children || root.childNodes;

          for (var i = 0; i < children.length; i++) {
            /** @type {?} */
            var tabbableChild = children[i].nodeType === this._document.ELEMENT_NODE ? this._getFirstTabbableElement(
            /** @type {?} */
            children[i]) : null;

            if (tabbableChild) {
              return tabbableChild;
            }
          }

          return null;
        }
        /**
         * Get the last tabbable element from a DOM subtree (inclusive).
         * @private
         * @param {?} root
         * @return {?}
         */

      }, {
        key: "_getLastTabbableElement",
        value: function _getLastTabbableElement(root) {
          if (this._checker.isFocusable(root) && this._checker.isTabbable(root)) {
            return root;
          } // Iterate in reverse DOM order.

          /** @type {?} */


          var children = root.children || root.childNodes;

          for (var i = children.length - 1; i >= 0; i--) {
            /** @type {?} */
            var tabbableChild = children[i].nodeType === this._document.ELEMENT_NODE ? this._getLastTabbableElement(
            /** @type {?} */
            children[i]) : null;

            if (tabbableChild) {
              return tabbableChild;
            }
          }

          return null;
        }
        /**
         * Creates an anchor element.
         * @private
         * @return {?}
         */

      }, {
        key: "_createAnchor",
        value: function _createAnchor() {
          /** @type {?} */
          var anchor = this._document.createElement('div');

          this._toggleAnchorTabIndex(this._enabled, anchor);

          anchor.classList.add('cdk-visually-hidden');
          anchor.classList.add('cdk-focus-trap-anchor');
          anchor.setAttribute('aria-hidden', 'true');
          return anchor;
        }
        /**
         * Toggles the `tabindex` of an anchor, based on the enabled state of the focus trap.
         * @private
         * @param {?} isEnabled Whether the focus trap is enabled.
         * @param {?} anchor Anchor on which to toggle the tabindex.
         * @return {?}
         */

      }, {
        key: "_toggleAnchorTabIndex",
        value: function _toggleAnchorTabIndex(isEnabled, anchor) {
          // Remove the tabindex completely, rather than setting it to -1, because if the
          // element has a tabindex, the user might still hit it when navigating with the arrow keys.
          isEnabled ? anchor.setAttribute('tabindex', '0') : anchor.removeAttribute('tabindex');
        }
        /**
         * Toggles the`tabindex` of both anchors to either trap Tab focus or allow it to escape.
         * @protected
         * @param {?} enabled
         * @return {?}
         */

      }, {
        key: "toggleAnchors",
        value: function toggleAnchors(enabled) {
          if (this._startAnchor && this._endAnchor) {
            this._toggleAnchorTabIndex(enabled, this._startAnchor);

            this._toggleAnchorTabIndex(enabled, this._endAnchor);
          }
        }
        /**
         * Executes a function when the zone is stable.
         * @private
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "_executeOnStable",
        value: function _executeOnStable(fn) {
          if (this._ngZone.isStable) {
            fn();
          } else {
            this._ngZone.onStable.asObservable().pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_4__["take"])(1)).subscribe(fn);
          }
        }
      }, {
        key: "enabled",
        get: function get() {
          return this._enabled;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._enabled = value;

          if (this._startAnchor && this._endAnchor) {
            this._toggleAnchorTabIndex(value, this._startAnchor);

            this._toggleAnchorTabIndex(value, this._endAnchor);
          }
        }
      }]);

      return FocusTrap;
    }();

    if (false) {}
    /**
     * Factory that allows easy instantiation of focus traps.
     * @deprecated Use `ConfigurableFocusTrapFactory` instead.
     * \@breaking-change for 11.0.0 Remove this class.
     */


    var FocusTrapFactory = /*#__PURE__*/function () {
      /**
       * @param {?} _checker
       * @param {?} _ngZone
       * @param {?} _document
       */
      function FocusTrapFactory(_checker, _ngZone, _document) {
        _classCallCheck(this, FocusTrapFactory);

        this._checker = _checker;
        this._ngZone = _ngZone;
        this._document = _document;
      }
      /**
       * Creates a focus-trapped region around the given element.
       * @param {?} element The element around which focus will be trapped.
       * @param {?=} deferCaptureElements Defers the creation of focus-capturing elements to be done
       *     manually by the user.
       * @return {?} The created focus trap instance.
       */


      _createClass2(FocusTrapFactory, [{
        key: "create",
        value: function create(element) {
          var deferCaptureElements = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
          return new FocusTrap(element, this._checker, this._ngZone, this._document, deferCaptureElements);
        }
      }]);

      return FocusTrapFactory;
    }();

    FocusTrapFactory.ɵfac = function FocusTrapFactory_Factory(t) {
      return new (t || FocusTrapFactory)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](InteractivityChecker), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]));
    };
    /** @nocollapse */


    FocusTrapFactory.ctorParameters = function () {
      return [{
        type: InteractivityChecker
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
        }]
      }];
    };
    /** @nocollapse */


    FocusTrapFactory.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: function FocusTrapFactory_Factory() {
        return new FocusTrapFactory(Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(InteractivityChecker), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]));
      },
      token: FocusTrapFactory,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](FocusTrapFactory, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [{
          type: InteractivityChecker
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * Directive for trapping focus within a region.
     */


    var CdkTrapFocus = /*#__PURE__*/function () {
      /**
       * @param {?} _elementRef
       * @param {?} _focusTrapFactory
       * @param {?} _document
       */
      function CdkTrapFocus(_elementRef, _focusTrapFactory, _document) {
        _classCallCheck(this, CdkTrapFocus);

        this._elementRef = _elementRef;
        this._focusTrapFactory = _focusTrapFactory;
        /**
         * Previously focused element to restore focus to upon destroy when using autoCapture.
         */

        this._previouslyFocusedElement = null;
        this._document = _document;
        this.focusTrap = this._focusTrapFactory.create(this._elementRef.nativeElement, true);
      }
      /**
       * Whether the focus trap is active.
       * @return {?}
       */


      _createClass2(CdkTrapFocus, [{
        key: "ngOnDestroy",

        /**
         * @return {?}
         */
        value: function ngOnDestroy() {
          this.focusTrap.destroy(); // If we stored a previously focused element when using autoCapture, return focus to that
          // element now that the trapped region is being destroyed.

          if (this._previouslyFocusedElement) {
            this._previouslyFocusedElement.focus();

            this._previouslyFocusedElement = null;
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngAfterContentInit",
        value: function ngAfterContentInit() {
          this.focusTrap.attachAnchors();

          if (this.autoCapture) {
            this._previouslyFocusedElement =
            /** @type {?} */
            this._document.activeElement;
            this.focusTrap.focusInitialElementWhenReady();
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngDoCheck",
        value: function ngDoCheck() {
          if (!this.focusTrap.hasAttached()) {
            this.focusTrap.attachAnchors();
          }
        }
      }, {
        key: "enabled",
        get: function get() {
          return this.focusTrap.enabled;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this.focusTrap.enabled = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceBooleanProperty"])(value);
        }
        /**
         * Whether the directive should automatially move focus into the trapped region upon
         * initialization and return focus to the previous activeElement upon destruction.
         * @return {?}
         */

      }, {
        key: "autoCapture",
        get: function get() {
          return this._autoCapture;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._autoCapture = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceBooleanProperty"])(value);
        }
      }]);

      return CdkTrapFocus;
    }();

    CdkTrapFocus.ɵfac = function CdkTrapFocus_Factory(t) {
      return new (t || CdkTrapFocus)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](FocusTrapFactory), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]));
    };

    CdkTrapFocus.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineDirective"]({
      type: CdkTrapFocus,
      selectors: [["", "cdkTrapFocus", ""]],
      inputs: {
        enabled: ["cdkTrapFocus", "enabled"],
        autoCapture: ["cdkTrapFocusAutoCapture", "autoCapture"]
      },
      exportAs: ["cdkTrapFocus"]
    });
    /** @nocollapse */

    CdkTrapFocus.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]
      }, {
        type: FocusTrapFactory
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
        }]
      }];
    };

    CdkTrapFocus.propDecorators = {
      enabled: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkTrapFocus']
      }],
      autoCapture: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkTrapFocusAutoCapture']
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](CdkTrapFocus, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Directive"],
        args: [{
          selector: '[cdkTrapFocus]',
          exportAs: 'cdkTrapFocus'
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]
        }, {
          type: FocusTrapFactory
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
          }]
        }];
      }, {
        enabled: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkTrapFocus']
        }],
        autoCapture: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkTrapFocusAutoCapture']
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/focus-trap/configurable-focus-trap.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Class that allows for trapping focus within a DOM element.
     *
     * This class uses a strategy pattern that determines how it traps focus.
     * See FocusTrapInertStrategy.
     */


    var ConfigurableFocusTrap = /*#__PURE__*/function (_FocusTrap) {
      _inherits(ConfigurableFocusTrap, _FocusTrap);

      var _super6 = _createSuper(ConfigurableFocusTrap);

      /**
       * @param {?} _element
       * @param {?} _checker
       * @param {?} _ngZone
       * @param {?} _document
       * @param {?} _focusTrapManager
       * @param {?} _inertStrategy
       * @param {?} config
       */
      function ConfigurableFocusTrap(_element, _checker, _ngZone, _document, _focusTrapManager, _inertStrategy, config) {
        var _this58;

        _classCallCheck(this, ConfigurableFocusTrap);

        _this58 = _super6.call(this, _element, _checker, _ngZone, _document, config.defer);
        _this58._focusTrapManager = _focusTrapManager;
        _this58._inertStrategy = _inertStrategy;

        _this58._focusTrapManager.register(_assertThisInitialized(_this58));

        return _this58;
      }
      /**
       * Whether the FocusTrap is enabled.
       * @return {?}
       */


      _createClass2(ConfigurableFocusTrap, [{
        key: "destroy",

        /**
         * Notifies the FocusTrapManager that this FocusTrap will be destroyed.
         * @return {?}
         */
        value: function destroy() {
          this._focusTrapManager.deregister(this);

          _get(_getPrototypeOf(ConfigurableFocusTrap.prototype), "destroy", this).call(this);
        }
        /**
         * \@docs-private Implemented as part of ManagedFocusTrap.
         * @return {?}
         */

      }, {
        key: "_enable",
        value: function _enable() {
          this._inertStrategy.preventFocus(this);

          this.toggleAnchors(true);
        }
        /**
         * \@docs-private Implemented as part of ManagedFocusTrap.
         * @return {?}
         */

      }, {
        key: "_disable",
        value: function _disable() {
          this._inertStrategy.allowFocus(this);

          this.toggleAnchors(false);
        }
      }, {
        key: "enabled",
        get: function get() {
          return this._enabled;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._enabled = value;

          if (this._enabled) {
            this._focusTrapManager.register(this);
          } else {
            this._focusTrapManager.deregister(this);
          }
        }
      }]);

      return ConfigurableFocusTrap;
    }(FocusTrap);

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/focus-trap/polyfill.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * IE 11 compatible closest implementation that is able to start from non-Element Nodes.
     * @param {?} element
     * @param {?} selector
     * @return {?}
     */


    function closest(element, selector) {
      if (!(element instanceof Node)) {
        return null;
      }
      /** @type {?} */


      var curr = element;

      while (curr != null && !(curr instanceof Element)) {
        curr = curr.parentNode;
      }

      return curr && (
      /** @type {?} */
      hasNativeClosest ? curr.closest(selector) : polyfillClosest(curr, selector));
    }
    /**
     * Polyfill for browsers without Element.closest.
     * @param {?} element
     * @param {?} selector
     * @return {?}
     */


    function polyfillClosest(element, selector) {
      /** @type {?} */
      var curr = element;

      while (curr != null && !(curr instanceof Element && matches(curr, selector))) {
        curr = curr.parentNode;
      }

      return (
        /** @type {?} */
        curr || null
      );
    }
    /** @type {?} */


    var hasNativeClosest = typeof Element != 'undefined' && !!Element.prototype.closest;
    /**
     * IE 11 compatible matches implementation.
     * @param {?} element
     * @param {?} selector
     * @return {?}
     */

    function matches(element, selector) {
      return element.matches ? element.matches(selector) :
      /** @type {?} */
      element['msMatchesSelector'](selector);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/focus-trap/event-listener-inert-strategy.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Lightweight FocusTrapInertStrategy that adds a document focus event
     * listener to redirect focus back inside the FocusTrap.
     */


    var EventListenerFocusTrapInertStrategy = /*#__PURE__*/function () {
      function EventListenerFocusTrapInertStrategy() {
        _classCallCheck(this, EventListenerFocusTrapInertStrategy);

        /**
         * Focus event handler.
         */
        this._listener = null;
      }
      /**
       * Adds a document event listener that keeps focus inside the FocusTrap.
       * @param {?} focusTrap
       * @return {?}
       */


      _createClass2(EventListenerFocusTrapInertStrategy, [{
        key: "preventFocus",
        value: function preventFocus(focusTrap) {
          var _this59 = this;

          // Ensure there's only one listener per document
          if (this._listener) {
            focusTrap._document.removeEventListener('focus',
            /** @type {?} */
            this._listener, true);
          }

          this._listener =
          /**
          * @param {?} e
          * @return {?}
          */
          function (e) {
            return _this59._trapFocus(focusTrap, e);
          };

          focusTrap._ngZone.runOutsideAngular(
          /**
          * @return {?}
          */
          function () {
            focusTrap._document.addEventListener('focus',
            /** @type {?} */
            _this59._listener, true);
          });
        }
        /**
         * Removes the event listener added in preventFocus.
         * @param {?} focusTrap
         * @return {?}
         */

      }, {
        key: "allowFocus",
        value: function allowFocus(focusTrap) {
          if (!this._listener) {
            return;
          }

          focusTrap._document.removeEventListener('focus',
          /** @type {?} */
          this._listener, true);

          this._listener = null;
        }
        /**
         * Refocuses the first element in the FocusTrap if the focus event target was outside
         * the FocusTrap.
         *
         * This is an event listener callback. The event listener is added in runOutsideAngular,
         * so all this code runs outside Angular as well.
         * @private
         * @param {?} focusTrap
         * @param {?} event
         * @return {?}
         */

      }, {
        key: "_trapFocus",
        value: function _trapFocus(focusTrap, event) {
          /** @type {?} */
          var target =
          /** @type {?} */
          event.target;
          /** @type {?} */

          var focusTrapRoot = focusTrap._element; // Don't refocus if target was in an overlay, because the overlay might be associated
          // with an element inside the FocusTrap, ex. mat-select.

          if (!focusTrapRoot.contains(target) && closest(target, 'div.cdk-overlay-pane') === null) {
            // Some legacy FocusTrap usages have logic that focuses some element on the page
            // just before FocusTrap is destroyed. For backwards compatibility, wait
            // to be sure FocusTrap is still enabled before refocusing.
            setTimeout(
            /**
            * @return {?}
            */
            function () {
              // Check whether focus wasn't put back into the focus trap while the timeout was pending.
              if (focusTrap.enabled && !focusTrapRoot.contains(focusTrap._document.activeElement)) {
                focusTrap.focusFirstTabbableElement();
              }
            });
          }
        }
      }]);

      return EventListenerFocusTrapInertStrategy;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/focus-trap/configurable-focus-trap-config.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Configuration for creating a ConfigurableFocusTrap.
     */


    var ConfigurableFocusTrapConfig = function ConfigurableFocusTrapConfig() {
      _classCallCheck(this, ConfigurableFocusTrapConfig);

      /**
       * Whether to defer the creation of FocusTrap elements to be
       * done manually by the user. Default is to create them
       * automatically.
       */
      this.defer = false;
    };

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/focus-trap/focus-trap-inert-strategy.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * The injection token used to specify the inert strategy.
     * @type {?}
     */


    var FOCUS_TRAP_INERT_STRATEGY = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["InjectionToken"]('FOCUS_TRAP_INERT_STRATEGY');
    /**
     * A strategy that dictates how FocusTrap should prevent elements
     * outside of the FocusTrap from being focused.
     * @record
     */

    function FocusTrapInertStrategy() {}

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/focus-trap/focus-trap-manager.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * A FocusTrap managed by FocusTrapManager.
     * Implemented by ConfigurableFocusTrap to avoid circular dependency.
     * @record
     */


    function ManagedFocusTrap() {}

    if (false) {}
    /**
     * Injectable that ensures only the most recently enabled FocusTrap is active.
     */


    var FocusTrapManager = /*#__PURE__*/function () {
      function FocusTrapManager() {
        _classCallCheck(this, FocusTrapManager);

        // A stack of the FocusTraps on the page. Only the FocusTrap at the
        // top of the stack is active.
        this._focusTrapStack = [];
      }
      /**
       * Disables the FocusTrap at the top of the stack, and then pushes
       * the new FocusTrap onto the stack.
       * @param {?} focusTrap
       * @return {?}
       */


      _createClass2(FocusTrapManager, [{
        key: "register",
        value: function register(focusTrap) {
          // Dedupe focusTraps that register multiple times.
          this._focusTrapStack = this._focusTrapStack.filter(
          /**
          * @param {?} ft
          * @return {?}
          */
          function (ft) {
            return ft !== focusTrap;
          });
          /** @type {?} */

          var stack = this._focusTrapStack;

          if (stack.length) {
            stack[stack.length - 1]._disable();
          }

          stack.push(focusTrap);

          focusTrap._enable();
        }
        /**
         * Removes the FocusTrap from the stack, and activates the
         * FocusTrap that is the new top of the stack.
         * @param {?} focusTrap
         * @return {?}
         */

      }, {
        key: "deregister",
        value: function deregister(focusTrap) {
          focusTrap._disable();
          /** @type {?} */


          var stack = this._focusTrapStack;
          /** @type {?} */

          var i = stack.indexOf(focusTrap);

          if (i !== -1) {
            stack.splice(i, 1);

            if (stack.length) {
              stack[stack.length - 1]._enable();
            }
          }
        }
      }]);

      return FocusTrapManager;
    }();

    FocusTrapManager.ɵfac = function FocusTrapManager_Factory(t) {
      return new (t || FocusTrapManager)();
    };
    /** @nocollapse */


    FocusTrapManager.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: function FocusTrapManager_Factory() {
        return new FocusTrapManager();
      },
      token: FocusTrapManager,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](FocusTrapManager, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/focus-trap/configurable-focus-trap-factory.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Factory that allows easy instantiation of configurable focus traps.
     */


    var ConfigurableFocusTrapFactory = /*#__PURE__*/function () {
      /**
       * @param {?} _checker
       * @param {?} _ngZone
       * @param {?} _focusTrapManager
       * @param {?} _document
       * @param {?=} _inertStrategy
       */
      function ConfigurableFocusTrapFactory(_checker, _ngZone, _focusTrapManager, _document, _inertStrategy) {
        _classCallCheck(this, ConfigurableFocusTrapFactory);

        this._checker = _checker;
        this._ngZone = _ngZone;
        this._focusTrapManager = _focusTrapManager;
        this._document = _document; // TODO split up the strategies into different modules, similar to DateAdapter.

        this._inertStrategy = _inertStrategy || new EventListenerFocusTrapInertStrategy();
      }
      /**
       * @param {?} element
       * @param {?=} config
       * @return {?}
       */


      _createClass2(ConfigurableFocusTrapFactory, [{
        key: "create",
        value: function create(element) {
          var config = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : new ConfigurableFocusTrapConfig();

          /** @type {?} */
          var configObject;

          if (typeof config === 'boolean') {
            configObject = new ConfigurableFocusTrapConfig();
            configObject.defer = config;
          } else {
            configObject = config;
          }

          return new ConfigurableFocusTrap(element, this._checker, this._ngZone, this._document, this._focusTrapManager, this._inertStrategy, configObject);
        }
      }]);

      return ConfigurableFocusTrapFactory;
    }();

    ConfigurableFocusTrapFactory.ɵfac = function ConfigurableFocusTrapFactory_Factory(t) {
      return new (t || ConfigurableFocusTrapFactory)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](InteractivityChecker), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](FocusTrapManager), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](FOCUS_TRAP_INERT_STRATEGY, 8));
    };
    /** @nocollapse */


    ConfigurableFocusTrapFactory.ctorParameters = function () {
      return [{
        type: InteractivityChecker
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
      }, {
        type: FocusTrapManager
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
        }]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [FOCUS_TRAP_INERT_STRATEGY]
        }]
      }];
    };
    /** @nocollapse */


    ConfigurableFocusTrapFactory.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: function ConfigurableFocusTrapFactory_Factory() {
        return new ConfigurableFocusTrapFactory(Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(InteractivityChecker), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(FocusTrapManager), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(FOCUS_TRAP_INERT_STRATEGY, 8));
      },
      token: ConfigurableFocusTrapFactory,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](ConfigurableFocusTrapFactory, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [{
          type: InteractivityChecker
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
        }, {
          type: FocusTrapManager
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
          }]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [FOCUS_TRAP_INERT_STRATEGY]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/live-announcer/live-announcer-tokens.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var LIVE_ANNOUNCER_ELEMENT_TOKEN = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["InjectionToken"]('liveAnnouncerElement', {
      providedIn: 'root',
      factory: LIVE_ANNOUNCER_ELEMENT_TOKEN_FACTORY
    });
    /**
     * \@docs-private
     * @return {?}
     */

    function LIVE_ANNOUNCER_ELEMENT_TOKEN_FACTORY() {
      return null;
    }
    /**
     * Object that can be used to configure the default options for the LiveAnnouncer.
     * @record
     */


    function LiveAnnouncerDefaultOptions() {}

    if (false) {}
    /**
     * Injection token that can be used to configure the default options for the LiveAnnouncer.
     * @type {?}
     */


    var LIVE_ANNOUNCER_DEFAULT_OPTIONS = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["InjectionToken"]('LIVE_ANNOUNCER_DEFAULT_OPTIONS');
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/live-announcer/live-announcer.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    var LiveAnnouncer = /*#__PURE__*/function () {
      /**
       * @param {?} elementToken
       * @param {?} _ngZone
       * @param {?} _document
       * @param {?=} _defaultOptions
       */
      function LiveAnnouncer(elementToken, _ngZone, _document, _defaultOptions) {
        _classCallCheck(this, LiveAnnouncer);

        this._ngZone = _ngZone;
        this._defaultOptions = _defaultOptions; // We inject the live element and document as `any` because the constructor signature cannot
        // reference browser globals (HTMLElement, Document) on non-browser environments, since having
        // a class decorator causes TypeScript to preserve the constructor signature types.

        this._document = _document;
        this._liveElement = elementToken || this._createLiveElement();
      }
      /**
       * @param {?} message
       * @param {...?} args
       * @return {?}
       */


      _createClass2(LiveAnnouncer, [{
        key: "announce",
        value: function announce(message) {
          var _this60 = this;

          /** @type {?} */
          var defaultOptions = this._defaultOptions;
          /** @type {?} */

          var politeness;
          /** @type {?} */

          var duration;

          for (var _len2 = arguments.length, args = new Array(_len2 > 1 ? _len2 - 1 : 0), _key3 = 1; _key3 < _len2; _key3++) {
            args[_key3 - 1] = arguments[_key3];
          }

          if (args.length === 1 && typeof args[0] === 'number') {
            duration = args[0];
          } else {
            politeness = args[0];
            duration = args[1];
          }

          this.clear();
          clearTimeout(this._previousTimeout);

          if (!politeness) {
            politeness = defaultOptions && defaultOptions.politeness ? defaultOptions.politeness : 'polite';
          }

          if (duration == null && defaultOptions) {
            duration = defaultOptions.duration;
          } // TODO: ensure changing the politeness works on all environments we support.


          this._liveElement.setAttribute('aria-live', politeness); // This 100ms timeout is necessary for some browser + screen-reader combinations:
          // - Both JAWS and NVDA over IE11 will not announce anything without a non-zero timeout.
          // - With Chrome and IE11 with NVDA or JAWS, a repeated (identical) message won't be read a
          //   second time without clearing and then using a non-zero delay.
          // (using JAWS 17 at time of this writing).


          return this._ngZone.runOutsideAngular(
          /**
          * @return {?}
          */
          function () {
            return new Promise(
            /**
            * @param {?} resolve
            * @return {?}
            */
            function (resolve) {
              clearTimeout(_this60._previousTimeout);
              _this60._previousTimeout = setTimeout(
              /**
              * @return {?}
              */
              function () {
                _this60._liveElement.textContent = message;
                resolve();

                if (typeof duration === 'number') {
                  _this60._previousTimeout = setTimeout(
                  /**
                  * @return {?}
                  */
                  function () {
                    return _this60.clear();
                  }, duration);
                }
              }, 100);
            });
          });
        }
        /**
         * Clears the current text from the announcer element. Can be used to prevent
         * screen readers from reading the text out again while the user is going
         * through the page landmarks.
         * @return {?}
         */

      }, {
        key: "clear",
        value: function clear() {
          if (this._liveElement) {
            this._liveElement.textContent = '';
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          clearTimeout(this._previousTimeout);

          if (this._liveElement && this._liveElement.parentNode) {
            this._liveElement.parentNode.removeChild(this._liveElement);

            this._liveElement =
            /** @type {?} */
            null;
          }
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_createLiveElement",
        value: function _createLiveElement() {
          /** @type {?} */
          var elementClass = 'cdk-live-announcer-element';
          /** @type {?} */

          var previousElements = this._document.getElementsByClassName(elementClass);
          /** @type {?} */


          var liveEl = this._document.createElement('div'); // Remove any old containers. This can happen when coming in from a server-side-rendered page.


          for (var i = 0; i < previousElements.length; i++) {
            /** @type {?} */
            previousElements[i].parentNode.removeChild(previousElements[i]);
          }

          liveEl.classList.add(elementClass);
          liveEl.classList.add('cdk-visually-hidden');
          liveEl.setAttribute('aria-atomic', 'true');
          liveEl.setAttribute('aria-live', 'polite');

          this._document.body.appendChild(liveEl);

          return liveEl;
        }
      }]);

      return LiveAnnouncer;
    }();

    LiveAnnouncer.ɵfac = function LiveAnnouncer_Factory(t) {
      return new (t || LiveAnnouncer)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](LIVE_ANNOUNCER_ELEMENT_TOKEN, 8), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](LIVE_ANNOUNCER_DEFAULT_OPTIONS, 8));
    };
    /** @nocollapse */


    LiveAnnouncer.ctorParameters = function () {
      return [{
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [LIVE_ANNOUNCER_ELEMENT_TOKEN]
        }]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
        }]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [LIVE_ANNOUNCER_DEFAULT_OPTIONS]
        }]
      }];
    };
    /** @nocollapse */


    LiveAnnouncer.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: function LiveAnnouncer_Factory() {
        return new LiveAnnouncer(Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(LIVE_ANNOUNCER_ELEMENT_TOKEN, 8), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(LIVE_ANNOUNCER_DEFAULT_OPTIONS, 8));
      },
      token: LiveAnnouncer,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](LiveAnnouncer, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [{
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [LIVE_ANNOUNCER_ELEMENT_TOKEN]
          }]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
          }]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [LIVE_ANNOUNCER_DEFAULT_OPTIONS]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * A directive that works similarly to aria-live, but uses the LiveAnnouncer to ensure compatibility
     * with a wider range of browsers and screen readers.
     */


    var CdkAriaLive = /*#__PURE__*/function () {
      /**
       * @param {?} _elementRef
       * @param {?} _liveAnnouncer
       * @param {?} _contentObserver
       * @param {?} _ngZone
       */
      function CdkAriaLive(_elementRef, _liveAnnouncer, _contentObserver, _ngZone) {
        _classCallCheck(this, CdkAriaLive);

        this._elementRef = _elementRef;
        this._liveAnnouncer = _liveAnnouncer;
        this._contentObserver = _contentObserver;
        this._ngZone = _ngZone;
        this._politeness = 'off';
      }
      /**
       * The aria-live politeness level to use when announcing messages.
       * @return {?}
       */


      _createClass2(CdkAriaLive, [{
        key: "ngOnDestroy",

        /**
         * @return {?}
         */
        value: function ngOnDestroy() {
          if (this._subscription) {
            this._subscription.unsubscribe();
          }
        }
      }, {
        key: "politeness",
        get: function get() {
          return this._politeness;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          var _this61 = this;

          this._politeness = value === 'polite' || value === 'assertive' ? value : 'off';

          if (this._politeness === 'off') {
            if (this._subscription) {
              this._subscription.unsubscribe();

              this._subscription = null;
            }
          } else if (!this._subscription) {
            this._subscription = this._ngZone.runOutsideAngular(
            /**
            * @return {?}
            */
            function () {
              return _this61._contentObserver.observe(_this61._elementRef).subscribe(
              /**
              * @return {?}
              */
              function () {
                // Note that we use textContent here, rather than innerText, in order to avoid a reflow.

                /** @type {?} */
                var elementText = _this61._elementRef.nativeElement.textContent; // The `MutationObserver` fires also for attribute
                // changes which we don't want to announce.

                if (elementText !== _this61._previousAnnouncedText) {
                  _this61._liveAnnouncer.announce(elementText, _this61._politeness);

                  _this61._previousAnnouncedText = elementText;
                }
              });
            });
          }
        }
      }]);

      return CdkAriaLive;
    }();

    CdkAriaLive.ɵfac = function CdkAriaLive_Factory(t) {
      return new (t || CdkAriaLive)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](LiveAnnouncer), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_cdk_observers__WEBPACK_IMPORTED_MODULE_7__["ContentObserver"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]));
    };

    CdkAriaLive.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineDirective"]({
      type: CdkAriaLive,
      selectors: [["", "cdkAriaLive", ""]],
      inputs: {
        politeness: ["cdkAriaLive", "politeness"]
      },
      exportAs: ["cdkAriaLive"]
    });
    /** @nocollapse */

    CdkAriaLive.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]
      }, {
        type: LiveAnnouncer
      }, {
        type: _angular_cdk_observers__WEBPACK_IMPORTED_MODULE_7__["ContentObserver"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
      }];
    };

    CdkAriaLive.propDecorators = {
      politeness: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkAriaLive']
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](CdkAriaLive, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Directive"],
        args: [{
          selector: '[cdkAriaLive]',
          exportAs: 'cdkAriaLive'
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]
        }, {
          type: LiveAnnouncer
        }, {
          type: _angular_cdk_observers__WEBPACK_IMPORTED_MODULE_7__["ContentObserver"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
        }];
      }, {
        politeness: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkAriaLive']
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/fake-mousedown.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Screenreaders will often fire fake mousedown events when a focusable element
     * is activated using the keyboard. We can typically distinguish between these faked
     * mousedown events and real mousedown events using the "buttons" property. While
     * real mousedowns will indicate the mouse button that was pressed (e.g. "1" for
     * the left mouse button), faked mousedowns will usually set the property value to 0.
     * @param {?} event
     * @return {?}
     */


    function isFakeMousedownFromScreenReader(event) {
      return event.buttons === 0;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/focus-monitor/focus-monitor.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */
    // This is the value used by AngularJS Material. Through trial and error (on iPhone 6S) they found
    // that a value of around 650ms seems appropriate.

    /** @type {?} */


    var TOUCH_BUFFER_MS = 650;
    /**
     * Corresponds to the options that can be passed to the native `focus` event.
     * via https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement/focus
     * @record
     */

    function FocusOptions() {}

    if (false) {}
    /** @enum {number} */


    var FocusMonitorDetectionMode = {
      /**
       * Any mousedown, keydown, or touchstart event that happened in the previous
       * tick or the current tick will be used to assign a focus event's origin (to
       * either mouse, keyboard, or touch). This is the default option.
       */
      IMMEDIATE: 0,

      /**
       * A focus event's origin is always attributed to the last corresponding
       * mousedown, keydown, or touchstart event, no matter how long ago it occured.
       */
      EVENTUAL: 1
    };
    /**
     * Injectable service-level options for FocusMonitor.
     * @record
     */

    function FocusMonitorOptions() {}

    if (false) {}
    /**
     * InjectionToken for FocusMonitorOptions.
     * @type {?}
     */


    var FOCUS_MONITOR_DEFAULT_OPTIONS = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["InjectionToken"]('cdk-focus-monitor-default-options');
    /**
     * Event listener options that enable capturing and also
     * mark the listener as passive if the browser supports it.
     * @type {?}
     */

    var captureEventListenerOptions = Object(_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_6__["normalizePassiveListenerOptions"])({
      passive: true,
      capture: true
    });
    /**
     * Monitors mouse and keyboard events to determine the cause of focus events.
     */

    var FocusMonitor = /*#__PURE__*/function () {
      /**
       * @param {?} _ngZone
       * @param {?} _platform
       * @param {?} document
       * @param {?} options
       */
      function FocusMonitor(_ngZone, _platform,
      /** @breaking-change 11.0.0 make document required */
      document, options) {
        var _this62 = this;

        _classCallCheck(this, FocusMonitor);

        this._ngZone = _ngZone;
        this._platform = _platform;
        /**
         * The focus origin that the next focus event is a result of.
         */

        this._origin = null;
        /**
         * Whether the window has just been focused.
         */

        this._windowFocused = false;
        /**
         * Map of elements being monitored to their info.
         */

        this._elementInfo = new Map();
        /**
         * The number of elements currently being monitored.
         */

        this._monitoredElementCount = 0;
        /**
         * Keeps track of the root nodes to which we've currently bound a focus/blur handler,
         * as well as the number of monitored elements that they contain. We have to treat focus/blur
         * handlers differently from the rest of the events, because the browser won't emit events
         * to the document when focus moves inside of a shadow root.
         */

        this._rootNodeFocusListenerCount = new Map();
        /**
         * Event listener for `keydown` events on the document.
         * Needs to be an arrow function in order to preserve the context when it gets bound.
         */

        this._documentKeydownListener =
        /**
        * @return {?}
        */
        function () {
          // On keydown record the origin and clear any touch event that may be in progress.
          _this62._lastTouchTarget = null;

          _this62._setOriginForCurrentEventQueue('keyboard');
        };
        /**
         * Event listener for `mousedown` events on the document.
         * Needs to be an arrow function in order to preserve the context when it gets bound.
         */


        this._documentMousedownListener =
        /**
        * @param {?} event
        * @return {?}
        */
        function (event) {
          // On mousedown record the origin only if there is not touch
          // target, since a mousedown can happen as a result of a touch event.
          if (!_this62._lastTouchTarget) {
            // In some cases screen readers fire fake `mousedown` events instead of `keydown`.
            // Resolve the focus source to `keyboard` if we detect one of them.

            /** @type {?} */
            var source = isFakeMousedownFromScreenReader(event) ? 'keyboard' : 'mouse';

            _this62._setOriginForCurrentEventQueue(source);
          }
        };
        /**
         * Event listener for `touchstart` events on the document.
         * Needs to be an arrow function in order to preserve the context when it gets bound.
         */


        this._documentTouchstartListener =
        /**
        * @param {?} event
        * @return {?}
        */
        function (event) {
          // When the touchstart event fires the focus event is not yet in the event queue. This means
          // we can't rely on the trick used above (setting timeout of 1ms). Instead we wait 650ms to
          // see if a focus happens.
          if (_this62._touchTimeoutId != null) {
            clearTimeout(_this62._touchTimeoutId);
          }

          _this62._lastTouchTarget = getTarget(event);
          _this62._touchTimeoutId = setTimeout(
          /**
          * @return {?}
          */
          function () {
            return _this62._lastTouchTarget = null;
          }, TOUCH_BUFFER_MS);
        };
        /**
         * Event listener for `focus` events on the window.
         * Needs to be an arrow function in order to preserve the context when it gets bound.
         */


        this._windowFocusListener =
        /**
        * @return {?}
        */
        function () {
          // Make a note of when the window regains focus, so we can
          // restore the origin info for the focused element.
          _this62._windowFocused = true;
          _this62._windowFocusTimeoutId = setTimeout(
          /**
          * @return {?}
          */
          function () {
            return _this62._windowFocused = false;
          });
        };
        /**
         * Event listener for `focus` and 'blur' events on the document.
         * Needs to be an arrow function in order to preserve the context when it gets bound.
         */


        this._rootNodeFocusAndBlurListener =
        /**
        * @param {?} event
        * @return {?}
        */
        function (event) {
          /** @type {?} */
          var target = getTarget(event);
          /** @type {?} */

          var handler = event.type === 'focus' ? _this62._onFocus : _this62._onBlur; // We need to walk up the ancestor chain in order to support `checkChildren`.

          for (var element = target; element; element = element.parentElement) {
            handler.call(_this62,
            /** @type {?} */
            event, element);
          }
        };

        this._document = document;
        this._detectionMode = (options === null || options === void 0 ? void 0 : options.detectionMode) || 0
        /* IMMEDIATE */
        ;
      }
      /**
       * @param {?} element
       * @param {?=} checkChildren
       * @return {?}
       */


      _createClass2(FocusMonitor, [{
        key: "monitor",
        value: function monitor(element) {
          var checkChildren = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;

          // Do nothing if we're not on the browser platform.
          if (!this._platform.isBrowser) {
            return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(null);
          }
          /** @type {?} */


          var nativeElement = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceElement"])(element); // If the element is inside the shadow DOM, we need to bind our focus/blur listeners to
          // the shadow root, rather than the `document`, because the browser won't emit focus events
          // to the `document`, if focus is moving within the same shadow root.

          /** @type {?} */

          var rootNode =
          /** @type {?} */
          Object(_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_6__["_getShadowRoot"])(nativeElement) || this._getDocument(); // Check if we're already monitoring this element.


          if (this._elementInfo.has(nativeElement)) {
            /** @type {?} */
            var cachedInfo =
            /** @type {?} */
            this._elementInfo.get(nativeElement);

            cachedInfo.checkChildren = checkChildren;
            return cachedInfo.subject.asObservable();
          } // Create monitored element info.

          /** @type {?} */


          var info = {
            checkChildren: checkChildren,
            subject: new rxjs__WEBPACK_IMPORTED_MODULE_2__["Subject"](),
            rootNode: rootNode
          };

          this._elementInfo.set(nativeElement, info);

          this._registerGlobalListeners(info);

          return info.subject.asObservable();
        }
        /**
         * @param {?} element
         * @return {?}
         */

      }, {
        key: "stopMonitoring",
        value: function stopMonitoring(element) {
          /** @type {?} */
          var nativeElement = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceElement"])(element);
          /** @type {?} */

          var elementInfo = this._elementInfo.get(nativeElement);

          if (elementInfo) {
            elementInfo.subject.complete();

            this._setClasses(nativeElement);

            this._elementInfo["delete"](nativeElement);

            this._removeGlobalListeners(elementInfo);
          }
        }
        /**
         * @param {?} element
         * @param {?} origin
         * @param {?=} options
         * @return {?}
         */

      }, {
        key: "focusVia",
        value: function focusVia(element, origin, options) {
          /** @type {?} */
          var nativeElement = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceElement"])(element);

          this._setOriginForCurrentEventQueue(origin); // `focus` isn't available on the server


          if (typeof nativeElement.focus === 'function') {
            // Cast the element to `any`, because the TS typings don't have the `options` parameter yet.

            /** @type {?} */
            nativeElement.focus(options);
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          var _this63 = this;

          this._elementInfo.forEach(
          /**
          * @param {?} _info
          * @param {?} element
          * @return {?}
          */
          function (_info, element) {
            return _this63.stopMonitoring(element);
          });
        }
        /**
         * Access injected document if available or fallback to global document reference
         * @private
         * @return {?}
         */

      }, {
        key: "_getDocument",
        value: function _getDocument() {
          return this._document || document;
        }
        /**
         * Use defaultView of injected document if available or fallback to global window reference
         * @private
         * @return {?}
         */

      }, {
        key: "_getWindow",
        value: function _getWindow() {
          /** @type {?} */
          var doc = this._getDocument();

          return doc.defaultView || window;
        }
        /**
         * @private
         * @param {?} element
         * @param {?} className
         * @param {?} shouldSet
         * @return {?}
         */

      }, {
        key: "_toggleClass",
        value: function _toggleClass(element, className, shouldSet) {
          if (shouldSet) {
            element.classList.add(className);
          } else {
            element.classList.remove(className);
          }
        }
        /**
         * @private
         * @param {?} event
         * @return {?}
         */

      }, {
        key: "_getFocusOrigin",
        value: function _getFocusOrigin(event) {
          // If we couldn't detect a cause for the focus event, it's due to one of three reasons:
          // 1) The window has just regained focus, in which case we want to restore the focused state of
          //    the element from before the window blurred.
          // 2) It was caused by a touch event, in which case we mark the origin as 'touch'.
          // 3) The element was programmatically focused, in which case we should mark the origin as
          //    'program'.
          if (this._origin) {
            return this._origin;
          }

          if (this._windowFocused && this._lastFocusOrigin) {
            return this._lastFocusOrigin;
          } else if (this._wasCausedByTouch(event)) {
            return 'touch';
          } else {
            return 'program';
          }
        }
        /**
         * Sets the focus classes on the element based on the given focus origin.
         * @private
         * @param {?} element The element to update the classes on.
         * @param {?=} origin The focus origin.
         * @return {?}
         */

      }, {
        key: "_setClasses",
        value: function _setClasses(element, origin) {
          this._toggleClass(element, 'cdk-focused', !!origin);

          this._toggleClass(element, 'cdk-touch-focused', origin === 'touch');

          this._toggleClass(element, 'cdk-keyboard-focused', origin === 'keyboard');

          this._toggleClass(element, 'cdk-mouse-focused', origin === 'mouse');

          this._toggleClass(element, 'cdk-program-focused', origin === 'program');
        }
        /**
         * Sets the origin and schedules an async function to clear it at the end of the event queue.
         * If the detection mode is 'eventual', the origin is never cleared.
         * @private
         * @param {?} origin The origin to set.
         * @return {?}
         */

      }, {
        key: "_setOriginForCurrentEventQueue",
        value: function _setOriginForCurrentEventQueue(origin) {
          var _this64 = this;

          this._ngZone.runOutsideAngular(
          /**
          * @return {?}
          */
          function () {
            _this64._origin = origin;

            if (_this64._detectionMode === 0
            /* IMMEDIATE */
            ) {
                // Sometimes the focus origin won't be valid in Firefox because Firefox seems to focus *one*
                // tick after the interaction event fired. To ensure the focus origin is always correct,
                // the focus origin will be determined at the beginning of the next tick.
                _this64._originTimeoutId = setTimeout(
                /**
                * @return {?}
                */
                function () {
                  return _this64._origin = null;
                }, 1);
              }
          });
        }
        /**
         * Checks whether the given focus event was caused by a touchstart event.
         * @private
         * @param {?} event The focus event to check.
         * @return {?} Whether the event was caused by a touch.
         */

      }, {
        key: "_wasCausedByTouch",
        value: function _wasCausedByTouch(event) {
          // Note(mmalerba): This implementation is not quite perfect, there is a small edge case.
          // Consider the following dom structure:
          //
          // <div #parent tabindex="0" cdkFocusClasses>
          //   <div #child (click)="#parent.focus()"></div>
          // </div>
          //
          // If the user touches the #child element and the #parent is programmatically focused as a
          // result, this code will still consider it to have been caused by the touch event and will
          // apply the cdk-touch-focused class rather than the cdk-program-focused class. This is a
          // relatively small edge-case that can be worked around by using
          // focusVia(parentEl, 'program') to focus the parent element.
          //
          // If we decide that we absolutely must handle this case correctly, we can do so by listening
          // for the first focus event after the touchstart, and then the first blur event after that
          // focus event. When that blur event fires we know that whatever follows is not a result of the
          // touchstart.

          /** @type {?} */
          var focusTarget = getTarget(event);
          return this._lastTouchTarget instanceof Node && focusTarget instanceof Node && (focusTarget === this._lastTouchTarget || focusTarget.contains(this._lastTouchTarget));
        }
        /**
         * Handles focus events on a registered element.
         * @private
         * @param {?} event The focus event.
         * @param {?} element The monitored element.
         * @return {?}
         */

      }, {
        key: "_onFocus",
        value: function _onFocus(event, element) {
          // NOTE(mmalerba): We currently set the classes based on the focus origin of the most recent
          // focus event affecting the monitored element. If we want to use the origin of the first event
          // instead we should check for the cdk-focused class here and return if the element already has
          // it. (This only matters for elements that have includesChildren = true).
          // NOTE(mmalerba): We currently set the classes based on the focus origin of the most recent
          // focus event affecting the monitored element. If we want to use the origin of the first event
          // instead we should check for the cdk-focused class here and return if the element already has
          // it. (This only matters for elements that have includesChildren = true).
          // If we are not counting child-element-focus as focused, make sure that the event target is the
          // monitored element itself.

          /** @type {?} */
          var elementInfo = this._elementInfo.get(element);

          if (!elementInfo || !elementInfo.checkChildren && element !== getTarget(event)) {
            return;
          }
          /** @type {?} */


          var origin = this._getFocusOrigin(event);

          this._setClasses(element, origin);

          this._emitOrigin(elementInfo.subject, origin);

          this._lastFocusOrigin = origin;
        }
        /**
         * Handles blur events on a registered element.
         * @param {?} event The blur event.
         * @param {?} element The monitored element.
         * @return {?}
         */

      }, {
        key: "_onBlur",
        value: function _onBlur(event, element) {
          // If we are counting child-element-focus as focused, make sure that we aren't just blurring in
          // order to focus another child of the monitored element.

          /** @type {?} */
          var elementInfo = this._elementInfo.get(element);

          if (!elementInfo || elementInfo.checkChildren && event.relatedTarget instanceof Node && element.contains(event.relatedTarget)) {
            return;
          }

          this._setClasses(element);

          this._emitOrigin(elementInfo.subject, null);
        }
        /**
         * @private
         * @param {?} subject
         * @param {?} origin
         * @return {?}
         */

      }, {
        key: "_emitOrigin",
        value: function _emitOrigin(subject, origin) {
          this._ngZone.run(
          /**
          * @return {?}
          */
          function () {
            return subject.next(origin);
          });
        }
        /**
         * @private
         * @param {?} elementInfo
         * @return {?}
         */

      }, {
        key: "_registerGlobalListeners",
        value: function _registerGlobalListeners(elementInfo) {
          var _this65 = this;

          if (!this._platform.isBrowser) {
            return;
          }
          /** @type {?} */


          var rootNode = elementInfo.rootNode;
          /** @type {?} */

          var rootNodeFocusListeners = this._rootNodeFocusListenerCount.get(rootNode) || 0;

          if (!rootNodeFocusListeners) {
            this._ngZone.runOutsideAngular(
            /**
            * @return {?}
            */
            function () {
              rootNode.addEventListener('focus', _this65._rootNodeFocusAndBlurListener, captureEventListenerOptions);
              rootNode.addEventListener('blur', _this65._rootNodeFocusAndBlurListener, captureEventListenerOptions);
            });
          }

          this._rootNodeFocusListenerCount.set(rootNode, rootNodeFocusListeners + 1); // Register global listeners when first element is monitored.


          if (++this._monitoredElementCount === 1) {
            // Note: we listen to events in the capture phase so we
            // can detect them even if the user stops propagation.
            this._ngZone.runOutsideAngular(
            /**
            * @return {?}
            */
            function () {
              /** @type {?} */
              var document = _this65._getDocument();
              /** @type {?} */


              var window = _this65._getWindow();

              document.addEventListener('keydown', _this65._documentKeydownListener, captureEventListenerOptions);
              document.addEventListener('mousedown', _this65._documentMousedownListener, captureEventListenerOptions);
              document.addEventListener('touchstart', _this65._documentTouchstartListener, captureEventListenerOptions);
              window.addEventListener('focus', _this65._windowFocusListener);
            });
          }
        }
        /**
         * @private
         * @param {?} elementInfo
         * @return {?}
         */

      }, {
        key: "_removeGlobalListeners",
        value: function _removeGlobalListeners(elementInfo) {
          /** @type {?} */
          var rootNode = elementInfo.rootNode;

          if (this._rootNodeFocusListenerCount.has(rootNode)) {
            /** @type {?} */
            var rootNodeFocusListeners =
            /** @type {?} */
            this._rootNodeFocusListenerCount.get(rootNode);

            if (rootNodeFocusListeners > 1) {
              this._rootNodeFocusListenerCount.set(rootNode, rootNodeFocusListeners - 1);
            } else {
              rootNode.removeEventListener('focus', this._rootNodeFocusAndBlurListener, captureEventListenerOptions);
              rootNode.removeEventListener('blur', this._rootNodeFocusAndBlurListener, captureEventListenerOptions);

              this._rootNodeFocusListenerCount["delete"](rootNode);
            }
          } // Unregister global listeners when last element is unmonitored.


          if (! --this._monitoredElementCount) {
            /** @type {?} */
            var _document2 = this._getDocument();
            /** @type {?} */


            var _window = this._getWindow();

            _document2.removeEventListener('keydown', this._documentKeydownListener, captureEventListenerOptions);

            _document2.removeEventListener('mousedown', this._documentMousedownListener, captureEventListenerOptions);

            _document2.removeEventListener('touchstart', this._documentTouchstartListener, captureEventListenerOptions);

            _window.removeEventListener('focus', this._windowFocusListener); // Clear timeouts for all potentially pending timeouts to prevent the leaks.


            clearTimeout(this._windowFocusTimeoutId);
            clearTimeout(this._touchTimeoutId);
            clearTimeout(this._originTimeoutId);
          }
        }
      }]);

      return FocusMonitor;
    }();

    FocusMonitor.ɵfac = function FocusMonitor_Factory(t) {
      return new (t || FocusMonitor)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_6__["Platform"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"], 8), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](FOCUS_MONITOR_DEFAULT_OPTIONS, 8));
    };
    /** @nocollapse */


    FocusMonitor.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
      }, {
        type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_6__["Platform"]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
        }]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [FOCUS_MONITOR_DEFAULT_OPTIONS]
        }]
      }];
    };
    /** @nocollapse */


    FocusMonitor.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: function FocusMonitor_Factory() {
        return new FocusMonitor(Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_6__["Platform"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"], 8), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(FOCUS_MONITOR_DEFAULT_OPTIONS, 8));
      },
      token: FocusMonitor,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](FocusMonitor, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
        }, {
          type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_6__["Platform"]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
          }]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [FOCUS_MONITOR_DEFAULT_OPTIONS]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * Gets the target of an event, accounting for Shadow DOM.
     * @param {?} event
     * @return {?}
     */


    function getTarget(event) {
      // If an event is bound outside the Shadow DOM, the `event.target` will
      // point to the shadow root so we have to use `composedPath` instead.
      return (
        /** @type {?} */
        event.composedPath ? event.composedPath()[0] : event.target
      );
    }
    /**
     * Directive that determines how a particular element was focused (via keyboard, mouse, touch, or
     * programmatically) and adds corresponding classes to the element.
     *
     * There are two variants of this directive:
     * 1) cdkMonitorElementFocus: does not consider an element to be focused if one of its children is
     *    focused.
     * 2) cdkMonitorSubtreeFocus: considers an element focused if it or any of its children are focused.
     */


    var CdkMonitorFocus = /*#__PURE__*/function () {
      /**
       * @param {?} _elementRef
       * @param {?} _focusMonitor
       */
      function CdkMonitorFocus(_elementRef, _focusMonitor) {
        var _this66 = this;

        _classCallCheck(this, CdkMonitorFocus);

        this._elementRef = _elementRef;
        this._focusMonitor = _focusMonitor;
        this.cdkFocusChange = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"]();
        this._monitorSubscription = this._focusMonitor.monitor(this._elementRef, this._elementRef.nativeElement.hasAttribute('cdkMonitorSubtreeFocus')).subscribe(
        /**
        * @param {?} origin
        * @return {?}
        */
        function (origin) {
          return _this66.cdkFocusChange.emit(origin);
        });
      }
      /**
       * @return {?}
       */


      _createClass2(CdkMonitorFocus, [{
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this._focusMonitor.stopMonitoring(this._elementRef);

          this._monitorSubscription.unsubscribe();
        }
      }]);

      return CdkMonitorFocus;
    }();

    CdkMonitorFocus.ɵfac = function CdkMonitorFocus_Factory(t) {
      return new (t || CdkMonitorFocus)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](FocusMonitor));
    };

    CdkMonitorFocus.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineDirective"]({
      type: CdkMonitorFocus,
      selectors: [["", "cdkMonitorElementFocus", ""], ["", "cdkMonitorSubtreeFocus", ""]],
      outputs: {
        cdkFocusChange: "cdkFocusChange"
      }
    });
    /** @nocollapse */

    CdkMonitorFocus.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]
      }, {
        type: FocusMonitor
      }];
    };

    CdkMonitorFocus.propDecorators = {
      cdkFocusChange: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](CdkMonitorFocus, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Directive"],
        args: [{
          selector: '[cdkMonitorElementFocus], [cdkMonitorSubtreeFocus]'
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]
        }, {
          type: FocusMonitor
        }];
      }, {
        cdkFocusChange: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"]
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/high-contrast-mode/high-contrast-mode-detector.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @enum {number} */


    var HighContrastMode = {
      NONE: 0,
      BLACK_ON_WHITE: 1,
      WHITE_ON_BLACK: 2
    };
    /**
     * CSS class applied to the document body when in black-on-white high-contrast mode.
     * @type {?}
     */

    var BLACK_ON_WHITE_CSS_CLASS = 'cdk-high-contrast-black-on-white';
    /**
     * CSS class applied to the document body when in white-on-black high-contrast mode.
     * @type {?}
     */

    var WHITE_ON_BLACK_CSS_CLASS = 'cdk-high-contrast-white-on-black';
    /**
     * CSS class applied to the document body when in high-contrast mode.
     * @type {?}
     */

    var HIGH_CONTRAST_MODE_ACTIVE_CSS_CLASS = 'cdk-high-contrast-active';
    /**
     * Service to determine whether the browser is currently in a high-contrast-mode environment.
     *
     * Microsoft Windows supports an accessibility feature called "High Contrast Mode". This mode
     * changes the appearance of all applications, including web applications, to dramatically increase
     * contrast.
     *
     * IE, Edge, and Firefox currently support this mode. Chrome does not support Windows High Contrast
     * Mode. This service does not detect high-contrast mode as added by the Chrome "High Contrast"
     * browser extension.
     */

    var HighContrastModeDetector = /*#__PURE__*/function () {
      /**
       * @param {?} _platform
       * @param {?} document
       */
      function HighContrastModeDetector(_platform, document) {
        _classCallCheck(this, HighContrastModeDetector);

        this._platform = _platform;
        this._document = document;
      }
      /**
       * Gets the current high-contrast-mode for the page.
       * @return {?}
       */


      _createClass2(HighContrastModeDetector, [{
        key: "getHighContrastMode",
        value: function getHighContrastMode() {
          if (!this._platform.isBrowser) {
            return 0
            /* NONE */
            ;
          } // Create a test element with an arbitrary background-color that is neither black nor
          // white; high-contrast mode will coerce the color to either black or white. Also ensure that
          // appending the test element to the DOM does not affect layout by absolutely positioning it

          /** @type {?} */


          var testElement = this._document.createElement('div');

          testElement.style.backgroundColor = 'rgb(1,2,3)';
          testElement.style.position = 'absolute';

          this._document.body.appendChild(testElement); // Get the computed style for the background color, collapsing spaces to normalize between
          // browsers. Once we get this color, we no longer need the test element. Access the `window`
          // via the document so we can fake it in tests. Note that we have extra null checks, because
          // this logic will likely run during app bootstrap and throwing can break the entire app.

          /** @type {?} */


          var documentWindow = this._document.defaultView || window;
          /** @type {?} */

          var computedStyle = documentWindow && documentWindow.getComputedStyle ? documentWindow.getComputedStyle(testElement) : null;
          /** @type {?} */

          var computedColor = (computedStyle && computedStyle.backgroundColor || '').replace(/ /g, '');

          this._document.body.removeChild(testElement);

          switch (computedColor) {
            case 'rgb(0,0,0)':
              return 2
              /* WHITE_ON_BLACK */
              ;

            case 'rgb(255,255,255)':
              return 1
              /* BLACK_ON_WHITE */
              ;
          }

          return 0
          /* NONE */
          ;
        }
        /**
         * Applies CSS classes indicating high-contrast mode to document body (browser-only).
         * @return {?}
         */

      }, {
        key: "_applyBodyHighContrastModeCssClasses",
        value: function _applyBodyHighContrastModeCssClasses() {
          if (this._platform.isBrowser && this._document.body) {
            /** @type {?} */
            var bodyClasses = this._document.body.classList; // IE11 doesn't support `classList` operations with multiple arguments

            bodyClasses.remove(HIGH_CONTRAST_MODE_ACTIVE_CSS_CLASS);
            bodyClasses.remove(BLACK_ON_WHITE_CSS_CLASS);
            bodyClasses.remove(WHITE_ON_BLACK_CSS_CLASS);
            /** @type {?} */

            var mode = this.getHighContrastMode();

            if (mode === 1
            /* BLACK_ON_WHITE */
            ) {
                bodyClasses.add(HIGH_CONTRAST_MODE_ACTIVE_CSS_CLASS);
                bodyClasses.add(BLACK_ON_WHITE_CSS_CLASS);
              } else if (mode === 2
            /* WHITE_ON_BLACK */
            ) {
                bodyClasses.add(HIGH_CONTRAST_MODE_ACTIVE_CSS_CLASS);
                bodyClasses.add(WHITE_ON_BLACK_CSS_CLASS);
              }
          }
        }
      }]);

      return HighContrastModeDetector;
    }();

    HighContrastModeDetector.ɵfac = function HighContrastModeDetector_Factory(t) {
      return new (t || HighContrastModeDetector)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_6__["Platform"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]));
    };
    /** @nocollapse */


    HighContrastModeDetector.ctorParameters = function () {
      return [{
        type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_6__["Platform"]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
        }]
      }];
    };
    /** @nocollapse */


    HighContrastModeDetector.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: function HighContrastModeDetector_Factory() {
        return new HighContrastModeDetector(Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_6__["Platform"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]));
      },
      token: HighContrastModeDetector,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](HighContrastModeDetector, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [{
          type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_6__["Platform"]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/a11y-module.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var A11yModule =
    /**
     * @param {?} highContrastModeDetector
     */
    function A11yModule(highContrastModeDetector) {
      _classCallCheck(this, A11yModule);

      highContrastModeDetector._applyBodyHighContrastModeCssClasses();
    };

    A11yModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineNgModule"]({
      type: A11yModule
    });
    A11yModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjector"]({
      factory: function A11yModule_Factory(t) {
        return new (t || A11yModule)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](HighContrastModeDetector));
      },
      imports: [[_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_6__["PlatformModule"], _angular_cdk_observers__WEBPACK_IMPORTED_MODULE_7__["ObserversModule"]]]
    });
    /** @nocollapse */

    A11yModule.ctorParameters = function () {
      return [{
        type: HighContrastModeDetector
      }];
    };

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵsetNgModuleScope"](A11yModule, {
        declarations: function declarations() {
          return [CdkAriaLive, CdkTrapFocus, CdkMonitorFocus];
        },
        imports: function imports() {
          return [_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_6__["PlatformModule"], _angular_cdk_observers__WEBPACK_IMPORTED_MODULE_7__["ObserversModule"]];
        },
        exports: function exports() {
          return [CdkAriaLive, CdkTrapFocus, CdkMonitorFocus];
        }
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](A11yModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModule"],
        args: [{
          imports: [_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_6__["PlatformModule"], _angular_cdk_observers__WEBPACK_IMPORTED_MODULE_7__["ObserversModule"]],
          declarations: [CdkAriaLive, CdkTrapFocus, CdkMonitorFocus],
          exports: [CdkAriaLive, CdkTrapFocus, CdkMonitorFocus]
        }]
      }], function () {
        return [{
          type: HighContrastModeDetector
        }];
      }, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/a11y/public-api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=a11y.js.map

    /***/

  },

  /***/
  "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/bidi.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/bidi.js ***!
    \*****************************************************************/

  /*! exports provided: BidiModule, DIR_DOCUMENT, Dir, Directionality, ɵangular_material_src_cdk_bidi_bidi_a */

  /***/
  function node_modulesAngularCdk__ivy_ngcc__Fesm2015BidiJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "BidiModule", function () {
      return BidiModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DIR_DOCUMENT", function () {
      return DIR_DOCUMENT;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Dir", function () {
      return Dir;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Directionality", function () {
      return Directionality;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_material_src_cdk_bidi_bidi_a", function () {
      return DIR_DOCUMENT_FACTORY;
    });
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var _angular_common__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! @angular/common */
    "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/common.js");
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/bidi/dir-document-token.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Injection token used to inject the document into Directionality.
     * This is used so that the value can be faked in tests.
     *
     * We can't use the real document in tests because changing the real `dir` causes geometry-based
     * tests in Safari to fail.
     *
     * We also can't re-provide the DOCUMENT token from platform-brower because the unit tests
     * themselves use things like `querySelector` in test code.
     *
     * This token is defined in a separate file from Directionality as a workaround for
     * https://github.com/angular/angular/issues/22559
     *
     * \@docs-private
     * @type {?}
     */


    var DIR_DOCUMENT = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('cdk-dir-doc', {
      providedIn: 'root',
      factory: DIR_DOCUMENT_FACTORY
    });
    /**
     * \@docs-private
     * @return {?}
     */

    function DIR_DOCUMENT_FACTORY() {
      return Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["inject"])(_angular_common__WEBPACK_IMPORTED_MODULE_1__["DOCUMENT"]);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/bidi/directionality.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * The directionality (LTR / RTL) context for the application (or a subtree of it).
     * Exposes the current direction and a stream of direction changes.
     */


    var Directionality = /*#__PURE__*/function () {
      /**
       * @param {?=} _document
       */
      function Directionality(_document) {
        _classCallCheck(this, Directionality);

        /**
         * The current 'ltr' or 'rtl' value.
         */
        this.value = 'ltr';
        /**
         * Stream that emits whenever the 'ltr' / 'rtl' state changes.
         */

        this.change = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"]();

        if (_document) {
          // TODO: handle 'auto' value -
          // We still need to account for dir="auto".
          // It looks like HTMLElemenet.dir is also "auto" when that's set to the attribute,
          // but getComputedStyle return either "ltr" or "rtl". avoiding getComputedStyle for now

          /** @type {?} */
          var bodyDir = _document.body ? _document.body.dir : null;
          /** @type {?} */

          var htmlDir = _document.documentElement ? _document.documentElement.dir : null;
          /** @type {?} */

          var value = bodyDir || htmlDir;
          this.value = value === 'ltr' || value === 'rtl' ? value : 'ltr';
        }
      }
      /**
       * @return {?}
       */


      _createClass2(Directionality, [{
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this.change.complete();
        }
      }]);

      return Directionality;
    }();

    Directionality.ɵfac = function Directionality_Factory(t) {
      return new (t || Directionality)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](DIR_DOCUMENT, 8));
    };
    /** @nocollapse */


    Directionality.ctorParameters = function () {
      return [{
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [DIR_DOCUMENT]
        }]
      }];
    };
    /** @nocollapse */


    Directionality.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"])({
      factory: function Directionality_Factory() {
        return new Directionality(Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"])(DIR_DOCUMENT, 8));
      },
      token: Directionality,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](Directionality, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [{
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [DIR_DOCUMENT]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/bidi/dir.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Directive to listen for changes of direction of part of the DOM.
     *
     * Provides itself as Directionality such that descendant directives only need to ever inject
     * Directionality to get the closest direction.
     */


    var Dir = /*#__PURE__*/function () {
      function Dir() {
        _classCallCheck(this, Dir);

        /**
         * Normalized direction that accounts for invalid/unsupported values.
         */
        this._dir = 'ltr';
        /**
         * Whether the `value` has been set to its initial value.
         */

        this._isInitialized = false;
        /**
         * Event emitted when the direction changes.
         */

        this.change = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"]();
      }
      /**
       * \@docs-private
       * @return {?}
       */


      _createClass2(Dir, [{
        key: "ngAfterContentInit",

        /**
         * Initialize once default value has been set.
         * @return {?}
         */
        value: function ngAfterContentInit() {
          this._isInitialized = true;
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this.change.complete();
        }
      }, {
        key: "dir",
        get: function get() {
          return this._dir;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          /** @type {?} */
          var old = this._dir;
          /** @type {?} */

          var normalizedValue = value ? value.toLowerCase() : value;
          this._rawDir = value;
          this._dir = normalizedValue === 'ltr' || normalizedValue === 'rtl' ? normalizedValue : 'ltr';

          if (old !== this._dir && this._isInitialized) {
            this.change.emit(this._dir);
          }
        }
        /**
         * Current layout direction of the element.
         * @return {?}
         */

      }, {
        key: "value",
        get: function get() {
          return this.dir;
        }
      }]);

      return Dir;
    }();

    Dir.ɵfac = function Dir_Factory(t) {
      return new (t || Dir)();
    };

    Dir.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: Dir,
      selectors: [["", "dir", ""]],
      hostVars: 1,
      hostBindings: function Dir_HostBindings(rf, ctx) {
        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵattribute"]("dir", ctx._rawDir);
        }
      },
      inputs: {
        dir: "dir"
      },
      outputs: {
        change: "dirChange"
      },
      exportAs: ["dir"],
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([{
        provide: Directionality,
        useExisting: Dir
      }])]
    });
    Dir.propDecorators = {
      change: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Output"],
        args: ['dirChange']
      }],
      dir: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](Dir, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[dir]',
          providers: [{
            provide: Directionality,
            useExisting: Dir
          }],
          host: {
            '[attr.dir]': '_rawDir'
          },
          exportAs: 'dir'
        }]
      }], function () {
        return [];
      }, {
        change: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Output"],
          args: ['dirChange']
        }],
        dir: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/bidi/bidi-module.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var BidiModule = function BidiModule() {
      _classCallCheck(this, BidiModule);
    };

    BidiModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: BidiModule
    });
    BidiModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function BidiModule_Factory(t) {
        return new (t || BidiModule)();
      }
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](BidiModule, {
        declarations: [Dir],
        exports: [Dir]
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](BidiModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{
          exports: [Dir],
          declarations: [Dir]
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/bidi/public-api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=bidi.js.map

    /***/

  },

  /***/
  "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/collections.js":
  /*!************************************************************************!*\
    !*** ./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/collections.js ***!
    \************************************************************************/

  /*! exports provided: ArrayDataSource, DataSource, SelectionModel, UniqueSelectionDispatcher, getMultipleValuesInSingleSelectionError, isDataSource */

  /***/
  function node_modulesAngularCdk__ivy_ngcc__Fesm2015CollectionsJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ArrayDataSource", function () {
      return ArrayDataSource;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DataSource", function () {
      return DataSource;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SelectionModel", function () {
      return SelectionModel;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "UniqueSelectionDispatcher", function () {
      return UniqueSelectionDispatcher;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getMultipleValuesInSingleSelectionError", function () {
      return getMultipleValuesInSingleSelectionError;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "isDataSource", function () {
      return isDataSource;
    });
    /* harmony import */


    var rxjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! rxjs */
    "./node_modules/rxjs/_esm2015/index.js");
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/collections/data-source.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * @abstract
     * @template T
     */


    var DataSource = function DataSource() {
      _classCallCheck(this, DataSource);
    };

    if (false) {}
    /**
     * Checks whether an object is a data source.
     * @param {?} value
     * @return {?}
     */


    function isDataSource(value) {
      // Check if the value is a DataSource by observing if it has a connect function. Cannot
      // be checked as an `instanceof DataSource` since people could create their own sources
      // that match the interface, but don't extend DataSource.
      return value && typeof value.connect === 'function';
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/collections/array-data-source.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * DataSource wrapper for a native array.
     * @template T
     */


    var ArrayDataSource = /*#__PURE__*/function (_DataSource) {
      _inherits(ArrayDataSource, _DataSource);

      var _super7 = _createSuper(ArrayDataSource);

      /**
       * @param {?} _data
       */
      function ArrayDataSource(_data) {
        var _this67;

        _classCallCheck(this, ArrayDataSource);

        _this67 = _super7.call(this);
        _this67._data = _data;
        return _this67;
      }
      /**
       * @return {?}
       */


      _createClass2(ArrayDataSource, [{
        key: "connect",
        value: function connect() {
          return Object(rxjs__WEBPACK_IMPORTED_MODULE_0__["isObservable"])(this._data) ? this._data : Object(rxjs__WEBPACK_IMPORTED_MODULE_0__["of"])(this._data);
        }
        /**
         * @return {?}
         */

      }, {
        key: "disconnect",
        value: function disconnect() {}
      }]);

      return ArrayDataSource;
    }(DataSource);

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/collections/collection-viewer.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Interface for any component that provides a view of some data collection and wants to provide
     * information regarding the view and any changes made.
     * @record
     */


    function CollectionViewer() {}

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/collections/selection-model.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Class to be used to power selecting one or more options from a list.
     * @template T
     */


    var SelectionModel = /*#__PURE__*/function () {
      /**
       * @param {?=} _multiple
       * @param {?=} initiallySelectedValues
       * @param {?=} _emitChanges
       */
      function SelectionModel() {
        var _this68 = this;

        var _multiple = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;

        var initiallySelectedValues = arguments.length > 1 ? arguments[1] : undefined;

        var _emitChanges = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;

        _classCallCheck(this, SelectionModel);

        this._multiple = _multiple;
        this._emitChanges = _emitChanges;
        /**
         * Currently-selected values.
         */

        this._selection = new Set();
        /**
         * Keeps track of the deselected options that haven't been emitted by the change event.
         */

        this._deselectedToEmit = [];
        /**
         * Keeps track of the selected options that haven't been emitted by the change event.
         */

        this._selectedToEmit = [];
        /**
         * Event emitted when the value has changed.
         */

        this.changed = new rxjs__WEBPACK_IMPORTED_MODULE_0__["Subject"]();

        if (initiallySelectedValues && initiallySelectedValues.length) {
          if (_multiple) {
            initiallySelectedValues.forEach(
            /**
            * @param {?} value
            * @return {?}
            */
            function (value) {
              return _this68._markSelected(value);
            });
          } else {
            this._markSelected(initiallySelectedValues[0]);
          } // Clear the array in order to avoid firing the change event for preselected values.


          this._selectedToEmit.length = 0;
        }
      }
      /**
       * Selected values.
       * @return {?}
       */


      _createClass2(SelectionModel, [{
        key: "select",

        /**
         * Selects a value or an array of values.
         * @param {...?} values
         * @return {?}
         */
        value: function select() {
          var _this69 = this;

          for (var _len3 = arguments.length, values = new Array(_len3), _key4 = 0; _key4 < _len3; _key4++) {
            values[_key4] = arguments[_key4];
          }

          this._verifyValueAssignment(values);

          values.forEach(
          /**
          * @param {?} value
          * @return {?}
          */
          function (value) {
            return _this69._markSelected(value);
          });

          this._emitChangeEvent();
        }
        /**
         * Deselects a value or an array of values.
         * @param {...?} values
         * @return {?}
         */

      }, {
        key: "deselect",
        value: function deselect() {
          var _this70 = this;

          for (var _len4 = arguments.length, values = new Array(_len4), _key5 = 0; _key5 < _len4; _key5++) {
            values[_key5] = arguments[_key5];
          }

          this._verifyValueAssignment(values);

          values.forEach(
          /**
          * @param {?} value
          * @return {?}
          */
          function (value) {
            return _this70._unmarkSelected(value);
          });

          this._emitChangeEvent();
        }
        /**
         * Toggles a value between selected and deselected.
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "toggle",
        value: function toggle(value) {
          this.isSelected(value) ? this.deselect(value) : this.select(value);
        }
        /**
         * Clears all of the selected values.
         * @return {?}
         */

      }, {
        key: "clear",
        value: function clear() {
          this._unmarkAll();

          this._emitChangeEvent();
        }
        /**
         * Determines whether a value is selected.
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "isSelected",
        value: function isSelected(value) {
          return this._selection.has(value);
        }
        /**
         * Determines whether the model does not have a value.
         * @return {?}
         */

      }, {
        key: "isEmpty",
        value: function isEmpty() {
          return this._selection.size === 0;
        }
        /**
         * Determines whether the model has a value.
         * @return {?}
         */

      }, {
        key: "hasValue",
        value: function hasValue() {
          return !this.isEmpty();
        }
        /**
         * Sorts the selected values based on a predicate function.
         * @param {?=} predicate
         * @return {?}
         */

      }, {
        key: "sort",
        value: function sort(predicate) {
          if (this._multiple && this.selected) {
            /** @type {?} */
            this._selected.sort(predicate);
          }
        }
        /**
         * Gets whether multiple values can be selected.
         * @return {?}
         */

      }, {
        key: "isMultipleSelection",
        value: function isMultipleSelection() {
          return this._multiple;
        }
        /**
         * Emits a change event and clears the records of selected and deselected values.
         * @private
         * @return {?}
         */

      }, {
        key: "_emitChangeEvent",
        value: function _emitChangeEvent() {
          // Clear the selected values so they can be re-cached.
          this._selected = null;

          if (this._selectedToEmit.length || this._deselectedToEmit.length) {
            this.changed.next({
              source: this,
              added: this._selectedToEmit,
              removed: this._deselectedToEmit
            });
            this._deselectedToEmit = [];
            this._selectedToEmit = [];
          }
        }
        /**
         * Selects a value.
         * @private
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "_markSelected",
        value: function _markSelected(value) {
          if (!this.isSelected(value)) {
            if (!this._multiple) {
              this._unmarkAll();
            }

            this._selection.add(value);

            if (this._emitChanges) {
              this._selectedToEmit.push(value);
            }
          }
        }
        /**
         * Deselects a value.
         * @private
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "_unmarkSelected",
        value: function _unmarkSelected(value) {
          if (this.isSelected(value)) {
            this._selection["delete"](value);

            if (this._emitChanges) {
              this._deselectedToEmit.push(value);
            }
          }
        }
        /**
         * Clears out the selected values.
         * @private
         * @return {?}
         */

      }, {
        key: "_unmarkAll",
        value: function _unmarkAll() {
          var _this71 = this;

          if (!this.isEmpty()) {
            this._selection.forEach(
            /**
            * @param {?} value
            * @return {?}
            */
            function (value) {
              return _this71._unmarkSelected(value);
            });
          }
        }
        /**
         * Verifies the value assignment and throws an error if the specified value array is
         * including multiple values while the selection model is not supporting multiple values.
         * @private
         * @param {?} values
         * @return {?}
         */

      }, {
        key: "_verifyValueAssignment",
        value: function _verifyValueAssignment(values) {
          if (values.length > 1 && !this._multiple) {
            throw getMultipleValuesInSingleSelectionError();
          }
        }
      }, {
        key: "selected",
        get: function get() {
          if (!this._selected) {
            this._selected = Array.from(this._selection.values());
          }

          return this._selected;
        }
      }]);

      return SelectionModel;
    }();

    if (false) {}
    /**
     * Event emitted when the value of a MatSelectionModel has changed.
     * \@docs-private
     * @record
     * @template T
     */


    function SelectionChange() {}

    if (false) {}
    /**
     * Returns an error that reports that multiple values are passed into a selection model
     * with a single value.
     * \@docs-private
     * @return {?}
     */


    function getMultipleValuesInSingleSelectionError() {
      return Error('Cannot pass multiple values into SelectionModel with single-value mode.');
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/collections/unique-selection-dispatcher.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Class to coordinate unique selection based on name.
     * Intended to be consumed as an Angular service.
     * This service is needed because native radio change events are only fired on the item currently
     * being selected, and we still need to uncheck the previous selection.
     *
     * This service does not *store* any IDs and names because they may change at any time, so it is
     * less error-prone if they are simply passed through when the events occur.
     */


    var UniqueSelectionDispatcher = /*#__PURE__*/function () {
      function UniqueSelectionDispatcher() {
        _classCallCheck(this, UniqueSelectionDispatcher);

        this._listeners = [];
      }
      /**
       * Notify other items that selection for the given name has been set.
       * @param {?} id ID of the item.
       * @param {?} name Name of the item.
       * @return {?}
       */


      _createClass2(UniqueSelectionDispatcher, [{
        key: "notify",
        value: function notify(id, name) {
          var _iterator2 = _createForOfIteratorHelper(this._listeners),
              _step2;

          try {
            for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
              var listener = _step2.value;
              listener(id, name);
            }
          } catch (err) {
            _iterator2.e(err);
          } finally {
            _iterator2.f();
          }
        }
        /**
         * Listen for future changes to item selection.
         * @param {?} listener
         * @return {?} Function used to deregister listener
         */

      }, {
        key: "listen",
        value: function listen(listener) {
          var _this72 = this;

          this._listeners.push(listener);

          return (
            /**
            * @return {?}
            */
            function () {
              _this72._listeners = _this72._listeners.filter(
              /**
              * @param {?} registered
              * @return {?}
              */
              function (registered) {
                return listener !== registered;
              });
            }
          );
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this._listeners = [];
        }
      }]);

      return UniqueSelectionDispatcher;
    }();

    UniqueSelectionDispatcher.ɵfac = function UniqueSelectionDispatcher_Factory(t) {
      return new (t || UniqueSelectionDispatcher)();
    };
    /** @nocollapse */


    UniqueSelectionDispatcher.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: function UniqueSelectionDispatcher_Factory() {
        return new UniqueSelectionDispatcher();
      },
      token: UniqueSelectionDispatcher,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](UniqueSelectionDispatcher, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/collections/tree-adapter.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Interface for a class that can flatten hierarchical structured data and re-expand the flattened
     * data back into its original structure. Should be used in conjunction with the cdk-tree.
     * @record
     * @template T
     */


    function TreeDataNodeFlattener() {}

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/collections/public-api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=collections.js.map

    /***/

  },

  /***/
  "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/keycodes.js":
  /*!*********************************************************************!*\
    !*** ./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/keycodes.js ***!
    \*********************************************************************/

  /*! exports provided: A, ALT, APOSTROPHE, AT_SIGN, B, BACKSLASH, BACKSPACE, C, CAPS_LOCK, CLOSE_SQUARE_BRACKET, COMMA, CONTEXT_MENU, CONTROL, D, DASH, DELETE, DOWN_ARROW, E, EIGHT, END, ENTER, EQUALS, ESCAPE, F, F1, F10, F11, F12, F2, F3, F4, F5, F6, F7, F8, F9, FF_EQUALS, FF_MINUS, FF_MUTE, FF_SEMICOLON, FF_VOLUME_DOWN, FF_VOLUME_UP, FIRST_MEDIA, FIVE, FOUR, G, H, HOME, I, INSERT, J, K, L, LAST_MEDIA, LEFT_ARROW, M, MAC_ENTER, MAC_META, MAC_WK_CMD_LEFT, MAC_WK_CMD_RIGHT, META, MUTE, N, NINE, NUMPAD_DIVIDE, NUMPAD_EIGHT, NUMPAD_FIVE, NUMPAD_FOUR, NUMPAD_MINUS, NUMPAD_MULTIPLY, NUMPAD_NINE, NUMPAD_ONE, NUMPAD_PERIOD, NUMPAD_PLUS, NUMPAD_SEVEN, NUMPAD_SIX, NUMPAD_THREE, NUMPAD_TWO, NUMPAD_ZERO, NUM_CENTER, NUM_LOCK, O, ONE, OPEN_SQUARE_BRACKET, P, PAGE_DOWN, PAGE_UP, PAUSE, PLUS_SIGN, PRINT_SCREEN, Q, QUESTION_MARK, R, RIGHT_ARROW, S, SCROLL_LOCK, SEMICOLON, SEVEN, SHIFT, SINGLE_QUOTE, SIX, SLASH, SPACE, T, TAB, THREE, TILDE, TWO, U, UP_ARROW, V, VOLUME_DOWN, VOLUME_UP, W, X, Y, Z, ZERO, hasModifierKey */

  /***/
  function node_modulesAngularCdk__ivy_ngcc__Fesm2015KeycodesJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "A", function () {
      return A;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ALT", function () {
      return ALT;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "APOSTROPHE", function () {
      return APOSTROPHE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AT_SIGN", function () {
      return AT_SIGN;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "B", function () {
      return B;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "BACKSLASH", function () {
      return BACKSLASH;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "BACKSPACE", function () {
      return BACKSPACE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "C", function () {
      return C;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CAPS_LOCK", function () {
      return CAPS_LOCK;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CLOSE_SQUARE_BRACKET", function () {
      return CLOSE_SQUARE_BRACKET;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "COMMA", function () {
      return COMMA;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CONTEXT_MENU", function () {
      return CONTEXT_MENU;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CONTROL", function () {
      return CONTROL;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "D", function () {
      return D;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DASH", function () {
      return DASH;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DELETE", function () {
      return DELETE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DOWN_ARROW", function () {
      return DOWN_ARROW;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "E", function () {
      return E;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "EIGHT", function () {
      return EIGHT;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "END", function () {
      return END;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ENTER", function () {
      return ENTER;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "EQUALS", function () {
      return EQUALS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ESCAPE", function () {
      return ESCAPE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "F", function () {
      return F;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "F1", function () {
      return F1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "F10", function () {
      return F10;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "F11", function () {
      return F11;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "F12", function () {
      return F12;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "F2", function () {
      return F2;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "F3", function () {
      return F3;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "F4", function () {
      return F4;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "F5", function () {
      return F5;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "F6", function () {
      return F6;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "F7", function () {
      return F7;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "F8", function () {
      return F8;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "F9", function () {
      return F9;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FF_EQUALS", function () {
      return FF_EQUALS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FF_MINUS", function () {
      return FF_MINUS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FF_MUTE", function () {
      return FF_MUTE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FF_SEMICOLON", function () {
      return FF_SEMICOLON;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FF_VOLUME_DOWN", function () {
      return FF_VOLUME_DOWN;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FF_VOLUME_UP", function () {
      return FF_VOLUME_UP;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FIRST_MEDIA", function () {
      return FIRST_MEDIA;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FIVE", function () {
      return FIVE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FOUR", function () {
      return FOUR;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "G", function () {
      return G;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "H", function () {
      return H;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HOME", function () {
      return HOME;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "I", function () {
      return I;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "INSERT", function () {
      return INSERT;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "J", function () {
      return J;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "K", function () {
      return K;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "L", function () {
      return L;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "LAST_MEDIA", function () {
      return LAST_MEDIA;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "LEFT_ARROW", function () {
      return LEFT_ARROW;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "M", function () {
      return M;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MAC_ENTER", function () {
      return MAC_ENTER;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MAC_META", function () {
      return MAC_META;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MAC_WK_CMD_LEFT", function () {
      return MAC_WK_CMD_LEFT;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MAC_WK_CMD_RIGHT", function () {
      return MAC_WK_CMD_RIGHT;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "META", function () {
      return META;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MUTE", function () {
      return MUTE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "N", function () {
      return N;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NINE", function () {
      return NINE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NUMPAD_DIVIDE", function () {
      return NUMPAD_DIVIDE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NUMPAD_EIGHT", function () {
      return NUMPAD_EIGHT;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NUMPAD_FIVE", function () {
      return NUMPAD_FIVE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NUMPAD_FOUR", function () {
      return NUMPAD_FOUR;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NUMPAD_MINUS", function () {
      return NUMPAD_MINUS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NUMPAD_MULTIPLY", function () {
      return NUMPAD_MULTIPLY;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NUMPAD_NINE", function () {
      return NUMPAD_NINE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NUMPAD_ONE", function () {
      return NUMPAD_ONE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NUMPAD_PERIOD", function () {
      return NUMPAD_PERIOD;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NUMPAD_PLUS", function () {
      return NUMPAD_PLUS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NUMPAD_SEVEN", function () {
      return NUMPAD_SEVEN;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NUMPAD_SIX", function () {
      return NUMPAD_SIX;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NUMPAD_THREE", function () {
      return NUMPAD_THREE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NUMPAD_TWO", function () {
      return NUMPAD_TWO;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NUMPAD_ZERO", function () {
      return NUMPAD_ZERO;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NUM_CENTER", function () {
      return NUM_CENTER;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NUM_LOCK", function () {
      return NUM_LOCK;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "O", function () {
      return O;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ONE", function () {
      return ONE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "OPEN_SQUARE_BRACKET", function () {
      return OPEN_SQUARE_BRACKET;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "P", function () {
      return P;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "PAGE_DOWN", function () {
      return PAGE_DOWN;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "PAGE_UP", function () {
      return PAGE_UP;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "PAUSE", function () {
      return PAUSE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "PLUS_SIGN", function () {
      return PLUS_SIGN;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "PRINT_SCREEN", function () {
      return PRINT_SCREEN;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Q", function () {
      return Q;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "QUESTION_MARK", function () {
      return QUESTION_MARK;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "R", function () {
      return R;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RIGHT_ARROW", function () {
      return RIGHT_ARROW;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "S", function () {
      return S;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SCROLL_LOCK", function () {
      return SCROLL_LOCK;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SEMICOLON", function () {
      return SEMICOLON;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SEVEN", function () {
      return SEVEN;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SHIFT", function () {
      return SHIFT;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SINGLE_QUOTE", function () {
      return SINGLE_QUOTE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SIX", function () {
      return SIX;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SLASH", function () {
      return SLASH;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SPACE", function () {
      return SPACE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "T", function () {
      return T;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "TAB", function () {
      return TAB;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "THREE", function () {
      return THREE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "TILDE", function () {
      return TILDE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "TWO", function () {
      return TWO;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "U", function () {
      return U;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "UP_ARROW", function () {
      return UP_ARROW;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "V", function () {
      return V;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "VOLUME_DOWN", function () {
      return VOLUME_DOWN;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "VOLUME_UP", function () {
      return VOLUME_UP;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "W", function () {
      return W;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "X", function () {
      return X;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Y", function () {
      return Y;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Z", function () {
      return Z;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ZERO", function () {
      return ZERO;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "hasModifierKey", function () {
      return hasModifierKey;
    });
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/keycodes/keycodes.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** @type {?} */


    var MAC_ENTER = 3;
    /** @type {?} */

    var BACKSPACE = 8;
    /** @type {?} */

    var TAB = 9;
    /** @type {?} */

    var NUM_CENTER = 12;
    /** @type {?} */

    var ENTER = 13;
    /** @type {?} */

    var SHIFT = 16;
    /** @type {?} */

    var CONTROL = 17;
    /** @type {?} */

    var ALT = 18;
    /** @type {?} */

    var PAUSE = 19;
    /** @type {?} */

    var CAPS_LOCK = 20;
    /** @type {?} */

    var ESCAPE = 27;
    /** @type {?} */

    var SPACE = 32;
    /** @type {?} */

    var PAGE_UP = 33;
    /** @type {?} */

    var PAGE_DOWN = 34;
    /** @type {?} */

    var END = 35;
    /** @type {?} */

    var HOME = 36;
    /** @type {?} */

    var LEFT_ARROW = 37;
    /** @type {?} */

    var UP_ARROW = 38;
    /** @type {?} */

    var RIGHT_ARROW = 39;
    /** @type {?} */

    var DOWN_ARROW = 40;
    /** @type {?} */

    var PLUS_SIGN = 43;
    /** @type {?} */

    var PRINT_SCREEN = 44;
    /** @type {?} */

    var INSERT = 45;
    /** @type {?} */

    var DELETE = 46;
    /** @type {?} */

    var ZERO = 48;
    /** @type {?} */

    var ONE = 49;
    /** @type {?} */

    var TWO = 50;
    /** @type {?} */

    var THREE = 51;
    /** @type {?} */

    var FOUR = 52;
    /** @type {?} */

    var FIVE = 53;
    /** @type {?} */

    var SIX = 54;
    /** @type {?} */

    var SEVEN = 55;
    /** @type {?} */

    var EIGHT = 56;
    /** @type {?} */

    var NINE = 57;
    /** @type {?} */

    var FF_SEMICOLON = 59; // Firefox (Gecko) fires this for semicolon instead of 186

    /** @type {?} */

    var FF_EQUALS = 61; // Firefox (Gecko) fires this for equals instead of 187

    /** @type {?} */

    var QUESTION_MARK = 63;
    /** @type {?} */

    var AT_SIGN = 64;
    /** @type {?} */

    var A = 65;
    /** @type {?} */

    var B = 66;
    /** @type {?} */

    var C = 67;
    /** @type {?} */

    var D = 68;
    /** @type {?} */

    var E = 69;
    /** @type {?} */

    var F = 70;
    /** @type {?} */

    var G = 71;
    /** @type {?} */

    var H = 72;
    /** @type {?} */

    var I = 73;
    /** @type {?} */

    var J = 74;
    /** @type {?} */

    var K = 75;
    /** @type {?} */

    var L = 76;
    /** @type {?} */

    var M = 77;
    /** @type {?} */

    var N = 78;
    /** @type {?} */

    var O = 79;
    /** @type {?} */

    var P = 80;
    /** @type {?} */

    var Q = 81;
    /** @type {?} */

    var R = 82;
    /** @type {?} */

    var S = 83;
    /** @type {?} */

    var T = 84;
    /** @type {?} */

    var U = 85;
    /** @type {?} */

    var V = 86;
    /** @type {?} */

    var W = 87;
    /** @type {?} */

    var X = 88;
    /** @type {?} */

    var Y = 89;
    /** @type {?} */

    var Z = 90;
    /** @type {?} */

    var META = 91; // WIN_KEY_LEFT

    /** @type {?} */

    var MAC_WK_CMD_LEFT = 91;
    /** @type {?} */

    var MAC_WK_CMD_RIGHT = 93;
    /** @type {?} */

    var CONTEXT_MENU = 93;
    /** @type {?} */

    var NUMPAD_ZERO = 96;
    /** @type {?} */

    var NUMPAD_ONE = 97;
    /** @type {?} */

    var NUMPAD_TWO = 98;
    /** @type {?} */

    var NUMPAD_THREE = 99;
    /** @type {?} */

    var NUMPAD_FOUR = 100;
    /** @type {?} */

    var NUMPAD_FIVE = 101;
    /** @type {?} */

    var NUMPAD_SIX = 102;
    /** @type {?} */

    var NUMPAD_SEVEN = 103;
    /** @type {?} */

    var NUMPAD_EIGHT = 104;
    /** @type {?} */

    var NUMPAD_NINE = 105;
    /** @type {?} */

    var NUMPAD_MULTIPLY = 106;
    /** @type {?} */

    var NUMPAD_PLUS = 107;
    /** @type {?} */

    var NUMPAD_MINUS = 109;
    /** @type {?} */

    var NUMPAD_PERIOD = 110;
    /** @type {?} */

    var NUMPAD_DIVIDE = 111;
    /** @type {?} */

    var F1 = 112;
    /** @type {?} */

    var F2 = 113;
    /** @type {?} */

    var F3 = 114;
    /** @type {?} */

    var F4 = 115;
    /** @type {?} */

    var F5 = 116;
    /** @type {?} */

    var F6 = 117;
    /** @type {?} */

    var F7 = 118;
    /** @type {?} */

    var F8 = 119;
    /** @type {?} */

    var F9 = 120;
    /** @type {?} */

    var F10 = 121;
    /** @type {?} */

    var F11 = 122;
    /** @type {?} */

    var F12 = 123;
    /** @type {?} */

    var NUM_LOCK = 144;
    /** @type {?} */

    var SCROLL_LOCK = 145;
    /** @type {?} */

    var FIRST_MEDIA = 166;
    /** @type {?} */

    var FF_MINUS = 173;
    /** @type {?} */

    var MUTE = 173; // Firefox (Gecko) fires 181 for MUTE

    /** @type {?} */

    var VOLUME_DOWN = 174; // Firefox (Gecko) fires 182 for VOLUME_DOWN

    /** @type {?} */

    var VOLUME_UP = 175; // Firefox (Gecko) fires 183 for VOLUME_UP

    /** @type {?} */

    var FF_MUTE = 181;
    /** @type {?} */

    var FF_VOLUME_DOWN = 182;
    /** @type {?} */

    var LAST_MEDIA = 183;
    /** @type {?} */

    var FF_VOLUME_UP = 183;
    /** @type {?} */

    var SEMICOLON = 186; // Firefox (Gecko) fires 59 for SEMICOLON

    /** @type {?} */

    var EQUALS = 187; // Firefox (Gecko) fires 61 for EQUALS

    /** @type {?} */

    var COMMA = 188;
    /** @type {?} */

    var DASH = 189; // Firefox (Gecko) fires 173 for DASH/MINUS

    /** @type {?} */

    var SLASH = 191;
    /** @type {?} */

    var APOSTROPHE = 192;
    /** @type {?} */

    var TILDE = 192;
    /** @type {?} */

    var OPEN_SQUARE_BRACKET = 219;
    /** @type {?} */

    var BACKSLASH = 220;
    /** @type {?} */

    var CLOSE_SQUARE_BRACKET = 221;
    /** @type {?} */

    var SINGLE_QUOTE = 222;
    /** @type {?} */

    var MAC_META = 224;
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/keycodes/modifiers.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Checks whether a modifier key is pressed.
     * @param {?} event Event to be checked.
     * @param {...?} modifiers
     * @return {?}
     */

    function hasModifierKey(event) {
      for (var _len5 = arguments.length, modifiers = new Array(_len5 > 1 ? _len5 - 1 : 0), _key6 = 1; _key6 < _len5; _key6++) {
        modifiers[_key6 - 1] = arguments[_key6];
      }

      if (modifiers.length) {
        return modifiers.some(
        /**
        * @param {?} modifier
        * @return {?}
        */
        function (modifier) {
          return event[modifier];
        });
      }

      return event.altKey || event.shiftKey || event.ctrlKey || event.metaKey;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/keycodes/public-api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=keycodes.js.map

    /***/

  },

  /***/
  "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/layout.js":
  /*!*******************************************************************!*\
    !*** ./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/layout.js ***!
    \*******************************************************************/

  /*! exports provided: BreakpointObserver, Breakpoints, LayoutModule, MediaMatcher */

  /***/
  function node_modulesAngularCdk__ivy_ngcc__Fesm2015LayoutJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "BreakpointObserver", function () {
      return BreakpointObserver;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Breakpoints", function () {
      return Breakpoints;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "LayoutModule", function () {
      return LayoutModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MediaMatcher", function () {
      return MediaMatcher;
    });
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! @angular/cdk/platform */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/platform.js");
    /* harmony import */


    var rxjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! rxjs */
    "./node_modules/rxjs/_esm2015/index.js");
    /* harmony import */


    var rxjs_operators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! rxjs/operators */
    "./node_modules/rxjs/_esm2015/operators/index.js");
    /* harmony import */


    var _angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! @angular/cdk/coercion */
    "./node_modules/@angular/cdk/fesm2015/coercion.js");
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/layout/layout-module.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var LayoutModule = function LayoutModule() {
      _classCallCheck(this, LayoutModule);
    };

    LayoutModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: LayoutModule
    });
    LayoutModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function LayoutModule_Factory(t) {
        return new (t || LayoutModule)();
      }
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](LayoutModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{}]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/layout/media-matcher.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Global registry for all dynamically-created, injected media queries.
     * @type {?}
     */


    var mediaQueriesForWebkitCompatibility = new Set();
    /**
     * Style tag that holds all of the dynamically-created media queries.
     * @type {?}
     */

    var mediaQueryStyleNode;
    /**
     * A utility for calling matchMedia queries.
     */

    var MediaMatcher = /*#__PURE__*/function () {
      /**
       * @param {?} _platform
       */
      function MediaMatcher(_platform) {
        _classCallCheck(this, MediaMatcher);

        this._platform = _platform;
        this._matchMedia = this._platform.isBrowser && window.matchMedia ? // matchMedia is bound to the window scope intentionally as it is an illegal invocation to
        // call it from a different scope.
        window.matchMedia.bind(window) : noopMatchMedia;
      }
      /**
       * Evaluates the given media query and returns the native MediaQueryList from which results
       * can be retrieved.
       * Confirms the layout engine will trigger for the selector query provided and returns the
       * MediaQueryList for the query provided.
       * @param {?} query
       * @return {?}
       */


      _createClass2(MediaMatcher, [{
        key: "matchMedia",
        value: function matchMedia(query) {
          if (this._platform.WEBKIT) {
            createEmptyStyleRule(query);
          }

          return this._matchMedia(query);
        }
      }]);

      return MediaMatcher;
    }();

    MediaMatcher.ɵfac = function MediaMatcher_Factory(t) {
      return new (t || MediaMatcher)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_1__["Platform"]));
    };
    /** @nocollapse */


    MediaMatcher.ctorParameters = function () {
      return [{
        type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_1__["Platform"]
      }];
    };
    /** @nocollapse */


    MediaMatcher.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"])({
      factory: function MediaMatcher_Factory() {
        return new MediaMatcher(Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"])(_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_1__["Platform"]));
      },
      token: MediaMatcher,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MediaMatcher, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [{
          type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_1__["Platform"]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * For Webkit engines that only trigger the MediaQueryListListener when
     * there is at least one CSS selector for the respective media query.
     * @param {?} query
     * @return {?}
     */


    function createEmptyStyleRule(query) {
      if (mediaQueriesForWebkitCompatibility.has(query)) {
        return;
      }

      try {
        if (!mediaQueryStyleNode) {
          mediaQueryStyleNode = document.createElement('style');
          mediaQueryStyleNode.setAttribute('type', 'text/css');

          /** @type {?} */
          document.head.appendChild(mediaQueryStyleNode);
        }

        if (mediaQueryStyleNode.sheet) {
          /** @type {?} */
          mediaQueryStyleNode.sheet.insertRule("@media ".concat(query, " {.fx-query-test{ }}"), 0);
          mediaQueriesForWebkitCompatibility.add(query);
        }
      } catch (e) {
        console.error(e);
      }
    }
    /**
     * No-op matchMedia replacement for non-browser platforms.
     * @param {?} query
     * @return {?}
     */


    function noopMatchMedia(query) {
      // Use `as any` here to avoid adding additional necessary properties for
      // the noop matcher.
      return (
        /** @type {?} */
        {
          matches: query === 'all' || query === '',
          media: query,
          addListener:
          /**
          * @return {?}
          */
          function addListener() {},
          removeListener:
          /**
          * @return {?}
          */
          function removeListener() {}
        }
      );
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/layout/breakpoints-observer.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * The current state of a layout breakpoint.
     * @record
     */


    function BreakpointState() {}

    if (false) {}
    /**
     * The current state of a layout breakpoint.
     * @record
     */


    function InternalBreakpointState() {}

    if (false) {}
    /**
     * @record
     */


    function Query() {}

    if (false) {}
    /**
     * Utility for checking the matching state of \@media queries.
     */


    var BreakpointObserver = /*#__PURE__*/function () {
      /**
       * @param {?} _mediaMatcher
       * @param {?} _zone
       */
      function BreakpointObserver(_mediaMatcher, _zone) {
        _classCallCheck(this, BreakpointObserver);

        this._mediaMatcher = _mediaMatcher;
        this._zone = _zone;
        /**
         * A map of all media queries currently being listened for.
         */

        this._queries = new Map();
        /**
         * A subject for all other observables to takeUntil based on.
         */

        this._destroySubject = new rxjs__WEBPACK_IMPORTED_MODULE_2__["Subject"]();
      }
      /**
       * Completes the active subject, signalling to all other observables to complete.
       * @return {?}
       */


      _createClass2(BreakpointObserver, [{
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this._destroySubject.next();

          this._destroySubject.complete();
        }
        /**
         * Whether one or more media queries match the current viewport size.
         * @param {?} value One or more media queries to check.
         * @return {?} Whether any of the media queries match.
         */

      }, {
        key: "isMatched",
        value: function isMatched(value) {
          var _this73 = this;

          /** @type {?} */
          var queries = splitQueries(Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_4__["coerceArray"])(value));
          return queries.some(
          /**
          * @param {?} mediaQuery
          * @return {?}
          */
          function (mediaQuery) {
            return _this73._registerQuery(mediaQuery).mql.matches;
          });
        }
        /**
         * Gets an observable of results for the given queries that will emit new results for any changes
         * in matching of the given queries.
         * @param {?} value One or more media queries to check.
         * @return {?} A stream of matches for the given queries.
         */

      }, {
        key: "observe",
        value: function observe(value) {
          var _this74 = this;

          /** @type {?} */
          var queries = splitQueries(Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_4__["coerceArray"])(value));
          /** @type {?} */

          var observables = queries.map(
          /**
          * @param {?} query
          * @return {?}
          */
          function (query) {
            return _this74._registerQuery(query).observable;
          });
          /** @type {?} */

          var stateObservable = Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["combineLatest"])(observables); // Emit the first state immediately, and then debounce the subsequent emissions.

          stateObservable = Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["concat"])(stateObservable.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["take"])(1)), stateObservable.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["skip"])(1), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["debounceTime"])(0)));
          return stateObservable.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
          /**
          * @param {?} breakpointStates
          * @return {?}
          */
          function (breakpointStates) {
            /** @type {?} */
            var response = {
              matches: false,
              breakpoints: {}
            };
            breakpointStates.forEach(
            /**
            * @param {?} state
            * @return {?}
            */
            function (state) {
              response.matches = response.matches || state.matches;
              response.breakpoints[state.query] = state.matches;
            });
            return response;
          }));
        }
        /**
         * Registers a specific query to be listened for.
         * @private
         * @param {?} query
         * @return {?}
         */

      }, {
        key: "_registerQuery",
        value: function _registerQuery(query) {
          var _this75 = this;

          // Only set up a new MediaQueryList if it is not already being listened for.
          if (this._queries.has(query)) {
            return (
              /** @type {?} */
              this._queries.get(query)
            );
          }
          /** @type {?} */


          var mql = this._mediaMatcher.matchMedia(query); // Create callback for match changes and add it is as a listener.

          /** @type {?} */


          var queryObservable = new rxjs__WEBPACK_IMPORTED_MODULE_2__["Observable"](
          /**
          * @param {?} observer
          * @return {?}
          */
          function (observer) {
            // Listener callback methods are wrapped to be placed back in ngZone. Callbacks must be placed
            // back into the zone because matchMedia is only included in Zone.js by loading the
            // webapis-media-query.js file alongside the zone.js file.  Additionally, some browsers do not
            // have MediaQueryList inherit from EventTarget, which causes inconsistencies in how Zone.js
            // patches it.

            /** @type {?} */
            var handler =
            /**
            * @param {?} e
            * @return {?}
            */
            function handler(e) {
              return _this75._zone.run(
              /**
              * @return {?}
              */
              function () {
                return observer.next(e);
              });
            };

            mql.addListener(handler);
            return (
              /**
              * @return {?}
              */
              function () {
                mql.removeListener(handler);
              }
            );
          }).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["startWith"])(mql), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
          /**
          * @param {?} nextMql
          * @return {?}
          */
          function (nextMql) {
            return {
              query: query,
              matches: nextMql.matches
            };
          }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["takeUntil"])(this._destroySubject)); // Add the MediaQueryList to the set of queries.

          /** @type {?} */

          var output = {
            observable: queryObservable,
            mql: mql
          };

          this._queries.set(query, output);

          return output;
        }
      }]);

      return BreakpointObserver;
    }();

    BreakpointObserver.ɵfac = function BreakpointObserver_Factory(t) {
      return new (t || BreakpointObserver)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](MediaMatcher), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["NgZone"]));
    };
    /** @nocollapse */


    BreakpointObserver.ctorParameters = function () {
      return [{
        type: MediaMatcher
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgZone"]
      }];
    };
    /** @nocollapse */


    BreakpointObserver.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"])({
      factory: function BreakpointObserver_Factory() {
        return new BreakpointObserver(Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"])(MediaMatcher), Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"])(_angular_core__WEBPACK_IMPORTED_MODULE_0__["NgZone"]));
      },
      token: BreakpointObserver,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](BreakpointObserver, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [{
          type: MediaMatcher
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgZone"]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * Split each query string into separate query strings if two queries are provided as comma
     * separated.
     * @param {?} queries
     * @return {?}
     */


    function splitQueries(queries) {
      return queries.map(
      /**
      * @param {?} query
      * @return {?}
      */
      function (query) {
        return query.split(',');
      }).reduce(
      /**
      * @param {?} a1
      * @param {?} a2
      * @return {?}
      */
      function (a1, a2) {
        return a1.concat(a2);
      }).map(
      /**
      * @param {?} query
      * @return {?}
      */
      function (query) {
        return query.trim();
      });
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/layout/breakpoints.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */
    // PascalCase is being used as Breakpoints is used like an enum.
    // tslint:disable-next-line:variable-name

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     * @type {?}
     */


    var Breakpoints = {
      XSmall: '(max-width: 599.99px)',
      Small: '(min-width: 600px) and (max-width: 959.99px)',
      Medium: '(min-width: 960px) and (max-width: 1279.99px)',
      Large: '(min-width: 1280px) and (max-width: 1919.99px)',
      XLarge: '(min-width: 1920px)',
      Handset: '(max-width: 599.99px) and (orientation: portrait), ' + '(max-width: 959.99px) and (orientation: landscape)',
      Tablet: '(min-width: 600px) and (max-width: 839.99px) and (orientation: portrait), ' + '(min-width: 960px) and (max-width: 1279.99px) and (orientation: landscape)',
      Web: '(min-width: 840px) and (orientation: portrait), ' + '(min-width: 1280px) and (orientation: landscape)',
      HandsetPortrait: '(max-width: 599.99px) and (orientation: portrait)',
      TabletPortrait: '(min-width: 600px) and (max-width: 839.99px) and (orientation: portrait)',
      WebPortrait: '(min-width: 840px) and (orientation: portrait)',
      HandsetLandscape: '(max-width: 959.99px) and (orientation: landscape)',
      TabletLandscape: '(min-width: 960px) and (max-width: 1279.99px) and (orientation: landscape)',
      WebLandscape: '(min-width: 1280px) and (orientation: landscape)'
    };
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/layout/public-api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=layout.js.map

    /***/
  },

  /***/
  "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/observers.js":
  /*!**********************************************************************!*\
    !*** ./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/observers.js ***!
    \**********************************************************************/

  /*! exports provided: CdkObserveContent, ContentObserver, MutationObserverFactory, ObserversModule */

  /***/
  function node_modulesAngularCdk__ivy_ngcc__Fesm2015ObserversJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CdkObserveContent", function () {
      return CdkObserveContent;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ContentObserver", function () {
      return ContentObserver;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MutationObserverFactory", function () {
      return MutationObserverFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ObserversModule", function () {
      return ObserversModule;
    });
    /* harmony import */


    var _angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/cdk/coercion */
    "./node_modules/@angular/cdk/fesm2015/coercion.js");
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var rxjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! rxjs */
    "./node_modules/rxjs/_esm2015/index.js");
    /* harmony import */


    var rxjs_operators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! rxjs/operators */
    "./node_modules/rxjs/_esm2015/operators/index.js");
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/observers/observe-content.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Factory that creates a new MutationObserver and allows us to stub it out in unit tests.
     * \@docs-private
     */


    var MutationObserverFactory = /*#__PURE__*/function () {
      function MutationObserverFactory() {
        _classCallCheck(this, MutationObserverFactory);
      }

      _createClass2(MutationObserverFactory, [{
        key: "create",

        /**
         * @param {?} callback
         * @return {?}
         */
        value: function create(callback) {
          return typeof MutationObserver === 'undefined' ? null : new MutationObserver(callback);
        }
      }]);

      return MutationObserverFactory;
    }();

    MutationObserverFactory.ɵfac = function MutationObserverFactory_Factory(t) {
      return new (t || MutationObserverFactory)();
    };
    /** @nocollapse */


    MutationObserverFactory.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: function MutationObserverFactory_Factory() {
        return new MutationObserverFactory();
      },
      token: MutationObserverFactory,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](MutationObserverFactory, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], null, null);
    })();
    /**
     * An injectable service that allows watching elements for changes to their content.
     */


    var ContentObserver = /*#__PURE__*/function () {
      /**
       * @param {?} _mutationObserverFactory
       */
      function ContentObserver(_mutationObserverFactory) {
        _classCallCheck(this, ContentObserver);

        this._mutationObserverFactory = _mutationObserverFactory;
        /**
         * Keeps track of the existing MutationObservers so they can be reused.
         */

        this._observedElements = new Map();
      }
      /**
       * @return {?}
       */


      _createClass2(ContentObserver, [{
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          var _this76 = this;

          this._observedElements.forEach(
          /**
          * @param {?} _
          * @param {?} element
          * @return {?}
          */
          function (_, element) {
            return _this76._cleanupObserver(element);
          });
        }
        /**
         * @param {?} elementOrRef
         * @return {?}
         */

      }, {
        key: "observe",
        value: function observe(elementOrRef) {
          var _this77 = this;

          /** @type {?} */
          var element = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_0__["coerceElement"])(elementOrRef);
          return new rxjs__WEBPACK_IMPORTED_MODULE_2__["Observable"](
          /**
          * @param {?} observer
          * @return {?}
          */
          function (observer) {
            /** @type {?} */
            var stream = _this77._observeElement(element);
            /** @type {?} */


            var subscription = stream.subscribe(observer);
            return (
              /**
              * @return {?}
              */
              function () {
                subscription.unsubscribe();

                _this77._unobserveElement(element);
              }
            );
          });
        }
        /**
         * Observes the given element by using the existing MutationObserver if available, or creating a
         * new one if not.
         * @private
         * @param {?} element
         * @return {?}
         */

      }, {
        key: "_observeElement",
        value: function _observeElement(element) {
          if (!this._observedElements.has(element)) {
            /** @type {?} */
            var stream = new rxjs__WEBPACK_IMPORTED_MODULE_2__["Subject"]();
            /** @type {?} */

            var observer = this._mutationObserverFactory.create(
            /**
            * @param {?} mutations
            * @return {?}
            */
            function (mutations) {
              return stream.next(mutations);
            });

            if (observer) {
              observer.observe(element, {
                characterData: true,
                childList: true,
                subtree: true
              });
            }

            this._observedElements.set(element, {
              observer: observer,
              stream: stream,
              count: 1
            });
          } else {
            /** @type {?} */this._observedElements.get(element).count++;
          }

          return (
            /** @type {?} */
            this._observedElements.get(element).stream
          );
        }
        /**
         * Un-observes the given element and cleans up the underlying MutationObserver if nobody else is
         * observing this element.
         * @private
         * @param {?} element
         * @return {?}
         */

      }, {
        key: "_unobserveElement",
        value: function _unobserveElement(element) {
          if (this._observedElements.has(element)) {
            /** @type {?} */this._observedElements.get(element).count--;

            if (!
            /** @type {?} */
            this._observedElements.get(element).count) {
              this._cleanupObserver(element);
            }
          }
        }
        /**
         * Clean up the underlying MutationObserver for the specified element.
         * @private
         * @param {?} element
         * @return {?}
         */

      }, {
        key: "_cleanupObserver",
        value: function _cleanupObserver(element) {
          if (this._observedElements.has(element)) {
            var _this$_observedElemen =
            /** @type {?} */
            this._observedElements.get(element),
                observer = _this$_observedElemen.observer,
                stream = _this$_observedElemen.stream;

            if (observer) {
              observer.disconnect();
            }

            stream.complete();

            this._observedElements["delete"](element);
          }
        }
      }]);

      return ContentObserver;
    }();

    ContentObserver.ɵfac = function ContentObserver_Factory(t) {
      return new (t || ContentObserver)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](MutationObserverFactory));
    };
    /** @nocollapse */


    ContentObserver.ctorParameters = function () {
      return [{
        type: MutationObserverFactory
      }];
    };
    /** @nocollapse */


    ContentObserver.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: function ContentObserver_Factory() {
        return new ContentObserver(Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(MutationObserverFactory));
      },
      token: ContentObserver,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](ContentObserver, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [{
          type: MutationObserverFactory
        }];
      }, null);
    })();

    if (false) {}
    /**
     * Directive that triggers a callback whenever the content of
     * its associated element has changed.
     */


    var CdkObserveContent = /*#__PURE__*/function () {
      /**
       * @param {?} _contentObserver
       * @param {?} _elementRef
       * @param {?} _ngZone
       */
      function CdkObserveContent(_contentObserver, _elementRef, _ngZone) {
        _classCallCheck(this, CdkObserveContent);

        this._contentObserver = _contentObserver;
        this._elementRef = _elementRef;
        this._ngZone = _ngZone;
        /**
         * Event emitted for each change in the element's content.
         */

        this.event = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"]();
        this._disabled = false;
        this._currentSubscription = null;
      }
      /**
       * Whether observing content is disabled. This option can be used
       * to disconnect the underlying MutationObserver until it is needed.
       * @return {?}
       */


      _createClass2(CdkObserveContent, [{
        key: "ngAfterContentInit",

        /**
         * @return {?}
         */
        value: function ngAfterContentInit() {
          if (!this._currentSubscription && !this.disabled) {
            this._subscribe();
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this._unsubscribe();
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_subscribe",
        value: function _subscribe() {
          var _this78 = this;

          this._unsubscribe();
          /** @type {?} */


          var stream = this._contentObserver.observe(this._elementRef); // TODO(mmalerba): We shouldn't be emitting on this @Output() outside the zone.
          // Consider brining it back inside the zone next time we're making breaking changes.
          // Bringing it back inside can cause things like infinite change detection loops and changed
          // after checked errors if people's code isn't handling it properly.


          this._ngZone.runOutsideAngular(
          /**
          * @return {?}
          */
          function () {
            _this78._currentSubscription = (_this78.debounce ? stream.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["debounceTime"])(_this78.debounce)) : stream).subscribe(_this78.event);
          });
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_unsubscribe",
        value: function _unsubscribe() {
          if (this._currentSubscription) {
            this._currentSubscription.unsubscribe();
          }
        }
      }, {
        key: "disabled",
        get: function get() {
          return this._disabled;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._disabled = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_0__["coerceBooleanProperty"])(value);
          this._disabled ? this._unsubscribe() : this._subscribe();
        }
        /**
         * Debounce interval for emitting the changes.
         * @return {?}
         */

      }, {
        key: "debounce",
        get: function get() {
          return this._debounce;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._debounce = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_0__["coerceNumberProperty"])(value);

          this._subscribe();
        }
      }]);

      return CdkObserveContent;
    }();

    CdkObserveContent.ɵfac = function CdkObserveContent_Factory(t) {
      return new (t || CdkObserveContent)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](ContentObserver), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]));
    };

    CdkObserveContent.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineDirective"]({
      type: CdkObserveContent,
      selectors: [["", "cdkObserveContent", ""]],
      inputs: {
        disabled: ["cdkObserveContentDisabled", "disabled"],
        debounce: "debounce"
      },
      outputs: {
        event: "cdkObserveContent"
      },
      exportAs: ["cdkObserveContent"]
    });
    /** @nocollapse */

    CdkObserveContent.ctorParameters = function () {
      return [{
        type: ContentObserver
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
      }];
    };

    CdkObserveContent.propDecorators = {
      event: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"],
        args: ['cdkObserveContent']
      }],
      disabled: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkObserveContentDisabled']
      }],
      debounce: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](CdkObserveContent, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Directive"],
        args: [{
          selector: '[cdkObserveContent]',
          exportAs: 'cdkObserveContent'
        }]
      }], function () {
        return [{
          type: ContentObserver
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
        }];
      }, {
        event: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"],
          args: ['cdkObserveContent']
        }],
        disabled: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkObserveContentDisabled']
        }],
        debounce: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }]
      });
    })();

    if (false) {}

    var ObserversModule = function ObserversModule() {
      _classCallCheck(this, ObserversModule);
    };

    ObserversModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineNgModule"]({
      type: ObserversModule
    });
    ObserversModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjector"]({
      factory: function ObserversModule_Factory(t) {
        return new (t || ObserversModule)();
      },
      providers: [MutationObserverFactory]
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵsetNgModuleScope"](ObserversModule, {
        declarations: [CdkObserveContent],
        exports: [CdkObserveContent]
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](ObserversModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModule"],
        args: [{
          exports: [CdkObserveContent],
          declarations: [CdkObserveContent],
          providers: [MutationObserverFactory]
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/observers/public-api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=observers.js.map

    /***/

  },

  /***/
  "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/overlay.js":
  /*!********************************************************************!*\
    !*** ./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/overlay.js ***!
    \********************************************************************/

  /*! exports provided: CdkScrollable, ScrollDispatcher, ViewportRuler, BlockScrollStrategy, CdkConnectedOverlay, CdkOverlayOrigin, CloseScrollStrategy, ConnectedOverlayPositionChange, ConnectedPositionStrategy, ConnectionPositionPair, FlexibleConnectedPositionStrategy, FullscreenOverlayContainer, GlobalPositionStrategy, NoopScrollStrategy, OVERLAY_PROVIDERS, Overlay, OverlayConfig, OverlayContainer, OverlayKeyboardDispatcher, OverlayModule, OverlayPositionBuilder, OverlayRef, RepositionScrollStrategy, ScrollStrategyOptions, ScrollingVisibility, validateHorizontalPosition, validateVerticalPosition, ɵangular_material_src_cdk_overlay_overlay_a, ɵangular_material_src_cdk_overlay_overlay_b, ɵangular_material_src_cdk_overlay_overlay_c, ɵangular_material_src_cdk_overlay_overlay_d, ɵangular_material_src_cdk_overlay_overlay_e, ɵangular_material_src_cdk_overlay_overlay_f, ɵangular_material_src_cdk_overlay_overlay_g */

  /***/
  function node_modulesAngularCdk__ivy_ngcc__Fesm2015OverlayJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "BlockScrollStrategy", function () {
      return BlockScrollStrategy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CdkConnectedOverlay", function () {
      return CdkConnectedOverlay;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CdkOverlayOrigin", function () {
      return CdkOverlayOrigin;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CloseScrollStrategy", function () {
      return CloseScrollStrategy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ConnectedOverlayPositionChange", function () {
      return ConnectedOverlayPositionChange;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ConnectedPositionStrategy", function () {
      return ConnectedPositionStrategy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ConnectionPositionPair", function () {
      return ConnectionPositionPair;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FlexibleConnectedPositionStrategy", function () {
      return FlexibleConnectedPositionStrategy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FullscreenOverlayContainer", function () {
      return FullscreenOverlayContainer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "GlobalPositionStrategy", function () {
      return GlobalPositionStrategy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NoopScrollStrategy", function () {
      return NoopScrollStrategy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "OVERLAY_PROVIDERS", function () {
      return OVERLAY_PROVIDERS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Overlay", function () {
      return Overlay;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "OverlayConfig", function () {
      return OverlayConfig;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "OverlayContainer", function () {
      return OverlayContainer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "OverlayKeyboardDispatcher", function () {
      return OverlayKeyboardDispatcher;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "OverlayModule", function () {
      return OverlayModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "OverlayPositionBuilder", function () {
      return OverlayPositionBuilder;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "OverlayRef", function () {
      return OverlayRef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RepositionScrollStrategy", function () {
      return RepositionScrollStrategy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ScrollStrategyOptions", function () {
      return ScrollStrategyOptions;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ScrollingVisibility", function () {
      return ScrollingVisibility;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "validateHorizontalPosition", function () {
      return validateHorizontalPosition;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "validateVerticalPosition", function () {
      return validateVerticalPosition;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_material_src_cdk_overlay_overlay_a", function () {
      return OVERLAY_CONTAINER_PROVIDER_FACTORY;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_material_src_cdk_overlay_overlay_b", function () {
      return OVERLAY_CONTAINER_PROVIDER;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_material_src_cdk_overlay_overlay_c", function () {
      return CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_material_src_cdk_overlay_overlay_d", function () {
      return CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER_FACTORY;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_material_src_cdk_overlay_overlay_e", function () {
      return CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_material_src_cdk_overlay_overlay_f", function () {
      return OVERLAY_KEYBOARD_DISPATCHER_PROVIDER_FACTORY;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_material_src_cdk_overlay_overlay_g", function () {
      return OVERLAY_KEYBOARD_DISPATCHER_PROVIDER;
    });
    /* harmony import */


    var _angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/cdk/scrolling */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/scrolling.js");
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! @angular/cdk/platform */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/platform.js");
    /* harmony import */


    var _angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! @angular/cdk/bidi */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/bidi.js");
    /* harmony import */


    var _angular_common__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! @angular/common */
    "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/common.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "CdkScrollable", function () {
      return _angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["CdkScrollable"];
    });
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "ScrollDispatcher", function () {
      return _angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["ScrollDispatcher"];
    });
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "ViewportRuler", function () {
      return _angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["ViewportRuler"];
    });
    /* harmony import */


    var _angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(
    /*! @angular/cdk/coercion */
    "./node_modules/@angular/cdk/fesm2015/coercion.js");
    /* harmony import */


    var _angular_cdk_portal__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(
    /*! @angular/cdk/portal */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/portal.js");
    /* harmony import */


    var rxjs__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(
    /*! rxjs */
    "./node_modules/rxjs/_esm2015/index.js");
    /* harmony import */


    var rxjs_operators__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(
    /*! rxjs/operators */
    "./node_modules/rxjs/_esm2015/operators/index.js");
    /* harmony import */


    var _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(
    /*! @angular/cdk/keycodes */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/keycodes.js");
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/scroll/block-scroll-strategy.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Strategy that will prevent the user from scrolling while the overlay is visible.
     */


    var BlockScrollStrategy = /*#__PURE__*/function () {
      /**
       * @param {?} _viewportRuler
       * @param {?} document
       */
      function BlockScrollStrategy(_viewportRuler, document) {
        _classCallCheck(this, BlockScrollStrategy);

        this._viewportRuler = _viewportRuler;
        this._previousHTMLStyles = {
          top: '',
          left: ''
        };
        this._isEnabled = false;
        this._document = document;
      }
      /**
       * Attaches this scroll strategy to an overlay.
       * @return {?}
       */


      _createClass2(BlockScrollStrategy, [{
        key: "attach",
        value: function attach() {}
        /**
         * Blocks page-level scroll while the attached overlay is open.
         * @return {?}
         */

      }, {
        key: "enable",
        value: function enable() {
          if (this._canBeEnabled()) {
            /** @type {?} */
            var root =
            /** @type {?} */
            this._document.documentElement;
            this._previousScrollPosition = this._viewportRuler.getViewportScrollPosition(); // Cache the previous inline styles in case the user had set them.

            this._previousHTMLStyles.left = root.style.left || '';
            this._previousHTMLStyles.top = root.style.top || ''; // Note: we're using the `html` node, instead of the `body`, because the `body` may
            // have the user agent margin, whereas the `html` is guaranteed not to have one.

            root.style.left = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceCssPixelValue"])(-this._previousScrollPosition.left);
            root.style.top = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceCssPixelValue"])(-this._previousScrollPosition.top);
            root.classList.add('cdk-global-scrollblock');
            this._isEnabled = true;
          }
        }
        /**
         * Unblocks page-level scroll while the attached overlay is open.
         * @return {?}
         */

      }, {
        key: "disable",
        value: function disable() {
          if (this._isEnabled) {
            /** @type {?} */
            var html =
            /** @type {?} */
            this._document.documentElement;
            /** @type {?} */

            var body =
            /** @type {?} */
            this._document.body;
            /** @type {?} */

            var htmlStyle =
            /** @type {?} */
            html.style;
            /** @type {?} */

            var bodyStyle =
            /** @type {?} */
            body.style;
            /** @type {?} */

            var previousHtmlScrollBehavior = htmlStyle.scrollBehavior || '';
            /** @type {?} */

            var previousBodyScrollBehavior = bodyStyle.scrollBehavior || '';
            this._isEnabled = false;
            htmlStyle.left = this._previousHTMLStyles.left;
            htmlStyle.top = this._previousHTMLStyles.top;
            html.classList.remove('cdk-global-scrollblock'); // Disable user-defined smooth scrolling temporarily while we restore the scroll position.
            // See https://developer.mozilla.org/en-US/docs/Web/CSS/scroll-behavior

            htmlStyle.scrollBehavior = bodyStyle.scrollBehavior = 'auto';
            window.scroll(this._previousScrollPosition.left, this._previousScrollPosition.top);
            htmlStyle.scrollBehavior = previousHtmlScrollBehavior;
            bodyStyle.scrollBehavior = previousBodyScrollBehavior;
          }
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_canBeEnabled",
        value: function _canBeEnabled() {
          // Since the scroll strategies can't be singletons, we have to use a global CSS class
          // (`cdk-global-scrollblock`) to make sure that we don't try to disable global
          // scrolling multiple times.

          /** @type {?} */
          var html =
          /** @type {?} */
          this._document.documentElement;

          if (html.classList.contains('cdk-global-scrollblock') || this._isEnabled) {
            return false;
          }
          /** @type {?} */


          var body = this._document.body;
          /** @type {?} */

          var viewport = this._viewportRuler.getViewportSize();

          return body.scrollHeight > viewport.height || body.scrollWidth > viewport.width;
        }
      }]);

      return BlockScrollStrategy;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/scroll/scroll-strategy.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Describes a strategy that will be used by an overlay to handle scroll events while it is open.
     * @record
     */


    function ScrollStrategy() {}

    if (false) {}
    /**
     * Returns an error to be thrown when attempting to attach an already-attached scroll strategy.
     * @return {?}
     */


    function getMatScrollStrategyAlreadyAttachedError() {
      return Error("Scroll strategy has already been attached.");
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/scroll/close-scroll-strategy.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Config options for the CloseScrollStrategy.
     * @record
     */


    function CloseScrollStrategyConfig() {}

    if (false) {}
    /**
     * Strategy that will close the overlay as soon as the user starts scrolling.
     */


    var CloseScrollStrategy = /*#__PURE__*/function () {
      /**
       * @param {?} _scrollDispatcher
       * @param {?} _ngZone
       * @param {?} _viewportRuler
       * @param {?=} _config
       */
      function CloseScrollStrategy(_scrollDispatcher, _ngZone, _viewportRuler, _config) {
        var _this79 = this;

        _classCallCheck(this, CloseScrollStrategy);

        this._scrollDispatcher = _scrollDispatcher;
        this._ngZone = _ngZone;
        this._viewportRuler = _viewportRuler;
        this._config = _config;
        this._scrollSubscription = null;
        /**
         * Detaches the overlay ref and disables the scroll strategy.
         */

        this._detach =
        /**
        * @return {?}
        */
        function () {
          _this79.disable();

          if (_this79._overlayRef.hasAttached()) {
            _this79._ngZone.run(
            /**
            * @return {?}
            */
            function () {
              return _this79._overlayRef.detach();
            });
          }
        };
      }
      /**
       * Attaches this scroll strategy to an overlay.
       * @param {?} overlayRef
       * @return {?}
       */


      _createClass2(CloseScrollStrategy, [{
        key: "attach",
        value: function attach(overlayRef) {
          if (this._overlayRef) {
            throw getMatScrollStrategyAlreadyAttachedError();
          }

          this._overlayRef = overlayRef;
        }
        /**
         * Enables the closing of the attached overlay on scroll.
         * @return {?}
         */

      }, {
        key: "enable",
        value: function enable() {
          var _this80 = this;

          if (this._scrollSubscription) {
            return;
          }
          /** @type {?} */


          var stream = this._scrollDispatcher.scrolled(0);

          if (this._config && this._config.threshold && this._config.threshold > 1) {
            this._initialScrollPosition = this._viewportRuler.getViewportScrollPosition().top;
            this._scrollSubscription = stream.subscribe(
            /**
            * @return {?}
            */
            function () {
              /** @type {?} */
              var scrollPosition = _this80._viewportRuler.getViewportScrollPosition().top;

              if (Math.abs(scrollPosition - _this80._initialScrollPosition) >
              /** @type {?} */

              /** @type {?} */
              _this80._config.threshold) {
                _this80._detach();
              } else {
                _this80._overlayRef.updatePosition();
              }
            });
          } else {
            this._scrollSubscription = stream.subscribe(this._detach);
          }
        }
        /**
         * Disables the closing the attached overlay on scroll.
         * @return {?}
         */

      }, {
        key: "disable",
        value: function disable() {
          if (this._scrollSubscription) {
            this._scrollSubscription.unsubscribe();

            this._scrollSubscription = null;
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "detach",
        value: function detach() {
          this.disable();
          this._overlayRef =
          /** @type {?} */
          null;
        }
      }]);

      return CloseScrollStrategy;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/scroll/noop-scroll-strategy.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Scroll strategy that doesn't do anything.
     */


    var NoopScrollStrategy = /*#__PURE__*/function () {
      function NoopScrollStrategy() {
        _classCallCheck(this, NoopScrollStrategy);
      }

      _createClass2(NoopScrollStrategy, [{
        key: "enable",

        /**
         * Does nothing, as this scroll strategy is a no-op.
         * @return {?}
         */
        value: function enable() {}
        /**
         * Does nothing, as this scroll strategy is a no-op.
         * @return {?}
         */

      }, {
        key: "disable",
        value: function disable() {}
        /**
         * Does nothing, as this scroll strategy is a no-op.
         * @return {?}
         */

      }, {
        key: "attach",
        value: function attach() {}
      }]);

      return NoopScrollStrategy;
    }();
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/position/scroll-clip.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */
    // TODO(jelbourn): move this to live with the rest of the scrolling code
    // TODO(jelbourn): someday replace this with IntersectionObservers

    /**
     * Gets whether an element is scrolled outside of view by any of its parent scrolling containers.
     * \@docs-private
     * @param {?} element Dimensions of the element (from getBoundingClientRect)
     * @param {?} scrollContainers Dimensions of element's scrolling containers (from getBoundingClientRect)
     * @return {?} Whether the element is scrolled out of view
     */


    function isElementScrolledOutsideView(element, scrollContainers) {
      return scrollContainers.some(
      /**
      * @param {?} containerBounds
      * @return {?}
      */
      function (containerBounds) {
        /** @type {?} */
        var outsideAbove = element.bottom < containerBounds.top;
        /** @type {?} */

        var outsideBelow = element.top > containerBounds.bottom;
        /** @type {?} */

        var outsideLeft = element.right < containerBounds.left;
        /** @type {?} */

        var outsideRight = element.left > containerBounds.right;
        return outsideAbove || outsideBelow || outsideLeft || outsideRight;
      });
    }
    /**
     * Gets whether an element is clipped by any of its scrolling containers.
     * \@docs-private
     * @param {?} element Dimensions of the element (from getBoundingClientRect)
     * @param {?} scrollContainers Dimensions of element's scrolling containers (from getBoundingClientRect)
     * @return {?} Whether the element is clipped
     */


    function isElementClippedByScrolling(element, scrollContainers) {
      return scrollContainers.some(
      /**
      * @param {?} scrollContainerRect
      * @return {?}
      */
      function (scrollContainerRect) {
        /** @type {?} */
        var clippedAbove = element.top < scrollContainerRect.top;
        /** @type {?} */

        var clippedBelow = element.bottom > scrollContainerRect.bottom;
        /** @type {?} */

        var clippedLeft = element.left < scrollContainerRect.left;
        /** @type {?} */

        var clippedRight = element.right > scrollContainerRect.right;
        return clippedAbove || clippedBelow || clippedLeft || clippedRight;
      });
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/scroll/reposition-scroll-strategy.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Config options for the RepositionScrollStrategy.
     * @record
     */


    function RepositionScrollStrategyConfig() {}

    if (false) {}
    /**
     * Strategy that will update the element position as the user is scrolling.
     */


    var RepositionScrollStrategy = /*#__PURE__*/function () {
      /**
       * @param {?} _scrollDispatcher
       * @param {?} _viewportRuler
       * @param {?} _ngZone
       * @param {?=} _config
       */
      function RepositionScrollStrategy(_scrollDispatcher, _viewportRuler, _ngZone, _config) {
        _classCallCheck(this, RepositionScrollStrategy);

        this._scrollDispatcher = _scrollDispatcher;
        this._viewportRuler = _viewportRuler;
        this._ngZone = _ngZone;
        this._config = _config;
        this._scrollSubscription = null;
      }
      /**
       * Attaches this scroll strategy to an overlay.
       * @param {?} overlayRef
       * @return {?}
       */


      _createClass2(RepositionScrollStrategy, [{
        key: "attach",
        value: function attach(overlayRef) {
          if (this._overlayRef) {
            throw getMatScrollStrategyAlreadyAttachedError();
          }

          this._overlayRef = overlayRef;
        }
        /**
         * Enables repositioning of the attached overlay on scroll.
         * @return {?}
         */

      }, {
        key: "enable",
        value: function enable() {
          var _this81 = this;

          if (!this._scrollSubscription) {
            /** @type {?} */
            var throttle = this._config ? this._config.scrollThrottle : 0;
            this._scrollSubscription = this._scrollDispatcher.scrolled(throttle).subscribe(
            /**
            * @return {?}
            */
            function () {
              _this81._overlayRef.updatePosition(); // TODO(crisbeto): make `close` on by default once all components can handle it.


              if (_this81._config && _this81._config.autoClose) {
                /** @type {?} */
                var overlayRect = _this81._overlayRef.overlayElement.getBoundingClientRect();

                var _this81$_viewportRule = _this81._viewportRuler.getViewportSize(),
                    width = _this81$_viewportRule.width,
                    height = _this81$_viewportRule.height; // TODO(crisbeto): include all ancestor scroll containers here once
                // we have a way of exposing the trigger element to the scroll strategy.

                /** @type {?} */


                var parentRects = [{
                  width: width,
                  height: height,
                  bottom: height,
                  right: width,
                  top: 0,
                  left: 0
                }];

                if (isElementScrolledOutsideView(overlayRect, parentRects)) {
                  _this81.disable();

                  _this81._ngZone.run(
                  /**
                  * @return {?}
                  */
                  function () {
                    return _this81._overlayRef.detach();
                  });
                }
              }
            });
          }
        }
        /**
         * Disables repositioning of the attached overlay on scroll.
         * @return {?}
         */

      }, {
        key: "disable",
        value: function disable() {
          if (this._scrollSubscription) {
            this._scrollSubscription.unsubscribe();

            this._scrollSubscription = null;
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "detach",
        value: function detach() {
          this.disable();
          this._overlayRef =
          /** @type {?} */
          null;
        }
      }]);

      return RepositionScrollStrategy;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/scroll/scroll-strategy-options.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Options for how an overlay will handle scrolling.
     *
     * Users can provide a custom value for `ScrollStrategyOptions` to replace the default
     * behaviors. This class primarily acts as a factory for ScrollStrategy instances.
     */


    var ScrollStrategyOptions =
    /**
     * @param {?} _scrollDispatcher
     * @param {?} _viewportRuler
     * @param {?} _ngZone
     * @param {?} document
     */
    function ScrollStrategyOptions(_scrollDispatcher, _viewportRuler, _ngZone, document) {
      var _this82 = this;

      _classCallCheck(this, ScrollStrategyOptions);

      this._scrollDispatcher = _scrollDispatcher;
      this._viewportRuler = _viewportRuler;
      this._ngZone = _ngZone;
      /**
       * Do nothing on scroll.
       */

      this.noop =
      /**
      * @return {?}
      */
      function () {
        return new NoopScrollStrategy();
      };
      /**
       * Close the overlay as soon as the user scrolls.
       * @param config Configuration to be used inside the scroll strategy.
       */


      this.close =
      /**
      * @param {?=} config
      * @return {?}
      */
      function (config) {
        return new CloseScrollStrategy(_this82._scrollDispatcher, _this82._ngZone, _this82._viewportRuler, config);
      };
      /**
       * Block scrolling.
       */


      this.block =
      /**
      * @return {?}
      */
      function () {
        return new BlockScrollStrategy(_this82._viewportRuler, _this82._document);
      };
      /**
       * Update the overlay's position on scroll.
       * @param config Configuration to be used inside the scroll strategy.
       * Allows debouncing the reposition calls.
       */


      this.reposition =
      /**
      * @param {?=} config
      * @return {?}
      */
      function (config) {
        return new RepositionScrollStrategy(_this82._scrollDispatcher, _this82._viewportRuler, _this82._ngZone, config);
      };

      this._document = document;
    };

    ScrollStrategyOptions.ɵfac = function ScrollStrategyOptions_Factory(t) {
      return new (t || ScrollStrategyOptions)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["ScrollDispatcher"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["ViewportRuler"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]));
    };
    /** @nocollapse */


    ScrollStrategyOptions.ctorParameters = function () {
      return [{
        type: _angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["ScrollDispatcher"]
      }, {
        type: _angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["ViewportRuler"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]]
        }]
      }];
    };
    /** @nocollapse */


    ScrollStrategyOptions.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: function ScrollStrategyOptions_Factory() {
        return new ScrollStrategyOptions(Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["ScrollDispatcher"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["ViewportRuler"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]));
      },
      token: ScrollStrategyOptions,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](ScrollStrategyOptions, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [{
          type: _angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["ScrollDispatcher"]
        }, {
          type: _angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["ViewportRuler"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/scroll/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/overlay-config.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Initial configuration used when creating an overlay.
     */


    var OverlayConfig =
    /**
     * @param {?=} config
     */
    function OverlayConfig(config) {
      _classCallCheck(this, OverlayConfig);

      /**
       * Strategy to be used when handling scroll events while the overlay is open.
       */
      this.scrollStrategy = new NoopScrollStrategy();
      /**
       * Custom class to add to the overlay pane.
       */

      this.panelClass = '';
      /**
       * Whether the overlay has a backdrop.
       */

      this.hasBackdrop = false;
      /**
       * Custom class to add to the backdrop
       */

      this.backdropClass = 'cdk-overlay-dark-backdrop';
      /**
       * Whether the overlay should be disposed of when the user goes backwards/forwards in history.
       * Note that this usually doesn't include clicking on links (unless the user is using
       * the `HashLocationStrategy`).
       */

      this.disposeOnNavigation = false;

      if (config) {
        // Use `Iterable` instead of `Array` because TypeScript, as of 3.6.3,
        // loses the array generic type in the `for of`. But we *also* have to use `Array` because
        // typescript won't iterate over an `Iterable` unless you compile with `--downlevelIteration`

        /** @type {?} */
        var configKeys =
        /** @type {?} */
        Object.keys(config);

        for (var _i8 = 0, _configKeys = configKeys; _i8 < _configKeys.length; _i8++) {
          var key = _configKeys[_i8];

          if (config[key] !== undefined) {
            // TypeScript, as of version 3.5, sees the left-hand-side of this expression
            // as "I don't know *which* key this is, so the only valid value is the intersection
            // of all the posible values." In this case, that happens to be `undefined`. TypeScript
            // is not smart enough to see that the right-hand-side is actually an access of the same
            // exact type with the same exact key, meaning that the value type must be identical.
            // So we use `any` to work around this.
            this[key] =
            /** @type {?} */
            config[key];
          }
        }
      }
    };

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/position/connected-position.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * A connection point on the origin element.
     * @record
     */


    function OriginConnectionPosition() {}

    if (false) {}
    /**
     * A connection point on the overlay element.
     * @record
     */


    function OverlayConnectionPosition() {}

    if (false) {}
    /**
     * The points of the origin element and the overlay element to connect.
     */


    var ConnectionPositionPair =
    /**
     * @param {?} origin
     * @param {?} overlay
     * @param {?=} offsetX
     * @param {?=} offsetY
     * @param {?=} panelClass
     */
    function ConnectionPositionPair(origin, overlay, offsetX, offsetY, panelClass) {
      _classCallCheck(this, ConnectionPositionPair);

      this.offsetX = offsetX;
      this.offsetY = offsetY;
      this.panelClass = panelClass;
      this.originX = origin.originX;
      this.originY = origin.originY;
      this.overlayX = overlay.overlayX;
      this.overlayY = overlay.overlayY;
    };

    if (false) {}
    /**
     * Set of properties regarding the position of the origin and overlay relative to the viewport
     * with respect to the containing Scrollable elements.
     *
     * The overlay and origin are clipped if any part of their bounding client rectangle exceeds the
     * bounds of any one of the strategy's Scrollable's bounding client rectangle.
     *
     * The overlay and origin are outside view if there is no overlap between their bounding client
     * rectangle and any one of the strategy's Scrollable's bounding client rectangle.
     *
     *       -----------                    -----------
     *       | outside |                    | clipped |
     *       |  view   |              --------------------------
     *       |         |              |     |         |        |
     *       ----------               |     -----------        |
     *  --------------------------    |                        |
     *  |                        |    |      Scrollable        |
     *  |                        |    |                        |
     *  |                        |     --------------------------
     *  |      Scrollable        |
     *  |                        |
     *  --------------------------
     *
     * \@docs-private
     */


    var ScrollingVisibility = function ScrollingVisibility() {
      _classCallCheck(this, ScrollingVisibility);
    };

    if (false) {}
    /**
     * The change event emitted by the strategy when a fallback position is used.
     */


    var ConnectedOverlayPositionChange =
    /**
     * @param {?} connectionPair
     * @param {?} scrollableViewProperties
     */
    function ConnectedOverlayPositionChange(connectionPair, scrollableViewProperties) {
      _classCallCheck(this, ConnectedOverlayPositionChange);

      this.connectionPair = connectionPair;
      this.scrollableViewProperties = scrollableViewProperties;
    };
    /** @nocollapse */


    ConnectedOverlayPositionChange.ctorParameters = function () {
      return [{
        type: ConnectionPositionPair
      }, {
        type: ScrollingVisibility,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }]
      }];
    };

    if (false) {}
    /**
     * Validates whether a vertical position property matches the expected values.
     * \@docs-private
     * @param {?} property Name of the property being validated.
     * @param {?} value Value of the property being validated.
     * @return {?}
     */


    function validateVerticalPosition(property, value) {
      if (value !== 'top' && value !== 'bottom' && value !== 'center') {
        throw Error("ConnectedPosition: Invalid ".concat(property, " \"").concat(value, "\". ") + "Expected \"top\", \"bottom\" or \"center\".");
      }
    }
    /**
     * Validates whether a horizontal position property matches the expected values.
     * \@docs-private
     * @param {?} property Name of the property being validated.
     * @param {?} value Value of the property being validated.
     * @return {?}
     */


    function validateHorizontalPosition(property, value) {
      if (value !== 'start' && value !== 'end' && value !== 'center') {
        throw Error("ConnectedPosition: Invalid ".concat(property, " \"").concat(value, "\". ") + "Expected \"start\", \"end\" or \"center\".");
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/keyboard/overlay-keyboard-dispatcher.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Service for dispatching keyboard events that land on the body to appropriate overlay ref,
     * if any. It maintains a list of attached overlays to determine best suited overlay based
     * on event target and order of overlay opens.
     */


    var OverlayKeyboardDispatcher = /*#__PURE__*/function () {
      /**
       * @param {?} document
       */
      function OverlayKeyboardDispatcher(document) {
        var _this83 = this;

        _classCallCheck(this, OverlayKeyboardDispatcher);

        /**
         * Currently attached overlays in the order they were attached.
         */
        this._attachedOverlays = [];
        /**
         * Keyboard event listener that will be attached to the body.
         */

        this._keydownListener =
        /**
        * @param {?} event
        * @return {?}
        */
        function (event) {
          /** @type {?} */
          var overlays = _this83._attachedOverlays;

          for (var i = overlays.length - 1; i > -1; i--) {
            // Dispatch the keydown event to the top overlay which has subscribers to its keydown events.
            // We want to target the most recent overlay, rather than trying to match where the event came
            // from, because some components might open an overlay, but keep focus on a trigger element
            // (e.g. for select and autocomplete). We skip overlays without keydown event subscriptions,
            // because we don't want overlays that don't handle keyboard events to block the ones below
            // them that do.
            if (overlays[i]._keydownEventSubscriptions > 0) {
              overlays[i]._keydownEvents.next(event);

              break;
            }
          }
        };

        this._document = document;
      }
      /**
       * @return {?}
       */


      _createClass2(OverlayKeyboardDispatcher, [{
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this._detach();
        }
        /**
         * Add a new overlay to the list of attached overlay refs.
         * @param {?} overlayRef
         * @return {?}
         */

      }, {
        key: "add",
        value: function add(overlayRef) {
          // Ensure that we don't get the same overlay multiple times.
          this.remove(overlayRef); // Lazily start dispatcher once first overlay is added

          if (!this._isAttached) {
            this._document.body.addEventListener('keydown', this._keydownListener);

            this._isAttached = true;
          }

          this._attachedOverlays.push(overlayRef);
        }
        /**
         * Remove an overlay from the list of attached overlay refs.
         * @param {?} overlayRef
         * @return {?}
         */

      }, {
        key: "remove",
        value: function remove(overlayRef) {
          /** @type {?} */
          var index = this._attachedOverlays.indexOf(overlayRef);

          if (index > -1) {
            this._attachedOverlays.splice(index, 1);
          } // Remove the global listener once there are no more overlays.


          if (this._attachedOverlays.length === 0) {
            this._detach();
          }
        }
        /**
         * Detaches the global keyboard event listener.
         * @private
         * @return {?}
         */

      }, {
        key: "_detach",
        value: function _detach() {
          if (this._isAttached) {
            this._document.body.removeEventListener('keydown', this._keydownListener);

            this._isAttached = false;
          }
        }
      }]);

      return OverlayKeyboardDispatcher;
    }();

    OverlayKeyboardDispatcher.ɵfac = function OverlayKeyboardDispatcher_Factory(t) {
      return new (t || OverlayKeyboardDispatcher)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]));
    };
    /** @nocollapse */


    OverlayKeyboardDispatcher.ctorParameters = function () {
      return [{
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]]
        }]
      }];
    };
    /** @nocollapse */


    OverlayKeyboardDispatcher.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: function OverlayKeyboardDispatcher_Factory() {
        return new OverlayKeyboardDispatcher(Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]));
      },
      token: OverlayKeyboardDispatcher,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](OverlayKeyboardDispatcher, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [{
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * \@docs-private \@deprecated \@breaking-change 8.0.0
     * @param {?} dispatcher
     * @param {?} _document
     * @return {?}
     */


    function OVERLAY_KEYBOARD_DISPATCHER_PROVIDER_FACTORY(dispatcher, _document) {
      return dispatcher || new OverlayKeyboardDispatcher(_document);
    }
    /**
     * \@docs-private \@deprecated \@breaking-change 8.0.0
     * @type {?}
     */


    var OVERLAY_KEYBOARD_DISPATCHER_PROVIDER = {
      // If there is already an OverlayKeyboardDispatcher available, use that.
      // Otherwise, provide a new one.
      provide: OverlayKeyboardDispatcher,
      deps: [[new _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"](), new _angular_core__WEBPACK_IMPORTED_MODULE_1__["SkipSelf"](), OverlayKeyboardDispatcher],
      /** @type {?} */
      // Coerce to `InjectionToken` so that the `deps` match the "shape"
      // of the type expected by Angular
      _angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]],
      useFactory: OVERLAY_KEYBOARD_DISPATCHER_PROVIDER_FACTORY
    };
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/overlay-container.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Whether we're in a testing environment.
     * TODO(crisbeto): remove this once we have an overlay testing module.
     * @type {?}
     */

    var isTestEnvironment = typeof window !== 'undefined' && !!window && !!(
    /** @type {?} */
    window.__karma__ ||
    /** @type {?} */
    window.jasmine);
    /**
     * Container inside which all overlays will render.
     */

    var OverlayContainer = /*#__PURE__*/function () {
      /**
       * @param {?} document
       * @param {?=} _platform
       */
      function OverlayContainer(document, _platform) {
        _classCallCheck(this, OverlayContainer);

        this._platform = _platform;
        this._document = document;
      }
      /**
       * @return {?}
       */


      _createClass2(OverlayContainer, [{
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          /** @type {?} */
          var container = this._containerElement;

          if (container && container.parentNode) {
            container.parentNode.removeChild(container);
          }
        }
        /**
         * This method returns the overlay container element. It will lazily
         * create the element the first time  it is called to facilitate using
         * the container in non-browser environments.
         * @return {?} the container element
         */

      }, {
        key: "getContainerElement",
        value: function getContainerElement() {
          if (!this._containerElement) {
            this._createContainer();
          }

          return this._containerElement;
        }
        /**
         * Create the overlay container element, which is simply a div
         * with the 'cdk-overlay-container' class on the document body.
         * @protected
         * @return {?}
         */

      }, {
        key: "_createContainer",
        value: function _createContainer() {
          // @breaking-change 10.0.0 Remove null check for `_platform`.

          /** @type {?} */
          var isBrowser = this._platform ? this._platform.isBrowser : typeof window !== 'undefined';
          /** @type {?} */

          var containerClass = 'cdk-overlay-container';

          if (isBrowser || isTestEnvironment) {
            /** @type {?} */
            var oppositePlatformContainers = this._document.querySelectorAll(".".concat(containerClass, "[platform=\"server\"], ") + ".".concat(containerClass, "[platform=\"test\"]")); // Remove any old containers from the opposite platform.
            // This can happen when transitioning from the server to the client.


            for (var i = 0; i < oppositePlatformContainers.length; i++) {
              /** @type {?} */
              oppositePlatformContainers[i].parentNode.removeChild(oppositePlatformContainers[i]);
            }
          }
          /** @type {?} */


          var container = this._document.createElement('div');

          container.classList.add(containerClass); // A long time ago we kept adding new overlay containers whenever a new app was instantiated,
          // but at some point we added logic which clears the duplicate ones in order to avoid leaks.
          // The new logic was a little too aggressive since it was breaking some legitimate use cases.
          // To mitigate the problem we made it so that only containers from a different platform are
          // cleared, but the side-effect was that people started depending on the overly-aggressive
          // logic to clean up their tests for them. Until we can introduce an overlay-specific testing
          // module which does the cleanup, we try to detect that we're in a test environment and we
          // always clear the container. See #17006.
          // TODO(crisbeto): remove the test environment check once we have an overlay testing module.

          if (isTestEnvironment) {
            container.setAttribute('platform', 'test');
          } else if (!isBrowser) {
            container.setAttribute('platform', 'server');
          }

          this._document.body.appendChild(container);

          this._containerElement = container;
        }
      }]);

      return OverlayContainer;
    }();

    OverlayContainer.ɵfac = function OverlayContainer_Factory(t) {
      return new (t || OverlayContainer)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_2__["Platform"]));
    };
    /** @nocollapse */


    OverlayContainer.ctorParameters = function () {
      return [{
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]]
        }]
      }, {
        type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_2__["Platform"]
      }];
    };
    /** @nocollapse */


    OverlayContainer.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: function OverlayContainer_Factory() {
        return new OverlayContainer(Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_2__["Platform"]));
      },
      token: OverlayContainer,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](OverlayContainer, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [{
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]]
          }]
        }, {
          type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_2__["Platform"]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * \@docs-private \@deprecated \@breaking-change 8.0.0
     * @param {?} parentContainer
     * @param {?} _document
     * @return {?}
     */


    function OVERLAY_CONTAINER_PROVIDER_FACTORY(parentContainer, _document) {
      return parentContainer || new OverlayContainer(_document);
    }
    /**
     * \@docs-private \@deprecated \@breaking-change 8.0.0
     * @type {?}
     */


    var OVERLAY_CONTAINER_PROVIDER = {
      // If there is already an OverlayContainer available, use that. Otherwise, provide a new one.
      provide: OverlayContainer,
      deps: [[new _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"](), new _angular_core__WEBPACK_IMPORTED_MODULE_1__["SkipSelf"](), OverlayContainer],
      /** @type {?} */
      _angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]],
      useFactory: OVERLAY_CONTAINER_PROVIDER_FACTORY
    };
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/overlay-ref.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Reference to an overlay that has been created with the Overlay service.
     * Used to manipulate or dispose of said overlay.
     */

    var OverlayRef = /*#__PURE__*/function () {
      /**
       * @param {?} _portalOutlet
       * @param {?} _host
       * @param {?} _pane
       * @param {?} _config
       * @param {?} _ngZone
       * @param {?} _keyboardDispatcher
       * @param {?} _document
       * @param {?=} _location
       */
      function OverlayRef(_portalOutlet, _host, _pane, _config, _ngZone, _keyboardDispatcher, _document, _location) {
        var _this84 = this;

        _classCallCheck(this, OverlayRef);

        this._portalOutlet = _portalOutlet;
        this._host = _host;
        this._pane = _pane;
        this._config = _config;
        this._ngZone = _ngZone;
        this._keyboardDispatcher = _keyboardDispatcher;
        this._document = _document;
        this._location = _location;
        this._backdropElement = null;
        this._backdropClick = new rxjs__WEBPACK_IMPORTED_MODULE_7__["Subject"]();
        this._attachments = new rxjs__WEBPACK_IMPORTED_MODULE_7__["Subject"]();
        this._detachments = new rxjs__WEBPACK_IMPORTED_MODULE_7__["Subject"]();
        this._locationChanges = rxjs__WEBPACK_IMPORTED_MODULE_7__["Subscription"].EMPTY;

        this._backdropClickHandler =
        /**
        * @param {?} event
        * @return {?}
        */
        function (event) {
          return _this84._backdropClick.next(event);
        };

        this._keydownEventsObservable = new rxjs__WEBPACK_IMPORTED_MODULE_7__["Observable"](
        /**
        * @param {?} observer
        * @return {?}
        */
        function (observer) {
          /** @type {?} */
          var subscription = _this84._keydownEvents.subscribe(observer);

          _this84._keydownEventSubscriptions++;
          return (
            /**
            * @return {?}
            */
            function () {
              subscription.unsubscribe();
              _this84._keydownEventSubscriptions--;
            }
          );
        });
        /**
         * Stream of keydown events dispatched to this overlay.
         */

        this._keydownEvents = new rxjs__WEBPACK_IMPORTED_MODULE_7__["Subject"]();
        /**
         * Amount of subscriptions to the keydown events.
         */

        this._keydownEventSubscriptions = 0;

        if (_config.scrollStrategy) {
          this._scrollStrategy = _config.scrollStrategy;

          this._scrollStrategy.attach(this);
        }

        this._positionStrategy = _config.positionStrategy;
      }
      /**
       * The overlay's HTML element
       * @return {?}
       */


      _createClass2(OverlayRef, [{
        key: "attach",

        /**
         * Attaches content, given via a Portal, to the overlay.
         * If the overlay is configured to have a backdrop, it will be created.
         *
         * @param {?} portal Portal instance to which to attach the overlay.
         * @return {?} The portal attachment result.
         */
        value: function attach(portal) {
          var _this85 = this;

          /** @type {?} */
          var attachResult = this._portalOutlet.attach(portal); // Update the pane element with the given configuration.


          if (!this._host.parentElement && this._previousHostParent) {
            this._previousHostParent.appendChild(this._host);
          }

          if (this._positionStrategy) {
            this._positionStrategy.attach(this);
          }

          this._updateStackingOrder();

          this._updateElementSize();

          this._updateElementDirection();

          if (this._scrollStrategy) {
            this._scrollStrategy.enable();
          } // Update the position once the zone is stable so that the overlay will be fully rendered
          // before attempting to position it, as the position may depend on the size of the rendered
          // content.


          this._ngZone.onStable.asObservable().pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_8__["take"])(1)).subscribe(
          /**
          * @return {?}
          */
          function () {
            // The overlay could've been detached before the zone has stabilized.
            if (_this85.hasAttached()) {
              _this85.updatePosition();
            }
          }); // Enable pointer events for the overlay pane element.


          this._togglePointerEvents(true);

          if (this._config.hasBackdrop) {
            this._attachBackdrop();
          }

          if (this._config.panelClass) {
            this._toggleClasses(this._pane, this._config.panelClass, true);
          } // Only emit the `attachments` event once all other setup is done.


          this._attachments.next(); // Track this overlay by the keyboard dispatcher


          this._keyboardDispatcher.add(this); // @breaking-change 8.0.0 remove the null check for `_location`
          // once the constructor parameter is made required.


          if (this._config.disposeOnNavigation && this._location) {
            this._locationChanges = this._location.subscribe(
            /**
            * @return {?}
            */
            function () {
              return _this85.dispose();
            });
          }

          return attachResult;
        }
        /**
         * Detaches an overlay from a portal.
         * @return {?} The portal detachment result.
         */

      }, {
        key: "detach",
        value: function detach() {
          if (!this.hasAttached()) {
            return;
          }

          this.detachBackdrop(); // When the overlay is detached, the pane element should disable pointer events.
          // This is necessary because otherwise the pane element will cover the page and disable
          // pointer events therefore. Depends on the position strategy and the applied pane boundaries.

          this._togglePointerEvents(false);

          if (this._positionStrategy && this._positionStrategy.detach) {
            this._positionStrategy.detach();
          }

          if (this._scrollStrategy) {
            this._scrollStrategy.disable();
          }
          /** @type {?} */


          var detachmentResult = this._portalOutlet.detach(); // Only emit after everything is detached.


          this._detachments.next(); // Remove this overlay from keyboard dispatcher tracking.


          this._keyboardDispatcher.remove(this); // Keeping the host element in the DOM can cause scroll jank, because it still gets
          // rendered, even though it's transparent and unclickable which is why we remove it.


          this._detachContentWhenStable(); // Stop listening for location changes.


          this._locationChanges.unsubscribe();

          return detachmentResult;
        }
        /**
         * Cleans up the overlay from the DOM.
         * @return {?}
         */

      }, {
        key: "dispose",
        value: function dispose() {
          /** @type {?} */
          var isAttached = this.hasAttached();

          if (this._positionStrategy) {
            this._positionStrategy.dispose();
          }

          this._disposeScrollStrategy();

          this.detachBackdrop();

          this._locationChanges.unsubscribe();

          this._keyboardDispatcher.remove(this);

          this._portalOutlet.dispose();

          this._attachments.complete();

          this._backdropClick.complete();

          this._keydownEvents.complete();

          if (this._host && this._host.parentNode) {
            this._host.parentNode.removeChild(this._host);

            this._host =
            /** @type {?} */
            null;
          }

          this._previousHostParent = this._pane =
          /** @type {?} */
          null;

          if (isAttached) {
            this._detachments.next();
          }

          this._detachments.complete();
        }
        /**
         * Whether the overlay has attached content.
         * @return {?}
         */

      }, {
        key: "hasAttached",
        value: function hasAttached() {
          return this._portalOutlet.hasAttached();
        }
        /**
         * Gets an observable that emits when the backdrop has been clicked.
         * @return {?}
         */

      }, {
        key: "backdropClick",
        value: function backdropClick() {
          return this._backdropClick.asObservable();
        }
        /**
         * Gets an observable that emits when the overlay has been attached.
         * @return {?}
         */

      }, {
        key: "attachments",
        value: function attachments() {
          return this._attachments.asObservable();
        }
        /**
         * Gets an observable that emits when the overlay has been detached.
         * @return {?}
         */

      }, {
        key: "detachments",
        value: function detachments() {
          return this._detachments.asObservable();
        }
        /**
         * Gets an observable of keydown events targeted to this overlay.
         * @return {?}
         */

      }, {
        key: "keydownEvents",
        value: function keydownEvents() {
          return this._keydownEventsObservable;
        }
        /**
         * Gets the current overlay configuration, which is immutable.
         * @return {?}
         */

      }, {
        key: "getConfig",
        value: function getConfig() {
          return this._config;
        }
        /**
         * Updates the position of the overlay based on the position strategy.
         * @return {?}
         */

      }, {
        key: "updatePosition",
        value: function updatePosition() {
          if (this._positionStrategy) {
            this._positionStrategy.apply();
          }
        }
        /**
         * Switches to a new position strategy and updates the overlay position.
         * @param {?} strategy
         * @return {?}
         */

      }, {
        key: "updatePositionStrategy",
        value: function updatePositionStrategy(strategy) {
          if (strategy === this._positionStrategy) {
            return;
          }

          if (this._positionStrategy) {
            this._positionStrategy.dispose();
          }

          this._positionStrategy = strategy;

          if (this.hasAttached()) {
            strategy.attach(this);
            this.updatePosition();
          }
        }
        /**
         * Update the size properties of the overlay.
         * @param {?} sizeConfig
         * @return {?}
         */

      }, {
        key: "updateSize",
        value: function updateSize(sizeConfig) {
          this._config = Object.assign(Object.assign({}, this._config), sizeConfig);

          this._updateElementSize();
        }
        /**
         * Sets the LTR/RTL direction for the overlay.
         * @param {?} dir
         * @return {?}
         */

      }, {
        key: "setDirection",
        value: function setDirection(dir) {
          this._config = Object.assign(Object.assign({}, this._config), {
            direction: dir
          });

          this._updateElementDirection();
        }
        /**
         * Add a CSS class or an array of classes to the overlay pane.
         * @param {?} classes
         * @return {?}
         */

      }, {
        key: "addPanelClass",
        value: function addPanelClass(classes) {
          if (this._pane) {
            this._toggleClasses(this._pane, classes, true);
          }
        }
        /**
         * Remove a CSS class or an array of classes from the overlay pane.
         * @param {?} classes
         * @return {?}
         */

      }, {
        key: "removePanelClass",
        value: function removePanelClass(classes) {
          if (this._pane) {
            this._toggleClasses(this._pane, classes, false);
          }
        }
        /**
         * Returns the layout direction of the overlay panel.
         * @return {?}
         */

      }, {
        key: "getDirection",
        value: function getDirection() {
          /** @type {?} */
          var direction = this._config.direction;

          if (!direction) {
            return 'ltr';
          }

          return typeof direction === 'string' ? direction : direction.value;
        }
        /**
         * Switches to a new scroll strategy.
         * @param {?} strategy
         * @return {?}
         */

      }, {
        key: "updateScrollStrategy",
        value: function updateScrollStrategy(strategy) {
          if (strategy === this._scrollStrategy) {
            return;
          }

          this._disposeScrollStrategy();

          this._scrollStrategy = strategy;

          if (this.hasAttached()) {
            strategy.attach(this);
            strategy.enable();
          }
        }
        /**
         * Updates the text direction of the overlay panel.
         * @private
         * @return {?}
         */

      }, {
        key: "_updateElementDirection",
        value: function _updateElementDirection() {
          this._host.setAttribute('dir', this.getDirection());
        }
        /**
         * Updates the size of the overlay element based on the overlay config.
         * @private
         * @return {?}
         */

      }, {
        key: "_updateElementSize",
        value: function _updateElementSize() {
          if (!this._pane) {
            return;
          }
          /** @type {?} */


          var style = this._pane.style;
          style.width = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceCssPixelValue"])(this._config.width);
          style.height = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceCssPixelValue"])(this._config.height);
          style.minWidth = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceCssPixelValue"])(this._config.minWidth);
          style.minHeight = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceCssPixelValue"])(this._config.minHeight);
          style.maxWidth = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceCssPixelValue"])(this._config.maxWidth);
          style.maxHeight = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceCssPixelValue"])(this._config.maxHeight);
        }
        /**
         * Toggles the pointer events for the overlay pane element.
         * @private
         * @param {?} enablePointer
         * @return {?}
         */

      }, {
        key: "_togglePointerEvents",
        value: function _togglePointerEvents(enablePointer) {
          this._pane.style.pointerEvents = enablePointer ? 'auto' : 'none';
        }
        /**
         * Attaches a backdrop for this overlay.
         * @private
         * @return {?}
         */

      }, {
        key: "_attachBackdrop",
        value: function _attachBackdrop() {
          var _this86 = this;

          /** @type {?} */
          var showingClass = 'cdk-overlay-backdrop-showing';
          this._backdropElement = this._document.createElement('div');

          this._backdropElement.classList.add('cdk-overlay-backdrop');

          if (this._config.backdropClass) {
            this._toggleClasses(this._backdropElement, this._config.backdropClass, true);
          } // Insert the backdrop before the pane in the DOM order,
          // in order to handle stacked overlays properly.


          /** @type {?} */
          this._host.parentElement.insertBefore(this._backdropElement, this._host); // Forward backdrop clicks such that the consumer of the overlay can perform whatever
          // action desired when such a click occurs (usually closing the overlay).


          this._backdropElement.addEventListener('click', this._backdropClickHandler); // Add class to fade-in the backdrop after one frame.


          if (typeof requestAnimationFrame !== 'undefined') {
            this._ngZone.runOutsideAngular(
            /**
            * @return {?}
            */
            function () {
              requestAnimationFrame(
              /**
              * @return {?}
              */
              function () {
                if (_this86._backdropElement) {
                  _this86._backdropElement.classList.add(showingClass);
                }
              });
            });
          } else {
            this._backdropElement.classList.add(showingClass);
          }
        }
        /**
         * Updates the stacking order of the element, moving it to the top if necessary.
         * This is required in cases where one overlay was detached, while another one,
         * that should be behind it, was destroyed. The next time both of them are opened,
         * the stacking will be wrong, because the detached element's pane will still be
         * in its original DOM position.
         * @private
         * @return {?}
         */

      }, {
        key: "_updateStackingOrder",
        value: function _updateStackingOrder() {
          if (this._host.nextSibling) {
            /** @type {?} */
            this._host.parentNode.appendChild(this._host);
          }
        }
        /**
         * Detaches the backdrop (if any) associated with the overlay.
         * @return {?}
         */

      }, {
        key: "detachBackdrop",
        value: function detachBackdrop() {
          var _this87 = this;

          /** @type {?} */
          var backdropToDetach = this._backdropElement;

          if (!backdropToDetach) {
            return;
          }
          /** @type {?} */


          var timeoutId;
          /** @type {?} */

          var finishDetach =
          /**
          * @return {?}
          */
          function finishDetach() {
            // It may not be attached to anything in certain cases (e.g. unit tests).
            if (backdropToDetach) {
              backdropToDetach.removeEventListener('click', _this87._backdropClickHandler);
              backdropToDetach.removeEventListener('transitionend', finishDetach);

              if (backdropToDetach.parentNode) {
                backdropToDetach.parentNode.removeChild(backdropToDetach);
              }
            } // It is possible that a new portal has been attached to this overlay since we started
            // removing the backdrop. If that is the case, only clear the backdrop reference if it
            // is still the same instance that we started to remove.


            if (_this87._backdropElement == backdropToDetach) {
              _this87._backdropElement = null;
            }

            if (_this87._config.backdropClass) {
              _this87._toggleClasses(
              /** @type {?} */
              backdropToDetach, _this87._config.backdropClass, false);
            }

            clearTimeout(timeoutId);
          };

          backdropToDetach.classList.remove('cdk-overlay-backdrop-showing');

          this._ngZone.runOutsideAngular(
          /**
          * @return {?}
          */
          function () {
            /** @type {?} */
            backdropToDetach.addEventListener('transitionend', finishDetach);
          }); // If the backdrop doesn't have a transition, the `transitionend` event won't fire.
          // In this case we make it unclickable and we try to remove it after a delay.


          backdropToDetach.style.pointerEvents = 'none'; // Run this outside the Angular zone because there's nothing that Angular cares about.
          // If it were to run inside the Angular zone, every test that used Overlay would have to be
          // either async or fakeAsync.

          timeoutId = this._ngZone.runOutsideAngular(
          /**
          * @return {?}
          */
          function () {
            return setTimeout(finishDetach, 500);
          });
        }
        /**
         * Toggles a single CSS class or an array of classes on an element.
         * @private
         * @param {?} element
         * @param {?} cssClasses
         * @param {?} isAdd
         * @return {?}
         */

      }, {
        key: "_toggleClasses",
        value: function _toggleClasses(element, cssClasses, isAdd) {
          /** @type {?} */
          var classList = element.classList;
          Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceArray"])(cssClasses).forEach(
          /**
          * @param {?} cssClass
          * @return {?}
          */
          function (cssClass) {
            // We can't do a spread here, because IE doesn't support setting multiple classes.
            // Also trying to add an empty string to a DOMTokenList will throw.
            if (cssClass) {
              isAdd ? classList.add(cssClass) : classList.remove(cssClass);
            }
          });
        }
        /**
         * Detaches the overlay content next time the zone stabilizes.
         * @private
         * @return {?}
         */

      }, {
        key: "_detachContentWhenStable",
        value: function _detachContentWhenStable() {
          var _this88 = this;

          // Normally we wouldn't have to explicitly run this outside the `NgZone`, however
          // if the consumer is using `zone-patch-rxjs`, the `Subscription.unsubscribe` call will
          // be patched to run inside the zone, which will throw us into an infinite loop.
          this._ngZone.runOutsideAngular(
          /**
          * @return {?}
          */
          function () {
            // We can't remove the host here immediately, because the overlay pane's content
            // might still be animating. This stream helps us avoid interrupting the animation
            // by waiting for the pane to become empty.

            /** @type {?} */
            var subscription = _this88._ngZone.onStable.asObservable().pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_8__["takeUntil"])(Object(rxjs__WEBPACK_IMPORTED_MODULE_7__["merge"])(_this88._attachments, _this88._detachments))).subscribe(
            /**
            * @return {?}
            */
            function () {
              // Needs a couple of checks for the pane and host, because
              // they may have been removed by the time the zone stabilizes.
              if (!_this88._pane || !_this88._host || _this88._pane.children.length === 0) {
                if (_this88._pane && _this88._config.panelClass) {
                  _this88._toggleClasses(_this88._pane, _this88._config.panelClass, false);
                }

                if (_this88._host && _this88._host.parentElement) {
                  _this88._previousHostParent = _this88._host.parentElement;

                  _this88._previousHostParent.removeChild(_this88._host);
                }

                subscription.unsubscribe();
              }
            });
          });
        }
        /**
         * Disposes of a scroll strategy.
         * @private
         * @return {?}
         */

      }, {
        key: "_disposeScrollStrategy",
        value: function _disposeScrollStrategy() {
          /** @type {?} */
          var scrollStrategy = this._scrollStrategy;

          if (scrollStrategy) {
            scrollStrategy.disable();

            if (scrollStrategy.detach) {
              scrollStrategy.detach();
            }
          }
        }
      }, {
        key: "overlayElement",
        get: function get() {
          return this._pane;
        }
        /**
         * The overlay's backdrop HTML element.
         * @return {?}
         */

      }, {
        key: "backdropElement",
        get: function get() {
          return this._backdropElement;
        }
        /**
         * Wrapper around the panel element. Can be used for advanced
         * positioning where a wrapper with specific styling is
         * required around the overlay pane.
         * @return {?}
         */

      }, {
        key: "hostElement",
        get: function get() {
          return this._host;
        }
      }]);

      return OverlayRef;
    }();

    if (false) {}
    /**
     * Size properties for an overlay.
     * @record
     */


    function OverlaySizeConfig() {}

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/position/flexible-connected-position-strategy.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */
    // TODO: refactor clipping detection into a separate thing (part of scrolling module)
    // TODO: doesn't handle both flexible width and height when it has to scroll along both axis.

    /**
     * Class to be added to the overlay bounding box.
     * @type {?}
     */


    var boundingBoxClass = 'cdk-overlay-connected-position-bounding-box';
    /**
     * Regex used to split a string on its CSS units.
     * @type {?}
     */

    var cssUnitPattern = /([A-Za-z%]+)$/;
    /**
     * A strategy for positioning overlays. Using this strategy, an overlay is given an
     * implicit position relative some origin element. The relative position is defined in terms of
     * a point on the origin element that is connected to a point on the overlay element. For example,
     * a basic dropdown is connecting the bottom-left corner of the origin to the top-left corner
     * of the overlay.
     */

    var FlexibleConnectedPositionStrategy = /*#__PURE__*/function () {
      /**
       * @param {?} connectedTo
       * @param {?} _viewportRuler
       * @param {?} _document
       * @param {?} _platform
       * @param {?} _overlayContainer
       */
      function FlexibleConnectedPositionStrategy(connectedTo, _viewportRuler, _document, _platform, _overlayContainer) {
        _classCallCheck(this, FlexibleConnectedPositionStrategy);

        this._viewportRuler = _viewportRuler;
        this._document = _document;
        this._platform = _platform;
        this._overlayContainer = _overlayContainer;
        /**
         * Last size used for the bounding box. Used to avoid resizing the overlay after open.
         */

        this._lastBoundingBoxSize = {
          width: 0,
          height: 0
        };
        /**
         * Whether the overlay was pushed in a previous positioning.
         */

        this._isPushed = false;
        /**
         * Whether the overlay can be pushed on-screen on the initial open.
         */

        this._canPush = true;
        /**
         * Whether the overlay can grow via flexible width/height after the initial open.
         */

        this._growAfterOpen = false;
        /**
         * Whether the overlay's width and height can be constrained to fit within the viewport.
         */

        this._hasFlexibleDimensions = true;
        /**
         * Whether the overlay position is locked.
         */

        this._positionLocked = false;
        /**
         * Amount of space that must be maintained between the overlay and the edge of the viewport.
         */

        this._viewportMargin = 0;
        /**
         * The Scrollable containers used to check scrollable view properties on position change.
         */

        this._scrollables = [];
        /**
         * Ordered list of preferred positions, from most to least desirable.
         */

        this._preferredPositions = [];
        /**
         * Subject that emits whenever the position changes.
         */

        this._positionChanges = new rxjs__WEBPACK_IMPORTED_MODULE_7__["Subject"]();
        /**
         * Subscription to viewport size changes.
         */

        this._resizeSubscription = rxjs__WEBPACK_IMPORTED_MODULE_7__["Subscription"].EMPTY;
        /**
         * Default offset for the overlay along the x axis.
         */

        this._offsetX = 0;
        /**
         * Default offset for the overlay along the y axis.
         */

        this._offsetY = 0;
        /**
         * Keeps track of the CSS classes that the position strategy has applied on the overlay panel.
         */

        this._appliedPanelClasses = [];
        /**
         * Observable sequence of position changes.
         */

        this.positionChanges = this._positionChanges.asObservable();
        this.setOrigin(connectedTo);
      }
      /**
       * Ordered list of preferred positions, from most to least desirable.
       * @return {?}
       */


      _createClass2(FlexibleConnectedPositionStrategy, [{
        key: "attach",

        /**
         * Attaches this position strategy to an overlay.
         * @param {?} overlayRef
         * @return {?}
         */
        value: function attach(overlayRef) {
          var _this89 = this;

          if (this._overlayRef && overlayRef !== this._overlayRef) {
            throw Error('This position strategy is already attached to an overlay');
          }

          this._validatePositions();

          overlayRef.hostElement.classList.add(boundingBoxClass);
          this._overlayRef = overlayRef;
          this._boundingBox = overlayRef.hostElement;
          this._pane = overlayRef.overlayElement;
          this._isDisposed = false;
          this._isInitialRender = true;
          this._lastPosition = null;

          this._resizeSubscription.unsubscribe();

          this._resizeSubscription = this._viewportRuler.change().subscribe(
          /**
          * @return {?}
          */
          function () {
            // When the window is resized, we want to trigger the next reposition as if it
            // was an initial render, in order for the strategy to pick a new optimal position,
            // otherwise position locking will cause it to stay at the old one.
            _this89._isInitialRender = true;

            _this89.apply();
          });
        }
        /**
         * Updates the position of the overlay element, using whichever preferred position relative
         * to the origin best fits on-screen.
         *
         * The selection of a position goes as follows:
         *  - If any positions fit completely within the viewport as-is,
         *      choose the first position that does so.
         *  - If flexible dimensions are enabled and at least one satifies the given minimum width/height,
         *      choose the position with the greatest available size modified by the positions' weight.
         *  - If pushing is enabled, take the position that went off-screen the least and push it
         *      on-screen.
         *  - If none of the previous criteria were met, use the position that goes off-screen the least.
         * \@docs-private
         * @return {?}
         */

      }, {
        key: "apply",
        value: function apply() {
          // We shouldn't do anything if the strategy was disposed or we're on the server.
          if (this._isDisposed || !this._platform.isBrowser) {
            return;
          } // If the position has been applied already (e.g. when the overlay was opened) and the
          // consumer opted into locking in the position, re-use the old position, in order to
          // prevent the overlay from jumping around.


          if (!this._isInitialRender && this._positionLocked && this._lastPosition) {
            this.reapplyLastPosition();
            return;
          }

          this._clearPanelClasses();

          this._resetOverlayElementStyles();

          this._resetBoundingBoxStyles(); // We need the bounding rects for the origin and the overlay to determine how to position
          // the overlay relative to the origin.
          // We use the viewport rect to determine whether a position would go off-screen.


          this._viewportRect = this._getNarrowedViewportRect();
          this._originRect = this._getOriginRect();
          this._overlayRect = this._pane.getBoundingClientRect();
          /** @type {?} */

          var originRect = this._originRect;
          /** @type {?} */

          var overlayRect = this._overlayRect;
          /** @type {?} */

          var viewportRect = this._viewportRect; // Positions where the overlay will fit with flexible dimensions.

          /** @type {?} */

          var flexibleFits = []; // Fallback if none of the preferred positions fit within the viewport.

          /** @type {?} */

          var fallback; // Go through each of the preferred positions looking for a good fit.
          // If a good fit is found, it will be applied immediately.

          var _iterator3 = _createForOfIteratorHelper(this._preferredPositions),
              _step3;

          try {
            for (_iterator3.s(); !(_step3 = _iterator3.n()).done;) {
              var pos = _step3.value;

              // Get the exact (x, y) coordinate for the point-of-origin on the origin element.

              /** @type {?} */
              var originPoint = this._getOriginPoint(originRect, pos); // From that point-of-origin, get the exact (x, y) coordinate for the top-left corner of the
              // overlay in this position. We use the top-left corner for calculations and later translate
              // this into an appropriate (top, left, bottom, right) style.

              /** @type {?} */


              var overlayPoint = this._getOverlayPoint(originPoint, overlayRect, pos); // Calculate how well the overlay would fit into the viewport with this point.

              /** @type {?} */


              var overlayFit = this._getOverlayFit(overlayPoint, overlayRect, viewportRect, pos); // If the overlay, without any further work, fits into the viewport, use this position.


              if (overlayFit.isCompletelyWithinViewport) {
                this._isPushed = false;

                this._applyPosition(pos, originPoint);

                return;
              } // If the overlay has flexible dimensions, we can use this position
              // so long as there's enough space for the minimum dimensions.


              if (this._canFitWithFlexibleDimensions(overlayFit, overlayPoint, viewportRect)) {
                // Save positions where the overlay will fit with flexible dimensions. We will use these
                // if none of the positions fit *without* flexible dimensions.
                flexibleFits.push({
                  position: pos,
                  origin: originPoint,
                  overlayRect: overlayRect,
                  boundingBoxRect: this._calculateBoundingBoxRect(originPoint, pos)
                });
                continue;
              } // If the current preferred position does not fit on the screen, remember the position
              // if it has more visible area on-screen than we've seen and move onto the next preferred
              // position.


              if (!fallback || fallback.overlayFit.visibleArea < overlayFit.visibleArea) {
                fallback = {
                  overlayFit: overlayFit,
                  overlayPoint: overlayPoint,
                  originPoint: originPoint,
                  position: pos,
                  overlayRect: overlayRect
                };
              }
            } // If there are any positions where the overlay would fit with flexible dimensions, choose the
            // one that has the greatest area available modified by the position's weight

          } catch (err) {
            _iterator3.e(err);
          } finally {
            _iterator3.f();
          }

          if (flexibleFits.length) {
            /** @type {?} */
            var bestFit = null;
            /** @type {?} */

            var bestScore = -1;

            var _iterator4 = _createForOfIteratorHelper(flexibleFits),
                _step4;

            try {
              for (_iterator4.s(); !(_step4 = _iterator4.n()).done;) {
                var fit = _step4.value;

                /** @type {?} */
                var score = fit.boundingBoxRect.width * fit.boundingBoxRect.height * (fit.position.weight || 1);

                if (score > bestScore) {
                  bestScore = score;
                  bestFit = fit;
                }
              }
            } catch (err) {
              _iterator4.e(err);
            } finally {
              _iterator4.f();
            }

            this._isPushed = false;

            this._applyPosition(
            /** @type {?} */
            bestFit.position,
            /** @type {?} */
            bestFit.origin);

            return;
          } // When none of the preferred positions fit within the viewport, take the position
          // that went off-screen the least and attempt to push it on-screen.


          if (this._canPush) {
            // TODO(jelbourn): after pushing, the opening "direction" of the overlay might not make sense.
            this._isPushed = true;

            this._applyPosition(
            /** @type {?} */
            fallback.position,
            /** @type {?} */
            fallback.originPoint);

            return;
          } // All options for getting the overlay within the viewport have been exhausted, so go with the
          // position that went off-screen the least.


          this._applyPosition(
          /** @type {?} */
          fallback.position,
          /** @type {?} */
          fallback.originPoint);
        }
        /**
         * @return {?}
         */

      }, {
        key: "detach",
        value: function detach() {
          this._clearPanelClasses();

          this._lastPosition = null;
          this._previousPushAmount = null;

          this._resizeSubscription.unsubscribe();
        }
        /**
         * Cleanup after the element gets destroyed.
         * @return {?}
         */

      }, {
        key: "dispose",
        value: function dispose() {
          if (this._isDisposed) {
            return;
          } // We can't use `_resetBoundingBoxStyles` here, because it resets
          // some properties to zero, rather than removing them.


          if (this._boundingBox) {
            extendStyles(this._boundingBox.style,
            /** @type {?} */
            {
              top: '',
              left: '',
              right: '',
              bottom: '',
              height: '',
              width: '',
              alignItems: '',
              justifyContent: ''
            });
          }

          if (this._pane) {
            this._resetOverlayElementStyles();
          }

          if (this._overlayRef) {
            this._overlayRef.hostElement.classList.remove(boundingBoxClass);
          }

          this.detach();

          this._positionChanges.complete();

          this._overlayRef = this._boundingBox =
          /** @type {?} */
          null;
          this._isDisposed = true;
        }
        /**
         * This re-aligns the overlay element with the trigger in its last calculated position,
         * even if a position higher in the "preferred positions" list would now fit. This
         * allows one to re-align the panel without changing the orientation of the panel.
         * @return {?}
         */

      }, {
        key: "reapplyLastPosition",
        value: function reapplyLastPosition() {
          if (!this._isDisposed && (!this._platform || this._platform.isBrowser)) {
            this._originRect = this._getOriginRect();
            this._overlayRect = this._pane.getBoundingClientRect();
            this._viewportRect = this._getNarrowedViewportRect();
            /** @type {?} */

            var lastPosition = this._lastPosition || this._preferredPositions[0];
            /** @type {?} */

            var originPoint = this._getOriginPoint(this._originRect, lastPosition);

            this._applyPosition(lastPosition, originPoint);
          }
        }
        /**
         * Sets the list of Scrollable containers that host the origin element so that
         * on reposition we can evaluate if it or the overlay has been clipped or outside view. Every
         * Scrollable must be an ancestor element of the strategy's origin element.
         * @template THIS
         * @this {THIS}
         * @param {?} scrollables
         * @return {THIS}
         */

      }, {
        key: "withScrollableContainers",
        value: function withScrollableContainers(scrollables) {
          /** @type {?} */
          this._scrollables = scrollables;
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Adds new preferred positions.
         * @template THIS
         * @this {THIS}
         * @param {?} positions List of positions options for this overlay.
         * @return {THIS}
         */

      }, {
        key: "withPositions",
        value: function withPositions(positions) {
          /** @type {?} */
          this._preferredPositions = positions; // If the last calculated position object isn't part of the positions anymore, clear
          // it in order to avoid it being picked up if the consumer tries to re-apply.

          if (positions.indexOf(
          /** @type {?} */

          /** @type {?} */
          this._lastPosition) === -1) {
            /** @type {?} */
            this._lastPosition = null;
          }

          /** @type {?} */
          this._validatePositions();

          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Sets a minimum distance the overlay may be positioned to the edge of the viewport.
         * @template THIS
         * @this {THIS}
         * @param {?} margin Required margin between the overlay and the viewport edge in pixels.
         * @return {THIS}
         */

      }, {
        key: "withViewportMargin",
        value: function withViewportMargin(margin) {
          /** @type {?} */
          this._viewportMargin = margin;
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Sets whether the overlay's width and height can be constrained to fit within the viewport.
         * @template THIS
         * @this {THIS}
         * @param {?=} flexibleDimensions
         * @return {THIS}
         */

      }, {
        key: "withFlexibleDimensions",
        value: function withFlexibleDimensions() {
          var flexibleDimensions = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;

          /** @type {?} */
          this._hasFlexibleDimensions = flexibleDimensions;
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Sets whether the overlay can grow after the initial open via flexible width/height.
         * @template THIS
         * @this {THIS}
         * @param {?=} growAfterOpen
         * @return {THIS}
         */

      }, {
        key: "withGrowAfterOpen",
        value: function withGrowAfterOpen() {
          var growAfterOpen = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;

          /** @type {?} */
          this._growAfterOpen = growAfterOpen;
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Sets whether the overlay can be pushed on-screen if none of the provided positions fit.
         * @template THIS
         * @this {THIS}
         * @param {?=} canPush
         * @return {THIS}
         */

      }, {
        key: "withPush",
        value: function withPush() {
          var canPush = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;

          /** @type {?} */
          this._canPush = canPush;
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Sets whether the overlay's position should be locked in after it is positioned
         * initially. When an overlay is locked in, it won't attempt to reposition itself
         * when the position is re-applied (e.g. when the user scrolls away).
         * @template THIS
         * @this {THIS}
         * @param {?=} isLocked Whether the overlay should locked in.
         * @return {THIS}
         */

      }, {
        key: "withLockedPosition",
        value: function withLockedPosition() {
          var isLocked = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;

          /** @type {?} */
          this._positionLocked = isLocked;
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Sets the origin, relative to which to position the overlay.
         * Using an element origin is useful for building components that need to be positioned
         * relatively to a trigger (e.g. dropdown menus or tooltips), whereas using a point can be
         * used for cases like contextual menus which open relative to the user's pointer.
         * @template THIS
         * @this {THIS}
         * @param {?} origin Reference to the new origin.
         * @return {THIS}
         */

      }, {
        key: "setOrigin",
        value: function setOrigin(origin) {
          /** @type {?} */
          this._origin = origin;
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Sets the default offset for the overlay's connection point on the x-axis.
         * @template THIS
         * @this {THIS}
         * @param {?} offset New offset in the X axis.
         * @return {THIS}
         */

      }, {
        key: "withDefaultOffsetX",
        value: function withDefaultOffsetX(offset) {
          /** @type {?} */
          this._offsetX = offset;
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Sets the default offset for the overlay's connection point on the y-axis.
         * @template THIS
         * @this {THIS}
         * @param {?} offset New offset in the Y axis.
         * @return {THIS}
         */

      }, {
        key: "withDefaultOffsetY",
        value: function withDefaultOffsetY(offset) {
          /** @type {?} */
          this._offsetY = offset;
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Configures that the position strategy should set a `transform-origin` on some elements
         * inside the overlay, depending on the current position that is being applied. This is
         * useful for the cases where the origin of an animation can change depending on the
         * alignment of the overlay.
         * @template THIS
         * @this {THIS}
         * @param {?} selector CSS selector that will be used to find the target
         *    elements onto which to set the transform origin.
         * @return {THIS}
         */

      }, {
        key: "withTransformOriginOn",
        value: function withTransformOriginOn(selector) {
          /** @type {?} */
          this._transformOriginSelector = selector;
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Gets the (x, y) coordinate of a connection point on the origin based on a relative position.
         * @private
         * @param {?} originRect
         * @param {?} pos
         * @return {?}
         */

      }, {
        key: "_getOriginPoint",
        value: function _getOriginPoint(originRect, pos) {
          /** @type {?} */
          var x;

          if (pos.originX == 'center') {
            // Note: when centering we should always use the `left`
            // offset, otherwise the position will be wrong in RTL.
            x = originRect.left + originRect.width / 2;
          } else {
            /** @type {?} */
            var startX = this._isRtl() ? originRect.right : originRect.left;
            /** @type {?} */

            var endX = this._isRtl() ? originRect.left : originRect.right;
            x = pos.originX == 'start' ? startX : endX;
          }
          /** @type {?} */


          var y;

          if (pos.originY == 'center') {
            y = originRect.top + originRect.height / 2;
          } else {
            y = pos.originY == 'top' ? originRect.top : originRect.bottom;
          }

          return {
            x: x,
            y: y
          };
        }
        /**
         * Gets the (x, y) coordinate of the top-left corner of the overlay given a given position and
         * origin point to which the overlay should be connected.
         * @private
         * @param {?} originPoint
         * @param {?} overlayRect
         * @param {?} pos
         * @return {?}
         */

      }, {
        key: "_getOverlayPoint",
        value: function _getOverlayPoint(originPoint, overlayRect, pos) {
          // Calculate the (overlayStartX, overlayStartY), the start of the
          // potential overlay position relative to the origin point.

          /** @type {?} */
          var overlayStartX;

          if (pos.overlayX == 'center') {
            overlayStartX = -overlayRect.width / 2;
          } else if (pos.overlayX === 'start') {
            overlayStartX = this._isRtl() ? -overlayRect.width : 0;
          } else {
            overlayStartX = this._isRtl() ? 0 : -overlayRect.width;
          }
          /** @type {?} */


          var overlayStartY;

          if (pos.overlayY == 'center') {
            overlayStartY = -overlayRect.height / 2;
          } else {
            overlayStartY = pos.overlayY == 'top' ? 0 : -overlayRect.height;
          } // The (x, y) coordinates of the overlay.


          return {
            x: originPoint.x + overlayStartX,
            y: originPoint.y + overlayStartY
          };
        }
        /**
         * Gets how well an overlay at the given point will fit within the viewport.
         * @private
         * @param {?} point
         * @param {?} overlay
         * @param {?} viewport
         * @param {?} position
         * @return {?}
         */

      }, {
        key: "_getOverlayFit",
        value: function _getOverlayFit(point, overlay, viewport, position) {
          var x = point.x,
              y = point.y;
          /** @type {?} */

          var offsetX = this._getOffset(position, 'x');
          /** @type {?} */


          var offsetY = this._getOffset(position, 'y'); // Account for the offsets since they could push the overlay out of the viewport.


          if (offsetX) {
            x += offsetX;
          }

          if (offsetY) {
            y += offsetY;
          } // How much the overlay would overflow at this position, on each side.

          /** @type {?} */


          var leftOverflow = 0 - x;
          /** @type {?} */

          var rightOverflow = x + overlay.width - viewport.width;
          /** @type {?} */

          var topOverflow = 0 - y;
          /** @type {?} */

          var bottomOverflow = y + overlay.height - viewport.height; // Visible parts of the element on each axis.

          /** @type {?} */

          var visibleWidth = this._subtractOverflows(overlay.width, leftOverflow, rightOverflow);
          /** @type {?} */


          var visibleHeight = this._subtractOverflows(overlay.height, topOverflow, bottomOverflow);
          /** @type {?} */


          var visibleArea = visibleWidth * visibleHeight;
          return {
            visibleArea: visibleArea,
            isCompletelyWithinViewport: overlay.width * overlay.height === visibleArea,
            fitsInViewportVertically: visibleHeight === overlay.height,
            fitsInViewportHorizontally: visibleWidth == overlay.width
          };
        }
        /**
         * Whether the overlay can fit within the viewport when it may resize either its width or height.
         * @private
         * @param {?} fit How well the overlay fits in the viewport at some position.
         * @param {?} point The (x, y) coordinates of the overlat at some position.
         * @param {?} viewport The geometry of the viewport.
         * @return {?}
         */

      }, {
        key: "_canFitWithFlexibleDimensions",
        value: function _canFitWithFlexibleDimensions(fit, point, viewport) {
          if (this._hasFlexibleDimensions) {
            /** @type {?} */
            var availableHeight = viewport.bottom - point.y;
            /** @type {?} */

            var availableWidth = viewport.right - point.x;
            /** @type {?} */

            var minHeight = getPixelValue(this._overlayRef.getConfig().minHeight);
            /** @type {?} */

            var minWidth = getPixelValue(this._overlayRef.getConfig().minWidth);
            /** @type {?} */

            var verticalFit = fit.fitsInViewportVertically || minHeight != null && minHeight <= availableHeight;
            /** @type {?} */

            var horizontalFit = fit.fitsInViewportHorizontally || minWidth != null && minWidth <= availableWidth;
            return verticalFit && horizontalFit;
          }

          return false;
        }
        /**
         * Gets the point at which the overlay can be "pushed" on-screen. If the overlay is larger than
         * the viewport, the top-left corner will be pushed on-screen (with overflow occuring on the
         * right and bottom).
         *
         * @private
         * @param {?} start Starting point from which the overlay is pushed.
         * @param {?} overlay Dimensions of the overlay.
         * @param {?} scrollPosition Current viewport scroll position.
         * @return {?} The point at which to position the overlay after pushing. This is effectively a new
         *     originPoint.
         */

      }, {
        key: "_pushOverlayOnScreen",
        value: function _pushOverlayOnScreen(start, overlay, scrollPosition) {
          // If the position is locked and we've pushed the overlay already, reuse the previous push
          // amount, rather than pushing it again. If we were to continue pushing, the element would
          // remain in the viewport, which goes against the expectations when position locking is enabled.
          if (this._previousPushAmount && this._positionLocked) {
            return {
              x: start.x + this._previousPushAmount.x,
              y: start.y + this._previousPushAmount.y
            };
          }
          /** @type {?} */


          var viewport = this._viewportRect; // Determine how much the overlay goes outside the viewport on each
          // side, which we'll use to decide which direction to push it.

          /** @type {?} */

          var overflowRight = Math.max(start.x + overlay.width - viewport.right, 0);
          /** @type {?} */

          var overflowBottom = Math.max(start.y + overlay.height - viewport.bottom, 0);
          /** @type {?} */

          var overflowTop = Math.max(viewport.top - scrollPosition.top - start.y, 0);
          /** @type {?} */

          var overflowLeft = Math.max(viewport.left - scrollPosition.left - start.x, 0); // Amount by which to push the overlay in each axis such that it remains on-screen.

          /** @type {?} */

          var pushX = 0;
          /** @type {?} */

          var pushY = 0; // If the overlay fits completely within the bounds of the viewport, push it from whichever
          // direction is goes off-screen. Otherwise, push the top-left corner such that its in the
          // viewport and allow for the trailing end of the overlay to go out of bounds.

          if (overlay.width <= viewport.width) {
            pushX = overflowLeft || -overflowRight;
          } else {
            pushX = start.x < this._viewportMargin ? viewport.left - scrollPosition.left - start.x : 0;
          }

          if (overlay.height <= viewport.height) {
            pushY = overflowTop || -overflowBottom;
          } else {
            pushY = start.y < this._viewportMargin ? viewport.top - scrollPosition.top - start.y : 0;
          }

          this._previousPushAmount = {
            x: pushX,
            y: pushY
          };
          return {
            x: start.x + pushX,
            y: start.y + pushY
          };
        }
        /**
         * Applies a computed position to the overlay and emits a position change.
         * @private
         * @param {?} position The position preference
         * @param {?} originPoint The point on the origin element where the overlay is connected.
         * @return {?}
         */

      }, {
        key: "_applyPosition",
        value: function _applyPosition(position, originPoint) {
          this._setTransformOrigin(position);

          this._setOverlayElementStyles(originPoint, position);

          this._setBoundingBoxStyles(originPoint, position);

          if (position.panelClass) {
            this._addPanelClasses(position.panelClass);
          } // Save the last connected position in case the position needs to be re-calculated.


          this._lastPosition = position; // Notify that the position has been changed along with its change properties.
          // We only emit if we've got any subscriptions, because the scroll visibility
          // calculcations can be somewhat expensive.

          if (this._positionChanges.observers.length) {
            /** @type {?} */
            var scrollableViewProperties = this._getScrollVisibility();
            /** @type {?} */


            var changeEvent = new ConnectedOverlayPositionChange(position, scrollableViewProperties);

            this._positionChanges.next(changeEvent);
          }

          this._isInitialRender = false;
        }
        /**
         * Sets the transform origin based on the configured selector and the passed-in position.
         * @private
         * @param {?} position
         * @return {?}
         */

      }, {
        key: "_setTransformOrigin",
        value: function _setTransformOrigin(position) {
          if (!this._transformOriginSelector) {
            return;
          }
          /** @type {?} */


          var elements =
          /** @type {?} */
          this._boundingBox.querySelectorAll(this._transformOriginSelector);
          /** @type {?} */


          var xOrigin;
          /** @type {?} */

          var yOrigin = position.overlayY;

          if (position.overlayX === 'center') {
            xOrigin = 'center';
          } else if (this._isRtl()) {
            xOrigin = position.overlayX === 'start' ? 'right' : 'left';
          } else {
            xOrigin = position.overlayX === 'start' ? 'left' : 'right';
          }

          for (var i = 0; i < elements.length; i++) {
            elements[i].style.transformOrigin = "".concat(xOrigin, " ").concat(yOrigin);
          }
        }
        /**
         * Gets the position and size of the overlay's sizing container.
         *
         * This method does no measuring and applies no styles so that we can cheaply compute the
         * bounds for all positions and choose the best fit based on these results.
         * @private
         * @param {?} origin
         * @param {?} position
         * @return {?}
         */

      }, {
        key: "_calculateBoundingBoxRect",
        value: function _calculateBoundingBoxRect(origin, position) {
          /** @type {?} */
          var viewport = this._viewportRect;
          /** @type {?} */

          var isRtl = this._isRtl();
          /** @type {?} */


          var height;
          /** @type {?} */

          var top;
          /** @type {?} */

          var bottom;

          if (position.overlayY === 'top') {
            // Overlay is opening "downward" and thus is bound by the bottom viewport edge.
            top = origin.y;
            height = viewport.height - top + this._viewportMargin;
          } else if (position.overlayY === 'bottom') {
            // Overlay is opening "upward" and thus is bound by the top viewport edge. We need to add
            // the viewport margin back in, because the viewport rect is narrowed down to remove the
            // margin, whereas the `origin` position is calculated based on its `ClientRect`.
            bottom = viewport.height - origin.y + this._viewportMargin * 2;
            height = viewport.height - bottom + this._viewportMargin;
          } else {
            // If neither top nor bottom, it means that the overlay is vertically centered on the
            // origin point. Note that we want the position relative to the viewport, rather than
            // the page, which is why we don't use something like `viewport.bottom - origin.y` and
            // `origin.y - viewport.top`.

            /** @type {?} */
            var smallestDistanceToViewportEdge = Math.min(viewport.bottom - origin.y + viewport.top, origin.y);
            /** @type {?} */

            var previousHeight = this._lastBoundingBoxSize.height;
            height = smallestDistanceToViewportEdge * 2;
            top = origin.y - smallestDistanceToViewportEdge;

            if (height > previousHeight && !this._isInitialRender && !this._growAfterOpen) {
              top = origin.y - previousHeight / 2;
            }
          } // The overlay is opening 'right-ward' (the content flows to the right).

          /** @type {?} */


          var isBoundedByRightViewportEdge = position.overlayX === 'start' && !isRtl || position.overlayX === 'end' && isRtl; // The overlay is opening 'left-ward' (the content flows to the left).

          /** @type {?} */

          var isBoundedByLeftViewportEdge = position.overlayX === 'end' && !isRtl || position.overlayX === 'start' && isRtl;
          /** @type {?} */

          var width;
          /** @type {?} */

          var left;
          /** @type {?} */

          var right;

          if (isBoundedByLeftViewportEdge) {
            right = viewport.width - origin.x + this._viewportMargin;
            width = origin.x - this._viewportMargin;
          } else if (isBoundedByRightViewportEdge) {
            left = origin.x;
            width = viewport.right - origin.x;
          } else {
            // If neither start nor end, it means that the overlay is horizontally centered on the
            // origin point. Note that we want the position relative to the viewport, rather than
            // the page, which is why we don't use something like `viewport.right - origin.x` and
            // `origin.x - viewport.left`.

            /** @type {?} */
            var _smallestDistanceToViewportEdge = Math.min(viewport.right - origin.x + viewport.left, origin.x);
            /** @type {?} */


            var previousWidth = this._lastBoundingBoxSize.width;
            width = _smallestDistanceToViewportEdge * 2;
            left = origin.x - _smallestDistanceToViewportEdge;

            if (width > previousWidth && !this._isInitialRender && !this._growAfterOpen) {
              left = origin.x - previousWidth / 2;
            }
          }

          return {
            top:
            /** @type {?} */
            top,
            left:
            /** @type {?} */
            left,
            bottom:
            /** @type {?} */
            bottom,
            right:
            /** @type {?} */
            right,
            width: width,
            height: height
          };
        }
        /**
         * Sets the position and size of the overlay's sizing wrapper. The wrapper is positioned on the
         * origin's connection point and stetches to the bounds of the viewport.
         *
         * @private
         * @param {?} origin The point on the origin element where the overlay is connected.
         * @param {?} position The position preference
         * @return {?}
         */

      }, {
        key: "_setBoundingBoxStyles",
        value: function _setBoundingBoxStyles(origin, position) {
          /** @type {?} */
          var boundingBoxRect = this._calculateBoundingBoxRect(origin, position); // It's weird if the overlay *grows* while scrolling, so we take the last size into account
          // when applying a new size.


          if (!this._isInitialRender && !this._growAfterOpen) {
            boundingBoxRect.height = Math.min(boundingBoxRect.height, this._lastBoundingBoxSize.height);
            boundingBoxRect.width = Math.min(boundingBoxRect.width, this._lastBoundingBoxSize.width);
          }
          /** @type {?} */


          var styles =
          /** @type {?} */
          {};

          if (this._hasExactPosition()) {
            styles.top = styles.left = '0';
            styles.bottom = styles.right = styles.maxHeight = styles.maxWidth = '';
            styles.width = styles.height = '100%';
          } else {
            /** @type {?} */
            var maxHeight = this._overlayRef.getConfig().maxHeight;
            /** @type {?} */


            var maxWidth = this._overlayRef.getConfig().maxWidth;

            styles.height = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceCssPixelValue"])(boundingBoxRect.height);
            styles.top = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceCssPixelValue"])(boundingBoxRect.top);
            styles.bottom = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceCssPixelValue"])(boundingBoxRect.bottom);
            styles.width = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceCssPixelValue"])(boundingBoxRect.width);
            styles.left = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceCssPixelValue"])(boundingBoxRect.left);
            styles.right = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceCssPixelValue"])(boundingBoxRect.right); // Push the pane content towards the proper direction.

            if (position.overlayX === 'center') {
              styles.alignItems = 'center';
            } else {
              styles.alignItems = position.overlayX === 'end' ? 'flex-end' : 'flex-start';
            }

            if (position.overlayY === 'center') {
              styles.justifyContent = 'center';
            } else {
              styles.justifyContent = position.overlayY === 'bottom' ? 'flex-end' : 'flex-start';
            }

            if (maxHeight) {
              styles.maxHeight = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceCssPixelValue"])(maxHeight);
            }

            if (maxWidth) {
              styles.maxWidth = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceCssPixelValue"])(maxWidth);
            }
          }

          this._lastBoundingBoxSize = boundingBoxRect;
          extendStyles(
          /** @type {?} */
          this._boundingBox.style, styles);
        }
        /**
         * Resets the styles for the bounding box so that a new positioning can be computed.
         * @private
         * @return {?}
         */

      }, {
        key: "_resetBoundingBoxStyles",
        value: function _resetBoundingBoxStyles() {
          extendStyles(
          /** @type {?} */
          this._boundingBox.style,
          /** @type {?} */
          {
            top: '0',
            left: '0',
            right: '0',
            bottom: '0',
            height: '',
            width: '',
            alignItems: '',
            justifyContent: ''
          });
        }
        /**
         * Resets the styles for the overlay pane so that a new positioning can be computed.
         * @private
         * @return {?}
         */

      }, {
        key: "_resetOverlayElementStyles",
        value: function _resetOverlayElementStyles() {
          extendStyles(this._pane.style,
          /** @type {?} */
          {
            top: '',
            left: '',
            bottom: '',
            right: '',
            position: '',
            transform: ''
          });
        }
        /**
         * Sets positioning styles to the overlay element.
         * @private
         * @param {?} originPoint
         * @param {?} position
         * @return {?}
         */

      }, {
        key: "_setOverlayElementStyles",
        value: function _setOverlayElementStyles(originPoint, position) {
          /** @type {?} */
          var styles =
          /** @type {?} */
          {};
          /** @type {?} */

          var hasExactPosition = this._hasExactPosition();
          /** @type {?} */


          var hasFlexibleDimensions = this._hasFlexibleDimensions;
          /** @type {?} */

          var config = this._overlayRef.getConfig();

          if (hasExactPosition) {
            /** @type {?} */
            var scrollPosition = this._viewportRuler.getViewportScrollPosition();

            extendStyles(styles, this._getExactOverlayY(position, originPoint, scrollPosition));
            extendStyles(styles, this._getExactOverlayX(position, originPoint, scrollPosition));
          } else {
            styles.position = 'static';
          } // Use a transform to apply the offsets. We do this because the `center` positions rely on
          // being in the normal flex flow and setting a `top` / `left` at all will completely throw
          // off the position. We also can't use margins, because they won't have an effect in some
          // cases where the element doesn't have anything to "push off of". Finally, this works
          // better both with flexible and non-flexible positioning.

          /** @type {?} */


          var transformString = '';
          /** @type {?} */

          var offsetX = this._getOffset(position, 'x');
          /** @type {?} */


          var offsetY = this._getOffset(position, 'y');

          if (offsetX) {
            transformString += "translateX(".concat(offsetX, "px) ");
          }

          if (offsetY) {
            transformString += "translateY(".concat(offsetY, "px)");
          }

          styles.transform = transformString.trim(); // If a maxWidth or maxHeight is specified on the overlay, we remove them. We do this because
          // we need these values to both be set to "100%" for the automatic flexible sizing to work.
          // The maxHeight and maxWidth are set on the boundingBox in order to enforce the constraint.
          // Note that this doesn't apply when we have an exact position, in which case we do want to
          // apply them because they'll be cleared from the bounding box.

          if (config.maxHeight) {
            if (hasExactPosition) {
              styles.maxHeight = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceCssPixelValue"])(config.maxHeight);
            } else if (hasFlexibleDimensions) {
              styles.maxHeight = '';
            }
          }

          if (config.maxWidth) {
            if (hasExactPosition) {
              styles.maxWidth = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceCssPixelValue"])(config.maxWidth);
            } else if (hasFlexibleDimensions) {
              styles.maxWidth = '';
            }
          }

          extendStyles(this._pane.style, styles);
        }
        /**
         * Gets the exact top/bottom for the overlay when not using flexible sizing or when pushing.
         * @private
         * @param {?} position
         * @param {?} originPoint
         * @param {?} scrollPosition
         * @return {?}
         */

      }, {
        key: "_getExactOverlayY",
        value: function _getExactOverlayY(position, originPoint, scrollPosition) {
          // Reset any existing styles. This is necessary in case the
          // preferred position has changed since the last `apply`.

          /** @type {?} */
          var styles =
          /** @type {?} */
          {
            top: '',
            bottom: ''
          };
          /** @type {?} */

          var overlayPoint = this._getOverlayPoint(originPoint, this._overlayRect, position);

          if (this._isPushed) {
            overlayPoint = this._pushOverlayOnScreen(overlayPoint, this._overlayRect, scrollPosition);
          }
          /** @type {?} */


          var virtualKeyboardOffset = this._overlayContainer.getContainerElement().getBoundingClientRect().top; // Normally this would be zero, however when the overlay is attached to an input (e.g. in an
          // autocomplete), mobile browsers will shift everything in order to put the input in the middle
          // of the screen and to make space for the virtual keyboard. We need to account for this offset,
          // otherwise our positioning will be thrown off.


          overlayPoint.y -= virtualKeyboardOffset; // We want to set either `top` or `bottom` based on whether the overlay wants to appear
          // above or below the origin and the direction in which the element will expand.

          if (position.overlayY === 'bottom') {
            // When using `bottom`, we adjust the y position such that it is the distance
            // from the bottom of the viewport rather than the top.

            /** @type {?} */
            var documentHeight =
            /** @type {?} */
            this._document.documentElement.clientHeight;
            styles.bottom = "".concat(documentHeight - (overlayPoint.y + this._overlayRect.height), "px");
          } else {
            styles.top = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceCssPixelValue"])(overlayPoint.y);
          }

          return styles;
        }
        /**
         * Gets the exact left/right for the overlay when not using flexible sizing or when pushing.
         * @private
         * @param {?} position
         * @param {?} originPoint
         * @param {?} scrollPosition
         * @return {?}
         */

      }, {
        key: "_getExactOverlayX",
        value: function _getExactOverlayX(position, originPoint, scrollPosition) {
          // Reset any existing styles. This is necessary in case the preferred position has
          // changed since the last `apply`.

          /** @type {?} */
          var styles =
          /** @type {?} */
          {
            left: '',
            right: ''
          };
          /** @type {?} */

          var overlayPoint = this._getOverlayPoint(originPoint, this._overlayRect, position);

          if (this._isPushed) {
            overlayPoint = this._pushOverlayOnScreen(overlayPoint, this._overlayRect, scrollPosition);
          } // We want to set either `left` or `right` based on whether the overlay wants to appear "before"
          // or "after" the origin, which determines the direction in which the element will expand.
          // For the horizontal axis, the meaning of "before" and "after" change based on whether the
          // page is in RTL or LTR.

          /** @type {?} */


          var horizontalStyleProperty;

          if (this._isRtl()) {
            horizontalStyleProperty = position.overlayX === 'end' ? 'left' : 'right';
          } else {
            horizontalStyleProperty = position.overlayX === 'end' ? 'right' : 'left';
          } // When we're setting `right`, we adjust the x position such that it is the distance
          // from the right edge of the viewport rather than the left edge.


          if (horizontalStyleProperty === 'right') {
            /** @type {?} */
            var documentWidth =
            /** @type {?} */
            this._document.documentElement.clientWidth;
            styles.right = "".concat(documentWidth - (overlayPoint.x + this._overlayRect.width), "px");
          } else {
            styles.left = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceCssPixelValue"])(overlayPoint.x);
          }

          return styles;
        }
        /**
         * Gets the view properties of the trigger and overlay, including whether they are clipped
         * or completely outside the view of any of the strategy's scrollables.
         * @private
         * @return {?}
         */

      }, {
        key: "_getScrollVisibility",
        value: function _getScrollVisibility() {
          // Note: needs fresh rects since the position could've changed.

          /** @type {?} */
          var originBounds = this._getOriginRect();
          /** @type {?} */


          var overlayBounds = this._pane.getBoundingClientRect(); // TODO(jelbourn): instead of needing all of the client rects for these scrolling containers
          // every time, we should be able to use the scrollTop of the containers if the size of those
          // containers hasn't changed.

          /** @type {?} */


          var scrollContainerBounds = this._scrollables.map(
          /**
          * @param {?} scrollable
          * @return {?}
          */
          function (scrollable) {
            return scrollable.getElementRef().nativeElement.getBoundingClientRect();
          });

          return {
            isOriginClipped: isElementClippedByScrolling(originBounds, scrollContainerBounds),
            isOriginOutsideView: isElementScrolledOutsideView(originBounds, scrollContainerBounds),
            isOverlayClipped: isElementClippedByScrolling(overlayBounds, scrollContainerBounds),
            isOverlayOutsideView: isElementScrolledOutsideView(overlayBounds, scrollContainerBounds)
          };
        }
        /**
         * Subtracts the amount that an element is overflowing on an axis from its length.
         * @private
         * @param {?} length
         * @param {...?} overflows
         * @return {?}
         */

      }, {
        key: "_subtractOverflows",
        value: function _subtractOverflows(length) {
          for (var _len6 = arguments.length, overflows = new Array(_len6 > 1 ? _len6 - 1 : 0), _key7 = 1; _key7 < _len6; _key7++) {
            overflows[_key7 - 1] = arguments[_key7];
          }

          return overflows.reduce(
          /**
          * @param {?} currentValue
          * @param {?} currentOverflow
          * @return {?}
          */
          function (currentValue, currentOverflow) {
            return currentValue - Math.max(currentOverflow, 0);
          }, length);
        }
        /**
         * Narrows the given viewport rect by the current _viewportMargin.
         * @private
         * @return {?}
         */

      }, {
        key: "_getNarrowedViewportRect",
        value: function _getNarrowedViewportRect() {
          // We recalculate the viewport rect here ourselves, rather than using the ViewportRuler,
          // because we want to use the `clientWidth` and `clientHeight` as the base. The difference
          // being that the client properties don't include the scrollbar, as opposed to `innerWidth`
          // and `innerHeight` that do. This is necessary, because the overlay container uses
          // 100% `width` and `height` which don't include the scrollbar either.

          /** @type {?} */
          var width =
          /** @type {?} */
          this._document.documentElement.clientWidth;
          /** @type {?} */

          var height =
          /** @type {?} */
          this._document.documentElement.clientHeight;
          /** @type {?} */

          var scrollPosition = this._viewportRuler.getViewportScrollPosition();

          return {
            top: scrollPosition.top + this._viewportMargin,
            left: scrollPosition.left + this._viewportMargin,
            right: scrollPosition.left + width - this._viewportMargin,
            bottom: scrollPosition.top + height - this._viewportMargin,
            width: width - 2 * this._viewportMargin,
            height: height - 2 * this._viewportMargin
          };
        }
        /**
         * Whether the we're dealing with an RTL context
         * @private
         * @return {?}
         */

      }, {
        key: "_isRtl",
        value: function _isRtl() {
          return this._overlayRef.getDirection() === 'rtl';
        }
        /**
         * Determines whether the overlay uses exact or flexible positioning.
         * @private
         * @return {?}
         */

      }, {
        key: "_hasExactPosition",
        value: function _hasExactPosition() {
          return !this._hasFlexibleDimensions || this._isPushed;
        }
        /**
         * Retrieves the offset of a position along the x or y axis.
         * @private
         * @param {?} position
         * @param {?} axis
         * @return {?}
         */

      }, {
        key: "_getOffset",
        value: function _getOffset(position, axis) {
          if (axis === 'x') {
            // We don't do something like `position['offset' + axis]` in
            // order to avoid breking minifiers that rename properties.
            return position.offsetX == null ? this._offsetX : position.offsetX;
          }

          return position.offsetY == null ? this._offsetY : position.offsetY;
        }
        /**
         * Validates that the current position match the expected values.
         * @private
         * @return {?}
         */

      }, {
        key: "_validatePositions",
        value: function _validatePositions() {
          if (!this._preferredPositions.length) {
            throw Error('FlexibleConnectedPositionStrategy: At least one position is required.');
          } // TODO(crisbeto): remove these once Angular's template type
          // checking is advanced enough to catch these cases.


          this._preferredPositions.forEach(
          /**
          * @param {?} pair
          * @return {?}
          */
          function (pair) {
            validateHorizontalPosition('originX', pair.originX);
            validateVerticalPosition('originY', pair.originY);
            validateHorizontalPosition('overlayX', pair.overlayX);
            validateVerticalPosition('overlayY', pair.overlayY);
          });
        }
        /**
         * Adds a single CSS class or an array of classes on the overlay panel.
         * @private
         * @param {?} cssClasses
         * @return {?}
         */

      }, {
        key: "_addPanelClasses",
        value: function _addPanelClasses(cssClasses) {
          var _this90 = this;

          if (this._pane) {
            Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceArray"])(cssClasses).forEach(
            /**
            * @param {?} cssClass
            * @return {?}
            */
            function (cssClass) {
              if (cssClass !== '' && _this90._appliedPanelClasses.indexOf(cssClass) === -1) {
                _this90._appliedPanelClasses.push(cssClass);

                _this90._pane.classList.add(cssClass);
              }
            });
          }
        }
        /**
         * Clears the classes that the position strategy has applied from the overlay panel.
         * @private
         * @return {?}
         */

      }, {
        key: "_clearPanelClasses",
        value: function _clearPanelClasses() {
          var _this91 = this;

          if (this._pane) {
            this._appliedPanelClasses.forEach(
            /**
            * @param {?} cssClass
            * @return {?}
            */
            function (cssClass) {
              _this91._pane.classList.remove(cssClass);
            });

            this._appliedPanelClasses = [];
          }
        }
        /**
         * Returns the ClientRect of the current origin.
         * @private
         * @return {?}
         */

      }, {
        key: "_getOriginRect",
        value: function _getOriginRect() {
          /** @type {?} */
          var origin = this._origin;

          if (origin instanceof _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]) {
            return origin.nativeElement.getBoundingClientRect();
          } // Check for Element so SVG elements are also supported.


          if (origin instanceof Element) {
            return origin.getBoundingClientRect();
          }
          /** @type {?} */


          var width = origin.width || 0;
          /** @type {?} */

          var height = origin.height || 0; // If the origin is a point, return a client rect as if it was a 0x0 element at the point.

          return {
            top: origin.y,
            bottom: origin.y + height,
            left: origin.x,
            right: origin.x + width,
            height: height,
            width: width
          };
        }
      }, {
        key: "positions",
        get: function get() {
          return this._preferredPositions;
        }
      }]);

      return FlexibleConnectedPositionStrategy;
    }();

    if (false) {}
    /**
     * A simple (x, y) coordinate.
     * @record
     */


    function Point() {}

    if (false) {}
    /**
     * Record of measurements for how an overlay (at a given position) fits into the viewport.
     * @record
     */


    function OverlayFit() {}

    if (false) {}
    /**
     * Record of the measurments determining whether an overlay will fit in a specific position.
     * @record
     */


    function FallbackPosition() {}

    if (false) {}
    /**
     * Position and size of the overlay sizing wrapper for a specific position.
     * @record
     */


    function BoundingBoxRect() {}

    if (false) {}
    /**
     * Record of measures determining how well a given position will fit with flexible dimensions.
     * @record
     */


    function FlexibleFit() {}

    if (false) {}
    /**
     * A connected position as specified by the user.
     * @record
     */


    function ConnectedPosition() {}

    if (false) {}
    /**
     * Shallow-extends a stylesheet object with another stylesheet object.
     * @param {?} destination
     * @param {?} source
     * @return {?}
     */


    function extendStyles(destination, source) {
      for (var key in source) {
        if (source.hasOwnProperty(key)) {
          destination[key] = source[key];
        }
      }

      return destination;
    }
    /**
     * Extracts the pixel value as a number from a value, if it's a number
     * or a CSS pixel string (e.g. `1337px`). Otherwise returns null.
     * @param {?} input
     * @return {?}
     */


    function getPixelValue(input) {
      if (typeof input !== 'number' && input != null) {
        var _input$split = input.split(cssUnitPattern),
            _input$split2 = _slicedToArray(_input$split, 2),
            value = _input$split2[0],
            units = _input$split2[1];

        return !units || units === 'px' ? parseFloat(value) : null;
      }

      return input || null;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/position/connected-position-strategy.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * A strategy for positioning overlays. Using this strategy, an overlay is given an
     * implicit position relative to some origin element. The relative position is defined in terms of
     * a point on the origin element that is connected to a point on the overlay element. For example,
     * a basic dropdown is connecting the bottom-left corner of the origin to the top-left corner
     * of the overlay.
     * @deprecated Use `FlexibleConnectedPositionStrategy` instead.
     * \@breaking-change 8.0.0
     */


    var ConnectedPositionStrategy = /*#__PURE__*/function () {
      /**
       * @param {?} originPos
       * @param {?} overlayPos
       * @param {?} connectedTo
       * @param {?} viewportRuler
       * @param {?} document
       * @param {?} platform
       * @param {?} overlayContainer
       */
      function ConnectedPositionStrategy(originPos, overlayPos, connectedTo, viewportRuler, document, platform, overlayContainer) {
        _classCallCheck(this, ConnectedPositionStrategy);

        /**
         * Ordered list of preferred positions, from most to least desirable.
         */
        this._preferredPositions = []; // Since the `ConnectedPositionStrategy` is deprecated and we don't want to maintain
        // the extra logic, we create an instance of the positioning strategy that has some
        // defaults that make it behave as the old position strategy and to which we'll
        // proxy all of the API calls.

        this._positionStrategy = new FlexibleConnectedPositionStrategy(connectedTo, viewportRuler, document, platform, overlayContainer).withFlexibleDimensions(false).withPush(false).withViewportMargin(0);
        this.withFallbackPosition(originPos, overlayPos);
      }
      /**
       * Whether the we're dealing with an RTL context
       * @return {?}
       */


      _createClass2(ConnectedPositionStrategy, [{
        key: "attach",

        /**
         * Attach this position strategy to an overlay.
         * @param {?} overlayRef
         * @return {?}
         */
        value: function attach(overlayRef) {
          this._overlayRef = overlayRef;

          this._positionStrategy.attach(overlayRef);

          if (this._direction) {
            overlayRef.setDirection(this._direction);
            this._direction = null;
          }
        }
        /**
         * Disposes all resources used by the position strategy.
         * @return {?}
         */

      }, {
        key: "dispose",
        value: function dispose() {
          this._positionStrategy.dispose();
        }
        /**
         * \@docs-private
         * @return {?}
         */

      }, {
        key: "detach",
        value: function detach() {
          this._positionStrategy.detach();
        }
        /**
         * Updates the position of the overlay element, using whichever preferred position relative
         * to the origin fits on-screen.
         * \@docs-private
         * @return {?}
         */

      }, {
        key: "apply",
        value: function apply() {
          this._positionStrategy.apply();
        }
        /**
         * Re-positions the overlay element with the trigger in its last calculated position,
         * even if a position higher in the "preferred positions" list would now fit. This
         * allows one to re-align the panel without changing the orientation of the panel.
         * @return {?}
         */

      }, {
        key: "recalculateLastPosition",
        value: function recalculateLastPosition() {
          this._positionStrategy.reapplyLastPosition();
        }
        /**
         * Sets the list of Scrollable containers that host the origin element so that
         * on reposition we can evaluate if it or the overlay has been clipped or outside view. Every
         * Scrollable must be an ancestor element of the strategy's origin element.
         * @param {?} scrollables
         * @return {?}
         */

      }, {
        key: "withScrollableContainers",
        value: function withScrollableContainers(scrollables) {
          this._positionStrategy.withScrollableContainers(scrollables);
        }
        /**
         * Adds a new preferred fallback position.
         * @template THIS
         * @this {THIS}
         * @param {?} originPos
         * @param {?} overlayPos
         * @param {?=} offsetX
         * @param {?=} offsetY
         * @return {THIS}
         */

      }, {
        key: "withFallbackPosition",
        value: function withFallbackPosition(originPos, overlayPos, offsetX, offsetY) {
          /** @type {?} */
          var position = new ConnectionPositionPair(originPos, overlayPos, offsetX, offsetY);

          /** @type {?} */
          this._preferredPositions.push(position);

          /** @type {?} */
          this._positionStrategy.withPositions(
          /** @type {?} */
          this._preferredPositions);

          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Sets the layout direction so the overlay's position can be adjusted to match.
         * @template THIS
         * @this {THIS}
         * @param {?} dir New layout direction.
         * @return {THIS}
         */

      }, {
        key: "withDirection",
        value: function withDirection(dir) {
          // Since the direction might be declared before the strategy is attached,
          // we save the value in a temporary property and we'll transfer it to the
          // overlay ref on attachment.
          if (
          /** @type {?} */
          this._overlayRef) {
            /** @type {?} */
            this._overlayRef.setDirection(dir);
          } else {
            /** @type {?} */
            this._direction = dir;
          }

          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Sets an offset for the overlay's connection point on the x-axis
         * @template THIS
         * @this {THIS}
         * @param {?} offset New offset in the X axis.
         * @return {THIS}
         */

      }, {
        key: "withOffsetX",
        value: function withOffsetX(offset) {
          /** @type {?} */
          this._positionStrategy.withDefaultOffsetX(offset);

          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Sets an offset for the overlay's connection point on the y-axis
         * @template THIS
         * @this {THIS}
         * @param {?} offset New offset in the Y axis.
         * @return {THIS}
         */

      }, {
        key: "withOffsetY",
        value: function withOffsetY(offset) {
          /** @type {?} */
          this._positionStrategy.withDefaultOffsetY(offset);

          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Sets whether the overlay's position should be locked in after it is positioned
         * initially. When an overlay is locked in, it won't attempt to reposition itself
         * when the position is re-applied (e.g. when the user scrolls away).
         * @template THIS
         * @this {THIS}
         * @param {?} isLocked Whether the overlay should locked in.
         * @return {THIS}
         */

      }, {
        key: "withLockedPosition",
        value: function withLockedPosition(isLocked) {
          /** @type {?} */
          this._positionStrategy.withLockedPosition(isLocked);

          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Overwrites the current set of positions with an array of new ones.
         * @template THIS
         * @this {THIS}
         * @param {?} positions Position pairs to be set on the strategy.
         * @return {THIS}
         */

      }, {
        key: "withPositions",
        value: function withPositions(positions) {
          /** @type {?} */
          this._preferredPositions = positions.slice();

          /** @type {?} */
          this._positionStrategy.withPositions(
          /** @type {?} */
          this._preferredPositions);

          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Sets the origin element, relative to which to position the overlay.
         * @template THIS
         * @this {THIS}
         * @param {?} origin Reference to the new origin element.
         * @return {THIS}
         */

      }, {
        key: "setOrigin",
        value: function setOrigin(origin) {
          /** @type {?} */
          this._positionStrategy.setOrigin(origin);

          return (
            /** @type {?} */
            this
          );
        }
      }, {
        key: "_isRtl",
        get: function get() {
          return this._overlayRef.getDirection() === 'rtl';
        }
        /**
         * Emits an event when the connection point changes.
         * @return {?}
         */

      }, {
        key: "onPositionChange",
        get: function get() {
          return this._positionStrategy.positionChanges;
        }
        /**
         * Ordered list of preferred positions, from most to least desirable.
         * @return {?}
         */

      }, {
        key: "positions",
        get: function get() {
          return this._preferredPositions;
        }
      }]);

      return ConnectedPositionStrategy;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/position/global-position-strategy.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Class to be added to the overlay pane wrapper.
     * @type {?}
     */


    var wrapperClass = 'cdk-global-overlay-wrapper';
    /**
     * A strategy for positioning overlays. Using this strategy, an overlay is given an
     * explicit position relative to the browser's viewport. We use flexbox, instead of
     * transforms, in order to avoid issues with subpixel rendering which can cause the
     * element to become blurry.
     */

    var GlobalPositionStrategy = /*#__PURE__*/function () {
      function GlobalPositionStrategy() {
        _classCallCheck(this, GlobalPositionStrategy);

        this._cssPosition = 'static';
        this._topOffset = '';
        this._bottomOffset = '';
        this._leftOffset = '';
        this._rightOffset = '';
        this._alignItems = '';
        this._justifyContent = '';
        this._width = '';
        this._height = '';
      }
      /**
       * @param {?} overlayRef
       * @return {?}
       */


      _createClass2(GlobalPositionStrategy, [{
        key: "attach",
        value: function attach(overlayRef) {
          /** @type {?} */
          var config = overlayRef.getConfig();
          this._overlayRef = overlayRef;

          if (this._width && !config.width) {
            overlayRef.updateSize({
              width: this._width
            });
          }

          if (this._height && !config.height) {
            overlayRef.updateSize({
              height: this._height
            });
          }

          overlayRef.hostElement.classList.add(wrapperClass);
          this._isDisposed = false;
        }
        /**
         * Sets the top position of the overlay. Clears any previously set vertical position.
         * @template THIS
         * @this {THIS}
         * @param {?=} value New top offset.
         * @return {THIS}
         */

      }, {
        key: "top",
        value: function top() {
          var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';

          /** @type {?} */
          this._bottomOffset = '';

          /** @type {?} */
          this._topOffset = value;

          /** @type {?} */
          this._alignItems = 'flex-start';
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Sets the left position of the overlay. Clears any previously set horizontal position.
         * @template THIS
         * @this {THIS}
         * @param {?=} value New left offset.
         * @return {THIS}
         */

      }, {
        key: "left",
        value: function left() {
          var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';

          /** @type {?} */
          this._rightOffset = '';

          /** @type {?} */
          this._leftOffset = value;

          /** @type {?} */
          this._justifyContent = 'flex-start';
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Sets the bottom position of the overlay. Clears any previously set vertical position.
         * @template THIS
         * @this {THIS}
         * @param {?=} value New bottom offset.
         * @return {THIS}
         */

      }, {
        key: "bottom",
        value: function bottom() {
          var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';

          /** @type {?} */
          this._topOffset = '';

          /** @type {?} */
          this._bottomOffset = value;

          /** @type {?} */
          this._alignItems = 'flex-end';
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Sets the right position of the overlay. Clears any previously set horizontal position.
         * @template THIS
         * @this {THIS}
         * @param {?=} value New right offset.
         * @return {THIS}
         */

      }, {
        key: "right",
        value: function right() {
          var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';

          /** @type {?} */
          this._leftOffset = '';

          /** @type {?} */
          this._rightOffset = value;

          /** @type {?} */
          this._justifyContent = 'flex-end';
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Sets the overlay width and clears any previously set width.
         * @deprecated Pass the `width` through the `OverlayConfig`.
         * \@breaking-change 8.0.0
         * @template THIS
         * @this {THIS}
         * @param {?=} value New width for the overlay
         * @return {THIS}
         */

      }, {
        key: "width",
        value: function width() {
          var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';

          if (
          /** @type {?} */
          this._overlayRef) {
            /** @type {?} */
            this._overlayRef.updateSize({
              width: value
            });
          } else {
            /** @type {?} */
            this._width = value;
          }

          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Sets the overlay height and clears any previously set height.
         * @deprecated Pass the `height` through the `OverlayConfig`.
         * \@breaking-change 8.0.0
         * @template THIS
         * @this {THIS}
         * @param {?=} value New height for the overlay
         * @return {THIS}
         */

      }, {
        key: "height",
        value: function height() {
          var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';

          if (
          /** @type {?} */
          this._overlayRef) {
            /** @type {?} */
            this._overlayRef.updateSize({
              height: value
            });
          } else {
            /** @type {?} */
            this._height = value;
          }

          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Centers the overlay horizontally with an optional offset.
         * Clears any previously set horizontal position.
         *
         * @template THIS
         * @this {THIS}
         * @param {?=} offset Overlay offset from the horizontal center.
         * @return {THIS}
         */

      }, {
        key: "centerHorizontally",
        value: function centerHorizontally() {
          var offset = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';

          /** @type {?} */
          this.left(offset);

          /** @type {?} */
          this._justifyContent = 'center';
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Centers the overlay vertically with an optional offset.
         * Clears any previously set vertical position.
         *
         * @template THIS
         * @this {THIS}
         * @param {?=} offset Overlay offset from the vertical center.
         * @return {THIS}
         */

      }, {
        key: "centerVertically",
        value: function centerVertically() {
          var offset = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';

          /** @type {?} */
          this.top(offset);

          /** @type {?} */
          this._alignItems = 'center';
          return (
            /** @type {?} */
            this
          );
        }
        /**
         * Apply the position to the element.
         * \@docs-private
         * @return {?}
         */

      }, {
        key: "apply",
        value: function apply() {
          // Since the overlay ref applies the strategy asynchronously, it could
          // have been disposed before it ends up being applied. If that is the
          // case, we shouldn't do anything.
          if (!this._overlayRef || !this._overlayRef.hasAttached()) {
            return;
          }
          /** @type {?} */


          var styles = this._overlayRef.overlayElement.style;
          /** @type {?} */

          var parentStyles = this._overlayRef.hostElement.style;
          /** @type {?} */

          var config = this._overlayRef.getConfig();

          var width = config.width,
              height = config.height,
              maxWidth = config.maxWidth,
              maxHeight = config.maxHeight;
          /** @type {?} */

          var shouldBeFlushHorizontally = (width === '100%' || width === '100vw') && (!maxWidth || maxWidth === '100%' || maxWidth === '100vw');
          /** @type {?} */

          var shouldBeFlushVertically = (height === '100%' || height === '100vh') && (!maxHeight || maxHeight === '100%' || maxHeight === '100vh');
          styles.position = this._cssPosition;
          styles.marginLeft = shouldBeFlushHorizontally ? '0' : this._leftOffset;
          styles.marginTop = shouldBeFlushVertically ? '0' : this._topOffset;
          styles.marginBottom = this._bottomOffset;
          styles.marginRight = this._rightOffset;

          if (shouldBeFlushHorizontally) {
            parentStyles.justifyContent = 'flex-start';
          } else if (this._justifyContent === 'center') {
            parentStyles.justifyContent = 'center';
          } else if (this._overlayRef.getConfig().direction === 'rtl') {
            // In RTL the browser will invert `flex-start` and `flex-end` automatically, but we
            // don't want that because our positioning is explicitly `left` and `right`, hence
            // why we do another inversion to ensure that the overlay stays in the same position.
            // TODO: reconsider this if we add `start` and `end` methods.
            if (this._justifyContent === 'flex-start') {
              parentStyles.justifyContent = 'flex-end';
            } else if (this._justifyContent === 'flex-end') {
              parentStyles.justifyContent = 'flex-start';
            }
          } else {
            parentStyles.justifyContent = this._justifyContent;
          }

          parentStyles.alignItems = shouldBeFlushVertically ? 'flex-start' : this._alignItems;
        }
        /**
         * Cleans up the DOM changes from the position strategy.
         * \@docs-private
         * @return {?}
         */

      }, {
        key: "dispose",
        value: function dispose() {
          if (this._isDisposed || !this._overlayRef) {
            return;
          }
          /** @type {?} */


          var styles = this._overlayRef.overlayElement.style;
          /** @type {?} */

          var parent = this._overlayRef.hostElement;
          /** @type {?} */

          var parentStyles = parent.style;
          parent.classList.remove(wrapperClass);
          parentStyles.justifyContent = parentStyles.alignItems = styles.marginTop = styles.marginBottom = styles.marginLeft = styles.marginRight = styles.position = '';
          this._overlayRef =
          /** @type {?} */
          null;
          this._isDisposed = true;
        }
      }]);

      return GlobalPositionStrategy;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/position/overlay-position-builder.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Builder for overlay position strategy.
     */


    var OverlayPositionBuilder = /*#__PURE__*/function () {
      /**
       * @param {?} _viewportRuler
       * @param {?} _document
       * @param {?} _platform
       * @param {?} _overlayContainer
       */
      function OverlayPositionBuilder(_viewportRuler, _document, _platform, _overlayContainer) {
        _classCallCheck(this, OverlayPositionBuilder);

        this._viewportRuler = _viewportRuler;
        this._document = _document;
        this._platform = _platform;
        this._overlayContainer = _overlayContainer;
      }
      /**
       * Creates a global position strategy.
       * @return {?}
       */


      _createClass2(OverlayPositionBuilder, [{
        key: "global",
        value: function global() {
          return new GlobalPositionStrategy();
        }
        /**
         * Creates a relative position strategy.
         * @deprecated Use `flexibleConnectedTo` instead.
         * \@breaking-change 8.0.0
         * @param {?} elementRef
         * @param {?} originPos
         * @param {?} overlayPos
         * @return {?}
         */

      }, {
        key: "connectedTo",
        value: function connectedTo(elementRef, originPos, overlayPos) {
          return new ConnectedPositionStrategy(originPos, overlayPos, elementRef, this._viewportRuler, this._document, this._platform, this._overlayContainer);
        }
        /**
         * Creates a flexible position strategy.
         * @param {?} origin Origin relative to which to position the overlay.
         * @return {?}
         */

      }, {
        key: "flexibleConnectedTo",
        value: function flexibleConnectedTo(origin) {
          return new FlexibleConnectedPositionStrategy(origin, this._viewportRuler, this._document, this._platform, this._overlayContainer);
        }
      }]);

      return OverlayPositionBuilder;
    }();

    OverlayPositionBuilder.ɵfac = function OverlayPositionBuilder_Factory(t) {
      return new (t || OverlayPositionBuilder)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["ViewportRuler"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_2__["Platform"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](OverlayContainer));
    };
    /** @nocollapse */


    OverlayPositionBuilder.ctorParameters = function () {
      return [{
        type: _angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["ViewportRuler"]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]]
        }]
      }, {
        type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_2__["Platform"]
      }, {
        type: OverlayContainer
      }];
    };
    /** @nocollapse */


    OverlayPositionBuilder.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: function OverlayPositionBuilder_Factory() {
        return new OverlayPositionBuilder(Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["ViewportRuler"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_2__["Platform"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(OverlayContainer));
      },
      token: OverlayPositionBuilder,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](OverlayPositionBuilder, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [{
          type: _angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["ViewportRuler"]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]]
          }]
        }, {
          type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_2__["Platform"]
        }, {
          type: OverlayContainer
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/overlay.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Next overlay unique ID.
     * @type {?}
     */


    var nextUniqueId = 0; // Note that Overlay is *not* scoped to the app root because of the ComponentFactoryResolver
    // which needs to be different depending on where OverlayModule is imported.

    /**
     * Service to create Overlays. Overlays are dynamically added pieces of floating UI, meant to be
     * used as a low-level building block for other components. Dialogs, tooltips, menus,
     * selects, etc. can all be built using overlays. The service should primarily be used by authors
     * of re-usable components rather than developers building end-user applications.
     *
     * An overlay *is* a PortalOutlet, so any kind of Portal can be loaded into one.
     */

    var Overlay = /*#__PURE__*/function () {
      /**
       * @param {?} scrollStrategies
       * @param {?} _overlayContainer
       * @param {?} _componentFactoryResolver
       * @param {?} _positionBuilder
       * @param {?} _keyboardDispatcher
       * @param {?} _injector
       * @param {?} _ngZone
       * @param {?} _document
       * @param {?} _directionality
       * @param {?=} _location
       */
      function Overlay(scrollStrategies, _overlayContainer, _componentFactoryResolver, _positionBuilder, _keyboardDispatcher, _injector, _ngZone, _document, _directionality, _location) {
        _classCallCheck(this, Overlay);

        this.scrollStrategies = scrollStrategies;
        this._overlayContainer = _overlayContainer;
        this._componentFactoryResolver = _componentFactoryResolver;
        this._positionBuilder = _positionBuilder;
        this._keyboardDispatcher = _keyboardDispatcher;
        this._injector = _injector;
        this._ngZone = _ngZone;
        this._document = _document;
        this._directionality = _directionality;
        this._location = _location;
      }
      /**
       * Creates an overlay.
       * @param {?=} config Configuration applied to the overlay.
       * @return {?} Reference to the created overlay.
       */


      _createClass2(Overlay, [{
        key: "create",
        value: function create(config) {
          /** @type {?} */
          var host = this._createHostElement();
          /** @type {?} */


          var pane = this._createPaneElement(host);
          /** @type {?} */


          var portalOutlet = this._createPortalOutlet(pane);
          /** @type {?} */


          var overlayConfig = new OverlayConfig(config);
          overlayConfig.direction = overlayConfig.direction || this._directionality.value;
          return new OverlayRef(portalOutlet, host, pane, overlayConfig, this._ngZone, this._keyboardDispatcher, this._document, this._location);
        }
        /**
         * Gets a position builder that can be used, via fluent API,
         * to construct and configure a position strategy.
         * @return {?} An overlay position builder.
         */

      }, {
        key: "position",
        value: function position() {
          return this._positionBuilder;
        }
        /**
         * Creates the DOM element for an overlay and appends it to the overlay container.
         * @private
         * @param {?} host
         * @return {?} Newly-created pane element
         */

      }, {
        key: "_createPaneElement",
        value: function _createPaneElement(host) {
          /** @type {?} */
          var pane = this._document.createElement('div');

          pane.id = "cdk-overlay-".concat(nextUniqueId++);
          pane.classList.add('cdk-overlay-pane');
          host.appendChild(pane);
          return pane;
        }
        /**
         * Creates the host element that wraps around an overlay
         * and can be used for advanced positioning.
         * @private
         * @return {?} Newly-create host element.
         */

      }, {
        key: "_createHostElement",
        value: function _createHostElement() {
          /** @type {?} */
          var host = this._document.createElement('div');

          this._overlayContainer.getContainerElement().appendChild(host);

          return host;
        }
        /**
         * Create a DomPortalOutlet into which the overlay content can be loaded.
         * @private
         * @param {?} pane The DOM element to turn into a portal outlet.
         * @return {?} A portal outlet for the given DOM element.
         */

      }, {
        key: "_createPortalOutlet",
        value: function _createPortalOutlet(pane) {
          // We have to resolve the ApplicationRef later in order to allow people
          // to use overlay-based providers during app initialization.
          if (!this._appRef) {
            this._appRef = this._injector.get(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ApplicationRef"]);
          }

          return new _angular_cdk_portal__WEBPACK_IMPORTED_MODULE_6__["DomPortalOutlet"](pane, this._componentFactoryResolver, this._appRef, this._injector, this._document);
        }
      }]);

      return Overlay;
    }();

    Overlay.ɵfac = function Overlay_Factory(t) {
      return new (t || Overlay)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](ScrollStrategyOptions), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](OverlayContainer), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["ComponentFactoryResolver"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](OverlayPositionBuilder), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](OverlayKeyboardDispatcher), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["Injector"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_3__["Directionality"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_4__["Location"], 8));
    };

    Overlay.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"]({
      token: Overlay,
      factory: Overlay.ɵfac
    });
    /** @nocollapse */

    Overlay.ctorParameters = function () {
      return [{
        type: ScrollStrategyOptions
      }, {
        type: OverlayContainer
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ComponentFactoryResolver"]
      }, {
        type: OverlayPositionBuilder
      }, {
        type: OverlayKeyboardDispatcher
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injector"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]]
        }]
      }, {
        type: _angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_3__["Directionality"]
      }, {
        type: _angular_common__WEBPACK_IMPORTED_MODULE_4__["Location"],
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](Overlay, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"]
      }], function () {
        return [{
          type: ScrollStrategyOptions
        }, {
          type: OverlayContainer
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ComponentFactoryResolver"]
        }, {
          type: OverlayPositionBuilder
        }, {
          type: OverlayKeyboardDispatcher
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injector"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]]
          }]
        }, {
          type: _angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_3__["Directionality"]
        }, {
          type: _angular_common__WEBPACK_IMPORTED_MODULE_4__["Location"],
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/overlay-directives.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Default set of positions for the overlay. Follows the behavior of a dropdown.
     * @type {?}
     */


    var defaultPositionList = [{
      originX: 'start',
      originY: 'bottom',
      overlayX: 'start',
      overlayY: 'top'
    }, {
      originX: 'start',
      originY: 'top',
      overlayX: 'start',
      overlayY: 'bottom'
    }, {
      originX: 'end',
      originY: 'top',
      overlayX: 'end',
      overlayY: 'bottom'
    }, {
      originX: 'end',
      originY: 'bottom',
      overlayX: 'end',
      overlayY: 'top'
    }];
    /**
     * Injection token that determines the scroll handling while the connected overlay is open.
     * @type {?}
     */

    var CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["InjectionToken"]('cdk-connected-overlay-scroll-strategy');
    /**
     * \@docs-private \@deprecated \@breaking-change 8.0.0
     * @param {?} overlay
     * @return {?}
     */

    function CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_FACTORY(overlay) {
      return (
        /**
        * @param {?=} config
        * @return {?}
        */
        function (config) {
          return overlay.scrollStrategies.reposition(config);
        }
      );
    }
    /**
     * Directive applied to an element to make it usable as an origin for an Overlay using a
     * ConnectedPositionStrategy.
     */


    var CdkOverlayOrigin =
    /**
     * @param {?} elementRef
     */
    function CdkOverlayOrigin(elementRef) {
      _classCallCheck(this, CdkOverlayOrigin);

      this.elementRef = elementRef;
    };

    CdkOverlayOrigin.ɵfac = function CdkOverlayOrigin_Factory(t) {
      return new (t || CdkOverlayOrigin)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]));
    };

    CdkOverlayOrigin.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineDirective"]({
      type: CdkOverlayOrigin,
      selectors: [["", "cdk-overlay-origin", ""], ["", "overlay-origin", ""], ["", "cdkOverlayOrigin", ""]],
      exportAs: ["cdkOverlayOrigin"]
    });
    /** @nocollapse */

    CdkOverlayOrigin.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](CdkOverlayOrigin, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Directive"],
        args: [{
          selector: '[cdk-overlay-origin], [overlay-origin], [cdkOverlayOrigin]',
          exportAs: 'cdkOverlayOrigin'
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * Directive to facilitate declarative creation of an
     * Overlay using a FlexibleConnectedPositionStrategy.
     */


    var CdkConnectedOverlay = /*#__PURE__*/function () {
      // TODO(jelbourn): inputs for size, scroll behavior, animation, etc.

      /**
       * @param {?} _overlay
       * @param {?} templateRef
       * @param {?} viewContainerRef
       * @param {?} scrollStrategyFactory
       * @param {?} _dir
       */
      function CdkConnectedOverlay(_overlay, templateRef, viewContainerRef, scrollStrategyFactory, _dir) {
        _classCallCheck(this, CdkConnectedOverlay);

        this._overlay = _overlay;
        this._dir = _dir;
        this._hasBackdrop = false;
        this._lockPosition = false;
        this._growAfterOpen = false;
        this._flexibleDimensions = false;
        this._push = false;
        this._backdropSubscription = rxjs__WEBPACK_IMPORTED_MODULE_7__["Subscription"].EMPTY;
        /**
         * Margin between the overlay and the viewport edges.
         */

        this.viewportMargin = 0;
        /**
         * Whether the overlay is open.
         */

        this.open = false;
        /**
         * Event emitted when the backdrop is clicked.
         */

        this.backdropClick = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"]();
        /**
         * Event emitted when the position has changed.
         */

        this.positionChange = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"]();
        /**
         * Event emitted when the overlay has been attached.
         */

        this.attach = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"]();
        /**
         * Event emitted when the overlay has been detached.
         */

        this.detach = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"]();
        /**
         * Emits when there are keyboard events that are targeted at the overlay.
         */

        this.overlayKeydown = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"]();
        this._templatePortal = new _angular_cdk_portal__WEBPACK_IMPORTED_MODULE_6__["TemplatePortal"](templateRef, viewContainerRef);
        this._scrollStrategyFactory = scrollStrategyFactory;
        this.scrollStrategy = this._scrollStrategyFactory();
      }
      /**
       * The offset in pixels for the overlay connection point on the x-axis
       * @return {?}
       */


      _createClass2(CdkConnectedOverlay, [{
        key: "ngOnDestroy",

        /**
         * @return {?}
         */
        value: function ngOnDestroy() {
          if (this._overlayRef) {
            this._overlayRef.dispose();
          }

          this._backdropSubscription.unsubscribe();
        }
        /**
         * @param {?} changes
         * @return {?}
         */

      }, {
        key: "ngOnChanges",
        value: function ngOnChanges(changes) {
          if (this._position) {
            this._updatePositionStrategy(this._position);

            this._overlayRef.updateSize({
              width: this.width,
              minWidth: this.minWidth,
              height: this.height,
              minHeight: this.minHeight
            });

            if (changes['origin'] && this.open) {
              this._position.apply();
            }
          }

          if (changes['open']) {
            this.open ? this._attachOverlay() : this._detachOverlay();
          }
        }
        /**
         * Creates an overlay
         * @private
         * @return {?}
         */

      }, {
        key: "_createOverlay",
        value: function _createOverlay() {
          var _this92 = this;

          if (!this.positions || !this.positions.length) {
            this.positions = defaultPositionList;
          }

          this._overlayRef = this._overlay.create(this._buildConfig());

          this._overlayRef.keydownEvents().subscribe(
          /**
          * @param {?} event
          * @return {?}
          */
          function (event) {
            _this92.overlayKeydown.next(event);

            if (event.keyCode === _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_9__["ESCAPE"] && !Object(_angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_9__["hasModifierKey"])(event)) {
              event.preventDefault();

              _this92._detachOverlay();
            }
          });
        }
        /**
         * Builds the overlay config based on the directive's inputs
         * @private
         * @return {?}
         */

      }, {
        key: "_buildConfig",
        value: function _buildConfig() {
          /** @type {?} */
          var positionStrategy = this._position = this.positionStrategy || this._createPositionStrategy();
          /** @type {?} */


          var overlayConfig = new OverlayConfig({
            direction: this._dir,
            positionStrategy: positionStrategy,
            scrollStrategy: this.scrollStrategy,
            hasBackdrop: this.hasBackdrop
          });

          if (this.width || this.width === 0) {
            overlayConfig.width = this.width;
          }

          if (this.height || this.height === 0) {
            overlayConfig.height = this.height;
          }

          if (this.minWidth || this.minWidth === 0) {
            overlayConfig.minWidth = this.minWidth;
          }

          if (this.minHeight || this.minHeight === 0) {
            overlayConfig.minHeight = this.minHeight;
          }

          if (this.backdropClass) {
            overlayConfig.backdropClass = this.backdropClass;
          }

          if (this.panelClass) {
            overlayConfig.panelClass = this.panelClass;
          }

          return overlayConfig;
        }
        /**
         * Updates the state of a position strategy, based on the values of the directive inputs.
         * @private
         * @param {?} positionStrategy
         * @return {?}
         */

      }, {
        key: "_updatePositionStrategy",
        value: function _updatePositionStrategy(positionStrategy) {
          var _this93 = this;

          /** @type {?} */
          var positions = this.positions.map(
          /**
          * @param {?} currentPosition
          * @return {?}
          */
          function (currentPosition) {
            return {
              originX: currentPosition.originX,
              originY: currentPosition.originY,
              overlayX: currentPosition.overlayX,
              overlayY: currentPosition.overlayY,
              offsetX: currentPosition.offsetX || _this93.offsetX,
              offsetY: currentPosition.offsetY || _this93.offsetY,
              panelClass: currentPosition.panelClass || undefined
            };
          });
          return positionStrategy.setOrigin(this.origin.elementRef).withPositions(positions).withFlexibleDimensions(this.flexibleDimensions).withPush(this.push).withGrowAfterOpen(this.growAfterOpen).withViewportMargin(this.viewportMargin).withLockedPosition(this.lockPosition).withTransformOriginOn(this.transformOriginSelector);
        }
        /**
         * Returns the position strategy of the overlay to be set on the overlay config
         * @private
         * @return {?}
         */

      }, {
        key: "_createPositionStrategy",
        value: function _createPositionStrategy() {
          var _this94 = this;

          /** @type {?} */
          var strategy = this._overlay.position().flexibleConnectedTo(this.origin.elementRef);

          this._updatePositionStrategy(strategy);

          strategy.positionChanges.subscribe(
          /**
          * @param {?} p
          * @return {?}
          */
          function (p) {
            return _this94.positionChange.emit(p);
          });
          return strategy;
        }
        /**
         * Attaches the overlay and subscribes to backdrop clicks if backdrop exists
         * @private
         * @return {?}
         */

      }, {
        key: "_attachOverlay",
        value: function _attachOverlay() {
          var _this95 = this;

          if (!this._overlayRef) {
            this._createOverlay();
          } else {
            // Update the overlay size, in case the directive's inputs have changed
            this._overlayRef.getConfig().hasBackdrop = this.hasBackdrop;
          }

          if (!this._overlayRef.hasAttached()) {
            this._overlayRef.attach(this._templatePortal);

            this.attach.emit();
          }

          if (this.hasBackdrop) {
            this._backdropSubscription = this._overlayRef.backdropClick().subscribe(
            /**
            * @param {?} event
            * @return {?}
            */
            function (event) {
              _this95.backdropClick.emit(event);
            });
          } else {
            this._backdropSubscription.unsubscribe();
          }
        }
        /**
         * Detaches the overlay and unsubscribes to backdrop clicks if backdrop exists
         * @private
         * @return {?}
         */

      }, {
        key: "_detachOverlay",
        value: function _detachOverlay() {
          if (this._overlayRef) {
            this._overlayRef.detach();

            this.detach.emit();
          }

          this._backdropSubscription.unsubscribe();
        }
      }, {
        key: "offsetX",
        get: function get() {
          return this._offsetX;
        }
        /**
         * @param {?} offsetX
         * @return {?}
         */
        ,
        set: function set(offsetX) {
          this._offsetX = offsetX;

          if (this._position) {
            this._updatePositionStrategy(this._position);
          }
        }
        /**
         * The offset in pixels for the overlay connection point on the y-axis
         * @return {?}
         */

      }, {
        key: "offsetY",
        get: function get() {
          return this._offsetY;
        }
        /**
         * @param {?} offsetY
         * @return {?}
         */
        ,
        set: function set(offsetY) {
          this._offsetY = offsetY;

          if (this._position) {
            this._updatePositionStrategy(this._position);
          }
        }
        /**
         * Whether or not the overlay should attach a backdrop.
         * @return {?}
         */

      }, {
        key: "hasBackdrop",
        get: function get() {
          return this._hasBackdrop;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._hasBackdrop = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceBooleanProperty"])(value);
        }
        /**
         * Whether or not the overlay should be locked when scrolling.
         * @return {?}
         */

      }, {
        key: "lockPosition",
        get: function get() {
          return this._lockPosition;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._lockPosition = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceBooleanProperty"])(value);
        }
        /**
         * Whether the overlay's width and height can be constrained to fit within the viewport.
         * @return {?}
         */

      }, {
        key: "flexibleDimensions",
        get: function get() {
          return this._flexibleDimensions;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._flexibleDimensions = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceBooleanProperty"])(value);
        }
        /**
         * Whether the overlay can grow after the initial open when flexible positioning is turned on.
         * @return {?}
         */

      }, {
        key: "growAfterOpen",
        get: function get() {
          return this._growAfterOpen;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._growAfterOpen = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceBooleanProperty"])(value);
        }
        /**
         * Whether the overlay can be pushed on-screen if none of the provided positions fit.
         * @return {?}
         */

      }, {
        key: "push",
        get: function get() {
          return this._push;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._push = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceBooleanProperty"])(value);
        }
        /**
         * The associated overlay reference.
         * @return {?}
         */

      }, {
        key: "overlayRef",
        get: function get() {
          return this._overlayRef;
        }
        /**
         * The element's layout direction.
         * @return {?}
         */

      }, {
        key: "dir",
        get: function get() {
          return this._dir ? this._dir.value : 'ltr';
        }
      }]);

      return CdkConnectedOverlay;
    }();

    CdkConnectedOverlay.ɵfac = function CdkConnectedOverlay_Factory(t) {
      return new (t || CdkConnectedOverlay)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](Overlay), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["TemplateRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewContainerRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_3__["Directionality"], 8));
    };

    CdkConnectedOverlay.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineDirective"]({
      type: CdkConnectedOverlay,
      selectors: [["", "cdk-connected-overlay", ""], ["", "connected-overlay", ""], ["", "cdkConnectedOverlay", ""]],
      inputs: {
        viewportMargin: ["cdkConnectedOverlayViewportMargin", "viewportMargin"],
        open: ["cdkConnectedOverlayOpen", "open"],
        scrollStrategy: ["cdkConnectedOverlayScrollStrategy", "scrollStrategy"],
        offsetX: ["cdkConnectedOverlayOffsetX", "offsetX"],
        offsetY: ["cdkConnectedOverlayOffsetY", "offsetY"],
        hasBackdrop: ["cdkConnectedOverlayHasBackdrop", "hasBackdrop"],
        lockPosition: ["cdkConnectedOverlayLockPosition", "lockPosition"],
        flexibleDimensions: ["cdkConnectedOverlayFlexibleDimensions", "flexibleDimensions"],
        growAfterOpen: ["cdkConnectedOverlayGrowAfterOpen", "growAfterOpen"],
        push: ["cdkConnectedOverlayPush", "push"],
        positions: ["cdkConnectedOverlayPositions", "positions"],
        origin: ["cdkConnectedOverlayOrigin", "origin"],
        positionStrategy: ["cdkConnectedOverlayPositionStrategy", "positionStrategy"],
        width: ["cdkConnectedOverlayWidth", "width"],
        height: ["cdkConnectedOverlayHeight", "height"],
        minWidth: ["cdkConnectedOverlayMinWidth", "minWidth"],
        minHeight: ["cdkConnectedOverlayMinHeight", "minHeight"],
        backdropClass: ["cdkConnectedOverlayBackdropClass", "backdropClass"],
        panelClass: ["cdkConnectedOverlayPanelClass", "panelClass"],
        transformOriginSelector: ["cdkConnectedOverlayTransformOriginOn", "transformOriginSelector"]
      },
      outputs: {
        backdropClick: "backdropClick",
        positionChange: "positionChange",
        attach: "attach",
        detach: "detach",
        overlayKeydown: "overlayKeydown"
      },
      exportAs: ["cdkConnectedOverlay"],
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵNgOnChangesFeature"]]
    });
    /** @nocollapse */

    CdkConnectedOverlay.ctorParameters = function () {
      return [{
        type: Overlay
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["TemplateRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewContainerRef"]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY]
        }]
      }, {
        type: _angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_3__["Directionality"],
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }]
      }];
    };

    CdkConnectedOverlay.propDecorators = {
      origin: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkConnectedOverlayOrigin']
      }],
      positions: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkConnectedOverlayPositions']
      }],
      positionStrategy: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkConnectedOverlayPositionStrategy']
      }],
      offsetX: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkConnectedOverlayOffsetX']
      }],
      offsetY: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkConnectedOverlayOffsetY']
      }],
      width: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkConnectedOverlayWidth']
      }],
      height: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkConnectedOverlayHeight']
      }],
      minWidth: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkConnectedOverlayMinWidth']
      }],
      minHeight: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkConnectedOverlayMinHeight']
      }],
      backdropClass: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkConnectedOverlayBackdropClass']
      }],
      panelClass: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkConnectedOverlayPanelClass']
      }],
      viewportMargin: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkConnectedOverlayViewportMargin']
      }],
      scrollStrategy: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkConnectedOverlayScrollStrategy']
      }],
      open: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkConnectedOverlayOpen']
      }],
      transformOriginSelector: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkConnectedOverlayTransformOriginOn']
      }],
      hasBackdrop: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkConnectedOverlayHasBackdrop']
      }],
      lockPosition: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkConnectedOverlayLockPosition']
      }],
      flexibleDimensions: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkConnectedOverlayFlexibleDimensions']
      }],
      growAfterOpen: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkConnectedOverlayGrowAfterOpen']
      }],
      push: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
        args: ['cdkConnectedOverlayPush']
      }],
      backdropClick: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"]
      }],
      positionChange: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"]
      }],
      attach: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"]
      }],
      detach: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"]
      }],
      overlayKeydown: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](CdkConnectedOverlay, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Directive"],
        args: [{
          selector: '[cdk-connected-overlay], [connected-overlay], [cdkConnectedOverlay]',
          exportAs: 'cdkConnectedOverlay'
        }]
      }], function () {
        return [{
          type: Overlay
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["TemplateRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewContainerRef"]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY]
          }]
        }, {
          type: _angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_3__["Directionality"],
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }]
        }];
      }, {
        viewportMargin: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkConnectedOverlayViewportMargin']
        }],
        open: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkConnectedOverlayOpen']
        }],
        backdropClick: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"]
        }],
        positionChange: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"]
        }],
        attach: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"]
        }],
        detach: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"]
        }],
        overlayKeydown: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"]
        }],
        scrollStrategy: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkConnectedOverlayScrollStrategy']
        }],
        offsetX: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkConnectedOverlayOffsetX']
        }],
        offsetY: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkConnectedOverlayOffsetY']
        }],
        hasBackdrop: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkConnectedOverlayHasBackdrop']
        }],
        lockPosition: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkConnectedOverlayLockPosition']
        }],
        flexibleDimensions: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkConnectedOverlayFlexibleDimensions']
        }],
        growAfterOpen: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkConnectedOverlayGrowAfterOpen']
        }],
        push: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkConnectedOverlayPush']
        }],
        positions: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkConnectedOverlayPositions']
        }],
        origin: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkConnectedOverlayOrigin']
        }],
        positionStrategy: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkConnectedOverlayPositionStrategy']
        }],
        width: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkConnectedOverlayWidth']
        }],
        height: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkConnectedOverlayHeight']
        }],
        minWidth: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkConnectedOverlayMinWidth']
        }],
        minHeight: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkConnectedOverlayMinHeight']
        }],
        backdropClass: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkConnectedOverlayBackdropClass']
        }],
        panelClass: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkConnectedOverlayPanelClass']
        }],
        transformOriginSelector: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"],
          args: ['cdkConnectedOverlayTransformOriginOn']
        }]
      });
    })();

    if (false) {}
    /**
     * \@docs-private
     * @param {?} overlay
     * @return {?}
     */


    function CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER_FACTORY(overlay) {
      return (
        /**
        * @return {?}
        */
        function () {
          return overlay.scrollStrategies.reposition();
        }
      );
    }
    /**
     * \@docs-private
     * @type {?}
     */


    var CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER = {
      provide: CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY,
      deps: [Overlay],
      useFactory: CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER_FACTORY
    };
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/overlay-module.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    var OverlayModule = function OverlayModule() {
      _classCallCheck(this, OverlayModule);
    };

    OverlayModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineNgModule"]({
      type: OverlayModule
    });
    OverlayModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjector"]({
      factory: function OverlayModule_Factory(t) {
        return new (t || OverlayModule)();
      },
      providers: [Overlay, CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER],
      imports: [[_angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_3__["BidiModule"], _angular_cdk_portal__WEBPACK_IMPORTED_MODULE_6__["PortalModule"], _angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["ScrollingModule"]], _angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["ScrollingModule"]]
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵsetNgModuleScope"](OverlayModule, {
        declarations: function declarations() {
          return [CdkConnectedOverlay, CdkOverlayOrigin];
        },
        imports: function imports() {
          return [_angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_3__["BidiModule"], _angular_cdk_portal__WEBPACK_IMPORTED_MODULE_6__["PortalModule"], _angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["ScrollingModule"]];
        },
        exports: function exports() {
          return [CdkConnectedOverlay, CdkOverlayOrigin, _angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["ScrollingModule"]];
        }
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](OverlayModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModule"],
        args: [{
          imports: [_angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_3__["BidiModule"], _angular_cdk_portal__WEBPACK_IMPORTED_MODULE_6__["PortalModule"], _angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["ScrollingModule"]],
          exports: [CdkConnectedOverlay, CdkOverlayOrigin, _angular_cdk_scrolling__WEBPACK_IMPORTED_MODULE_0__["ScrollingModule"]],
          declarations: [CdkConnectedOverlay, CdkOverlayOrigin],
          providers: [Overlay, CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER]
        }]
      }], null, null);
    })();
    /**
     * @deprecated Use `OverlayModule` instead.
     * \@breaking-change 8.0.0
     * \@docs-private
     * @type {?}
     */


    var OVERLAY_PROVIDERS = [Overlay, OverlayPositionBuilder, OVERLAY_KEYBOARD_DISPATCHER_PROVIDER, OVERLAY_CONTAINER_PROVIDER, CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER];
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/fullscreen-overlay-container.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Alternative to OverlayContainer that supports correct displaying of overlay elements in
     * Fullscreen mode
     * https://developer.mozilla.org/en-US/docs/Web/API/Element/requestFullScreen
     *
     * Should be provided in the root component.
     */

    var FullscreenOverlayContainer = /*#__PURE__*/function (_OverlayContainer) {
      _inherits(FullscreenOverlayContainer, _OverlayContainer);

      var _super8 = _createSuper(FullscreenOverlayContainer);

      /**
       * @param {?} _document
       * @param {?=} platform
       */
      function FullscreenOverlayContainer(_document,
      /**
       * @deprecated `platform` parameter to become required.
       * @breaking-change 10.0.0
       */
      platform) {
        _classCallCheck(this, FullscreenOverlayContainer);

        return _super8.call(this, _document, platform);
      }
      /**
       * @return {?}
       */


      _createClass2(FullscreenOverlayContainer, [{
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          _get(_getPrototypeOf(FullscreenOverlayContainer.prototype), "ngOnDestroy", this).call(this);

          if (this._fullScreenEventName && this._fullScreenListener) {
            this._document.removeEventListener(this._fullScreenEventName, this._fullScreenListener);
          }
        }
        /**
         * @protected
         * @return {?}
         */

      }, {
        key: "_createContainer",
        value: function _createContainer() {
          var _this96 = this;

          _get(_getPrototypeOf(FullscreenOverlayContainer.prototype), "_createContainer", this).call(this);

          this._adjustParentForFullscreenChange();

          this._addFullscreenChangeListener(
          /**
          * @return {?}
          */
          function () {
            return _this96._adjustParentForFullscreenChange();
          });
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_adjustParentForFullscreenChange",
        value: function _adjustParentForFullscreenChange() {
          if (!this._containerElement) {
            return;
          }
          /** @type {?} */


          var fullscreenElement = this.getFullscreenElement();
          /** @type {?} */

          var parent = fullscreenElement || this._document.body;
          parent.appendChild(this._containerElement);
        }
        /**
         * @private
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "_addFullscreenChangeListener",
        value: function _addFullscreenChangeListener(fn) {
          /** @type {?} */
          var eventName = this._getEventName();

          if (eventName) {
            if (this._fullScreenListener) {
              this._document.removeEventListener(eventName, this._fullScreenListener);
            }

            this._document.addEventListener(eventName, fn);

            this._fullScreenListener = fn;
          }
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_getEventName",
        value: function _getEventName() {
          if (!this._fullScreenEventName) {
            /** @type {?} */
            var _document =
            /** @type {?} */
            this._document;

            if (_document.fullscreenEnabled) {
              this._fullScreenEventName = 'fullscreenchange';
            } else if (_document.webkitFullscreenEnabled) {
              this._fullScreenEventName = 'webkitfullscreenchange';
            } else if (_document.mozFullScreenEnabled) {
              this._fullScreenEventName = 'mozfullscreenchange';
            } else if (_document.msFullscreenEnabled) {
              this._fullScreenEventName = 'MSFullscreenChange';
            }
          }

          return this._fullScreenEventName;
        }
        /**
         * When the page is put into fullscreen mode, a specific element is specified.
         * Only that element and its children are visible when in fullscreen mode.
         * @return {?}
         */

      }, {
        key: "getFullscreenElement",
        value: function getFullscreenElement() {
          /** @type {?} */
          var _document =
          /** @type {?} */
          this._document;
          return _document.fullscreenElement || _document.webkitFullscreenElement || _document.mozFullScreenElement || _document.msFullscreenElement || null;
        }
      }]);

      return FullscreenOverlayContainer;
    }(OverlayContainer);

    FullscreenOverlayContainer.ɵfac = function FullscreenOverlayContainer_Factory(t) {
      return new (t || FullscreenOverlayContainer)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_2__["Platform"]));
    };
    /** @nocollapse */


    FullscreenOverlayContainer.ctorParameters = function () {
      return [{
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]]
        }]
      }, {
        type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_2__["Platform"]
      }];
    };
    /** @nocollapse */


    FullscreenOverlayContainer.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: function FullscreenOverlayContainer_Factory() {
        return new FullscreenOverlayContainer(Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_2__["Platform"]));
      },
      token: FullscreenOverlayContainer,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](FullscreenOverlayContainer, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [{
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]]
          }]
        }, {
          type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_2__["Platform"]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/overlay/public-api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=overlay.js.map

    /***/

  },

  /***/
  "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/platform.js":
  /*!*********************************************************************!*\
    !*** ./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/platform.js ***!
    \*********************************************************************/

  /*! exports provided: Platform, PlatformModule, _getShadowRoot, _supportsShadowDom, getRtlScrollAxisType, getSupportedInputTypes, normalizePassiveListenerOptions, supportsPassiveEventListeners, supportsScrollBehavior */

  /***/
  function node_modulesAngularCdk__ivy_ngcc__Fesm2015PlatformJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Platform", function () {
      return Platform;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "PlatformModule", function () {
      return PlatformModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "_getShadowRoot", function () {
      return _getShadowRoot;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "_supportsShadowDom", function () {
      return _supportsShadowDom;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getRtlScrollAxisType", function () {
      return getRtlScrollAxisType;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getSupportedInputTypes", function () {
      return getSupportedInputTypes;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "normalizePassiveListenerOptions", function () {
      return normalizePassiveListenerOptions;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "supportsPassiveEventListeners", function () {
      return supportsPassiveEventListeners;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "supportsScrollBehavior", function () {
      return supportsScrollBehavior;
    });
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var _angular_common__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! @angular/common */
    "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/common.js");
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/platform/platform.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */
    // Whether the current platform supports the V8 Break Iterator. The V8 check
    // is necessary to detect all Blink based browsers.

    /** @type {?} */


    var hasV8BreakIterator; // We need a try/catch around the reference to `Intl`, because accessing it in some cases can
    // cause IE to throw. These cases are tied to particular versions of Windows and can happen if
    // the consumer is providing a polyfilled `Map`. See:
    // https://github.com/Microsoft/ChakraCore/issues/3189
    // https://github.com/angular/components/issues/15687

    try {
      hasV8BreakIterator = typeof Intl !== 'undefined' &&
      /** @type {?} */
      Intl.v8BreakIterator;
    } catch (_a) {
      hasV8BreakIterator = false;
    }
    /**
     * Service to detect the current platform by comparing the userAgent strings and
     * checking browser-specific global properties.
     */


    var Platform =
    /**
     * \@breaking-change 8.0.0 remove optional decorator
     * @param {?=} _platformId
     */
    function Platform(_platformId) {
      _classCallCheck(this, Platform);

      this._platformId = _platformId; // We want to use the Angular platform check because if the Document is shimmed
      // without the navigator, the following checks will fail. This is preferred because
      // sometimes the Document may be shimmed without the user's knowledge or intention

      /**
       * Whether the Angular application is being rendered in the browser.
       */

      this.isBrowser = this._platformId ? Object(_angular_common__WEBPACK_IMPORTED_MODULE_1__["isPlatformBrowser"])(this._platformId) : typeof document === 'object' && !!document;
      /**
       * Whether the current browser is Microsoft Edge.
       */

      this.EDGE = this.isBrowser && /(edge)/i.test(navigator.userAgent);
      /**
       * Whether the current rendering engine is Microsoft Trident.
       */

      this.TRIDENT = this.isBrowser && /(msie|trident)/i.test(navigator.userAgent); // EdgeHTML and Trident mock Blink specific things and need to be excluded from this check.

      /**
       * Whether the current rendering engine is Blink.
       */

      this.BLINK = this.isBrowser && !!(
      /** @type {?} */
      window.chrome || hasV8BreakIterator) && typeof CSS !== 'undefined' && !this.EDGE && !this.TRIDENT; // Webkit is part of the userAgent in EdgeHTML, Blink and Trident. Therefore we need to
      // ensure that Webkit runs standalone and is not used as another engine's base.

      /**
       * Whether the current rendering engine is WebKit.
       */

      this.WEBKIT = this.isBrowser && /AppleWebKit/i.test(navigator.userAgent) && !this.BLINK && !this.EDGE && !this.TRIDENT;
      /**
       * Whether the current platform is Apple iOS.
       */

      this.IOS = this.isBrowser && /iPad|iPhone|iPod/.test(navigator.userAgent) && !('MSStream' in window); // It's difficult to detect the plain Gecko engine, because most of the browsers identify
      // them self as Gecko-like browsers and modify the userAgent's according to that.
      // Since we only cover one explicit Firefox case, we can simply check for Firefox
      // instead of having an unstable check for Gecko.

      /**
       * Whether the current browser is Firefox.
       */

      this.FIREFOX = this.isBrowser && /(firefox|minefield)/i.test(navigator.userAgent);
      /**
       * Whether the current platform is Android.
       */
      // Trident on mobile adds the android platform to the userAgent to trick detections.

      this.ANDROID = this.isBrowser && /android/i.test(navigator.userAgent) && !this.TRIDENT; // Safari browsers will include the Safari keyword in their userAgent. Some browsers may fake
      // this and just place the Safari keyword in the userAgent. To be more safe about Safari every
      // Safari browser should also use Webkit as its layout engine.

      /**
       * Whether the current browser is Safari.
       */

      this.SAFARI = this.isBrowser && /safari/i.test(navigator.userAgent) && this.WEBKIT;
    };

    Platform.ɵfac = function Platform_Factory(t) {
      return new (t || Platform)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["PLATFORM_ID"], 8));
    };
    /** @nocollapse */


    Platform.ctorParameters = function () {
      return [{
        type: Object,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["PLATFORM_ID"]]
        }]
      }];
    };
    /** @nocollapse */


    Platform.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"])({
      factory: function Platform_Factory() {
        return new Platform(Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"])(_angular_core__WEBPACK_IMPORTED_MODULE_0__["PLATFORM_ID"], 8));
      },
      token: Platform,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](Platform, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [{
          type: Object,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["PLATFORM_ID"]]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/platform/platform-module.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var PlatformModule = function PlatformModule() {
      _classCallCheck(this, PlatformModule);
    };

    PlatformModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: PlatformModule
    });
    PlatformModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function PlatformModule_Factory(t) {
        return new (t || PlatformModule)();
      }
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](PlatformModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{}]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/platform/features/input-types.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Cached result Set of input types support by the current browser.
     * @type {?}
     */


    var supportedInputTypes;
    /**
     * Types of `<input>` that *might* be supported.
     * @type {?}
     */

    var candidateInputTypes = [// `color` must come first. Chrome 56 shows a warning if we change the type to `color` after
    // first changing it to something else:
    // The specified value "" does not conform to the required format.
    // The format is "#rrggbb" where rr, gg, bb are two-digit hexadecimal numbers.
    'color', 'button', 'checkbox', 'date', 'datetime-local', 'email', 'file', 'hidden', 'image', 'month', 'number', 'password', 'radio', 'range', 'reset', 'search', 'submit', 'tel', 'text', 'time', 'url', 'week'];
    /**
     * @return {?} The input types supported by this browser.
     */

    function getSupportedInputTypes() {
      // Result is cached.
      if (supportedInputTypes) {
        return supportedInputTypes;
      } // We can't check if an input type is not supported until we're on the browser, so say that
      // everything is supported when not on the browser. We don't use `Platform` here since it's
      // just a helper function and can't inject it.


      if (typeof document !== 'object' || !document) {
        supportedInputTypes = new Set(candidateInputTypes);
        return supportedInputTypes;
      }
      /** @type {?} */


      var featureTestInput = document.createElement('input');
      supportedInputTypes = new Set(candidateInputTypes.filter(
      /**
      * @param {?} value
      * @return {?}
      */
      function (value) {
        featureTestInput.setAttribute('type', value);
        return featureTestInput.type === value;
      }));
      return supportedInputTypes;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/platform/features/passive-listeners.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Cached result of whether the user's browser supports passive event listeners.
     * @type {?}
     */


    var supportsPassiveEvents;
    /**
     * Checks whether the user's browser supports passive event listeners.
     * See: https://github.com/WICG/EventListenerOptions/blob/gh-pages/explainer.md
     * @return {?}
     */

    function supportsPassiveEventListeners() {
      if (supportsPassiveEvents == null && typeof window !== 'undefined') {
        try {
          window.addEventListener('test',
          /** @type {?} */
          null, Object.defineProperty({}, 'passive', {
            get:
            /**
            * @return {?}
            */
            function get() {
              return supportsPassiveEvents = true;
            }
          }));
        } finally {
          supportsPassiveEvents = supportsPassiveEvents || false;
        }
      }

      return supportsPassiveEvents;
    }
    /**
     * Normalizes an `AddEventListener` object to something that can be passed
     * to `addEventListener` on any browser, no matter whether it supports the
     * `options` parameter.
     * @param {?} options Object to be normalized.
     * @return {?}
     */


    function normalizePassiveListenerOptions(options) {
      return supportsPassiveEventListeners() ? options : !!options.capture;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/platform/features/scrolling.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** @enum {number} */


    var RtlScrollAxisType = {
      /**
       * scrollLeft is 0 when scrolled all the way left and (scrollWidth - clientWidth) when scrolled
       * all the way right.
       */
      NORMAL: 0,

      /**
       * scrollLeft is -(scrollWidth - clientWidth) when scrolled all the way left and 0 when scrolled
       * all the way right.
       */
      NEGATED: 1,

      /**
       * scrollLeft is (scrollWidth - clientWidth) when scrolled all the way left and 0 when scrolled
       * all the way right.
       */
      INVERTED: 2
    };
    /**
     * Cached result of the way the browser handles the horizontal scroll axis in RTL mode.
     * @type {?}
     */

    var rtlScrollAxisType;
    /**
     * Check whether the browser supports scroll behaviors.
     * @return {?}
     */

    function supportsScrollBehavior() {
      return !!(typeof document == 'object' && 'scrollBehavior' in
      /** @type {?} */
      document.documentElement.style);
    }
    /**
     * Checks the type of RTL scroll axis used by this browser. As of time of writing, Chrome is NORMAL,
     * Firefox & Safari are NEGATED, and IE & Edge are INVERTED.
     * @return {?}
     */


    function getRtlScrollAxisType() {
      // We can't check unless we're on the browser. Just assume 'normal' if we're not.
      if (typeof document !== 'object' || !document) {
        return 0
        /* NORMAL */
        ;
      }

      if (rtlScrollAxisType == null) {
        // Create a 1px wide scrolling container and a 2px wide content element.

        /** @type {?} */
        var scrollContainer = document.createElement('div');
        /** @type {?} */

        var containerStyle = scrollContainer.style;
        scrollContainer.dir = 'rtl';
        containerStyle.height = '1px';
        containerStyle.width = '1px';
        containerStyle.overflow = 'auto';
        containerStyle.visibility = 'hidden';
        containerStyle.pointerEvents = 'none';
        containerStyle.position = 'absolute';
        /** @type {?} */

        var content = document.createElement('div');
        /** @type {?} */

        var contentStyle = content.style;
        contentStyle.width = '2px';
        contentStyle.height = '1px';
        scrollContainer.appendChild(content);
        document.body.appendChild(scrollContainer);
        rtlScrollAxisType = 0
        /* NORMAL */
        ; // The viewport starts scrolled all the way to the right in RTL mode. If we are in a NORMAL
        // browser this would mean that the scrollLeft should be 1. If it's zero instead we know we're
        // dealing with one of the other two types of browsers.

        if (scrollContainer.scrollLeft === 0) {
          // In a NEGATED browser the scrollLeft is always somewhere in [-maxScrollAmount, 0]. For an
          // INVERTED browser it is always somewhere in [0, maxScrollAmount]. We can determine which by
          // setting to the scrollLeft to 1. This is past the max for a NEGATED browser, so it will
          // return 0 when we read it again.
          scrollContainer.scrollLeft = 1;
          rtlScrollAxisType = scrollContainer.scrollLeft === 0 ? 1
          /* NEGATED */
          : 2
          /* INVERTED */
          ;
        }

        /** @type {?} */
        scrollContainer.parentNode.removeChild(scrollContainer);
      }

      return rtlScrollAxisType;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/platform/features/shadow-dom.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** @type {?} */


    var shadowDomIsSupported;
    /**
     * Checks whether the user's browser support Shadow DOM.
     * @return {?}
     */

    function _supportsShadowDom() {
      if (shadowDomIsSupported == null) {
        /** @type {?} */
        var head = typeof document !== 'undefined' ? document.head : null;
        shadowDomIsSupported = !!(head && (
        /** @type {?} */
        head.createShadowRoot || head.attachShadow));
      }

      return shadowDomIsSupported;
    }
    /**
     * Gets the shadow root of an element, if supported and the element is inside the Shadow DOM.
     * @param {?} element
     * @return {?}
     */


    function _getShadowRoot(element) {
      if (_supportsShadowDom()) {
        /** @type {?} */
        var rootNode = element.getRootNode ? element.getRootNode() : null; // Note that this should be caught by `_supportsShadowDom`, but some
        // teams have been able to hit this code path on unsupported browsers.

        if (typeof ShadowRoot !== 'undefined' && ShadowRoot && rootNode instanceof ShadowRoot) {
          return rootNode;
        }
      }

      return null;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/platform/public-api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=platform.js.map

    /***/

  },

  /***/
  "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/portal.js":
  /*!*******************************************************************!*\
    !*** ./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/portal.js ***!
    \*******************************************************************/

  /*! exports provided: BasePortalHost, BasePortalOutlet, CdkPortal, CdkPortalOutlet, ComponentPortal, DomPortal, DomPortalHost, DomPortalOutlet, Portal, PortalHostDirective, PortalInjector, PortalModule, TemplatePortal, TemplatePortalDirective */

  /***/
  function node_modulesAngularCdk__ivy_ngcc__Fesm2015PortalJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "BasePortalHost", function () {
      return BasePortalHost;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "BasePortalOutlet", function () {
      return BasePortalOutlet;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CdkPortal", function () {
      return CdkPortal;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CdkPortalOutlet", function () {
      return CdkPortalOutlet;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ComponentPortal", function () {
      return ComponentPortal;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DomPortal", function () {
      return DomPortal;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DomPortalHost", function () {
      return DomPortalHost;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DomPortalOutlet", function () {
      return DomPortalOutlet;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Portal", function () {
      return Portal;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "PortalHostDirective", function () {
      return PortalHostDirective;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "PortalInjector", function () {
      return PortalInjector;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "PortalModule", function () {
      return PortalModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "TemplatePortal", function () {
      return TemplatePortal;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "TemplatePortalDirective", function () {
      return TemplatePortalDirective;
    });
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var _angular_common__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! @angular/common */
    "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/common.js");
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/portal/portal-errors.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Throws an exception when attempting to attach a null portal to a host.
     * \@docs-private
     * @return {?}
     */


    function throwNullPortalError() {
      throw Error('Must provide a portal to attach');
    }
    /**
     * Throws an exception when attempting to attach a portal to a host that is already attached.
     * \@docs-private
     * @return {?}
     */


    function throwPortalAlreadyAttachedError() {
      throw Error('Host already has a portal attached');
    }
    /**
     * Throws an exception when attempting to attach a portal to an already-disposed host.
     * \@docs-private
     * @return {?}
     */


    function throwPortalOutletAlreadyDisposedError() {
      throw Error('This PortalOutlet has already been disposed');
    }
    /**
     * Throws an exception when attempting to attach an unknown portal type.
     * \@docs-private
     * @return {?}
     */


    function throwUnknownPortalTypeError() {
      throw Error('Attempting to attach an unknown Portal type. BasePortalOutlet accepts either ' + 'a ComponentPortal or a TemplatePortal.');
    }
    /**
     * Throws an exception when attempting to attach a portal to a null host.
     * \@docs-private
     * @return {?}
     */


    function throwNullPortalOutletError() {
      throw Error('Attempting to attach a portal to a null PortalOutlet');
    }
    /**
     * Throws an exception when attempting to detach a portal that is not attached.
     * \@docs-private
     * @return {?}
     */


    function throwNoPortalAttachedError() {
      throw Error('Attempting to detach a portal that is not attached to a host');
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/portal/portal.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Interface that can be used to generically type a class.
     * @record
     * @template T
     */


    function ComponentType() {}
    /**
     * A `Portal` is something that you want to render somewhere else.
     * It can be attach to / detached from a `PortalOutlet`.
     * @abstract
     * @template T
     */


    var Portal = /*#__PURE__*/function () {
      function Portal() {
        _classCallCheck(this, Portal);
      }

      _createClass2(Portal, [{
        key: "attach",

        /**
         * Attach this portal to a host.
         * @param {?} host
         * @return {?}
         */
        value: function attach(host) {
          if (host == null) {
            throwNullPortalOutletError();
          }

          if (host.hasAttached()) {
            throwPortalAlreadyAttachedError();
          }

          this._attachedHost = host;
          return (
            /** @type {?} */
            host.attach(this)
          );
        }
        /**
         * Detach this portal from its host
         * @return {?}
         */

      }, {
        key: "detach",
        value: function detach() {
          /** @type {?} */
          var host = this._attachedHost;

          if (host == null) {
            throwNoPortalAttachedError();
          } else {
            this._attachedHost = null;
            host.detach();
          }
        }
        /**
         * Whether this portal is attached to a host.
         * @return {?}
         */

      }, {
        key: "setAttachedHost",

        /**
         * Sets the PortalOutlet reference without performing `attach()`. This is used directly by
         * the PortalOutlet when it is performing an `attach()` or `detach()`.
         * @param {?} host
         * @return {?}
         */
        value: function setAttachedHost(host) {
          this._attachedHost = host;
        }
      }, {
        key: "isAttached",
        get: function get() {
          return this._attachedHost != null;
        }
      }]);

      return Portal;
    }();

    if (false) {}
    /**
     * A `ComponentPortal` is a portal that instantiates some Component upon attachment.
     * @template T
     */


    var ComponentPortal = /*#__PURE__*/function (_Portal) {
      _inherits(ComponentPortal, _Portal);

      var _super9 = _createSuper(ComponentPortal);

      /**
       * @param {?} component
       * @param {?=} viewContainerRef
       * @param {?=} injector
       * @param {?=} componentFactoryResolver
       */
      function ComponentPortal(component, viewContainerRef, injector, componentFactoryResolver) {
        var _this97;

        _classCallCheck(this, ComponentPortal);

        _this97 = _super9.call(this);
        _this97.component = component;
        _this97.viewContainerRef = viewContainerRef;
        _this97.injector = injector;
        _this97.componentFactoryResolver = componentFactoryResolver;
        return _this97;
      }

      return ComponentPortal;
    }(Portal);

    if (false) {}
    /**
     * A `TemplatePortal` is a portal that represents some embedded template (TemplateRef).
     * @template C
     */


    var TemplatePortal = /*#__PURE__*/function (_Portal2) {
      _inherits(TemplatePortal, _Portal2);

      var _super10 = _createSuper(TemplatePortal);

      /**
       * @param {?} template
       * @param {?} viewContainerRef
       * @param {?=} context
       */
      function TemplatePortal(template, viewContainerRef, context) {
        var _this98;

        _classCallCheck(this, TemplatePortal);

        _this98 = _super10.call(this);
        _this98.templateRef = template;
        _this98.viewContainerRef = viewContainerRef;
        _this98.context = context;
        return _this98;
      }
      /**
       * @return {?}
       */


      _createClass2(TemplatePortal, [{
        key: "attach",

        /**
         * Attach the portal to the provided `PortalOutlet`.
         * When a context is provided it will override the `context` property of the `TemplatePortal`
         * instance.
         * @param {?} host
         * @param {?=} context
         * @return {?}
         */
        value: function attach(host) {
          var context = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : this.context;
          this.context = context;
          return _get(_getPrototypeOf(TemplatePortal.prototype), "attach", this).call(this, host);
        }
        /**
         * @return {?}
         */

      }, {
        key: "detach",
        value: function detach() {
          this.context = undefined;
          return _get(_getPrototypeOf(TemplatePortal.prototype), "detach", this).call(this);
        }
      }, {
        key: "origin",
        get: function get() {
          return this.templateRef.elementRef;
        }
      }]);

      return TemplatePortal;
    }(Portal);

    if (false) {}
    /**
     * A `DomPortal` is a portal whose DOM element will be taken from its current position
     * in the DOM and moved into a portal outlet, when it is attached. On detach, the content
     * will be restored to its original position.
     * @template T
     */


    var DomPortal = /*#__PURE__*/function (_Portal3) {
      _inherits(DomPortal, _Portal3);

      var _super11 = _createSuper(DomPortal);

      /**
       * @param {?} element
       */
      function DomPortal(element) {
        var _this99;

        _classCallCheck(this, DomPortal);

        _this99 = _super11.call(this);
        _this99.element = element instanceof _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"] ? element.nativeElement : element;
        return _this99;
      }

      return DomPortal;
    }(Portal);

    if (false) {}
    /**
     * A `PortalOutlet` is an space that can contain a single `Portal`.
     * @record
     */


    function PortalOutlet() {}

    if (false) {}
    /**
     * Partial implementation of PortalOutlet that handles attaching
     * ComponentPortal and TemplatePortal.
     * @abstract
     */


    var BasePortalOutlet = /*#__PURE__*/function () {
      function BasePortalOutlet() {
        _classCallCheck(this, BasePortalOutlet);

        /**
         * Whether this host has already been permanently disposed.
         */
        this._isDisposed = false; // @breaking-change 10.0.0 `attachDomPortal` to become a required abstract method.

        this.attachDomPortal = null;
      }
      /**
       * Whether this host has an attached portal.
       * @return {?}
       */


      _createClass2(BasePortalOutlet, [{
        key: "hasAttached",
        value: function hasAttached() {
          return !!this._attachedPortal;
        }
        /**
         * Attaches a portal.
         * @param {?} portal
         * @return {?}
         */

      }, {
        key: "attach",
        value: function attach(portal) {
          if (!portal) {
            throwNullPortalError();
          }

          if (this.hasAttached()) {
            throwPortalAlreadyAttachedError();
          }

          if (this._isDisposed) {
            throwPortalOutletAlreadyDisposedError();
          }

          if (portal instanceof ComponentPortal) {
            this._attachedPortal = portal;
            return this.attachComponentPortal(portal);
          } else if (portal instanceof TemplatePortal) {
            this._attachedPortal = portal;
            return this.attachTemplatePortal(portal); // @breaking-change 10.0.0 remove null check for `this.attachDomPortal`.
          } else if (this.attachDomPortal && portal instanceof DomPortal) {
            this._attachedPortal = portal;
            return this.attachDomPortal(portal);
          }

          throwUnknownPortalTypeError();
        }
        /**
         * Detaches a previously attached portal.
         * @return {?}
         */

      }, {
        key: "detach",
        value: function detach() {
          if (this._attachedPortal) {
            this._attachedPortal.setAttachedHost(null);

            this._attachedPortal = null;
          }

          this._invokeDisposeFn();
        }
        /**
         * Permanently dispose of this portal host.
         * @return {?}
         */

      }, {
        key: "dispose",
        value: function dispose() {
          if (this.hasAttached()) {
            this.detach();
          }

          this._invokeDisposeFn();

          this._isDisposed = true;
        }
        /**
         * \@docs-private
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "setDisposeFn",
        value: function setDisposeFn(fn) {
          this._disposeFn = fn;
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_invokeDisposeFn",
        value: function _invokeDisposeFn() {
          if (this._disposeFn) {
            this._disposeFn();

            this._disposeFn = null;
          }
        }
      }]);

      return BasePortalOutlet;
    }();

    if (false) {}
    /**
     * @deprecated Use `BasePortalOutlet` instead.
     * \@breaking-change 9.0.0
     * @abstract
     */


    var BasePortalHost = /*#__PURE__*/function (_BasePortalOutlet) {
      _inherits(BasePortalHost, _BasePortalOutlet);

      var _super12 = _createSuper(BasePortalHost);

      function BasePortalHost() {
        _classCallCheck(this, BasePortalHost);

        return _super12.apply(this, arguments);
      }

      return BasePortalHost;
    }(BasePortalOutlet);
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/portal/dom-portal-outlet.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * A PortalOutlet for attaching portals to an arbitrary DOM element outside of the Angular
     * application context.
     */


    var DomPortalOutlet = /*#__PURE__*/function (_BasePortalOutlet2) {
      _inherits(DomPortalOutlet, _BasePortalOutlet2);

      var _super13 = _createSuper(DomPortalOutlet);

      /**
       * @param {?} outletElement
       * @param {?} _componentFactoryResolver
       * @param {?} _appRef
       * @param {?} _defaultInjector
       * @param {?=} _document
       */
      function DomPortalOutlet(outletElement, _componentFactoryResolver, _appRef, _defaultInjector,
      /**
       * @deprecated `_document` Parameter to be made required.
       * @breaking-change 10.0.0
       */
      _document) {
        var _thisSuper, _this100;

        _classCallCheck(this, DomPortalOutlet);

        _this100 = _super13.call(this);
        _this100.outletElement = outletElement;
        _this100._componentFactoryResolver = _componentFactoryResolver;
        _this100._appRef = _appRef;
        _this100._defaultInjector = _defaultInjector;
        /**
         * Attaches a DOM portal by transferring its content into the outlet.
         * @param portal Portal to be attached.
         * @deprecated To be turned into a method.
         * \@breaking-change 10.0.0
         */

        _this100.attachDomPortal =
        /**
        * @param {?} portal
        * @return {?}
        */
        function (portal) {
          // @breaking-change 10.0.0 Remove check and error once the
          // `_document` constructor parameter is required.
          if (!_this100._document) {
            throw Error('Cannot attach DOM portal without _document constructor parameter');
          }
          /** @type {?} */


          var element = portal.element;

          if (!element.parentNode) {
            throw Error('DOM portal content must be attached to a parent node.');
          } // Anchor used to save the element's previous position so
          // that we can restore it when the portal is detached.

          /** @type {?} */


          var anchorNode = _this100._document.createComment('dom-portal');

          element.parentNode.insertBefore(anchorNode, element);

          _this100.outletElement.appendChild(element);

          _get((_thisSuper = _assertThisInitialized(_this100), _getPrototypeOf(DomPortalOutlet.prototype)), "setDisposeFn", _thisSuper).call(_thisSuper,
          /**
          * @return {?}
          */
          function () {
            // We can't use `replaceWith` here because IE doesn't support it.
            if (anchorNode.parentNode) {
              anchorNode.parentNode.replaceChild(element, anchorNode);
            }
          });
        };

        _this100._document = _document;
        return _this100;
      }
      /**
       * Attach the given ComponentPortal to DOM element using the ComponentFactoryResolver.
       * @template T
       * @param {?} portal Portal to be attached
       * @return {?} Reference to the created component.
       */


      _createClass2(DomPortalOutlet, [{
        key: "attachComponentPortal",
        value: function attachComponentPortal(portal) {
          var _this101 = this;

          /** @type {?} */
          var resolver = portal.componentFactoryResolver || this._componentFactoryResolver;
          /** @type {?} */

          var componentFactory = resolver.resolveComponentFactory(portal.component);
          /** @type {?} */

          var componentRef; // If the portal specifies a ViewContainerRef, we will use that as the attachment point
          // for the component (in terms of Angular's component tree, not rendering).
          // When the ViewContainerRef is missing, we use the factory to create the component directly
          // and then manually attach the view to the application.

          if (portal.viewContainerRef) {
            componentRef = portal.viewContainerRef.createComponent(componentFactory, portal.viewContainerRef.length, portal.injector || portal.viewContainerRef.injector);
            this.setDisposeFn(
            /**
            * @return {?}
            */
            function () {
              return componentRef.destroy();
            });
          } else {
            componentRef = componentFactory.create(portal.injector || this._defaultInjector);

            this._appRef.attachView(componentRef.hostView);

            this.setDisposeFn(
            /**
            * @return {?}
            */
            function () {
              _this101._appRef.detachView(componentRef.hostView);

              componentRef.destroy();
            });
          } // At this point the component has been instantiated, so we move it to the location in the DOM
          // where we want it to be rendered.


          this.outletElement.appendChild(this._getComponentRootNode(componentRef));
          return componentRef;
        }
        /**
         * Attaches a template portal to the DOM as an embedded view.
         * @template C
         * @param {?} portal Portal to be attached.
         * @return {?} Reference to the created embedded view.
         */

      }, {
        key: "attachTemplatePortal",
        value: function attachTemplatePortal(portal) {
          var _this102 = this;

          /** @type {?} */
          var viewContainer = portal.viewContainerRef;
          /** @type {?} */

          var viewRef = viewContainer.createEmbeddedView(portal.templateRef, portal.context);
          viewRef.detectChanges(); // The method `createEmbeddedView` will add the view as a child of the viewContainer.
          // But for the DomPortalOutlet the view can be added everywhere in the DOM
          // (e.g Overlay Container) To move the view to the specified host element. We just
          // re-append the existing root nodes.

          viewRef.rootNodes.forEach(
          /**
          * @param {?} rootNode
          * @return {?}
          */
          function (rootNode) {
            return _this102.outletElement.appendChild(rootNode);
          });
          this.setDisposeFn(
          /**
          * @return {?}
          */
          function () {
            /** @type {?} */
            var index = viewContainer.indexOf(viewRef);

            if (index !== -1) {
              viewContainer.remove(index);
            }
          }); // TODO(jelbourn): Return locals from view.

          return viewRef;
        }
        /**
         * Clears out a portal from the DOM.
         * @return {?}
         */

      }, {
        key: "dispose",
        value: function dispose() {
          _get(_getPrototypeOf(DomPortalOutlet.prototype), "dispose", this).call(this);

          if (this.outletElement.parentNode != null) {
            this.outletElement.parentNode.removeChild(this.outletElement);
          }
        }
        /**
         * Gets the root HTMLElement for an instantiated component.
         * @private
         * @param {?} componentRef
         * @return {?}
         */

      }, {
        key: "_getComponentRootNode",
        value: function _getComponentRootNode(componentRef) {
          return (
            /** @type {?} */

            /** @type {?} */
            componentRef.hostView.rootNodes[0]
          );
        }
      }]);

      return DomPortalOutlet;
    }(BasePortalOutlet);

    if (false) {}
    /**
     * @deprecated Use `DomPortalOutlet` instead.
     * \@breaking-change 9.0.0
     */


    var DomPortalHost = /*#__PURE__*/function (_DomPortalOutlet) {
      _inherits(DomPortalHost, _DomPortalOutlet);

      var _super14 = _createSuper(DomPortalHost);

      function DomPortalHost() {
        _classCallCheck(this, DomPortalHost);

        return _super14.apply(this, arguments);
      }

      return DomPortalHost;
    }(DomPortalOutlet);
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/portal/portal-directives.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Directive version of a `TemplatePortal`. Because the directive *is* a TemplatePortal,
     * the directive instance itself can be attached to a host, enabling declarative use of portals.
     */


    var CdkPortal = /*#__PURE__*/function (_TemplatePortal) {
      _inherits(CdkPortal, _TemplatePortal);

      var _super15 = _createSuper(CdkPortal);

      /**
       * @param {?} templateRef
       * @param {?} viewContainerRef
       */
      function CdkPortal(templateRef, viewContainerRef) {
        _classCallCheck(this, CdkPortal);

        return _super15.call(this, templateRef, viewContainerRef);
      }

      return CdkPortal;
    }(TemplatePortal);

    CdkPortal.ɵfac = function CdkPortal_Factory(t) {
      return new (t || CdkPortal)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]));
    };

    CdkPortal.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: CdkPortal,
      selectors: [["", "cdkPortal", ""]],
      exportAs: ["cdkPortal"],
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]]
    });
    /** @nocollapse */

    CdkPortal.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](CdkPortal, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[cdkPortal]',
          exportAs: 'cdkPortal'
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]
        }];
      }, null);
    })();
    /**
     * @deprecated Use `CdkPortal` instead.
     * \@breaking-change 9.0.0
     */


    var TemplatePortalDirective = /*#__PURE__*/function (_CdkPortal) {
      _inherits(TemplatePortalDirective, _CdkPortal);

      var _super16 = _createSuper(TemplatePortalDirective);

      function TemplatePortalDirective() {
        _classCallCheck(this, TemplatePortalDirective);

        return _super16.apply(this, arguments);
      }

      return TemplatePortalDirective;
    }(CdkPortal);

    TemplatePortalDirective.ɵfac = function TemplatePortalDirective_Factory(t) {
      return ɵTemplatePortalDirective_BaseFactory(t || TemplatePortalDirective);
    };

    TemplatePortalDirective.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: TemplatePortalDirective,
      selectors: [["", "cdk-portal", ""], ["", "portal", ""]],
      exportAs: ["cdkPortal"],
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([{
        provide: CdkPortal,
        useExisting: TemplatePortalDirective
      }]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]]
    });

    var ɵTemplatePortalDirective_BaseFactory = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵgetInheritedFactory"](TemplatePortalDirective);
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](TemplatePortalDirective, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[cdk-portal], [portal]',
          exportAs: 'cdkPortal',
          providers: [{
            provide: CdkPortal,
            useExisting: TemplatePortalDirective
          }]
        }]
      }], null, null);
    })();
    /**
     * Directive version of a PortalOutlet. Because the directive *is* a PortalOutlet, portals can be
     * directly attached to it, enabling declarative use.
     *
     * Usage:
     * `<ng-template [cdkPortalOutlet]="greeting"></ng-template>`
     */


    var CdkPortalOutlet = /*#__PURE__*/function (_BasePortalOutlet3) {
      _inherits(CdkPortalOutlet, _BasePortalOutlet3);

      var _super17 = _createSuper(CdkPortalOutlet);

      /**
       * @param {?} _componentFactoryResolver
       * @param {?} _viewContainerRef
       * @param {?=} _document
       */
      function CdkPortalOutlet(_componentFactoryResolver, _viewContainerRef,
      /**
       * @deprecated `_document` parameter to be made required.
       * @breaking-change 9.0.0
       */
      _document) {
        var _thisSuper2, _this103;

        _classCallCheck(this, CdkPortalOutlet);

        _this103 = _super17.call(this);
        _this103._componentFactoryResolver = _componentFactoryResolver;
        _this103._viewContainerRef = _viewContainerRef;
        /**
         * Whether the portal component is initialized.
         */

        _this103._isInitialized = false;
        /**
         * Emits when a portal is attached to the outlet.
         */

        _this103.attached = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"]();
        /**
         * Attaches the given DomPortal to this PortalHost by moving all of the portal content into it.
         * @param portal Portal to be attached.
         * @deprecated To be turned into a method.
         * \@breaking-change 10.0.0
         */

        _this103.attachDomPortal =
        /**
        * @param {?} portal
        * @return {?}
        */
        function (portal) {
          // @breaking-change 9.0.0 Remove check and error once the
          // `_document` constructor parameter is required.
          if (!_this103._document) {
            throw Error('Cannot attach DOM portal without _document constructor parameter');
          }
          /** @type {?} */


          var element = portal.element;

          if (!element.parentNode) {
            throw Error('DOM portal content must be attached to a parent node.');
          } // Anchor used to save the element's previous position so
          // that we can restore it when the portal is detached.

          /** @type {?} */


          var anchorNode = _this103._document.createComment('dom-portal');

          portal.setAttachedHost(_assertThisInitialized(_this103));
          element.parentNode.insertBefore(anchorNode, element);

          _this103._getRootNode().appendChild(element);

          _get((_thisSuper2 = _assertThisInitialized(_this103), _getPrototypeOf(CdkPortalOutlet.prototype)), "setDisposeFn", _thisSuper2).call(_thisSuper2,
          /**
          * @return {?}
          */
          function () {
            if (anchorNode.parentNode) {
              /** @type {?} */
              anchorNode.parentNode.replaceChild(element, anchorNode);
            }
          });
        };

        _this103._document = _document;
        return _this103;
      }
      /**
       * Portal associated with the Portal outlet.
       * @return {?}
       */


      _createClass2(CdkPortalOutlet, [{
        key: "ngOnInit",

        /**
         * @return {?}
         */
        value: function ngOnInit() {
          this._isInitialized = true;
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          _get(_getPrototypeOf(CdkPortalOutlet.prototype), "dispose", this).call(this);

          this._attachedPortal = null;
          this._attachedRef = null;
        }
        /**
         * Attach the given ComponentPortal to this PortalOutlet using the ComponentFactoryResolver.
         *
         * @template T
         * @param {?} portal Portal to be attached to the portal outlet.
         * @return {?} Reference to the created component.
         */

      }, {
        key: "attachComponentPortal",
        value: function attachComponentPortal(portal) {
          portal.setAttachedHost(this); // If the portal specifies an origin, use that as the logical location of the component
          // in the application tree. Otherwise use the location of this PortalOutlet.

          /** @type {?} */

          var viewContainerRef = portal.viewContainerRef != null ? portal.viewContainerRef : this._viewContainerRef;
          /** @type {?} */

          var resolver = portal.componentFactoryResolver || this._componentFactoryResolver;
          /** @type {?} */

          var componentFactory = resolver.resolveComponentFactory(portal.component);
          /** @type {?} */

          var ref = viewContainerRef.createComponent(componentFactory, viewContainerRef.length, portal.injector || viewContainerRef.injector); // If we're using a view container that's different from the injected one (e.g. when the portal
          // specifies its own) we need to move the component into the outlet, otherwise it'll be rendered
          // inside of the alternate view container.

          if (viewContainerRef !== this._viewContainerRef) {
            this._getRootNode().appendChild(
            /** @type {?} */
            ref.hostView.rootNodes[0]);
          }

          _get(_getPrototypeOf(CdkPortalOutlet.prototype), "setDisposeFn", this).call(this,
          /**
          * @return {?}
          */
          function () {
            return ref.destroy();
          });

          this._attachedPortal = portal;
          this._attachedRef = ref;
          this.attached.emit(ref);
          return ref;
        }
        /**
         * Attach the given TemplatePortal to this PortalHost as an embedded View.
         * @template C
         * @param {?} portal Portal to be attached.
         * @return {?} Reference to the created embedded view.
         */

      }, {
        key: "attachTemplatePortal",
        value: function attachTemplatePortal(portal) {
          var _this104 = this;

          portal.setAttachedHost(this);
          /** @type {?} */

          var viewRef = this._viewContainerRef.createEmbeddedView(portal.templateRef, portal.context);

          _get(_getPrototypeOf(CdkPortalOutlet.prototype), "setDisposeFn", this).call(this,
          /**
          * @return {?}
          */
          function () {
            return _this104._viewContainerRef.clear();
          });

          this._attachedPortal = portal;
          this._attachedRef = viewRef;
          this.attached.emit(viewRef);
          return viewRef;
        }
        /**
         * Gets the root node of the portal outlet.
         * @private
         * @return {?}
         */

      }, {
        key: "_getRootNode",
        value: function _getRootNode() {
          /** @type {?} */
          var nativeElement = this._viewContainerRef.element.nativeElement; // The directive could be set on a template which will result in a comment
          // node being the root. Use the comment's parent node if that is the case.

          return (
            /** @type {?} */
            nativeElement.nodeType === nativeElement.ELEMENT_NODE ? nativeElement :
            /** @type {?} */
            nativeElement.parentNode
          );
        }
      }, {
        key: "portal",
        get: function get() {
          return this._attachedPortal;
        }
        /**
         * @param {?} portal
         * @return {?}
         */
        ,
        set: function set(portal) {
          // Ignore the cases where the `portal` is set to a falsy value before the lifecycle hooks have
          // run. This handles the cases where the user might do something like `<div cdkPortalOutlet>`
          // and attach a portal programmatically in the parent component. When Angular does the first CD
          // round, it will fire the setter with empty string, causing the user's content to be cleared.
          if (this.hasAttached() && !portal && !this._isInitialized) {
            return;
          }

          if (this.hasAttached()) {
            _get(_getPrototypeOf(CdkPortalOutlet.prototype), "detach", this).call(this);
          }

          if (portal) {
            _get(_getPrototypeOf(CdkPortalOutlet.prototype), "attach", this).call(this, portal);
          }

          this._attachedPortal = portal;
        }
        /**
         * Component or view reference that is attached to the portal.
         * @return {?}
         */

      }, {
        key: "attachedRef",
        get: function get() {
          return this._attachedRef;
        }
      }]);

      return CdkPortalOutlet;
    }(BasePortalOutlet);

    CdkPortalOutlet.ɵfac = function CdkPortalOutlet_Factory(t) {
      return new (t || CdkPortalOutlet)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ComponentFactoryResolver"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_common__WEBPACK_IMPORTED_MODULE_1__["DOCUMENT"]));
    };

    CdkPortalOutlet.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: CdkPortalOutlet,
      selectors: [["", "cdkPortalOutlet", ""]],
      inputs: {
        portal: ["cdkPortalOutlet", "portal"]
      },
      outputs: {
        attached: "attached"
      },
      exportAs: ["cdkPortalOutlet"],
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]]
    });
    /** @nocollapse */

    CdkPortalOutlet.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ComponentFactoryResolver"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_1__["DOCUMENT"]]
        }]
      }];
    };

    CdkPortalOutlet.propDecorators = {
      attached: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Output"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](CdkPortalOutlet, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[cdkPortalOutlet]',
          exportAs: 'cdkPortalOutlet',
          inputs: ['portal: cdkPortalOutlet']
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ComponentFactoryResolver"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_1__["DOCUMENT"]]
          }]
        }];
      }, {
        attached: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Output"]
        }]
      });
    })();

    if (false) {}
    /**
     * @deprecated Use `CdkPortalOutlet` instead.
     * \@breaking-change 9.0.0
     */


    var PortalHostDirective = /*#__PURE__*/function (_CdkPortalOutlet) {
      _inherits(PortalHostDirective, _CdkPortalOutlet);

      var _super18 = _createSuper(PortalHostDirective);

      function PortalHostDirective() {
        _classCallCheck(this, PortalHostDirective);

        return _super18.apply(this, arguments);
      }

      return PortalHostDirective;
    }(CdkPortalOutlet);

    PortalHostDirective.ɵfac = function PortalHostDirective_Factory(t) {
      return ɵPortalHostDirective_BaseFactory(t || PortalHostDirective);
    };

    PortalHostDirective.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: PortalHostDirective,
      selectors: [["", "cdkPortalHost", ""], ["", "portalHost", ""]],
      inputs: {
        portal: ["cdkPortalHost", "portal"]
      },
      exportAs: ["cdkPortalHost"],
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([{
        provide: CdkPortalOutlet,
        useExisting: PortalHostDirective
      }]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]]
    });

    var ɵPortalHostDirective_BaseFactory = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵgetInheritedFactory"](PortalHostDirective);
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](PortalHostDirective, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[cdkPortalHost], [portalHost]',
          exportAs: 'cdkPortalHost',
          inputs: ['portal: cdkPortalHost'],
          providers: [{
            provide: CdkPortalOutlet,
            useExisting: PortalHostDirective
          }]
        }]
      }], null, null);
    })();

    var PortalModule = function PortalModule() {
      _classCallCheck(this, PortalModule);
    };

    PortalModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: PortalModule
    });
    PortalModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function PortalModule_Factory(t) {
        return new (t || PortalModule)();
      }
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](PortalModule, {
        declarations: [CdkPortal, CdkPortalOutlet, TemplatePortalDirective, PortalHostDirective],
        exports: [CdkPortal, CdkPortalOutlet, TemplatePortalDirective, PortalHostDirective]
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](PortalModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{
          exports: [CdkPortal, CdkPortalOutlet, TemplatePortalDirective, PortalHostDirective],
          declarations: [CdkPortal, CdkPortalOutlet, TemplatePortalDirective, PortalHostDirective]
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/portal/portal-injector.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Custom injector to be used when providing custom
     * injection tokens to components inside a portal.
     * \@docs-private
     */


    var PortalInjector = /*#__PURE__*/function () {
      /**
       * @param {?} _parentInjector
       * @param {?} _customTokens
       */
      function PortalInjector(_parentInjector, _customTokens) {
        _classCallCheck(this, PortalInjector);

        this._parentInjector = _parentInjector;
        this._customTokens = _customTokens;
      }
      /**
       * @param {?} token
       * @param {?=} notFoundValue
       * @return {?}
       */


      _createClass2(PortalInjector, [{
        key: "get",
        value: function get(token, notFoundValue) {
          /** @type {?} */
          var value = this._customTokens.get(token);

          if (typeof value !== 'undefined') {
            return value;
          }

          return this._parentInjector.get(token, notFoundValue);
        }
      }]);

      return PortalInjector;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/portal/public-api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=portal.js.map

    /***/

  },

  /***/
  "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/scrolling.js":
  /*!**********************************************************************!*\
    !*** ./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/scrolling.js ***!
    \**********************************************************************/

  /*! exports provided: CdkFixedSizeVirtualScroll, CdkScrollable, CdkScrollableModule, CdkVirtualForOf, CdkVirtualScrollViewport, DEFAULT_RESIZE_TIME, DEFAULT_SCROLL_TIME, FixedSizeVirtualScrollStrategy, ScrollDispatcher, ScrollingModule, VIRTUAL_SCROLL_STRATEGY, ViewportRuler, _fixedSizeVirtualScrollStrategyFactory */

  /***/
  function node_modulesAngularCdk__ivy_ngcc__Fesm2015ScrollingJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CdkFixedSizeVirtualScroll", function () {
      return CdkFixedSizeVirtualScroll;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CdkScrollable", function () {
      return CdkScrollable;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CdkScrollableModule", function () {
      return CdkScrollableModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CdkVirtualForOf", function () {
      return CdkVirtualForOf;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CdkVirtualScrollViewport", function () {
      return CdkVirtualScrollViewport;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DEFAULT_RESIZE_TIME", function () {
      return DEFAULT_RESIZE_TIME;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DEFAULT_SCROLL_TIME", function () {
      return DEFAULT_SCROLL_TIME;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FixedSizeVirtualScrollStrategy", function () {
      return FixedSizeVirtualScrollStrategy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ScrollDispatcher", function () {
      return ScrollDispatcher;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ScrollingModule", function () {
      return ScrollingModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "VIRTUAL_SCROLL_STRATEGY", function () {
      return VIRTUAL_SCROLL_STRATEGY;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ViewportRuler", function () {
      return ViewportRuler;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "_fixedSizeVirtualScrollStrategyFactory", function () {
      return _fixedSizeVirtualScrollStrategyFactory;
    });
    /* harmony import */


    var _angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/cdk/coercion */
    "./node_modules/@angular/cdk/fesm2015/coercion.js");
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var rxjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! rxjs */
    "./node_modules/rxjs/_esm2015/index.js");
    /* harmony import */


    var rxjs_operators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! rxjs/operators */
    "./node_modules/rxjs/_esm2015/operators/index.js");
    /* harmony import */


    var _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! @angular/cdk/platform */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/platform.js");
    /* harmony import */


    var _angular_common__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(
    /*! @angular/common */
    "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/common.js");
    /* harmony import */


    var _angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(
    /*! @angular/cdk/bidi */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/bidi.js");
    /* harmony import */


    var _angular_cdk_collections__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(
    /*! @angular/cdk/collections */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/collections.js");
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/scrolling/virtual-scroll-strategy.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * The injection token used to specify the virtual scrolling strategy.
     * @type {?}
     */


    var _c0 = ["contentWrapper"];
    var _c1 = ["*"];
    var VIRTUAL_SCROLL_STRATEGY = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["InjectionToken"]('VIRTUAL_SCROLL_STRATEGY');
    /**
     * A strategy that dictates which items should be rendered in the viewport.
     * @record
     */

    function VirtualScrollStrategy() {}

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/scrolling/fixed-size-virtual-scroll.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Virtual scrolling strategy for lists with items of known fixed size.
     */


    var FixedSizeVirtualScrollStrategy = /*#__PURE__*/function () {
      /**
       * @param {?} itemSize The size of the items in the virtually scrolling list.
       * @param {?} minBufferPx The minimum amount of buffer (in pixels) before needing to render more
       * @param {?} maxBufferPx The amount of buffer (in pixels) to render when rendering more.
       */
      function FixedSizeVirtualScrollStrategy(itemSize, minBufferPx, maxBufferPx) {
        _classCallCheck(this, FixedSizeVirtualScrollStrategy);

        this._scrolledIndexChange = new rxjs__WEBPACK_IMPORTED_MODULE_2__["Subject"]();
        /**
         * \@docs-private Implemented as part of VirtualScrollStrategy.
         */

        this.scrolledIndexChange = this._scrolledIndexChange.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["distinctUntilChanged"])());
        /**
         * The attached viewport.
         */

        this._viewport = null;
        this._itemSize = itemSize;
        this._minBufferPx = minBufferPx;
        this._maxBufferPx = maxBufferPx;
      }
      /**
       * Attaches this scroll strategy to a viewport.
       * @param {?} viewport The viewport to attach this strategy to.
       * @return {?}
       */


      _createClass2(FixedSizeVirtualScrollStrategy, [{
        key: "attach",
        value: function attach(viewport) {
          this._viewport = viewport;

          this._updateTotalContentSize();

          this._updateRenderedRange();
        }
        /**
         * Detaches this scroll strategy from the currently attached viewport.
         * @return {?}
         */

      }, {
        key: "detach",
        value: function detach() {
          this._scrolledIndexChange.complete();

          this._viewport = null;
        }
        /**
         * Update the item size and buffer size.
         * @param {?} itemSize The size of the items in the virtually scrolling list.
         * @param {?} minBufferPx The minimum amount of buffer (in pixels) before needing to render more
         * @param {?} maxBufferPx The amount of buffer (in pixels) to render when rendering more.
         * @return {?}
         */

      }, {
        key: "updateItemAndBufferSize",
        value: function updateItemAndBufferSize(itemSize, minBufferPx, maxBufferPx) {
          if (maxBufferPx < minBufferPx) {
            throw Error('CDK virtual scroll: maxBufferPx must be greater than or equal to minBufferPx');
          }

          this._itemSize = itemSize;
          this._minBufferPx = minBufferPx;
          this._maxBufferPx = maxBufferPx;

          this._updateTotalContentSize();

          this._updateRenderedRange();
        }
        /**
         * \@docs-private Implemented as part of VirtualScrollStrategy.
         * @return {?}
         */

      }, {
        key: "onContentScrolled",
        value: function onContentScrolled() {
          this._updateRenderedRange();
        }
        /**
         * \@docs-private Implemented as part of VirtualScrollStrategy.
         * @return {?}
         */

      }, {
        key: "onDataLengthChanged",
        value: function onDataLengthChanged() {
          this._updateTotalContentSize();

          this._updateRenderedRange();
        }
        /**
         * \@docs-private Implemented as part of VirtualScrollStrategy.
         * @return {?}
         */

      }, {
        key: "onContentRendered",
        value: function onContentRendered() {}
        /**
         * \@docs-private Implemented as part of VirtualScrollStrategy.
         * @return {?}
         */

      }, {
        key: "onRenderedOffsetChanged",
        value: function onRenderedOffsetChanged() {}
        /**
         * Scroll to the offset for the given index.
         * @param {?} index The index of the element to scroll to.
         * @param {?} behavior The ScrollBehavior to use when scrolling.
         * @return {?}
         */

      }, {
        key: "scrollToIndex",
        value: function scrollToIndex(index, behavior) {
          if (this._viewport) {
            this._viewport.scrollToOffset(index * this._itemSize, behavior);
          }
        }
        /**
         * Update the viewport's total content size.
         * @private
         * @return {?}
         */

      }, {
        key: "_updateTotalContentSize",
        value: function _updateTotalContentSize() {
          if (!this._viewport) {
            return;
          }

          this._viewport.setTotalContentSize(this._viewport.getDataLength() * this._itemSize);
        }
        /**
         * Update the viewport's rendered range.
         * @private
         * @return {?}
         */

      }, {
        key: "_updateRenderedRange",
        value: function _updateRenderedRange() {
          if (!this._viewport) {
            return;
          }
          /** @type {?} */


          var scrollOffset = this._viewport.measureScrollOffset();
          /** @type {?} */


          var firstVisibleIndex = scrollOffset / this._itemSize;
          /** @type {?} */

          var renderedRange = this._viewport.getRenderedRange();
          /** @type {?} */


          var newRange = {
            start: renderedRange.start,
            end: renderedRange.end
          };
          /** @type {?} */

          var viewportSize = this._viewport.getViewportSize();
          /** @type {?} */


          var dataLength = this._viewport.getDataLength();
          /** @type {?} */


          var startBuffer = scrollOffset - newRange.start * this._itemSize;

          if (startBuffer < this._minBufferPx && newRange.start != 0) {
            /** @type {?} */
            var expandStart = Math.ceil((this._maxBufferPx - startBuffer) / this._itemSize);
            newRange.start = Math.max(0, newRange.start - expandStart);
            newRange.end = Math.min(dataLength, Math.ceil(firstVisibleIndex + (viewportSize + this._minBufferPx) / this._itemSize));
          } else {
            /** @type {?} */
            var endBuffer = newRange.end * this._itemSize - (scrollOffset + viewportSize);

            if (endBuffer < this._minBufferPx && newRange.end != dataLength) {
              /** @type {?} */
              var expandEnd = Math.ceil((this._maxBufferPx - endBuffer) / this._itemSize);

              if (expandEnd > 0) {
                newRange.end = Math.min(dataLength, newRange.end + expandEnd);
                newRange.start = Math.max(0, Math.floor(firstVisibleIndex - this._minBufferPx / this._itemSize));
              }
            }
          }

          this._viewport.setRenderedRange(newRange);

          this._viewport.setRenderedContentOffset(this._itemSize * newRange.start);

          this._scrolledIndexChange.next(Math.floor(firstVisibleIndex));
        }
      }]);

      return FixedSizeVirtualScrollStrategy;
    }();

    if (false) {}
    /**
     * Provider factory for `FixedSizeVirtualScrollStrategy` that simply extracts the already created
     * `FixedSizeVirtualScrollStrategy` from the given directive.
     * @param {?} fixedSizeDir The instance of `CdkFixedSizeVirtualScroll` to extract the
     *     `FixedSizeVirtualScrollStrategy` from.
     * @return {?}
     */


    function _fixedSizeVirtualScrollStrategyFactory(fixedSizeDir) {
      return fixedSizeDir._scrollStrategy;
    }
    /**
     * A virtual scroll strategy that supports fixed-size items.
     */


    var CdkFixedSizeVirtualScroll = /*#__PURE__*/function () {
      function CdkFixedSizeVirtualScroll() {
        _classCallCheck(this, CdkFixedSizeVirtualScroll);

        this._itemSize = 20;
        this._minBufferPx = 100;
        this._maxBufferPx = 200;
        /**
         * The scroll strategy used by this directive.
         */

        this._scrollStrategy = new FixedSizeVirtualScrollStrategy(this.itemSize, this.minBufferPx, this.maxBufferPx);
      }
      /**
       * The size of the items in the list (in pixels).
       * @return {?}
       */


      _createClass2(CdkFixedSizeVirtualScroll, [{
        key: "ngOnChanges",

        /**
         * @return {?}
         */
        value: function ngOnChanges() {
          this._scrollStrategy.updateItemAndBufferSize(this.itemSize, this.minBufferPx, this.maxBufferPx);
        }
      }, {
        key: "itemSize",
        get: function get() {
          return this._itemSize;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._itemSize = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_0__["coerceNumberProperty"])(value);
        }
        /**
         * The minimum amount of buffer rendered beyond the viewport (in pixels).
         * If the amount of buffer dips below this number, more items will be rendered. Defaults to 100px.
         * @return {?}
         */

      }, {
        key: "minBufferPx",
        get: function get() {
          return this._minBufferPx;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._minBufferPx = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_0__["coerceNumberProperty"])(value);
        }
        /**
         * The number of pixels worth of buffer to render for when rendering new items. Defaults to 200px.
         * @return {?}
         */

      }, {
        key: "maxBufferPx",
        get: function get() {
          return this._maxBufferPx;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._maxBufferPx = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_0__["coerceNumberProperty"])(value);
        }
      }]);

      return CdkFixedSizeVirtualScroll;
    }();

    CdkFixedSizeVirtualScroll.ɵfac = function CdkFixedSizeVirtualScroll_Factory(t) {
      return new (t || CdkFixedSizeVirtualScroll)();
    };

    CdkFixedSizeVirtualScroll.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineDirective"]({
      type: CdkFixedSizeVirtualScroll,
      selectors: [["cdk-virtual-scroll-viewport", "itemSize", ""]],
      inputs: {
        itemSize: "itemSize",
        minBufferPx: "minBufferPx",
        maxBufferPx: "maxBufferPx"
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵProvidersFeature"]([{
        provide: VIRTUAL_SCROLL_STRATEGY,
        useFactory: _fixedSizeVirtualScrollStrategyFactory,
        deps: [Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["forwardRef"])(
        /**
        * @return {?}
        */
        function () {
          return CdkFixedSizeVirtualScroll;
        })]
      }]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵNgOnChangesFeature"]]
    });
    CdkFixedSizeVirtualScroll.propDecorators = {
      itemSize: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      minBufferPx: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      maxBufferPx: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](CdkFixedSizeVirtualScroll, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Directive"],
        args: [{
          selector: 'cdk-virtual-scroll-viewport[itemSize]',
          providers: [{
            provide: VIRTUAL_SCROLL_STRATEGY,
            useFactory: _fixedSizeVirtualScrollStrategyFactory,
            deps: [Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["forwardRef"])(
            /**
            * @return {?}
            */
            function () {
              return CdkFixedSizeVirtualScroll;
            })]
          }]
        }]
      }], function () {
        return [];
      }, {
        itemSize: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        minBufferPx: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        maxBufferPx: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/scrolling/scroll-dispatcher.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Time in ms to throttle the scrolling events by default.
     * @type {?}
     */


    var DEFAULT_SCROLL_TIME = 20;
    /**
     * Service contained all registered Scrollable references and emits an event when any one of the
     * Scrollable references emit a scrolled event.
     */

    var ScrollDispatcher = /*#__PURE__*/function () {
      /**
       * @param {?} _ngZone
       * @param {?} _platform
       * @param {?=} document
       */
      function ScrollDispatcher(_ngZone, _platform,
      /** @breaking-change 11.0.0 make document required */
      document) {
        _classCallCheck(this, ScrollDispatcher);

        this._ngZone = _ngZone;
        this._platform = _platform;
        /**
         * Subject for notifying that a registered scrollable reference element has been scrolled.
         */

        this._scrolled = new rxjs__WEBPACK_IMPORTED_MODULE_2__["Subject"]();
        /**
         * Keeps track of the global `scroll` and `resize` subscriptions.
         */

        this._globalSubscription = null;
        /**
         * Keeps track of the amount of subscriptions to `scrolled`. Used for cleaning up afterwards.
         */

        this._scrolledCount = 0;
        /**
         * Map of all the scrollable references that are registered with the service and their
         * scroll event subscriptions.
         */

        this.scrollContainers = new Map();
        this._document = document;
      }
      /**
       * Registers a scrollable instance with the service and listens for its scrolled events. When the
       * scrollable is scrolled, the service emits the event to its scrolled observable.
       * @param {?} scrollable Scrollable instance to be registered.
       * @return {?}
       */


      _createClass2(ScrollDispatcher, [{
        key: "register",
        value: function register(scrollable) {
          var _this105 = this;

          if (!this.scrollContainers.has(scrollable)) {
            this.scrollContainers.set(scrollable, scrollable.elementScrolled().subscribe(
            /**
            * @return {?}
            */
            function () {
              return _this105._scrolled.next(scrollable);
            }));
          }
        }
        /**
         * Deregisters a Scrollable reference and unsubscribes from its scroll event observable.
         * @param {?} scrollable Scrollable instance to be deregistered.
         * @return {?}
         */

      }, {
        key: "deregister",
        value: function deregister(scrollable) {
          /** @type {?} */
          var scrollableReference = this.scrollContainers.get(scrollable);

          if (scrollableReference) {
            scrollableReference.unsubscribe();
            this.scrollContainers["delete"](scrollable);
          }
        }
        /**
         * Returns an observable that emits an event whenever any of the registered Scrollable
         * references (or window, document, or body) fire a scrolled event. Can provide a time in ms
         * to override the default "throttle" time.
         *
         * **Note:** in order to avoid hitting change detection for every scroll event,
         * all of the events emitted from this stream will be run outside the Angular zone.
         * If you need to update any data bindings as a result of a scroll event, you have
         * to run the callback using `NgZone.run`.
         * @param {?=} auditTimeInMs
         * @return {?}
         */

      }, {
        key: "scrolled",
        value: function scrolled() {
          var _this106 = this;

          var auditTimeInMs = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : DEFAULT_SCROLL_TIME;

          if (!this._platform.isBrowser) {
            return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])();
          }

          return new rxjs__WEBPACK_IMPORTED_MODULE_2__["Observable"](
          /**
          * @param {?} observer
          * @return {?}
          */
          function (observer) {
            if (!_this106._globalSubscription) {
              _this106._addGlobalListener();
            } // In the case of a 0ms delay, use an observable without auditTime
            // since it does add a perceptible delay in processing overhead.

            /** @type {?} */


            var subscription = auditTimeInMs > 0 ? _this106._scrolled.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["auditTime"])(auditTimeInMs)).subscribe(observer) : _this106._scrolled.subscribe(observer);
            _this106._scrolledCount++;
            return (
              /**
              * @return {?}
              */
              function () {
                subscription.unsubscribe();
                _this106._scrolledCount--;

                if (!_this106._scrolledCount) {
                  _this106._removeGlobalListener();
                }
              }
            );
          });
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          var _this107 = this;

          this._removeGlobalListener();

          this.scrollContainers.forEach(
          /**
          * @param {?} _
          * @param {?} container
          * @return {?}
          */
          function (_, container) {
            return _this107.deregister(container);
          });

          this._scrolled.complete();
        }
        /**
         * Returns an observable that emits whenever any of the
         * scrollable ancestors of an element are scrolled.
         * @param {?} elementRef Element whose ancestors to listen for.
         * @param {?=} auditTimeInMs Time to throttle the scroll events.
         * @return {?}
         */

      }, {
        key: "ancestorScrolled",
        value: function ancestorScrolled(elementRef, auditTimeInMs) {
          /** @type {?} */
          var ancestors = this.getAncestorScrollContainers(elementRef);
          return this.scrolled(auditTimeInMs).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["filter"])(
          /**
          * @param {?} target
          * @return {?}
          */
          function (target) {
            return !target || ancestors.indexOf(target) > -1;
          }));
        }
        /**
         * Returns all registered Scrollables that contain the provided element.
         * @param {?} elementRef
         * @return {?}
         */

      }, {
        key: "getAncestorScrollContainers",
        value: function getAncestorScrollContainers(elementRef) {
          var _this108 = this;

          /** @type {?} */
          var scrollingContainers = [];
          this.scrollContainers.forEach(
          /**
          * @param {?} _subscription
          * @param {?} scrollable
          * @return {?}
          */
          function (_subscription, scrollable) {
            if (_this108._scrollableContainsElement(scrollable, elementRef)) {
              scrollingContainers.push(scrollable);
            }
          });
          return scrollingContainers;
        }
        /**
         * Access injected document if available or fallback to global document reference
         * @private
         * @return {?}
         */

      }, {
        key: "_getDocument",
        value: function _getDocument() {
          return this._document || document;
        }
        /**
         * Use defaultView of injected document if available or fallback to global window reference
         * @private
         * @return {?}
         */

      }, {
        key: "_getWindow",
        value: function _getWindow() {
          /** @type {?} */
          var doc = this._getDocument();

          return doc.defaultView || window;
        }
        /**
         * Returns true if the element is contained within the provided Scrollable.
         * @private
         * @param {?} scrollable
         * @param {?} elementRef
         * @return {?}
         */

      }, {
        key: "_scrollableContainsElement",
        value: function _scrollableContainsElement(scrollable, elementRef) {
          /** @type {?} */
          var element = elementRef.nativeElement;
          /** @type {?} */

          var scrollableElement = scrollable.getElementRef().nativeElement; // Traverse through the element parents until we reach null, checking if any of the elements
          // are the scrollable's element.

          do {
            if (element == scrollableElement) {
              return true;
            }
          } while (element =
          /** @type {?} */
          element.parentElement);

          return false;
        }
        /**
         * Sets up the global scroll listeners.
         * @private
         * @return {?}
         */

      }, {
        key: "_addGlobalListener",
        value: function _addGlobalListener() {
          var _this109 = this;

          this._globalSubscription = this._ngZone.runOutsideAngular(
          /**
          * @return {?}
          */
          function () {
            /** @type {?} */
            var window = _this109._getWindow();

            return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["fromEvent"])(window.document, 'scroll').subscribe(
            /**
            * @return {?}
            */
            function () {
              return _this109._scrolled.next();
            });
          });
        }
        /**
         * Cleans up the global scroll listener.
         * @private
         * @return {?}
         */

      }, {
        key: "_removeGlobalListener",
        value: function _removeGlobalListener() {
          if (this._globalSubscription) {
            this._globalSubscription.unsubscribe();

            this._globalSubscription = null;
          }
        }
      }]);

      return ScrollDispatcher;
    }();

    ScrollDispatcher.ɵfac = function ScrollDispatcher_Factory(t) {
      return new (t || ScrollDispatcher)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_4__["Platform"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_5__["DOCUMENT"], 8));
    };
    /** @nocollapse */


    ScrollDispatcher.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
      }, {
        type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_4__["Platform"]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_5__["DOCUMENT"]]
        }]
      }];
    };
    /** @nocollapse */


    ScrollDispatcher.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: function ScrollDispatcher_Factory() {
        return new ScrollDispatcher(Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_4__["Platform"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_common__WEBPACK_IMPORTED_MODULE_5__["DOCUMENT"], 8));
      },
      token: ScrollDispatcher,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](ScrollDispatcher, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
        }, {
          type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_4__["Platform"]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_5__["DOCUMENT"]]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/scrolling/scrollable.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Sends an event when the directive's element is scrolled. Registers itself with the
     * ScrollDispatcher service to include itself as part of its collection of scrolling events that it
     * can be listened to through the service.
     */


    var CdkScrollable = /*#__PURE__*/function () {
      /**
       * @param {?} elementRef
       * @param {?} scrollDispatcher
       * @param {?} ngZone
       * @param {?=} dir
       */
      function CdkScrollable(elementRef, scrollDispatcher, ngZone, dir) {
        var _this110 = this;

        _classCallCheck(this, CdkScrollable);

        this.elementRef = elementRef;
        this.scrollDispatcher = scrollDispatcher;
        this.ngZone = ngZone;
        this.dir = dir;
        this._destroyed = new rxjs__WEBPACK_IMPORTED_MODULE_2__["Subject"]();
        this._elementScrolled = new rxjs__WEBPACK_IMPORTED_MODULE_2__["Observable"](
        /**
        * @param {?} observer
        * @return {?}
        */
        function (observer) {
          return _this110.ngZone.runOutsideAngular(
          /**
          * @return {?}
          */
          function () {
            return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["fromEvent"])(_this110.elementRef.nativeElement, 'scroll').pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["takeUntil"])(_this110._destroyed)).subscribe(observer);
          });
        });
      }
      /**
       * @return {?}
       */


      _createClass2(CdkScrollable, [{
        key: "ngOnInit",
        value: function ngOnInit() {
          this.scrollDispatcher.register(this);
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this.scrollDispatcher.deregister(this);

          this._destroyed.next();

          this._destroyed.complete();
        }
        /**
         * Returns observable that emits when a scroll event is fired on the host element.
         * @return {?}
         */

      }, {
        key: "elementScrolled",
        value: function elementScrolled() {
          return this._elementScrolled;
        }
        /**
         * Gets the ElementRef for the viewport.
         * @return {?}
         */

      }, {
        key: "getElementRef",
        value: function getElementRef() {
          return this.elementRef;
        }
        /**
         * Scrolls to the specified offsets. This is a normalized version of the browser's native scrollTo
         * method, since browsers are not consistent about what scrollLeft means in RTL. For this method
         * left and right always refer to the left and right side of the scrolling container irrespective
         * of the layout direction. start and end refer to left and right in an LTR context and vice-versa
         * in an RTL context.
         * @param {?} options specified the offsets to scroll to.
         * @return {?}
         */

      }, {
        key: "scrollTo",
        value: function scrollTo(options) {
          /** @type {?} */
          var el = this.elementRef.nativeElement;
          /** @type {?} */

          var isRtl = this.dir && this.dir.value == 'rtl'; // Rewrite start & end offsets as right or left offsets.

          if (options.left == null) {
            options.left = isRtl ? options.end : options.start;
          }

          if (options.right == null) {
            options.right = isRtl ? options.start : options.end;
          } // Rewrite the bottom offset as a top offset.


          if (options.bottom != null) {
            /** @type {?} */
            options.top = el.scrollHeight - el.clientHeight - options.bottom;
          } // Rewrite the right offset as a left offset.


          if (isRtl && Object(_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_4__["getRtlScrollAxisType"])() != 0
          /* NORMAL */
          ) {
              if (options.left != null) {
                /** @type {?} */
                options.right = el.scrollWidth - el.clientWidth - options.left;
              }

              if (Object(_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_4__["getRtlScrollAxisType"])() == 2
              /* INVERTED */
              ) {
                  options.left = options.right;
                } else if (Object(_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_4__["getRtlScrollAxisType"])() == 1
              /* NEGATED */
              ) {
                  options.left = options.right ? -options.right : options.right;
                }
            } else {
            if (options.right != null) {
              /** @type {?} */
              options.left = el.scrollWidth - el.clientWidth - options.right;
            }
          }

          this._applyScrollToOptions(options);
        }
        /**
         * @private
         * @param {?} options
         * @return {?}
         */

      }, {
        key: "_applyScrollToOptions",
        value: function _applyScrollToOptions(options) {
          /** @type {?} */
          var el = this.elementRef.nativeElement;

          if (Object(_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_4__["supportsScrollBehavior"])()) {
            el.scrollTo(options);
          } else {
            if (options.top != null) {
              el.scrollTop = options.top;
            }

            if (options.left != null) {
              el.scrollLeft = options.left;
            }
          }
        }
        /**
         * Measures the scroll offset relative to the specified edge of the viewport. This method can be
         * used instead of directly checking scrollLeft or scrollTop, since browsers are not consistent
         * about what scrollLeft means in RTL. The values returned by this method are normalized such that
         * left and right always refer to the left and right side of the scrolling container irrespective
         * of the layout direction. start and end refer to left and right in an LTR context and vice-versa
         * in an RTL context.
         * @param {?} from The edge to measure from.
         * @return {?}
         */

      }, {
        key: "measureScrollOffset",
        value: function measureScrollOffset(from) {
          /** @type {?} */
          var LEFT = 'left';
          /** @type {?} */

          var RIGHT = 'right';
          /** @type {?} */

          var el = this.elementRef.nativeElement;

          if (from == 'top') {
            return el.scrollTop;
          }

          if (from == 'bottom') {
            return el.scrollHeight - el.clientHeight - el.scrollTop;
          } // Rewrite start & end as left or right offsets.

          /** @type {?} */


          var isRtl = this.dir && this.dir.value == 'rtl';

          if (from == 'start') {
            from = isRtl ? RIGHT : LEFT;
          } else if (from == 'end') {
            from = isRtl ? LEFT : RIGHT;
          }

          if (isRtl && Object(_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_4__["getRtlScrollAxisType"])() == 2
          /* INVERTED */
          ) {
              // For INVERTED, scrollLeft is (scrollWidth - clientWidth) when scrolled all the way left and
              // 0 when scrolled all the way right.
              if (from == LEFT) {
                return el.scrollWidth - el.clientWidth - el.scrollLeft;
              } else {
                return el.scrollLeft;
              }
            } else if (isRtl && Object(_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_4__["getRtlScrollAxisType"])() == 1
          /* NEGATED */
          ) {
              // For NEGATED, scrollLeft is -(scrollWidth - clientWidth) when scrolled all the way left and
              // 0 when scrolled all the way right.
              if (from == LEFT) {
                return el.scrollLeft + el.scrollWidth - el.clientWidth;
              } else {
                return -el.scrollLeft;
              }
            } else {
            // For NORMAL, as well as non-RTL contexts, scrollLeft is 0 when scrolled all the way left and
            // (scrollWidth - clientWidth) when scrolled all the way right.
            if (from == LEFT) {
              return el.scrollLeft;
            } else {
              return el.scrollWidth - el.clientWidth - el.scrollLeft;
            }
          }
        }
      }]);

      return CdkScrollable;
    }();

    CdkScrollable.ɵfac = function CdkScrollable_Factory(t) {
      return new (t || CdkScrollable)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](ScrollDispatcher), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_6__["Directionality"], 8));
    };

    CdkScrollable.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineDirective"]({
      type: CdkScrollable,
      selectors: [["", "cdk-scrollable", ""], ["", "cdkScrollable", ""]]
    });
    /** @nocollapse */

    CdkScrollable.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]
      }, {
        type: ScrollDispatcher
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
      }, {
        type: _angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_6__["Directionality"],
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](CdkScrollable, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Directive"],
        args: [{
          selector: '[cdk-scrollable], [cdkScrollable]'
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]
        }, {
          type: ScrollDispatcher
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
        }, {
          type: _angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_6__["Directionality"],
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/scrolling/viewport-ruler.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Time in ms to throttle the resize events by default.
     * @type {?}
     */


    var DEFAULT_RESIZE_TIME = 20;
    /**
     * Object that holds the scroll position of the viewport in each direction.
     * @record
     */

    function ViewportScrollPosition() {}

    if (false) {}
    /**
     * Simple utility for getting the bounds of the browser viewport.
     * \@docs-private
     */


    var ViewportRuler = /*#__PURE__*/function () {
      /**
       * @param {?} _platform
       * @param {?} ngZone
       * @param {?=} document
       */
      function ViewportRuler(_platform, ngZone,
      /** @breaking-change 11.0.0 make document required */
      document) {
        var _this111 = this;

        _classCallCheck(this, ViewportRuler);

        this._platform = _platform;
        this._document = document;
        ngZone.runOutsideAngular(
        /**
        * @return {?}
        */
        function () {
          /** @type {?} */
          var window = _this111._getWindow();

          _this111._change = _platform.isBrowser ? Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["merge"])(Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["fromEvent"])(window, 'resize'), Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["fromEvent"])(window, 'orientationchange')) : Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(); // Note that we need to do the subscription inside `runOutsideAngular`
          // since subscribing is what causes the event listener to be added.

          _this111._invalidateCache = _this111.change().subscribe(
          /**
          * @return {?}
          */
          function () {
            return _this111._updateViewportSize();
          });
        });
      }
      /**
       * @return {?}
       */


      _createClass2(ViewportRuler, [{
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this._invalidateCache.unsubscribe();
        }
        /**
         * Returns the viewport's width and height.
         * @return {?}
         */

      }, {
        key: "getViewportSize",
        value: function getViewportSize() {
          if (!this._viewportSize) {
            this._updateViewportSize();
          }
          /** @type {?} */


          var output = {
            width: this._viewportSize.width,
            height: this._viewportSize.height
          }; // If we're not on a browser, don't cache the size since it'll be mocked out anyway.

          if (!this._platform.isBrowser) {
            this._viewportSize =
            /** @type {?} */
            null;
          }

          return output;
        }
        /**
         * Gets a ClientRect for the viewport's bounds.
         * @return {?}
         */

      }, {
        key: "getViewportRect",
        value: function getViewportRect() {
          // Use the document element's bounding rect rather than the window scroll properties
          // (e.g. pageYOffset, scrollY) due to in issue in Chrome and IE where window scroll
          // properties and client coordinates (boundingClientRect, clientX/Y, etc.) are in different
          // conceptual viewports. Under most circumstances these viewports are equivalent, but they
          // can disagree when the page is pinch-zoomed (on devices that support touch).
          // See https://bugs.chromium.org/p/chromium/issues/detail?id=489206#c4
          // We use the documentElement instead of the body because, by default (without a css reset)
          // browsers typically give the document body an 8px margin, which is not included in
          // getBoundingClientRect().

          /** @type {?} */
          var scrollPosition = this.getViewportScrollPosition();

          var _this$getViewportSize = this.getViewportSize(),
              width = _this$getViewportSize.width,
              height = _this$getViewportSize.height;

          return {
            top: scrollPosition.top,
            left: scrollPosition.left,
            bottom: scrollPosition.top + height,
            right: scrollPosition.left + width,
            height: height,
            width: width
          };
        }
        /**
         * Gets the (top, left) scroll position of the viewport.
         * @return {?}
         */

      }, {
        key: "getViewportScrollPosition",
        value: function getViewportScrollPosition() {
          // While we can get a reference to the fake document
          // during SSR, it doesn't have getBoundingClientRect.
          if (!this._platform.isBrowser) {
            return {
              top: 0,
              left: 0
            };
          } // The top-left-corner of the viewport is determined by the scroll position of the document
          // body, normally just (scrollLeft, scrollTop). However, Chrome and Firefox disagree about
          // whether `document.body` or `document.documentElement` is the scrolled element, so reading
          // `scrollTop` and `scrollLeft` is inconsistent. However, using the bounding rect of
          // `document.documentElement` works consistently, where the `top` and `left` values will
          // equal negative the scroll position.

          /** @type {?} */


          var document = this._getDocument();
          /** @type {?} */


          var window = this._getWindow();
          /** @type {?} */


          var documentElement =
          /** @type {?} */
          document.documentElement;
          /** @type {?} */

          var documentRect = documentElement.getBoundingClientRect();
          /** @type {?} */

          var top = -documentRect.top || document.body.scrollTop || window.scrollY || documentElement.scrollTop || 0;
          /** @type {?} */

          var left = -documentRect.left || document.body.scrollLeft || window.scrollX || documentElement.scrollLeft || 0;
          return {
            top: top,
            left: left
          };
        }
        /**
         * Returns a stream that emits whenever the size of the viewport changes.
         * @param {?=} throttleTime Time in milliseconds to throttle the stream.
         * @return {?}
         */

      }, {
        key: "change",
        value: function change() {
          var throttleTime = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : DEFAULT_RESIZE_TIME;
          return throttleTime > 0 ? this._change.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["auditTime"])(throttleTime)) : this._change;
        }
        /**
         * Access injected document if available or fallback to global document reference
         * @private
         * @return {?}
         */

      }, {
        key: "_getDocument",
        value: function _getDocument() {
          return this._document || document;
        }
        /**
         * Use defaultView of injected document if available or fallback to global window reference
         * @private
         * @return {?}
         */

      }, {
        key: "_getWindow",
        value: function _getWindow() {
          /** @type {?} */
          var doc = this._getDocument();

          return doc.defaultView || window;
        }
        /**
         * Updates the cached viewport size.
         * @private
         * @return {?}
         */

      }, {
        key: "_updateViewportSize",
        value: function _updateViewportSize() {
          /** @type {?} */
          var window = this._getWindow();

          this._viewportSize = this._platform.isBrowser ? {
            width: window.innerWidth,
            height: window.innerHeight
          } : {
            width: 0,
            height: 0
          };
        }
      }]);

      return ViewportRuler;
    }();

    ViewportRuler.ɵfac = function ViewportRuler_Factory(t) {
      return new (t || ViewportRuler)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_4__["Platform"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_5__["DOCUMENT"], 8));
    };
    /** @nocollapse */


    ViewportRuler.ctorParameters = function () {
      return [{
        type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_4__["Platform"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_5__["DOCUMENT"]]
        }]
      }];
    };
    /** @nocollapse */


    ViewportRuler.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: function ViewportRuler_Factory() {
        return new ViewportRuler(Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_4__["Platform"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_common__WEBPACK_IMPORTED_MODULE_5__["DOCUMENT"], 8));
      },
      token: ViewportRuler,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](ViewportRuler, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], function () {
        return [{
          type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_4__["Platform"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_5__["DOCUMENT"]]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/scrolling/virtual-scroll-viewport.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Checks if the given ranges are equal.
     * @param {?} r1
     * @param {?} r2
     * @return {?}
     */


    function rangesEqual(r1, r2) {
      return r1.start == r2.start && r1.end == r2.end;
    }
    /**
     * Scheduler to be used for scroll events. Needs to fall back to
     * something that doesn't rely on requestAnimationFrame on environments
     * that don't support it (e.g. server-side rendering).
     * @type {?}
     */


    var SCROLL_SCHEDULER = typeof requestAnimationFrame !== 'undefined' ? rxjs__WEBPACK_IMPORTED_MODULE_2__["animationFrameScheduler"] : rxjs__WEBPACK_IMPORTED_MODULE_2__["asapScheduler"];
    /**
     * A viewport that virtualizes its scrolling with the help of `CdkVirtualForOf`.
     */

    var CdkVirtualScrollViewport = /*#__PURE__*/function (_CdkScrollable) {
      _inherits(CdkVirtualScrollViewport, _CdkScrollable);

      var _super19 = _createSuper(CdkVirtualScrollViewport);

      /**
       * @param {?} elementRef
       * @param {?} _changeDetectorRef
       * @param {?} ngZone
       * @param {?} _scrollStrategy
       * @param {?} dir
       * @param {?} scrollDispatcher
       * @param {?=} viewportRuler
       */
      function CdkVirtualScrollViewport(elementRef, _changeDetectorRef, ngZone, _scrollStrategy, dir, scrollDispatcher,
      /**
       * @deprecated `viewportRuler` parameter to become required.
       * @breaking-change 11.0.0
       */
      viewportRuler) {
        var _this112;

        _classCallCheck(this, CdkVirtualScrollViewport);

        _this112 = _super19.call(this, elementRef, scrollDispatcher, ngZone, dir);
        _this112.elementRef = elementRef;
        _this112._changeDetectorRef = _changeDetectorRef;
        _this112._scrollStrategy = _scrollStrategy;
        /**
         * Emits when the viewport is detached from a CdkVirtualForOf.
         */

        _this112._detachedSubject = new rxjs__WEBPACK_IMPORTED_MODULE_2__["Subject"]();
        /**
         * Emits when the rendered range changes.
         */

        _this112._renderedRangeSubject = new rxjs__WEBPACK_IMPORTED_MODULE_2__["Subject"]();
        _this112._orientation = 'vertical'; // Note: we don't use the typical EventEmitter here because we need to subscribe to the scroll
        // strategy lazily (i.e. only if the user is actually listening to the events). We do this because
        // depending on how the strategy calculates the scrolled index, it may come at a cost to
        // performance.

        /**
         * Emits when the index of the first element visible in the viewport changes.
         */

        _this112.scrolledIndexChange = new rxjs__WEBPACK_IMPORTED_MODULE_2__["Observable"](
        /**
        * @param {?} observer
        * @return {?}
        */
        function (observer) {
          return _this112._scrollStrategy.scrolledIndexChange.subscribe(
          /**
          * @param {?} index
          * @return {?}
          */
          function (index) {
            return Promise.resolve().then(
            /**
            * @return {?}
            */
            function () {
              return _this112.ngZone.run(
              /**
              * @return {?}
              */
              function () {
                return observer.next(index);
              });
            });
          });
        });
        /**
         * A stream that emits whenever the rendered range changes.
         */

        _this112.renderedRangeStream = _this112._renderedRangeSubject.asObservable();
        /**
         * The total size of all content (in pixels), including content that is not currently rendered.
         */

        _this112._totalContentSize = 0;
        /**
         * A string representing the `style.width` property value to be used for the spacer element.
         */

        _this112._totalContentWidth = '';
        /**
         * A string representing the `style.height` property value to be used for the spacer element.
         */

        _this112._totalContentHeight = '';
        /**
         * The currently rendered range of indices.
         */

        _this112._renderedRange = {
          start: 0,
          end: 0
        };
        /**
         * The length of the data bound to this viewport (in number of items).
         */

        _this112._dataLength = 0;
        /**
         * The size of the viewport (in pixels).
         */

        _this112._viewportSize = 0;
        /**
         * The last rendered content offset that was set.
         */

        _this112._renderedContentOffset = 0;
        /**
         * Whether the last rendered content offset was to the end of the content (and therefore needs to
         * be rewritten as an offset to the start of the content).
         */

        _this112._renderedContentOffsetNeedsRewrite = false;
        /**
         * Whether there is a pending change detection cycle.
         */

        _this112._isChangeDetectionPending = false;
        /**
         * A list of functions to run after the next change detection cycle.
         */

        _this112._runAfterChangeDetection = [];
        /**
         * Subscription to changes in the viewport size.
         */

        _this112._viewportChanges = rxjs__WEBPACK_IMPORTED_MODULE_2__["Subscription"].EMPTY;

        if (!_scrollStrategy) {
          throw Error('Error: cdk-virtual-scroll-viewport requires the "itemSize" property to be set.');
        } // @breaking-change 11.0.0 Remove null check for `viewportRuler`.


        if (viewportRuler) {
          _this112._viewportChanges = viewportRuler.change().subscribe(
          /**
          * @return {?}
          */
          function () {
            _this112.checkViewportSize();
          });
        }

        return _this112;
      }
      /**
       * The direction the viewport scrolls.
       * @return {?}
       */


      _createClass2(CdkVirtualScrollViewport, [{
        key: "ngOnInit",

        /**
         * @return {?}
         */
        value: function ngOnInit() {
          var _this113 = this;

          _get(_getPrototypeOf(CdkVirtualScrollViewport.prototype), "ngOnInit", this).call(this); // It's still too early to measure the viewport at this point. Deferring with a promise allows
          // the Viewport to be rendered with the correct size before we measure. We run this outside the
          // zone to avoid causing more change detection cycles. We handle the change detection loop
          // ourselves instead.


          this.ngZone.runOutsideAngular(
          /**
          * @return {?}
          */
          function () {
            return Promise.resolve().then(
            /**
            * @return {?}
            */
            function () {
              _this113._measureViewportSize();

              _this113._scrollStrategy.attach(_this113);

              _this113.elementScrolled().pipe( // Start off with a fake scroll event so we properly detect our initial position.
              Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["startWith"])(
              /** @type {?} */
              null), // Collect multiple events into one until the next animation frame. This way if
              // there are multiple scroll events in the same frame we only need to recheck
              // our layout once.
              Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["auditTime"])(0, SCROLL_SCHEDULER)).subscribe(
              /**
              * @return {?}
              */
              function () {
                return _this113._scrollStrategy.onContentScrolled();
              });

              _this113._markChangeDetectionNeeded();
            });
          });
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this.detach();

          this._scrollStrategy.detach(); // Complete all subjects


          this._renderedRangeSubject.complete();

          this._detachedSubject.complete();

          this._viewportChanges.unsubscribe();

          _get(_getPrototypeOf(CdkVirtualScrollViewport.prototype), "ngOnDestroy", this).call(this);
        }
        /**
         * Attaches a `CdkVirtualForOf` to this viewport.
         * @param {?} forOf
         * @return {?}
         */

      }, {
        key: "attach",
        value: function attach(forOf) {
          var _this114 = this;

          if (this._forOf) {
            throw Error('CdkVirtualScrollViewport is already attached.');
          } // Subscribe to the data stream of the CdkVirtualForOf to keep track of when the data length
          // changes. Run outside the zone to avoid triggering change detection, since we're managing the
          // change detection loop ourselves.


          this.ngZone.runOutsideAngular(
          /**
          * @return {?}
          */
          function () {
            _this114._forOf = forOf;

            _this114._forOf.dataStream.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["takeUntil"])(_this114._detachedSubject)).subscribe(
            /**
            * @param {?} data
            * @return {?}
            */
            function (data) {
              /** @type {?} */
              var newLength = data.length;

              if (newLength !== _this114._dataLength) {
                _this114._dataLength = newLength;

                _this114._scrollStrategy.onDataLengthChanged();
              }

              _this114._doChangeDetection();
            });
          });
        }
        /**
         * Detaches the current `CdkVirtualForOf`.
         * @return {?}
         */

      }, {
        key: "detach",
        value: function detach() {
          this._forOf = null;

          this._detachedSubject.next();
        }
        /**
         * Gets the length of the data bound to this viewport (in number of items).
         * @return {?}
         */

      }, {
        key: "getDataLength",
        value: function getDataLength() {
          return this._dataLength;
        }
        /**
         * Gets the size of the viewport (in pixels).
         * @return {?}
         */

      }, {
        key: "getViewportSize",
        value: function getViewportSize() {
          return this._viewportSize;
        } // TODO(mmalerba): This is technically out of sync with what's really rendered until a render
        // cycle happens. I'm being careful to only call it after the render cycle is complete and before
        // setting it to something else, but its error prone and should probably be split into
        // `pendingRange` and `renderedRange`, the latter reflecting whats actually in the DOM.

        /**
         * Get the current rendered range of items.
         * @return {?}
         */

      }, {
        key: "getRenderedRange",
        value: function getRenderedRange() {
          return this._renderedRange;
        }
        /**
         * Sets the total size of all content (in pixels), including content that is not currently
         * rendered.
         * @param {?} size
         * @return {?}
         */

      }, {
        key: "setTotalContentSize",
        value: function setTotalContentSize(size) {
          if (this._totalContentSize !== size) {
            this._totalContentSize = size;

            this._calculateSpacerSize();

            this._markChangeDetectionNeeded();
          }
        }
        /**
         * Sets the currently rendered range of indices.
         * @param {?} range
         * @return {?}
         */

      }, {
        key: "setRenderedRange",
        value: function setRenderedRange(range) {
          var _this115 = this;

          if (!rangesEqual(this._renderedRange, range)) {
            this._renderedRangeSubject.next(this._renderedRange = range);

            this._markChangeDetectionNeeded(
            /**
            * @return {?}
            */
            function () {
              return _this115._scrollStrategy.onContentRendered();
            });
          }
        }
        /**
         * Gets the offset from the start of the viewport to the start of the rendered data (in pixels).
         * @return {?}
         */

      }, {
        key: "getOffsetToRenderedContentStart",
        value: function getOffsetToRenderedContentStart() {
          return this._renderedContentOffsetNeedsRewrite ? null : this._renderedContentOffset;
        }
        /**
         * Sets the offset from the start of the viewport to either the start or end of the rendered data
         * (in pixels).
         * @param {?} offset
         * @param {?=} to
         * @return {?}
         */

      }, {
        key: "setRenderedContentOffset",
        value: function setRenderedContentOffset(offset) {
          var _this116 = this;

          var to = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'to-start';
          // For a horizontal viewport in a right-to-left language we need to translate along the x-axis
          // in the negative direction.

          /** @type {?} */
          var isRtl = this.dir && this.dir.value == 'rtl';
          /** @type {?} */

          var isHorizontal = this.orientation == 'horizontal';
          /** @type {?} */

          var axis = isHorizontal ? 'X' : 'Y';
          /** @type {?} */

          var axisDirection = isHorizontal && isRtl ? -1 : 1;
          /** @type {?} */

          var transform = "translate".concat(axis, "(").concat(Number(axisDirection * offset), "px)");
          this._renderedContentOffset = offset;

          if (to === 'to-end') {
            transform += " translate".concat(axis, "(-100%)"); // The viewport should rewrite this as a `to-start` offset on the next render cycle. Otherwise
            // elements will appear to expand in the wrong direction (e.g. `mat-expansion-panel` would
            // expand upward).

            this._renderedContentOffsetNeedsRewrite = true;
          }

          if (this._renderedContentTransform != transform) {
            // We know this value is safe because we parse `offset` with `Number()` before passing it
            // into the string.
            this._renderedContentTransform = transform;

            this._markChangeDetectionNeeded(
            /**
            * @return {?}
            */
            function () {
              if (_this116._renderedContentOffsetNeedsRewrite) {
                _this116._renderedContentOffset -= _this116.measureRenderedContentSize();
                _this116._renderedContentOffsetNeedsRewrite = false;

                _this116.setRenderedContentOffset(_this116._renderedContentOffset);
              } else {
                _this116._scrollStrategy.onRenderedOffsetChanged();
              }
            });
          }
        }
        /**
         * Scrolls to the given offset from the start of the viewport. Please note that this is not always
         * the same as setting `scrollTop` or `scrollLeft`. In a horizontal viewport with right-to-left
         * direction, this would be the equivalent of setting a fictional `scrollRight` property.
         * @param {?} offset The offset to scroll to.
         * @param {?=} behavior The ScrollBehavior to use when scrolling. Default is behavior is `auto`.
         * @return {?}
         */

      }, {
        key: "scrollToOffset",
        value: function scrollToOffset(offset) {
          var behavior = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'auto';

          /** @type {?} */
          var options = {
            behavior: behavior
          };

          if (this.orientation === 'horizontal') {
            options.start = offset;
          } else {
            options.top = offset;
          }

          this.scrollTo(options);
        }
        /**
         * Scrolls to the offset for the given index.
         * @param {?} index The index of the element to scroll to.
         * @param {?=} behavior The ScrollBehavior to use when scrolling. Default is behavior is `auto`.
         * @return {?}
         */

      }, {
        key: "scrollToIndex",
        value: function scrollToIndex(index) {
          var behavior = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'auto';

          this._scrollStrategy.scrollToIndex(index, behavior);
        }
        /**
         * Gets the current scroll offset from the start of the viewport (in pixels).
         * @param {?=} from The edge to measure the offset from. Defaults to 'top' in vertical mode and 'start'
         *     in horizontal mode.
         * @return {?}
         */

      }, {
        key: "measureScrollOffset",
        value: function measureScrollOffset(from) {
          return from ? _get(_getPrototypeOf(CdkVirtualScrollViewport.prototype), "measureScrollOffset", this).call(this, from) : _get(_getPrototypeOf(CdkVirtualScrollViewport.prototype), "measureScrollOffset", this).call(this, this.orientation === 'horizontal' ? 'start' : 'top');
        }
        /**
         * Measure the combined size of all of the rendered items.
         * @return {?}
         */

      }, {
        key: "measureRenderedContentSize",
        value: function measureRenderedContentSize() {
          /** @type {?} */
          var contentEl = this._contentWrapper.nativeElement;
          return this.orientation === 'horizontal' ? contentEl.offsetWidth : contentEl.offsetHeight;
        }
        /**
         * Measure the total combined size of the given range. Throws if the range includes items that are
         * not rendered.
         * @param {?} range
         * @return {?}
         */

      }, {
        key: "measureRangeSize",
        value: function measureRangeSize(range) {
          if (!this._forOf) {
            return 0;
          }

          return this._forOf.measureRangeSize(range, this.orientation);
        }
        /**
         * Update the viewport dimensions and re-render.
         * @return {?}
         */

      }, {
        key: "checkViewportSize",
        value: function checkViewportSize() {
          // TODO: Cleanup later when add logic for handling content resize
          this._measureViewportSize();

          this._scrollStrategy.onDataLengthChanged();
        }
        /**
         * Measure the viewport size.
         * @private
         * @return {?}
         */

      }, {
        key: "_measureViewportSize",
        value: function _measureViewportSize() {
          /** @type {?} */
          var viewportEl = this.elementRef.nativeElement;
          this._viewportSize = this.orientation === 'horizontal' ? viewportEl.clientWidth : viewportEl.clientHeight;
        }
        /**
         * Queue up change detection to run.
         * @private
         * @param {?=} runAfter
         * @return {?}
         */

      }, {
        key: "_markChangeDetectionNeeded",
        value: function _markChangeDetectionNeeded(runAfter) {
          var _this117 = this;

          if (runAfter) {
            this._runAfterChangeDetection.push(runAfter);
          } // Use a Promise to batch together calls to `_doChangeDetection`. This way if we set a bunch of
          // properties sequentially we only have to run `_doChangeDetection` once at the end.


          if (!this._isChangeDetectionPending) {
            this._isChangeDetectionPending = true;
            this.ngZone.runOutsideAngular(
            /**
            * @return {?}
            */
            function () {
              return Promise.resolve().then(
              /**
              * @return {?}
              */
              function () {
                _this117._doChangeDetection();
              });
            });
          }
        }
        /**
         * Run change detection.
         * @private
         * @return {?}
         */

      }, {
        key: "_doChangeDetection",
        value: function _doChangeDetection() {
          var _this118 = this;

          this._isChangeDetectionPending = false; // Apply the content transform. The transform can't be set via an Angular binding because
          // bypassSecurityTrustStyle is banned in Google. However the value is safe, it's composed of
          // string literals, a variable that can only be 'X' or 'Y', and user input that is run through
          // the `Number` function first to coerce it to a numeric value.

          this._contentWrapper.nativeElement.style.transform = this._renderedContentTransform; // Apply changes to Angular bindings. Note: We must call `markForCheck` to run change detection
          // from the root, since the repeated items are content projected in. Calling `detectChanges`
          // instead does not properly check the projected content.

          this.ngZone.run(
          /**
          * @return {?}
          */
          function () {
            return _this118._changeDetectorRef.markForCheck();
          });
          /** @type {?} */

          var runAfterChangeDetection = this._runAfterChangeDetection;
          this._runAfterChangeDetection = [];

          var _iterator5 = _createForOfIteratorHelper(runAfterChangeDetection),
              _step5;

          try {
            for (_iterator5.s(); !(_step5 = _iterator5.n()).done;) {
              var fn = _step5.value;
              fn();
            }
          } catch (err) {
            _iterator5.e(err);
          } finally {
            _iterator5.f();
          }
        }
        /**
         * Calculates the `style.width` and `style.height` for the spacer element.
         * @private
         * @return {?}
         */

      }, {
        key: "_calculateSpacerSize",
        value: function _calculateSpacerSize() {
          this._totalContentHeight = this.orientation === 'horizontal' ? '' : "".concat(this._totalContentSize, "px");
          this._totalContentWidth = this.orientation === 'horizontal' ? "".concat(this._totalContentSize, "px") : '';
        }
      }, {
        key: "orientation",
        get: function get() {
          return this._orientation;
        }
        /**
         * @param {?} orientation
         * @return {?}
         */
        ,
        set: function set(orientation) {
          if (this._orientation !== orientation) {
            this._orientation = orientation;

            this._calculateSpacerSize();
          }
        }
      }]);

      return CdkVirtualScrollViewport;
    }(CdkScrollable);

    CdkVirtualScrollViewport.ɵfac = function CdkVirtualScrollViewport_Factory(t) {
      return new (t || CdkVirtualScrollViewport)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["ChangeDetectorRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](VIRTUAL_SCROLL_STRATEGY, 8), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_6__["Directionality"], 8), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](ScrollDispatcher), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](ViewportRuler, 8));
    };

    CdkVirtualScrollViewport.ɵcmp = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineComponent"]({
      type: CdkVirtualScrollViewport,
      selectors: [["cdk-virtual-scroll-viewport"]],
      viewQuery: function CdkVirtualScrollViewport_Query(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵstaticViewQuery"](_c0, true);
        }

        if (rf & 2) {
          var _t;

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵqueryRefresh"](_t = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵloadQuery"]()) && (ctx._contentWrapper = _t.first);
        }
      },
      hostAttrs: [1, "cdk-virtual-scroll-viewport"],
      hostVars: 4,
      hostBindings: function CdkVirtualScrollViewport_HostBindings(rf, ctx) {
        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵclassProp"]("cdk-virtual-scroll-orientation-horizontal", ctx.orientation === "horizontal")("cdk-virtual-scroll-orientation-vertical", ctx.orientation !== "horizontal");
        }
      },
      inputs: {
        orientation: "orientation"
      },
      outputs: {
        scrolledIndexChange: "scrolledIndexChange"
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵProvidersFeature"]([{
        provide: CdkScrollable,
        useExisting: CdkVirtualScrollViewport
      }]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵInheritDefinitionFeature"]],
      ngContentSelectors: _c1,
      decls: 4,
      vars: 4,
      consts: [[1, "cdk-virtual-scroll-content-wrapper"], ["contentWrapper", ""], [1, "cdk-virtual-scroll-spacer"]],
      template: function CdkVirtualScrollViewport_Template(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵprojectionDef"]();

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelementStart"](0, "div", 0, 1);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵprojection"](2);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelementEnd"]();

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelement"](3, "div", 2);
        }

        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵadvance"](3);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵstyleProp"]("width", ctx._totalContentWidth)("height", ctx._totalContentHeight);
        }
      },
      styles: ["cdk-virtual-scroll-viewport{display:block;position:relative;overflow:auto;contain:strict;transform:translateZ(0);will-change:scroll-position;-webkit-overflow-scrolling:touch}.cdk-virtual-scroll-content-wrapper{position:absolute;top:0;left:0;contain:content}[dir=rtl] .cdk-virtual-scroll-content-wrapper{right:0;left:auto}.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper{min-height:100%}.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>dl:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>ol:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>table:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>ul:not([cdkVirtualFor]){padding-left:0;padding-right:0;margin-left:0;margin-right:0;border-left-width:0;border-right-width:0;outline:none}.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper{min-width:100%}.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>dl:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>ol:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>table:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>ul:not([cdkVirtualFor]){padding-top:0;padding-bottom:0;margin-top:0;margin-bottom:0;border-top-width:0;border-bottom-width:0;outline:none}.cdk-virtual-scroll-spacer{position:absolute;top:0;left:0;height:1px;width:1px;transform-origin:0 0}[dir=rtl] .cdk-virtual-scroll-spacer{right:0;left:auto;transform-origin:100% 0}\n"],
      encapsulation: 2,
      changeDetection: 0
    });
    /** @nocollapse */

    CdkVirtualScrollViewport.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ChangeDetectorRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [VIRTUAL_SCROLL_STRATEGY]
        }]
      }, {
        type: _angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_6__["Directionality"],
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }]
      }, {
        type: ScrollDispatcher
      }, {
        type: ViewportRuler,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }]
      }];
    };

    CdkVirtualScrollViewport.propDecorators = {
      orientation: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      scrolledIndexChange: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"]
      }],
      _contentWrapper: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"],
        args: ['contentWrapper', {
          "static": true
        }]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](CdkVirtualScrollViewport, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"],
        args: [{
          selector: 'cdk-virtual-scroll-viewport',
          template: "<!--\n  Wrap the rendered content in an element that will be used to offset it based on the scroll\n  position.\n-->\n<div #contentWrapper class=\"cdk-virtual-scroll-content-wrapper\">\n  <ng-content></ng-content>\n</div>\n<!--\n  Spacer used to force the scrolling container to the correct size for the *total* number of items\n  so that the scrollbar captures the size of the entire data set.\n-->\n<div class=\"cdk-virtual-scroll-spacer\"\n     [style.width]=\"_totalContentWidth\" [style.height]=\"_totalContentHeight\"></div>\n",
          host: {
            'class': 'cdk-virtual-scroll-viewport',
            '[class.cdk-virtual-scroll-orientation-horizontal]': 'orientation === "horizontal"',
            '[class.cdk-virtual-scroll-orientation-vertical]': 'orientation !== "horizontal"'
          },
          encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
          changeDetection: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ChangeDetectionStrategy"].OnPush,
          providers: [{
            provide: CdkScrollable,
            useExisting: CdkVirtualScrollViewport
          }],
          styles: ["cdk-virtual-scroll-viewport{display:block;position:relative;overflow:auto;contain:strict;transform:translateZ(0);will-change:scroll-position;-webkit-overflow-scrolling:touch}.cdk-virtual-scroll-content-wrapper{position:absolute;top:0;left:0;contain:content}[dir=rtl] .cdk-virtual-scroll-content-wrapper{right:0;left:auto}.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper{min-height:100%}.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>dl:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>ol:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>table:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-horizontal .cdk-virtual-scroll-content-wrapper>ul:not([cdkVirtualFor]){padding-left:0;padding-right:0;margin-left:0;margin-right:0;border-left-width:0;border-right-width:0;outline:none}.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper{min-width:100%}.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>dl:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>ol:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>table:not([cdkVirtualFor]),.cdk-virtual-scroll-orientation-vertical .cdk-virtual-scroll-content-wrapper>ul:not([cdkVirtualFor]){padding-top:0;padding-bottom:0;margin-top:0;margin-bottom:0;border-top-width:0;border-bottom-width:0;outline:none}.cdk-virtual-scroll-spacer{position:absolute;top:0;left:0;height:1px;width:1px;transform-origin:0 0}[dir=rtl] .cdk-virtual-scroll-spacer{right:0;left:auto;transform-origin:100% 0}\n"]
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ChangeDetectorRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [VIRTUAL_SCROLL_STRATEGY]
          }]
        }, {
          type: _angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_6__["Directionality"],
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }]
        }, {
          type: ScrollDispatcher
        }, {
          type: ViewportRuler,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }]
        }];
      }, {
        scrolledIndexChange: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"]
        }],
        orientation: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        _contentWrapper: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"],
          args: ['contentWrapper', {
            "static": true
          }]
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/scrolling/virtual-for-of.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Helper to extract size from a DOM Node.
     * @param {?} orientation
     * @param {?} node
     * @return {?}
     */


    function getSize(orientation, node) {
      /** @type {?} */
      var el =
      /** @type {?} */
      node;

      if (!el.getBoundingClientRect) {
        return 0;
      }
      /** @type {?} */


      var rect = el.getBoundingClientRect();
      return orientation == 'horizontal' ? rect.width : rect.height;
    }
    /**
     * A directive similar to `ngForOf` to be used for rendering data inside a virtual scrolling
     * container.
     * @template T
     */


    var CdkVirtualForOf = /*#__PURE__*/function () {
      /**
       * @param {?} _viewContainerRef
       * @param {?} _template
       * @param {?} _differs
       * @param {?} _viewport
       * @param {?} ngZone
       */
      function CdkVirtualForOf(_viewContainerRef, _template, _differs, _viewport, ngZone) {
        var _this119 = this;

        _classCallCheck(this, CdkVirtualForOf);

        this._viewContainerRef = _viewContainerRef;
        this._template = _template;
        this._differs = _differs;
        this._viewport = _viewport;
        /**
         * Emits when the rendered view of the data changes.
         */

        this.viewChange = new rxjs__WEBPACK_IMPORTED_MODULE_2__["Subject"]();
        /**
         * Subject that emits when a new DataSource instance is given.
         */

        this._dataSourceChanges = new rxjs__WEBPACK_IMPORTED_MODULE_2__["Subject"]();
        /**
         * The size of the cache used to store templates that are not being used for re-use later.
         * Setting the cache size to `0` will disable caching. Defaults to 20 templates.
         */

        this.cdkVirtualForTemplateCacheSize = 20;
        /**
         * Emits whenever the data in the current DataSource changes.
         */

        this.dataStream = this._dataSourceChanges.pipe( // Start off with null `DataSource`.
        Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["startWith"])(
        /** @type {?} */
        null), // Bundle up the previous and current data sources so we can work with both.
        Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["pairwise"])(), // Use `_changeDataSource` to disconnect from the previous data source and connect to the
        // new one, passing back a stream of data changes which we run through `switchMap` to give
        // us a data stream that emits the latest data from whatever the current `DataSource` is.
        Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["switchMap"])(
        /**
        * @param {?} __0
        * @return {?}
        */
        function (_ref2) {
          var _ref3 = _slicedToArray(_ref2, 2),
              prev = _ref3[0],
              cur = _ref3[1];

          return _this119._changeDataSource(prev, cur);
        }), // Replay the last emitted data when someone subscribes.
        Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["shareReplay"])(1));
        /**
         * The differ used to calculate changes to the data.
         */

        this._differ = null;
        /**
         * The template cache used to hold on ot template instancess that have been stamped out, but don't
         * currently need to be rendered. These instances will be reused in the future rather than
         * stamping out brand new ones.
         */

        this._templateCache = [];
        /**
         * Whether the rendered data should be updated during the next ngDoCheck cycle.
         */

        this._needsUpdate = false;
        this._destroyed = new rxjs__WEBPACK_IMPORTED_MODULE_2__["Subject"]();
        this.dataStream.subscribe(
        /**
        * @param {?} data
        * @return {?}
        */
        function (data) {
          _this119._data = data;

          _this119._onRenderedDataChange();
        });

        this._viewport.renderedRangeStream.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["takeUntil"])(this._destroyed)).subscribe(
        /**
        * @param {?} range
        * @return {?}
        */
        function (range) {
          _this119._renderedRange = range;
          ngZone.run(
          /**
          * @return {?}
          */
          function () {
            return _this119.viewChange.next(_this119._renderedRange);
          });

          _this119._onRenderedDataChange();
        });

        this._viewport.attach(this);
      }
      /**
       * The DataSource to display.
       * @return {?}
       */


      _createClass2(CdkVirtualForOf, [{
        key: "measureRangeSize",

        /**
         * Measures the combined size (width for horizontal orientation, height for vertical) of all items
         * in the specified range. Throws an error if the range includes items that are not currently
         * rendered.
         * @param {?} range
         * @param {?} orientation
         * @return {?}
         */
        value: function measureRangeSize(range, orientation) {
          if (range.start >= range.end) {
            return 0;
          }

          if (range.start < this._renderedRange.start || range.end > this._renderedRange.end) {
            throw Error("Error: attempted to measure an item that isn't rendered.");
          } // The index into the list of rendered views for the first item in the range.

          /** @type {?} */


          var renderedStartIndex = range.start - this._renderedRange.start; // The length of the range we're measuring.

          /** @type {?} */

          var rangeLen = range.end - range.start; // Loop over all root nodes for all items in the range and sum up their size.

          /** @type {?} */

          var totalSize = 0;
          /** @type {?} */

          var i = rangeLen;

          while (i--) {
            /** @type {?} */
            var view =
            /** @type {?} */
            this._viewContainerRef.get(i + renderedStartIndex);
            /** @type {?} */


            var j = view ? view.rootNodes.length : 0;

            while (j--) {
              totalSize += getSize(orientation,
              /** @type {?} */
              view.rootNodes[j]);
            }
          }

          return totalSize;
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngDoCheck",
        value: function ngDoCheck() {
          if (this._differ && this._needsUpdate) {
            // TODO(mmalerba): We should differentiate needs update due to scrolling and a new portion of
            // this list being rendered (can use simpler algorithm) vs needs update due to data actually
            // changing (need to do this diff).

            /** @type {?} */
            var changes = this._differ.diff(this._renderedItems);

            if (!changes) {
              this._updateContext();
            } else {
              this._applyChanges(changes);
            }

            this._needsUpdate = false;
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this._viewport.detach();

          this._dataSourceChanges.next();

          this._dataSourceChanges.complete();

          this.viewChange.complete();

          this._destroyed.next();

          this._destroyed.complete();

          var _iterator6 = _createForOfIteratorHelper(this._templateCache),
              _step6;

          try {
            for (_iterator6.s(); !(_step6 = _iterator6.n()).done;) {
              var view = _step6.value;
              view.destroy();
            }
          } catch (err) {
            _iterator6.e(err);
          } finally {
            _iterator6.f();
          }
        }
        /**
         * React to scroll state changes in the viewport.
         * @private
         * @return {?}
         */

      }, {
        key: "_onRenderedDataChange",
        value: function _onRenderedDataChange() {
          if (!this._renderedRange) {
            return;
          }

          this._renderedItems = this._data.slice(this._renderedRange.start, this._renderedRange.end);

          if (!this._differ) {
            this._differ = this._differs.find(this._renderedItems).create(this.cdkVirtualForTrackBy);
          }

          this._needsUpdate = true;
        }
        /**
         * Swap out one `DataSource` for another.
         * @private
         * @param {?} oldDs
         * @param {?} newDs
         * @return {?}
         */

      }, {
        key: "_changeDataSource",
        value: function _changeDataSource(oldDs, newDs) {
          if (oldDs) {
            oldDs.disconnect(this);
          }

          this._needsUpdate = true;
          return newDs ? newDs.connect(this) : Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])();
        }
        /**
         * Update the `CdkVirtualForOfContext` for all views.
         * @private
         * @return {?}
         */

      }, {
        key: "_updateContext",
        value: function _updateContext() {
          /** @type {?} */
          var count = this._data.length;
          /** @type {?} */

          var i = this._viewContainerRef.length;

          while (i--) {
            /** @type {?} */
            var view =
            /** @type {?} */
            this._viewContainerRef.get(i);

            view.context.index = this._renderedRange.start + i;
            view.context.count = count;

            this._updateComputedContextProperties(view.context);

            view.detectChanges();
          }
        }
        /**
         * Apply changes to the DOM.
         * @private
         * @param {?} changes
         * @return {?}
         */

      }, {
        key: "_applyChanges",
        value: function _applyChanges(changes) {
          var _this120 = this;

          // Rearrange the views to put them in the right location.
          changes.forEachOperation(
          /**
          * @param {?} record
          * @param {?} adjustedPreviousIndex
          * @param {?} currentIndex
          * @return {?}
          */
          function (record, adjustedPreviousIndex, currentIndex) {
            if (record.previousIndex == null) {
              // Item added.
              // Item added.

              /** @type {?} */
              var view = _this120._insertViewForNewItem(
              /** @type {?} */
              currentIndex);

              view.context.$implicit = record.item;
            } else if (currentIndex == null) {
              // Item removed.
              _this120._cacheView(_this120._detachView(
              /** @type {?} */
              adjustedPreviousIndex));
            } else {
              // Item moved.
              // Item moved.

              /** @type {?} */
              var _view2 =
              /** @type {?} */
              _this120._viewContainerRef.get(
              /** @type {?} */
              adjustedPreviousIndex);

              _this120._viewContainerRef.move(_view2, currentIndex);

              _view2.context.$implicit = record.item;
            }
          }); // Update $implicit for any items that had an identity change.

          changes.forEachIdentityChange(
          /**
          * @param {?} record
          * @return {?}
          */
          function (record) {
            /** @type {?} */
            var view =
            /** @type {?} */
            _this120._viewContainerRef.get(
            /** @type {?} */
            record.currentIndex);

            view.context.$implicit = record.item;
          }); // Update the context variables on all items.

          /** @type {?} */

          var count = this._data.length;
          /** @type {?} */

          var i = this._viewContainerRef.length;

          while (i--) {
            /** @type {?} */
            var view =
            /** @type {?} */
            this._viewContainerRef.get(i);

            view.context.index = this._renderedRange.start + i;
            view.context.count = count;

            this._updateComputedContextProperties(view.context);
          }
        }
        /**
         * Cache the given detached view.
         * @private
         * @param {?} view
         * @return {?}
         */

      }, {
        key: "_cacheView",
        value: function _cacheView(view) {
          if (this._templateCache.length < this.cdkVirtualForTemplateCacheSize) {
            this._templateCache.push(view);
          } else {
            /** @type {?} */
            var index = this._viewContainerRef.indexOf(view); // It's very unlikely that the index will ever be -1, but just in case,
            // destroy the view on its own, otherwise destroy it through the
            // container to ensure that all the references are removed.


            if (index === -1) {
              view.destroy();
            } else {
              this._viewContainerRef.remove(index);
            }
          }
        }
        /**
         * Inserts a view for a new item, either from the cache or by creating a new one.
         * @private
         * @param {?} index
         * @return {?}
         */

      }, {
        key: "_insertViewForNewItem",
        value: function _insertViewForNewItem(index) {
          return this._insertViewFromCache(index) || this._createEmbeddedViewAt(index);
        }
        /**
         * Update the computed properties on the `CdkVirtualForOfContext`.
         * @private
         * @param {?} context
         * @return {?}
         */

      }, {
        key: "_updateComputedContextProperties",
        value: function _updateComputedContextProperties(context) {
          context.first = context.index === 0;
          context.last = context.index === context.count - 1;
          context.even = context.index % 2 === 0;
          context.odd = !context.even;
        }
        /**
         * Creates a new embedded view and moves it to the given index
         * @private
         * @param {?} index
         * @return {?}
         */

      }, {
        key: "_createEmbeddedViewAt",
        value: function _createEmbeddedViewAt(index) {
          // Note that it's important that we insert the item directly at the proper index,
          // rather than inserting it and the moving it in place, because if there's a directive
          // on the same node that injects the `ViewContainerRef`, Angular will insert another
          // comment node which can throw off the move when it's being repeated for all items.
          return this._viewContainerRef.createEmbeddedView(this._template, {
            $implicit:
            /** @type {?} */
            null,
            // It's guaranteed that the iterable is not "undefined" or "null" because we only
            // generate views for elements if the "cdkVirtualForOf" iterable has elements.
            cdkVirtualForOf:
            /** @type {?} */
            this._cdkVirtualForOf,
            index: -1,
            count: -1,
            first: false,
            last: false,
            odd: false,
            even: false
          }, index);
        }
        /**
         * Inserts a recycled view from the cache at the given index.
         * @private
         * @param {?} index
         * @return {?}
         */

      }, {
        key: "_insertViewFromCache",
        value: function _insertViewFromCache(index) {
          /** @type {?} */
          var cachedView = this._templateCache.pop();

          if (cachedView) {
            this._viewContainerRef.insert(cachedView, index);
          }

          return cachedView || null;
        }
        /**
         * Detaches the embedded view at the given index.
         * @private
         * @param {?} index
         * @return {?}
         */

      }, {
        key: "_detachView",
        value: function _detachView(index) {
          return (
            /** @type {?} */
            this._viewContainerRef.detach(index)
          );
        }
      }, {
        key: "cdkVirtualForOf",
        get: function get() {
          return this._cdkVirtualForOf;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._cdkVirtualForOf = value;

          if (Object(_angular_cdk_collections__WEBPACK_IMPORTED_MODULE_7__["isDataSource"])(value)) {
            this._dataSourceChanges.next(value);
          } else {
            // Slice the value if its an NgIterable to ensure we're working with an array.
            this._dataSourceChanges.next(new _angular_cdk_collections__WEBPACK_IMPORTED_MODULE_7__["ArrayDataSource"](Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["isObservable"])(value) ? value : Array.prototype.slice.call(value || [])));
          }
        }
        /**
         * The `TrackByFunction` to use for tracking changes. The `TrackByFunction` takes the index and
         * the item and produces a value to be used as the item's identity when tracking changes.
         * @return {?}
         */

      }, {
        key: "cdkVirtualForTrackBy",
        get: function get() {
          return this._cdkVirtualForTrackBy;
        }
        /**
         * @param {?} fn
         * @return {?}
         */
        ,
        set: function set(fn) {
          var _this121 = this;

          this._needsUpdate = true;
          this._cdkVirtualForTrackBy = fn ?
          /**
          * @param {?} index
          * @param {?} item
          * @return {?}
          */
          function (index, item) {
            return fn(index + (_this121._renderedRange ? _this121._renderedRange.start : 0), item);
          } : undefined;
        }
        /**
         * The template used to stamp out new elements.
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "cdkVirtualForTemplate",
        set: function set(value) {
          if (value) {
            this._needsUpdate = true;
            this._template = value;
          }
        }
      }]);

      return CdkVirtualForOf;
    }();

    CdkVirtualForOf.ɵfac = function CdkVirtualForOf_Factory(t) {
      return new (t || CdkVirtualForOf)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewContainerRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["TemplateRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["IterableDiffers"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](CdkVirtualScrollViewport, 4), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]));
    };

    CdkVirtualForOf.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineDirective"]({
      type: CdkVirtualForOf,
      selectors: [["", "cdkVirtualFor", "", "cdkVirtualForOf", ""]],
      inputs: {
        cdkVirtualForTemplateCacheSize: "cdkVirtualForTemplateCacheSize",
        cdkVirtualForOf: "cdkVirtualForOf",
        cdkVirtualForTrackBy: "cdkVirtualForTrackBy",
        cdkVirtualForTemplate: "cdkVirtualForTemplate"
      }
    });
    /** @nocollapse */

    CdkVirtualForOf.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewContainerRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["TemplateRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["IterableDiffers"]
      }, {
        type: CdkVirtualScrollViewport,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["SkipSelf"]
        }]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
      }];
    };

    CdkVirtualForOf.propDecorators = {
      cdkVirtualForOf: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      cdkVirtualForTrackBy: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      cdkVirtualForTemplate: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      cdkVirtualForTemplateCacheSize: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](CdkVirtualForOf, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Directive"],
        args: [{
          selector: '[cdkVirtualFor][cdkVirtualForOf]'
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewContainerRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["TemplateRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["IterableDiffers"]
        }, {
          type: CdkVirtualScrollViewport,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["SkipSelf"]
          }]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
        }];
      }, {
        cdkVirtualForTemplateCacheSize: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        cdkVirtualForOf: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        cdkVirtualForTrackBy: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        cdkVirtualForTemplate: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/scrolling/scrolling-module.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var CdkScrollableModule = function CdkScrollableModule() {
      _classCallCheck(this, CdkScrollableModule);
    };

    CdkScrollableModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineNgModule"]({
      type: CdkScrollableModule
    });
    CdkScrollableModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjector"]({
      factory: function CdkScrollableModule_Factory(t) {
        return new (t || CdkScrollableModule)();
      }
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵsetNgModuleScope"](CdkScrollableModule, {
        declarations: [CdkScrollable],
        exports: [CdkScrollable]
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](CdkScrollableModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModule"],
        args: [{
          exports: [CdkScrollable],
          declarations: [CdkScrollable]
        }]
      }], null, null);
    })();

    var ScrollingModule = function ScrollingModule() {
      _classCallCheck(this, ScrollingModule);
    };

    ScrollingModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineNgModule"]({
      type: ScrollingModule
    });
    ScrollingModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjector"]({
      factory: function ScrollingModule_Factory(t) {
        return new (t || ScrollingModule)();
      },
      imports: [[_angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_6__["BidiModule"], _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_4__["PlatformModule"], CdkScrollableModule], _angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_6__["BidiModule"], CdkScrollableModule]
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵsetNgModuleScope"](ScrollingModule, {
        declarations: function declarations() {
          return [CdkFixedSizeVirtualScroll, CdkVirtualForOf, CdkVirtualScrollViewport];
        },
        imports: function imports() {
          return [_angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_6__["BidiModule"], _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_4__["PlatformModule"], CdkScrollableModule];
        },
        exports: function exports() {
          return [_angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_6__["BidiModule"], CdkScrollableModule, CdkFixedSizeVirtualScroll, CdkVirtualForOf, CdkVirtualScrollViewport];
        }
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](ScrollingModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModule"],
        args: [{
          imports: [_angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_6__["BidiModule"], _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_4__["PlatformModule"], CdkScrollableModule],
          exports: [_angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_6__["BidiModule"], CdkScrollableModule, CdkFixedSizeVirtualScroll, CdkVirtualForOf, CdkVirtualScrollViewport],
          declarations: [CdkFixedSizeVirtualScroll, CdkVirtualForOf, CdkVirtualScrollViewport]
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: src/cdk/scrolling/public-api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=scrolling.js.map

    /***/

  },

  /***/
  "./node_modules/@angular/cdk/fesm2015/cdk.js":
  /*!***************************************************!*\
    !*** ./node_modules/@angular/cdk/fesm2015/cdk.js ***!
    \***************************************************/

  /*! exports provided: VERSION */

  /***/
  function node_modulesAngularCdkFesm2015CdkJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "VERSION", function () {
      return VERSION;
    });
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** Current version of the Angular Component Development Kit. */


    var VERSION = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["Version"]('9.2.2');
    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */
    //# sourceMappingURL=cdk.js.map

    /***/
  },

  /***/
  "./node_modules/@angular/cdk/fesm2015/coercion.js":
  /*!********************************************************!*\
    !*** ./node_modules/@angular/cdk/fesm2015/coercion.js ***!
    \********************************************************/

  /*! exports provided: _isNumberValue, coerceArray, coerceBooleanProperty, coerceCssPixelValue, coerceElement, coerceNumberProperty */

  /***/
  function node_modulesAngularCdkFesm2015CoercionJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "_isNumberValue", function () {
      return _isNumberValue;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "coerceArray", function () {
      return coerceArray;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "coerceBooleanProperty", function () {
      return coerceBooleanProperty;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "coerceCssPixelValue", function () {
      return coerceCssPixelValue;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "coerceElement", function () {
      return coerceElement;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "coerceNumberProperty", function () {
      return coerceNumberProperty;
    });
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** Coerces a data-bound value (typically a string) to a boolean. */


    function coerceBooleanProperty(value) {
      return value != null && "".concat(value) !== 'false';
    }
    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */


    function coerceNumberProperty(value) {
      var fallbackValue = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
      return _isNumberValue(value) ? Number(value) : fallbackValue;
    }
    /**
     * Whether the provided value is considered a number.
     * @docs-private
     */


    function _isNumberValue(value) {
      // parseFloat(value) handles most of the cases we're interested in (it treats null, empty string,
      // and other non-number values as NaN, where Number just uses 0) but it considers the string
      // '123hello' to be a valid number. Therefore we also check if Number(value) is NaN.
      return !isNaN(parseFloat(value)) && !isNaN(Number(value));
    }
    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */


    function coerceArray(value) {
      return Array.isArray(value) ? value : [value];
    }
    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** Coerces a value to a CSS pixel value. */


    function coerceCssPixelValue(value) {
      if (value == null) {
        return '';
      }

      return typeof value === 'string' ? value : "".concat(value, "px");
    }
    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Coerces an ElementRef or an Element into an element.
     * Useful for APIs that can accept either a ref or the native element itself.
     */


    function coerceElement(elementOrRef) {
      return elementOrRef instanceof _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"] ? elementOrRef.nativeElement : elementOrRef;
    }
    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */
    //# sourceMappingURL=coercion.js.map

    /***/

  },

  /***/
  "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/common.js":
  /*!**********************************************************************!*\
    !*** ./node_modules/@angular/common/__ivy_ngcc__/fesm2015/common.js ***!
    \**********************************************************************/

  /*! exports provided: APP_BASE_HREF, AsyncPipe, CommonModule, CurrencyPipe, DOCUMENT, DatePipe, DecimalPipe, FormStyle, FormatWidth, HashLocationStrategy, I18nPluralPipe, I18nSelectPipe, JsonPipe, KeyValuePipe, LOCATION_INITIALIZED, Location, LocationStrategy, LowerCasePipe, NgClass, NgComponentOutlet, NgForOf, NgForOfContext, NgIf, NgIfContext, NgLocaleLocalization, NgLocalization, NgPlural, NgPluralCase, NgStyle, NgSwitch, NgSwitchCase, NgSwitchDefault, NgTemplateOutlet, NumberFormatStyle, NumberSymbol, PathLocationStrategy, PercentPipe, PlatformLocation, Plural, SlicePipe, TitleCasePipe, TranslationWidth, UpperCasePipe, VERSION, ViewportScroller, WeekDay, formatCurrency, formatDate, formatNumber, formatPercent, getCurrencySymbol, getLocaleCurrencyCode, getLocaleCurrencyName, getLocaleCurrencySymbol, getLocaleDateFormat, getLocaleDateTimeFormat, getLocaleDayNames, getLocaleDayPeriods, getLocaleDirection, getLocaleEraNames, getLocaleExtraDayPeriodRules, getLocaleExtraDayPeriods, getLocaleFirstDayOfWeek, getLocaleId, getLocaleMonthNames, getLocaleNumberFormat, getLocaleNumberSymbol, getLocalePluralCase, getLocaleTimeFormat, getLocaleWeekEndRange, getNumberOfCurrencyDigits, isPlatformBrowser, isPlatformServer, isPlatformWorkerApp, isPlatformWorkerUi, registerLocaleData, ɵBrowserPlatformLocation, ɵDomAdapter, ɵNullViewportScroller, ɵPLATFORM_BROWSER_ID, ɵPLATFORM_SERVER_ID, ɵPLATFORM_WORKER_APP_ID, ɵPLATFORM_WORKER_UI_ID, ɵangular_packages_common_common_a, ɵangular_packages_common_common_b, ɵangular_packages_common_common_c, ɵangular_packages_common_common_d, ɵangular_packages_common_common_e, ɵangular_packages_common_common_f, ɵgetDOM, ɵparseCookieValue, ɵsetRootDomAdapter */

  /***/
  function node_modulesAngularCommon__ivy_ngcc__Fesm2015CommonJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "APP_BASE_HREF", function () {
      return APP_BASE_HREF;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AsyncPipe", function () {
      return AsyncPipe;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CommonModule", function () {
      return CommonModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CurrencyPipe", function () {
      return CurrencyPipe;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DOCUMENT", function () {
      return DOCUMENT;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DatePipe", function () {
      return DatePipe;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DecimalPipe", function () {
      return DecimalPipe;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FormStyle", function () {
      return FormStyle;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FormatWidth", function () {
      return FormatWidth;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HashLocationStrategy", function () {
      return HashLocationStrategy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "I18nPluralPipe", function () {
      return I18nPluralPipe;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "I18nSelectPipe", function () {
      return I18nSelectPipe;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "JsonPipe", function () {
      return JsonPipe;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "KeyValuePipe", function () {
      return KeyValuePipe;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "LOCATION_INITIALIZED", function () {
      return LOCATION_INITIALIZED;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Location", function () {
      return Location;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "LocationStrategy", function () {
      return LocationStrategy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "LowerCasePipe", function () {
      return LowerCasePipe;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgClass", function () {
      return NgClass;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgComponentOutlet", function () {
      return NgComponentOutlet;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgForOf", function () {
      return NgForOf;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgForOfContext", function () {
      return NgForOfContext;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgIf", function () {
      return NgIf;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgIfContext", function () {
      return NgIfContext;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgLocaleLocalization", function () {
      return NgLocaleLocalization;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgLocalization", function () {
      return NgLocalization;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgPlural", function () {
      return NgPlural;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgPluralCase", function () {
      return NgPluralCase;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgStyle", function () {
      return NgStyle;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgSwitch", function () {
      return NgSwitch;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgSwitchCase", function () {
      return NgSwitchCase;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgSwitchDefault", function () {
      return NgSwitchDefault;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgTemplateOutlet", function () {
      return NgTemplateOutlet;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NumberFormatStyle", function () {
      return NumberFormatStyle;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NumberSymbol", function () {
      return NumberSymbol;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "PathLocationStrategy", function () {
      return PathLocationStrategy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "PercentPipe", function () {
      return PercentPipe;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "PlatformLocation", function () {
      return PlatformLocation;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Plural", function () {
      return Plural;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SlicePipe", function () {
      return SlicePipe;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "TitleCasePipe", function () {
      return TitleCasePipe;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "TranslationWidth", function () {
      return TranslationWidth;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "UpperCasePipe", function () {
      return UpperCasePipe;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "VERSION", function () {
      return VERSION;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ViewportScroller", function () {
      return ViewportScroller;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "WeekDay", function () {
      return WeekDay;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "formatCurrency", function () {
      return formatCurrency;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "formatDate", function () {
      return formatDate;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "formatNumber", function () {
      return formatNumber;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "formatPercent", function () {
      return formatPercent;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getCurrencySymbol", function () {
      return getCurrencySymbol;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getLocaleCurrencyCode", function () {
      return getLocaleCurrencyCode;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getLocaleCurrencyName", function () {
      return getLocaleCurrencyName;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getLocaleCurrencySymbol", function () {
      return getLocaleCurrencySymbol;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getLocaleDateFormat", function () {
      return getLocaleDateFormat;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getLocaleDateTimeFormat", function () {
      return getLocaleDateTimeFormat;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getLocaleDayNames", function () {
      return getLocaleDayNames;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getLocaleDayPeriods", function () {
      return getLocaleDayPeriods;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getLocaleDirection", function () {
      return getLocaleDirection;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getLocaleEraNames", function () {
      return getLocaleEraNames;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getLocaleExtraDayPeriodRules", function () {
      return getLocaleExtraDayPeriodRules;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getLocaleExtraDayPeriods", function () {
      return getLocaleExtraDayPeriods;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getLocaleFirstDayOfWeek", function () {
      return getLocaleFirstDayOfWeek;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getLocaleId", function () {
      return getLocaleId;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getLocaleMonthNames", function () {
      return getLocaleMonthNames;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getLocaleNumberFormat", function () {
      return getLocaleNumberFormat;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getLocaleNumberSymbol", function () {
      return getLocaleNumberSymbol;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getLocalePluralCase", function () {
      return getLocalePluralCase;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getLocaleTimeFormat", function () {
      return getLocaleTimeFormat;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getLocaleWeekEndRange", function () {
      return getLocaleWeekEndRange;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getNumberOfCurrencyDigits", function () {
      return getNumberOfCurrencyDigits;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "isPlatformBrowser", function () {
      return isPlatformBrowser;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "isPlatformServer", function () {
      return isPlatformServer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "isPlatformWorkerApp", function () {
      return isPlatformWorkerApp;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "isPlatformWorkerUi", function () {
      return isPlatformWorkerUi;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "registerLocaleData", function () {
      return registerLocaleData;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵBrowserPlatformLocation", function () {
      return BrowserPlatformLocation;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵDomAdapter", function () {
      return DomAdapter;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵNullViewportScroller", function () {
      return NullViewportScroller;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵPLATFORM_BROWSER_ID", function () {
      return PLATFORM_BROWSER_ID;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵPLATFORM_SERVER_ID", function () {
      return PLATFORM_SERVER_ID;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵPLATFORM_WORKER_APP_ID", function () {
      return PLATFORM_WORKER_APP_ID;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵPLATFORM_WORKER_UI_ID", function () {
      return PLATFORM_WORKER_UI_ID;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_common_a", function () {
      return useBrowserPlatformLocation;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_common_b", function () {
      return createBrowserPlatformLocation;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_common_c", function () {
      return createLocation;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_common_d", function () {
      return provideLocationStrategy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_common_e", function () {
      return COMMON_DIRECTIVES;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_common_f", function () {
      return COMMON_PIPES;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵgetDOM", function () {
      return getDOM;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵparseCookieValue", function () {
      return parseCookieValue;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵsetRootDomAdapter", function () {
      return setRootDomAdapter;
    });
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /**
     * @license Angular v9.1.4
     * (c) 2010-2020 Google LLC. https://angular.io/
     * License: MIT
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/dom_adapter.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** @type {?} */


    var _DOM =
    /** @type {?} */
    null;
    /**
     * @return {?}
     */

    function getDOM() {
      return _DOM;
    }
    /**
     * @param {?} adapter
     * @return {?}
     */


    function setDOM(adapter) {
      _DOM = adapter;
    }
    /**
     * @param {?} adapter
     * @return {?}
     */


    function setRootDomAdapter(adapter) {
      if (!_DOM) {
        _DOM = adapter;
      }
    }
    /* tslint:disable:requireParameterType */

    /**
     * Provides DOM operations in an environment-agnostic way.
     *
     * \@security Tread carefully! Interacting with the DOM directly is dangerous and
     * can introduce XSS risks.
     * @abstract
     */


    var DomAdapter = function DomAdapter() {
      _classCallCheck(this, DomAdapter);
    };

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/dom_tokens.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * A DI Token representing the main rendering context. In a browser this is the DOM Document.
     *
     * Note: Document might not be available in the Application Context when Application and Rendering
     * Contexts are not the same (e.g. when running the application in a Web Worker).
     *
     * \@publicApi
     * @type {?}
     */


    var DOCUMENT = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('DocumentToken');
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/location/platform_location.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * This class should not be used directly by an application developer. Instead, use
     * {\@link Location}.
     *
     * `PlatformLocation` encapsulates all calls to DOM apis, which allows the Router to be platform
     * agnostic.
     * This means that we can have different implementation of `PlatformLocation` for the different
     * platforms that angular supports. For example, `\@angular/platform-browser` provides an
     * implementation specific to the browser environment, while `\@angular/platform-webworker` provides
     * one suitable for use with web workers.
     *
     * The `PlatformLocation` class is used directly by all implementations of {\@link LocationStrategy}
     * when they need to interact with the DOM apis like pushState, popState, etc...
     *
     * {\@link LocationStrategy} in turn is used by the {\@link Location} service which is used directly
     * by the {\@link Router} in order to navigate between routes. Since all interactions between {\@link
     * Router} /
     * {\@link Location} / {\@link LocationStrategy} and DOM apis flow through the `PlatformLocation`
     * class they are all platform independent.
     *
     * \@publicApi
     * @abstract
     */

    var PlatformLocation = function PlatformLocation() {
      _classCallCheck(this, PlatformLocation);
    };

    PlatformLocation.ɵfac = function PlatformLocation_Factory(t) {
      return new (t || PlatformLocation)();
    };
    /** @nocollapse */


    PlatformLocation.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"])({
      factory: useBrowserPlatformLocation,
      token: PlatformLocation,
      providedIn: "platform"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](PlatformLocation, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"],
        args: [{
          providedIn: 'platform',
          // See #23917
          useFactory: useBrowserPlatformLocation
        }]
      }], null, null);
    })();

    if (false) {}
    /**
     * @return {?}
     */


    function useBrowserPlatformLocation() {
      return Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"])(BrowserPlatformLocation);
    }
    /**
     * \@description
     * Indicates when a location is initialized.
     *
     * \@publicApi
     * @type {?}
     */


    var LOCATION_INITIALIZED = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('Location Initialized');
    /**
     * \@description
     * A serializable version of the event from `onPopState` or `onHashChange`
     *
     * \@publicApi
     * @record
     */

    function LocationChangeEvent() {}

    if (false) {}
    /**
     * \@publicApi
     * @record
     */


    function LocationChangeListener() {}
    /**
     * `PlatformLocation` encapsulates all of the direct calls to platform APIs.
     * This class should not be used directly by an application developer. Instead, use
     * {\@link Location}.
     */


    var BrowserPlatformLocation = /*#__PURE__*/function (_PlatformLocation) {
      _inherits(BrowserPlatformLocation, _PlatformLocation);

      var _super20 = _createSuper(BrowserPlatformLocation);

      /**
       * @param {?} _doc
       */
      function BrowserPlatformLocation(_doc) {
        var _this122;

        _classCallCheck(this, BrowserPlatformLocation);

        _this122 = _super20.call(this);
        _this122._doc = _doc;

        _this122._init();

        return _this122;
      } // This is moved to its own method so that `MockPlatformLocationStrategy` can overwrite it

      /**
       * \@internal
       * @return {?}
       */


      _createClass2(BrowserPlatformLocation, [{
        key: "_init",
        value: function _init() {
          /** @type {?} */
          this.location = getDOM().getLocation();
          this._history = getDOM().getHistory();
        }
        /**
         * @return {?}
         */

      }, {
        key: "getBaseHrefFromDOM",
        value: function getBaseHrefFromDOM() {
          return (
            /** @type {?} */
            getDOM().getBaseHref(this._doc)
          );
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "onPopState",
        value: function onPopState(fn) {
          getDOM().getGlobalEventTarget(this._doc, 'window').addEventListener('popstate', fn, false);
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "onHashChange",
        value: function onHashChange(fn) {
          getDOM().getGlobalEventTarget(this._doc, 'window').addEventListener('hashchange', fn, false);
        }
        /**
         * @return {?}
         */

      }, {
        key: "pushState",

        /**
         * @param {?} state
         * @param {?} title
         * @param {?} url
         * @return {?}
         */
        value: function pushState(state, title, url) {
          if (supportsState()) {
            this._history.pushState(state, title, url);
          } else {
            this.location.hash = url;
          }
        }
        /**
         * @param {?} state
         * @param {?} title
         * @param {?} url
         * @return {?}
         */

      }, {
        key: "replaceState",
        value: function replaceState(state, title, url) {
          if (supportsState()) {
            this._history.replaceState(state, title, url);
          } else {
            this.location.hash = url;
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "forward",
        value: function forward() {
          this._history.forward();
        }
        /**
         * @return {?}
         */

      }, {
        key: "back",
        value: function back() {
          this._history.back();
        }
        /**
         * @return {?}
         */

      }, {
        key: "getState",
        value: function getState() {
          return this._history.state;
        }
      }, {
        key: "href",
        get: function get() {
          return this.location.href;
        }
        /**
         * @return {?}
         */

      }, {
        key: "protocol",
        get: function get() {
          return this.location.protocol;
        }
        /**
         * @return {?}
         */

      }, {
        key: "hostname",
        get: function get() {
          return this.location.hostname;
        }
        /**
         * @return {?}
         */

      }, {
        key: "port",
        get: function get() {
          return this.location.port;
        }
        /**
         * @return {?}
         */

      }, {
        key: "pathname",
        get: function get() {
          return this.location.pathname;
        }
        /**
         * @return {?}
         */
        ,

        /**
         * @param {?} newPath
         * @return {?}
         */
        set: function set(newPath) {
          this.location.pathname = newPath;
        }
      }, {
        key: "search",
        get: function get() {
          return this.location.search;
        }
        /**
         * @return {?}
         */

      }, {
        key: "hash",
        get: function get() {
          return this.location.hash;
        }
      }]);

      return BrowserPlatformLocation;
    }(PlatformLocation);

    BrowserPlatformLocation.ɵfac = function BrowserPlatformLocation_Factory(t) {
      return new (t || BrowserPlatformLocation)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](DOCUMENT));
    };
    /** @nocollapse */


    BrowserPlatformLocation.ctorParameters = function () {
      return [{
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [DOCUMENT]
        }]
      }];
    };
    /** @nocollapse */


    BrowserPlatformLocation.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"])({
      factory: createBrowserPlatformLocation,
      token: BrowserPlatformLocation,
      providedIn: "platform"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](BrowserPlatformLocation, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"],
        args: [{
          providedIn: 'platform',
          // See #23917
          useFactory: createBrowserPlatformLocation
        }]
      }], function () {
        return [{
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [DOCUMENT]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @return {?}
     */


    function supportsState() {
      return !!window.history.pushState;
    }
    /**
     * @return {?}
     */


    function createBrowserPlatformLocation() {
      return new BrowserPlatformLocation(Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"])(DOCUMENT));
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/private_export.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/location/util.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Joins two parts of a URL with a slash if needed.
     *
     * @param {?} start  URL string
     * @param {?} end    URL string
     *
     *
     * @return {?} The joined URL string.
     */


    function joinWithSlash(start, end) {
      if (start.length == 0) {
        return end;
      }

      if (end.length == 0) {
        return start;
      }
      /** @type {?} */


      var slashes = 0;

      if (start.endsWith('/')) {
        slashes++;
      }

      if (end.startsWith('/')) {
        slashes++;
      }

      if (slashes == 2) {
        return start + end.substring(1);
      }

      if (slashes == 1) {
        return start + end;
      }

      return start + '/' + end;
    }
    /**
     * Removes a trailing slash from a URL string if needed.
     * Looks for the first occurrence of either `#`, `?`, or the end of the
     * line as `/` characters and removes the trailing slash if one exists.
     *
     * @param {?} url URL string.
     *
     * @return {?} The URL string, modified if needed.
     */


    function stripTrailingSlash(url) {
      /** @type {?} */
      var match = url.match(/#|\?|$/);
      /** @type {?} */

      var pathEndIdx = match && match.index || url.length;
      /** @type {?} */

      var droppedSlashIdx = pathEndIdx - (url[pathEndIdx - 1] === '/' ? 1 : 0);
      return url.slice(0, droppedSlashIdx) + url.slice(pathEndIdx);
    }
    /**
     * Normalizes URL parameters by prepending with `?` if needed.
     *
     * @param {?} params String of URL parameters.
     *
     * @return {?} The normalized URL parameters string.
     */


    function normalizeQueryParams(params) {
      return params && params[0] !== '?' ? '?' + params : params;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/location/location_strategy.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Enables the `Location` service to read route state from the browser's URL.
     * Angular provides two strategies:
     * `HashLocationStrategy` and `PathLocationStrategy`.
     *
     * Applications should use the `Router` or `Location` services to
     * interact with application route state.
     *
     * For instance, `HashLocationStrategy` produces URLs like
     * <code class="no-auto-link">http://example.com#/foo</code>,
     * and `PathLocationStrategy` produces
     * <code class="no-auto-link">http://example.com/foo</code> as an equivalent URL.
     *
     * See these two classes for more.
     *
     * \@publicApi
     * @abstract
     */


    var LocationStrategy = function LocationStrategy() {
      _classCallCheck(this, LocationStrategy);
    };

    LocationStrategy.ɵfac = function LocationStrategy_Factory(t) {
      return new (t || LocationStrategy)();
    };
    /** @nocollapse */


    LocationStrategy.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"])({
      factory: provideLocationStrategy,
      token: LocationStrategy,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](LocationStrategy, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"],
        args: [{
          providedIn: 'root',
          useFactory: provideLocationStrategy
        }]
      }], null, null);
    })();

    if (false) {}
    /**
     * @param {?} platformLocation
     * @return {?}
     */


    function provideLocationStrategy(platformLocation) {
      // See #23917

      /** @type {?} */
      var location = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"])(DOCUMENT).location;
      return new PathLocationStrategy(Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"])(
      /** @type {?} */
      PlatformLocation), location && location.origin || '');
    }
    /**
     * A predefined [DI token](guide/glossary#di-token) for the base href
     * to be used with the `PathLocationStrategy`.
     * The base href is the URL prefix that should be preserved when generating
     * and recognizing URLs.
     *
     * \@usageNotes
     *
     * The following example shows how to use this token to configure the root app injector
     * with a base href value, so that the DI framework can supply the dependency anywhere in the app.
     *
     * ```typescript
     * import {Component, NgModule} from '\@angular/core';
     * import {APP_BASE_HREF} from '\@angular/common';
     *
     * \@NgModule({
     *   providers: [{provide: APP_BASE_HREF, useValue: '/my/app'}]
     * })
     * class AppModule {}
     * ```
     *
     * \@publicApi
     * @type {?}
     */


    var APP_BASE_HREF = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('appBaseHref');
    /**
     * \@description
     * A {\@link LocationStrategy} used to configure the {\@link Location} service to
     * represent its state in the
     * [path](https://en.wikipedia.org/wiki/Uniform_Resource_Locator#Syntax) of the
     * browser's URL.
     *
     * If you're using `PathLocationStrategy`, you must provide a {\@link APP_BASE_HREF}
     * or add a base element to the document. This URL prefix that will be preserved
     * when generating and recognizing URLs.
     *
     * For instance, if you provide an `APP_BASE_HREF` of `'/my/app'` and call
     * `location.go('/foo')`, the browser's URL will become
     * `example.com/my/app/foo`.
     *
     * Similarly, if you add `<base href='/my/app'/>` to the document and call
     * `location.go('/foo')`, the browser's URL will become
     * `example.com/my/app/foo`.
     *
     * \@usageNotes
     *
     * ### Example
     *
     * {\@example common/location/ts/path_location_component.ts region='LocationComponent'}
     *
     * \@publicApi
     */

    var PathLocationStrategy = /*#__PURE__*/function (_LocationStrategy) {
      _inherits(PathLocationStrategy, _LocationStrategy);

      var _super21 = _createSuper(PathLocationStrategy);

      /**
       * @param {?} _platformLocation
       * @param {?=} href
       */
      function PathLocationStrategy(_platformLocation, href) {
        var _this123;

        _classCallCheck(this, PathLocationStrategy);

        _this123 = _super21.call(this);
        _this123._platformLocation = _platformLocation;

        if (href == null) {
          href = _this123._platformLocation.getBaseHrefFromDOM();
        }

        if (href == null) {
          throw new Error("No base href set. Please provide a value for the APP_BASE_HREF token or add a base element to the document.");
        }

        _this123._baseHref = href;
        return _this123;
      }
      /**
       * @param {?} fn
       * @return {?}
       */


      _createClass2(PathLocationStrategy, [{
        key: "onPopState",
        value: function onPopState(fn) {
          this._platformLocation.onPopState(fn);

          this._platformLocation.onHashChange(fn);
        }
        /**
         * @return {?}
         */

      }, {
        key: "getBaseHref",
        value: function getBaseHref() {
          return this._baseHref;
        }
        /**
         * @param {?} internal
         * @return {?}
         */

      }, {
        key: "prepareExternalUrl",
        value: function prepareExternalUrl(internal) {
          return joinWithSlash(this._baseHref, internal);
        }
        /**
         * @param {?=} includeHash
         * @return {?}
         */

      }, {
        key: "path",
        value: function path() {
          var includeHash = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;

          /** @type {?} */
          var pathname = this._platformLocation.pathname + normalizeQueryParams(this._platformLocation.search);
          /** @type {?} */

          var hash = this._platformLocation.hash;
          return hash && includeHash ? "".concat(pathname).concat(hash) : pathname;
        }
        /**
         * @param {?} state
         * @param {?} title
         * @param {?} url
         * @param {?} queryParams
         * @return {?}
         */

      }, {
        key: "pushState",
        value: function pushState(state, title, url, queryParams) {
          /** @type {?} */
          var externalUrl = this.prepareExternalUrl(url + normalizeQueryParams(queryParams));

          this._platformLocation.pushState(state, title, externalUrl);
        }
        /**
         * @param {?} state
         * @param {?} title
         * @param {?} url
         * @param {?} queryParams
         * @return {?}
         */

      }, {
        key: "replaceState",
        value: function replaceState(state, title, url, queryParams) {
          /** @type {?} */
          var externalUrl = this.prepareExternalUrl(url + normalizeQueryParams(queryParams));

          this._platformLocation.replaceState(state, title, externalUrl);
        }
        /**
         * @return {?}
         */

      }, {
        key: "forward",
        value: function forward() {
          this._platformLocation.forward();
        }
        /**
         * @return {?}
         */

      }, {
        key: "back",
        value: function back() {
          this._platformLocation.back();
        }
      }]);

      return PathLocationStrategy;
    }(LocationStrategy);

    PathLocationStrategy.ɵfac = function PathLocationStrategy_Factory(t) {
      return new (t || PathLocationStrategy)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](PlatformLocation), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](APP_BASE_HREF, 8));
    };

    PathLocationStrategy.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({
      token: PathLocationStrategy,
      factory: PathLocationStrategy.ɵfac
    });
    /** @nocollapse */

    PathLocationStrategy.ctorParameters = function () {
      return [{
        type: PlatformLocation
      }, {
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [APP_BASE_HREF]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](PathLocationStrategy, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"]
      }], function () {
        return [{
          type: PlatformLocation
        }, {
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [APP_BASE_HREF]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/location/hash_location_strategy.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@description
     * A {\@link LocationStrategy} used to configure the {\@link Location} service to
     * represent its state in the
     * [hash fragment](https://en.wikipedia.org/wiki/Uniform_Resource_Locator#Syntax)
     * of the browser's URL.
     *
     * For instance, if you call `location.go('/foo')`, the browser's URL will become
     * `example.com#/foo`.
     *
     * \@usageNotes
     *
     * ### Example
     *
     * {\@example common/location/ts/hash_location_component.ts region='LocationComponent'}
     *
     * \@publicApi
     */


    var HashLocationStrategy = /*#__PURE__*/function (_LocationStrategy2) {
      _inherits(HashLocationStrategy, _LocationStrategy2);

      var _super22 = _createSuper(HashLocationStrategy);

      /**
       * @param {?} _platformLocation
       * @param {?=} _baseHref
       */
      function HashLocationStrategy(_platformLocation, _baseHref) {
        var _this124;

        _classCallCheck(this, HashLocationStrategy);

        _this124 = _super22.call(this);
        _this124._platformLocation = _platformLocation;
        _this124._baseHref = '';

        if (_baseHref != null) {
          _this124._baseHref = _baseHref;
        }

        return _this124;
      }
      /**
       * @param {?} fn
       * @return {?}
       */


      _createClass2(HashLocationStrategy, [{
        key: "onPopState",
        value: function onPopState(fn) {
          this._platformLocation.onPopState(fn);

          this._platformLocation.onHashChange(fn);
        }
        /**
         * @return {?}
         */

      }, {
        key: "getBaseHref",
        value: function getBaseHref() {
          return this._baseHref;
        }
        /**
         * @param {?=} includeHash
         * @return {?}
         */

      }, {
        key: "path",
        value: function path() {
          var includeHash = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
          // the hash value is always prefixed with a `#`
          // and if it is empty then it will stay empty

          /** @type {?} */
          var path = this._platformLocation.hash;
          if (path == null) path = '#';
          return path.length > 0 ? path.substring(1) : path;
        }
        /**
         * @param {?} internal
         * @return {?}
         */

      }, {
        key: "prepareExternalUrl",
        value: function prepareExternalUrl(internal) {
          /** @type {?} */
          var url = joinWithSlash(this._baseHref, internal);
          return url.length > 0 ? '#' + url : url;
        }
        /**
         * @param {?} state
         * @param {?} title
         * @param {?} path
         * @param {?} queryParams
         * @return {?}
         */

      }, {
        key: "pushState",
        value: function pushState(state, title, path, queryParams) {
          /** @type {?} */
          var url = this.prepareExternalUrl(path + normalizeQueryParams(queryParams));

          if (url.length == 0) {
            url = this._platformLocation.pathname;
          }

          this._platformLocation.pushState(state, title, url);
        }
        /**
         * @param {?} state
         * @param {?} title
         * @param {?} path
         * @param {?} queryParams
         * @return {?}
         */

      }, {
        key: "replaceState",
        value: function replaceState(state, title, path, queryParams) {
          /** @type {?} */
          var url = this.prepareExternalUrl(path + normalizeQueryParams(queryParams));

          if (url.length == 0) {
            url = this._platformLocation.pathname;
          }

          this._platformLocation.replaceState(state, title, url);
        }
        /**
         * @return {?}
         */

      }, {
        key: "forward",
        value: function forward() {
          this._platformLocation.forward();
        }
        /**
         * @return {?}
         */

      }, {
        key: "back",
        value: function back() {
          this._platformLocation.back();
        }
      }]);

      return HashLocationStrategy;
    }(LocationStrategy);

    HashLocationStrategy.ɵfac = function HashLocationStrategy_Factory(t) {
      return new (t || HashLocationStrategy)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](PlatformLocation), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](APP_BASE_HREF, 8));
    };

    HashLocationStrategy.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({
      token: HashLocationStrategy,
      factory: HashLocationStrategy.ɵfac
    });
    /** @nocollapse */

    HashLocationStrategy.ctorParameters = function () {
      return [{
        type: PlatformLocation
      }, {
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [APP_BASE_HREF]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](HashLocationStrategy, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"]
      }], function () {
        return [{
          type: PlatformLocation
        }, {
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [APP_BASE_HREF]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/location/location.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@publicApi
     * @record
     */


    function PopStateEvent() {}

    if (false) {}
    /**
     * \@description
     *
     * A service that applications can use to interact with a browser's URL.
     *
     * Depending on the `LocationStrategy` used, `Location` persists
     * to the URL's path or the URL's hash segment.
     *
     * \@usageNotes
     *
     * It's better to use the `Router#navigate` service to trigger route changes. Use
     * `Location` only if you need to interact with or create normalized URLs outside of
     * routing.
     *
     * `Location` is responsible for normalizing the URL against the application's base href.
     * A normalized URL is absolute from the URL host, includes the application's base href, and has no
     * trailing slash:
     * - `/my/app/user/123` is normalized
     * - `my/app/user/123` **is not** normalized
     * - `/my/app/user/123/` **is not** normalized
     *
     * ### Example
     *
     * <code-example path='common/location/ts/path_location_component.ts'
     * region='LocationComponent'></code-example>
     *
     * \@publicApi
     */


    var Location = /*#__PURE__*/function () {
      /**
       * @param {?} platformStrategy
       * @param {?} platformLocation
       */
      function Location(platformStrategy, platformLocation) {
        var _this125 = this;

        _classCallCheck(this, Location);

        /**
         * \@internal
         */
        this._subject = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"]();
        /**
         * \@internal
         */

        this._urlChangeListeners = [];
        this._platformStrategy = platformStrategy;
        /** @type {?} */

        var browserBaseHref = this._platformStrategy.getBaseHref();

        this._platformLocation = platformLocation;
        this._baseHref = stripTrailingSlash(_stripIndexHtml(browserBaseHref));

        this._platformStrategy.onPopState(
        /**
        * @param {?} ev
        * @return {?}
        */
        function (ev) {
          _this125._subject.emit({
            'url': _this125.path(true),
            'pop': true,
            'state': ev.state,
            'type': ev.type
          });
        });
      }
      /**
       * Normalizes the URL path for this location.
       *
       * @param {?=} includeHash True to include an anchor fragment in the path.
       *
       * @return {?} The normalized URL path.
       */
      // TODO: vsavkin. Remove the boolean flag and always include hash once the deprecated router is
      // removed.


      _createClass2(Location, [{
        key: "path",
        value: function path() {
          var includeHash = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
          return this.normalize(this._platformStrategy.path(includeHash));
        }
        /**
         * Reports the current state of the location history.
         * @return {?} The current value of the `history.state` object.
         */

      }, {
        key: "getState",
        value: function getState() {
          return this._platformLocation.getState();
        }
        /**
         * Normalizes the given path and compares to the current normalized path.
         *
         * @param {?} path The given URL path.
         * @param {?=} query Query parameters.
         *
         * @return {?} True if the given URL path is equal to the current normalized path, false
         * otherwise.
         */

      }, {
        key: "isCurrentPathEqualTo",
        value: function isCurrentPathEqualTo(path) {
          var query = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';
          return this.path() == this.normalize(path + normalizeQueryParams(query));
        }
        /**
         * Normalizes a URL path by stripping any trailing slashes.
         *
         * @param {?} url String representing a URL.
         *
         * @return {?} The normalized URL string.
         */

      }, {
        key: "normalize",
        value: function normalize(url) {
          return Location.stripTrailingSlash(_stripBaseHref(this._baseHref, _stripIndexHtml(url)));
        }
        /**
         * Normalizes an external URL path.
         * If the given URL doesn't begin with a leading slash (`'/'`), adds one
         * before normalizing. Adds a hash if `HashLocationStrategy` is
         * in use, or the `APP_BASE_HREF` if the `PathLocationStrategy` is in use.
         *
         * @param {?} url String representing a URL.
         *
         * @return {?} A normalized platform-specific URL.
         */

      }, {
        key: "prepareExternalUrl",
        value: function prepareExternalUrl(url) {
          if (url && url[0] !== '/') {
            url = '/' + url;
          }

          return this._platformStrategy.prepareExternalUrl(url);
        } // TODO: rename this method to pushState

        /**
         * Changes the browser's URL to a normalized version of a given URL, and pushes a
         * new item onto the platform's history.
         *
         * @param {?} path  URL path to normalize.
         * @param {?=} query Query parameters.
         * @param {?=} state Location history state.
         *
         * @return {?}
         */

      }, {
        key: "go",
        value: function go(path) {
          var query = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';
          var state = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;

          this._platformStrategy.pushState(state, '', path, query);

          this._notifyUrlChangeListeners(this.prepareExternalUrl(path + normalizeQueryParams(query)), state);
        }
        /**
         * Changes the browser's URL to a normalized version of the given URL, and replaces
         * the top item on the platform's history stack.
         *
         * @param {?} path  URL path to normalize.
         * @param {?=} query Query parameters.
         * @param {?=} state Location history state.
         * @return {?}
         */

      }, {
        key: "replaceState",
        value: function replaceState(path) {
          var query = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';
          var state = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;

          this._platformStrategy.replaceState(state, '', path, query);

          this._notifyUrlChangeListeners(this.prepareExternalUrl(path + normalizeQueryParams(query)), state);
        }
        /**
         * Navigates forward in the platform's history.
         * @return {?}
         */

      }, {
        key: "forward",
        value: function forward() {
          this._platformStrategy.forward();
        }
        /**
         * Navigates back in the platform's history.
         * @return {?}
         */

      }, {
        key: "back",
        value: function back() {
          this._platformStrategy.back();
        }
        /**
         * Registers a URL change listener. Use to catch updates performed by the Angular
         * framework that are not detectible through "popstate" or "hashchange" events.
         *
         * @param {?} fn The change handler function, which take a URL and a location history state.
         * @return {?}
         */

      }, {
        key: "onUrlChange",
        value: function onUrlChange(fn) {
          var _this126 = this;

          this._urlChangeListeners.push(fn);

          this.subscribe(
          /**
          * @param {?} v
          * @return {?}
          */
          function (v) {
            _this126._notifyUrlChangeListeners(v.url, v.state);
          });
        }
        /**
         * \@internal
         * @param {?=} url
         * @param {?=} state
         * @return {?}
         */

      }, {
        key: "_notifyUrlChangeListeners",
        value: function _notifyUrlChangeListeners() {
          var url = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';
          var state = arguments.length > 1 ? arguments[1] : undefined;

          this._urlChangeListeners.forEach(
          /**
          * @param {?} fn
          * @return {?}
          */
          function (fn) {
            return fn(url, state);
          });
        }
        /**
         * Subscribes to the platform's `popState` events.
         *
         * @param {?} onNext
         * @param {?=} onThrow
         * @param {?=} onReturn
         * @return {?} Subscribed events.
         */

      }, {
        key: "subscribe",
        value: function subscribe(onNext, onThrow, onReturn) {
          return this._subject.subscribe({
            next: onNext,
            error: onThrow,
            complete: onReturn
          });
        }
      }]);

      return Location;
    }();

    Location.ɵfac = function Location_Factory(t) {
      return new (t || Location)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](LocationStrategy), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](PlatformLocation));
    };
    /**
     * Normalizes URL parameters by prepending with `?` if needed.
     *
     * @param params String of URL parameters.
     *
     * @return The normalized URL parameters string.
     */


    Location.normalizeQueryParams = normalizeQueryParams;
    /**
     * Joins two parts of a URL with a slash if needed.
     *
     * @param start  URL string
     * @param end    URL string
     *
     *
     * @return The joined URL string.
     */

    Location.joinWithSlash = joinWithSlash;
    /**
     * Removes a trailing slash from a URL string if needed.
     * Looks for the first occurrence of either `#`, `?`, or the end of the
     * line as `/` characters and removes the trailing slash if one exists.
     *
     * @param url URL string.
     *
     * @return The URL string, modified if needed.
     */

    Location.stripTrailingSlash = stripTrailingSlash;
    /** @nocollapse */

    Location.ctorParameters = function () {
      return [{
        type: LocationStrategy
      }, {
        type: PlatformLocation
      }];
    };
    /** @nocollapse */


    Location.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"])({
      factory: createLocation,
      token: Location,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](Location, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"],
        args: [{
          providedIn: 'root',
          // See #23917
          useFactory: createLocation
        }]
      }], function () {
        return [{
          type: LocationStrategy
        }, {
          type: PlatformLocation
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @return {?}
     */


    function createLocation() {
      return new Location(Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"])(
      /** @type {?} */
      LocationStrategy), Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"])(
      /** @type {?} */
      PlatformLocation));
    }
    /**
     * @param {?} baseHref
     * @param {?} url
     * @return {?}
     */


    function _stripBaseHref(baseHref, url) {
      return baseHref && url.startsWith(baseHref) ? url.substring(baseHref.length) : url;
    }
    /**
     * @param {?} url
     * @return {?}
     */


    function _stripIndexHtml(url) {
      return url.replace(/\/index.html$/, '');
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/location/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/i18n/currencies.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */
    // THIS CODE IS GENERATED - DO NOT MODIFY
    // See angular/tools/gulp-tasks/cldr/extract.js

    /**
     * \@internal
     * @type {?}
     */


    var CURRENCIES_EN = {
      'ADP': [undefined, undefined, 0],
      'AFN': [undefined, undefined, 0],
      'ALL': [undefined, undefined, 0],
      'AMD': [undefined, undefined, 2],
      'AOA': [undefined, 'Kz'],
      'ARS': [undefined, '$'],
      'AUD': ['A$', '$'],
      'BAM': [undefined, 'KM'],
      'BBD': [undefined, '$'],
      'BDT': [undefined, '৳'],
      'BHD': [undefined, undefined, 3],
      'BIF': [undefined, undefined, 0],
      'BMD': [undefined, '$'],
      'BND': [undefined, '$'],
      'BOB': [undefined, 'Bs'],
      'BRL': ['R$'],
      'BSD': [undefined, '$'],
      'BWP': [undefined, 'P'],
      'BYN': [undefined, 'р.', 2],
      'BYR': [undefined, undefined, 0],
      'BZD': [undefined, '$'],
      'CAD': ['CA$', '$', 2],
      'CHF': [undefined, undefined, 2],
      'CLF': [undefined, undefined, 4],
      'CLP': [undefined, '$', 0],
      'CNY': ['CN¥', '¥'],
      'COP': [undefined, '$', 2],
      'CRC': [undefined, '₡', 2],
      'CUC': [undefined, '$'],
      'CUP': [undefined, '$'],
      'CZK': [undefined, 'Kč', 2],
      'DJF': [undefined, undefined, 0],
      'DKK': [undefined, 'kr', 2],
      'DOP': [undefined, '$'],
      'EGP': [undefined, 'E£'],
      'ESP': [undefined, '₧', 0],
      'EUR': ['€'],
      'FJD': [undefined, '$'],
      'FKP': [undefined, '£'],
      'GBP': ['£'],
      'GEL': [undefined, '₾'],
      'GIP': [undefined, '£'],
      'GNF': [undefined, 'FG', 0],
      'GTQ': [undefined, 'Q'],
      'GYD': [undefined, '$', 2],
      'HKD': ['HK$', '$'],
      'HNL': [undefined, 'L'],
      'HRK': [undefined, 'kn'],
      'HUF': [undefined, 'Ft', 2],
      'IDR': [undefined, 'Rp', 2],
      'ILS': ['₪'],
      'INR': ['₹'],
      'IQD': [undefined, undefined, 0],
      'IRR': [undefined, undefined, 0],
      'ISK': [undefined, 'kr', 0],
      'ITL': [undefined, undefined, 0],
      'JMD': [undefined, '$'],
      'JOD': [undefined, undefined, 3],
      'JPY': ['¥', undefined, 0],
      'KHR': [undefined, '៛'],
      'KMF': [undefined, 'CF', 0],
      'KPW': [undefined, '₩', 0],
      'KRW': ['₩', undefined, 0],
      'KWD': [undefined, undefined, 3],
      'KYD': [undefined, '$'],
      'KZT': [undefined, '₸'],
      'LAK': [undefined, '₭', 0],
      'LBP': [undefined, 'L£', 0],
      'LKR': [undefined, 'Rs'],
      'LRD': [undefined, '$'],
      'LTL': [undefined, 'Lt'],
      'LUF': [undefined, undefined, 0],
      'LVL': [undefined, 'Ls'],
      'LYD': [undefined, undefined, 3],
      'MGA': [undefined, 'Ar', 0],
      'MGF': [undefined, undefined, 0],
      'MMK': [undefined, 'K', 0],
      'MNT': [undefined, '₮', 2],
      'MRO': [undefined, undefined, 0],
      'MUR': [undefined, 'Rs', 2],
      'MXN': ['MX$', '$'],
      'MYR': [undefined, 'RM'],
      'NAD': [undefined, '$'],
      'NGN': [undefined, '₦'],
      'NIO': [undefined, 'C$'],
      'NOK': [undefined, 'kr', 2],
      'NPR': [undefined, 'Rs'],
      'NZD': ['NZ$', '$'],
      'OMR': [undefined, undefined, 3],
      'PHP': [undefined, '₱'],
      'PKR': [undefined, 'Rs', 2],
      'PLN': [undefined, 'zł'],
      'PYG': [undefined, '₲', 0],
      'RON': [undefined, 'lei'],
      'RSD': [undefined, undefined, 0],
      'RUB': [undefined, '₽'],
      'RUR': [undefined, 'р.'],
      'RWF': [undefined, 'RF', 0],
      'SBD': [undefined, '$'],
      'SEK': [undefined, 'kr', 2],
      'SGD': [undefined, '$'],
      'SHP': [undefined, '£'],
      'SLL': [undefined, undefined, 0],
      'SOS': [undefined, undefined, 0],
      'SRD': [undefined, '$'],
      'SSP': [undefined, '£'],
      'STD': [undefined, undefined, 0],
      'STN': [undefined, 'Db'],
      'SYP': [undefined, '£', 0],
      'THB': [undefined, '฿'],
      'TMM': [undefined, undefined, 0],
      'TND': [undefined, undefined, 3],
      'TOP': [undefined, 'T$'],
      'TRL': [undefined, undefined, 0],
      'TRY': [undefined, '₺'],
      'TTD': [undefined, '$'],
      'TWD': ['NT$', '$', 2],
      'TZS': [undefined, undefined, 2],
      'UAH': [undefined, '₴'],
      'UGX': [undefined, undefined, 0],
      'USD': ['$'],
      'UYI': [undefined, undefined, 0],
      'UYU': [undefined, '$'],
      'UYW': [undefined, undefined, 4],
      'UZS': [undefined, undefined, 2],
      'VEF': [undefined, 'Bs', 2],
      'VND': ['₫', undefined, 0],
      'VUV': [undefined, undefined, 0],
      'XAF': ['FCFA', undefined, 0],
      'XCD': ['EC$', '$'],
      'XOF': ['CFA', undefined, 0],
      'XPF': ['CFPF', undefined, 0],
      'XXX': ['¤'],
      'YER': [undefined, undefined, 0],
      'ZAR': [undefined, 'R'],
      'ZMK': [undefined, undefined, 0],
      'ZMW': [undefined, 'ZK'],
      'ZWD': [undefined, undefined, 0]
    };
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/i18n/locale_data_api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @enum {number} */

    var NumberFormatStyle = {
      Decimal: 0,
      Percent: 1,
      Currency: 2,
      Scientific: 3
    };
    NumberFormatStyle[NumberFormatStyle.Decimal] = 'Decimal';
    NumberFormatStyle[NumberFormatStyle.Percent] = 'Percent';
    NumberFormatStyle[NumberFormatStyle.Currency] = 'Currency';
    NumberFormatStyle[NumberFormatStyle.Scientific] = 'Scientific';
    /** @enum {number} */

    var Plural = {
      Zero: 0,
      One: 1,
      Two: 2,
      Few: 3,
      Many: 4,
      Other: 5
    };
    Plural[Plural.Zero] = 'Zero';
    Plural[Plural.One] = 'One';
    Plural[Plural.Two] = 'Two';
    Plural[Plural.Few] = 'Few';
    Plural[Plural.Many] = 'Many';
    Plural[Plural.Other] = 'Other';
    /** @enum {number} */

    var FormStyle = {
      Format: 0,
      Standalone: 1
    };
    FormStyle[FormStyle.Format] = 'Format';
    FormStyle[FormStyle.Standalone] = 'Standalone';
    /** @enum {number} */

    var TranslationWidth = {
      /** 1 character for `en-US`. For example: 'S' */
      Narrow: 0,

      /** 3 characters for `en-US`. For example: 'Sun' */
      Abbreviated: 1,

      /** Full length for `en-US`. For example: "Sunday" */
      Wide: 2,

      /** 2 characters for `en-US`, For example: "Su" */
      Short: 3
    };
    TranslationWidth[TranslationWidth.Narrow] = 'Narrow';
    TranslationWidth[TranslationWidth.Abbreviated] = 'Abbreviated';
    TranslationWidth[TranslationWidth.Wide] = 'Wide';
    TranslationWidth[TranslationWidth.Short] = 'Short';
    /** @enum {number} */

    var FormatWidth = {
      /**
       * For `en-US`, 'M/d/yy, h:mm a'`
       * (Example: `6/15/15, 9:03 AM`)
       */
      Short: 0,

      /**
       * For `en-US`, `'MMM d, y, h:mm:ss a'`
       * (Example: `Jun 15, 2015, 9:03:01 AM`)
       */
      Medium: 1,

      /**
       * For `en-US`, `'MMMM d, y, h:mm:ss a z'`
       * (Example: `June 15, 2015 at 9:03:01 AM GMT+1`)
       */
      Long: 2,

      /**
       * For `en-US`, `'EEEE, MMMM d, y, h:mm:ss a zzzz'`
       * (Example: `Monday, June 15, 2015 at 9:03:01 AM GMT+01:00`)
       */
      Full: 3
    };
    FormatWidth[FormatWidth.Short] = 'Short';
    FormatWidth[FormatWidth.Medium] = 'Medium';
    FormatWidth[FormatWidth.Long] = 'Long';
    FormatWidth[FormatWidth.Full] = 'Full';
    /** @enum {number} */

    var NumberSymbol = {
      /**
       * Decimal separator.
       * For `en-US`, the dot character.
       * Example : 2,345`.`67
       */
      Decimal: 0,

      /**
       * Grouping separator, typically for thousands.
       * For `en-US`, the comma character.
       * Example: 2`,`345.67
       */
      Group: 1,

      /**
       * List-item separator.
       * Example: "one, two, and three"
       */
      List: 2,

      /**
       * Sign for percentage (out of 100).
       * Example: 23.4%
       */
      PercentSign: 3,

      /**
       * Sign for positive numbers.
       * Example: +23
       */
      PlusSign: 4,

      /**
       * Sign for negative numbers.
       * Example: -23
       */
      MinusSign: 5,

      /**
       * Computer notation for exponential value (n times a power of 10).
       * Example: 1.2E3
       */
      Exponential: 6,

      /**
       * Human-readable format of exponential.
       * Example: 1.2x103
       */
      SuperscriptingExponent: 7,

      /**
       * Sign for permille (out of 1000).
       * Example: 23.4‰
       */
      PerMille: 8,

      /**
       * Infinity, can be used with plus and minus.
       * Example: ∞, +∞, -∞
       */
      Infinity: 9,

      /**
       * Not a number.
       * Example: NaN
       */
      NaN: 10,

      /**
       * Symbol used between time units.
       * Example: 10:52
       */
      TimeSeparator: 11,

      /**
       * Decimal separator for currency values (fallback to `Decimal`).
       * Example: $2,345.67
       */
      CurrencyDecimal: 12,

      /**
       * Group separator for currency values (fallback to `Group`).
       * Example: $2,345.67
       */
      CurrencyGroup: 13
    };
    NumberSymbol[NumberSymbol.Decimal] = 'Decimal';
    NumberSymbol[NumberSymbol.Group] = 'Group';
    NumberSymbol[NumberSymbol.List] = 'List';
    NumberSymbol[NumberSymbol.PercentSign] = 'PercentSign';
    NumberSymbol[NumberSymbol.PlusSign] = 'PlusSign';
    NumberSymbol[NumberSymbol.MinusSign] = 'MinusSign';
    NumberSymbol[NumberSymbol.Exponential] = 'Exponential';
    NumberSymbol[NumberSymbol.SuperscriptingExponent] = 'SuperscriptingExponent';
    NumberSymbol[NumberSymbol.PerMille] = 'PerMille';
    NumberSymbol[NumberSymbol.Infinity] = 'Infinity';
    NumberSymbol[NumberSymbol.NaN] = 'NaN';
    NumberSymbol[NumberSymbol.TimeSeparator] = 'TimeSeparator';
    NumberSymbol[NumberSymbol.CurrencyDecimal] = 'CurrencyDecimal';
    NumberSymbol[NumberSymbol.CurrencyGroup] = 'CurrencyGroup';
    /** @enum {number} */

    var WeekDay = {
      Sunday: 0,
      Monday: 1,
      Tuesday: 2,
      Wednesday: 3,
      Thursday: 4,
      Friday: 5,
      Saturday: 6
    };
    WeekDay[WeekDay.Sunday] = 'Sunday';
    WeekDay[WeekDay.Monday] = 'Monday';
    WeekDay[WeekDay.Tuesday] = 'Tuesday';
    WeekDay[WeekDay.Wednesday] = 'Wednesday';
    WeekDay[WeekDay.Thursday] = 'Thursday';
    WeekDay[WeekDay.Friday] = 'Friday';
    WeekDay[WeekDay.Saturday] = 'Saturday';
    /**
     * Retrieves the locale ID from the currently loaded locale.
     * The loaded locale could be, for example, a global one rather than a regional one.
     * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @param {?} locale A locale code, such as `fr-FR`.
     * @return {?} The locale code. For example, `fr`.
     */

    function getLocaleId(locale) {
      return Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale)[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].LocaleId];
    }
    /**
     * Retrieves day period strings for the given locale.
     *
     * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @param {?} locale A locale code for the locale format rules to use.
     * @param {?} formStyle The required grammatical form.
     * @param {?} width The required character width.
     * @return {?} An array of localized period strings. For example, `[AM, PM]` for `en-US`.
     */


    function getLocaleDayPeriods(locale, formStyle, width) {
      /** @type {?} */
      var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale);
      /** @type {?} */

      var amPmData =
      /** @type {?} */
      [data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].DayPeriodsFormat], data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].DayPeriodsStandalone]];
      /** @type {?} */

      var amPm = getLastDefinedValue(amPmData, formStyle);
      return getLastDefinedValue(amPm, width);
    }
    /**
     * Retrieves days of the week for the given locale, using the Gregorian calendar.
     *
     * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @param {?} locale A locale code for the locale format rules to use.
     * @param {?} formStyle The required grammatical form.
     * @param {?} width The required character width.
     * @return {?} An array of localized name strings.
     * For example,`[Sunday, Monday, ... Saturday]` for `en-US`.
     */


    function getLocaleDayNames(locale, formStyle, width) {
      /** @type {?} */
      var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale);
      /** @type {?} */

      var daysData =
      /** @type {?} */
      [data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].DaysFormat], data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].DaysStandalone]];
      /** @type {?} */

      var days = getLastDefinedValue(daysData, formStyle);
      return getLastDefinedValue(days, width);
    }
    /**
     * Retrieves months of the year for the given locale, using the Gregorian calendar.
     *
     * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @param {?} locale A locale code for the locale format rules to use.
     * @param {?} formStyle The required grammatical form.
     * @param {?} width The required character width.
     * @return {?} An array of localized name strings.
     * For example,  `[January, February, ...]` for `en-US`.
     */


    function getLocaleMonthNames(locale, formStyle, width) {
      /** @type {?} */
      var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale);
      /** @type {?} */

      var monthsData =
      /** @type {?} */
      [data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].MonthsFormat], data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].MonthsStandalone]];
      /** @type {?} */

      var months = getLastDefinedValue(monthsData, formStyle);
      return getLastDefinedValue(months, width);
    }
    /**
     * Retrieves Gregorian-calendar eras for the given locale.
     * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @param {?} locale A locale code for the locale format rules to use.
     * @param {?} width The required character width.
     * @return {?} An array of localized era strings.
     * For example, `[AD, BC]` for `en-US`.
     */


    function getLocaleEraNames(locale, width) {
      /** @type {?} */
      var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale);
      /** @type {?} */

      var erasData =
      /** @type {?} */
      data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].Eras];
      return getLastDefinedValue(erasData, width);
    }
    /**
     * Retrieves the first day of the week for the given locale.
     *
     * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @param {?} locale A locale code for the locale format rules to use.
     * @return {?} A day index number, using the 0-based week-day index for `en-US`
     * (Sunday = 0, Monday = 1, ...).
     * For example, for `fr-FR`, returns 1 to indicate that the first day is Monday.
     */


    function getLocaleFirstDayOfWeek(locale) {
      /** @type {?} */
      var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale);
      return data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].FirstDayOfWeek];
    }
    /**
     * Range of week days that are considered the week-end for the given locale.
     *
     * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @param {?} locale A locale code for the locale format rules to use.
     * @return {?} The range of day values, `[startDay, endDay]`.
     */


    function getLocaleWeekEndRange(locale) {
      /** @type {?} */
      var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale);
      return data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].WeekendRange];
    }
    /**
     * Retrieves a localized date-value formating string.
     *
     * @see `FormatWidth` / [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @param {?} locale A locale code for the locale format rules to use.
     * @param {?} width The format type.
     * @return {?} The localized formating string.
     */


    function getLocaleDateFormat(locale, width) {
      /** @type {?} */
      var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale);
      return getLastDefinedValue(data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].DateFormat], width);
    }
    /**
     * Retrieves a localized time-value formatting string.
     *
     * @see `FormatWidth` / [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     * \@publicApi
     * @param {?} locale A locale code for the locale format rules to use.
     * @param {?} width The format type.
     * @return {?} The localized formatting string.
     */


    function getLocaleTimeFormat(locale, width) {
      /** @type {?} */
      var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale);
      return getLastDefinedValue(data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].TimeFormat], width);
    }
    /**
     * Retrieves a localized date-time formatting string.
     *
     * @see `FormatWidth` / [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @param {?} locale A locale code for the locale format rules to use.
     * @param {?} width The format type.
     * @return {?} The localized formatting string.
     */


    function getLocaleDateTimeFormat(locale, width) {
      /** @type {?} */
      var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale);
      /** @type {?} */

      var dateTimeFormatData =
      /** @type {?} */
      data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].DateTimeFormat];
      return getLastDefinedValue(dateTimeFormatData, width);
    }
    /**
     * Retrieves a localized number symbol that can be used to replace placeholders in number formats.
     * @see `NumberSymbol` / [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @param {?} locale The locale code.
     * @param {?} symbol The symbol to localize.
     * @return {?} The character for the localized symbol.
     */


    function getLocaleNumberSymbol(locale, symbol) {
      /** @type {?} */
      var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale);
      /** @type {?} */

      var res = data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].NumberSymbols][symbol];

      if (typeof res === 'undefined') {
        if (symbol === NumberSymbol.CurrencyDecimal) {
          return data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].NumberSymbols][NumberSymbol.Decimal];
        } else if (symbol === NumberSymbol.CurrencyGroup) {
          return data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].NumberSymbols][NumberSymbol.Group];
        }
      }

      return res;
    }
    /**
     * Retrieves a number format for a given locale.
     *
     * Numbers are formatted using patterns, like `#,###.00`. For example, the pattern `#,###.00`
     * when used to format the number 12345.678 could result in "12'345,678". That would happen if the
     * grouping separator for your language is an apostrophe, and the decimal separator is a comma.
     *
     * <b>Important:</b> The characters `.` `,` `0` `#` (and others below) are special placeholders
     * that stand for the decimal separator, and so on, and are NOT real characters.
     * You must NOT "translate" the placeholders. For example, don't change `.` to `,` even though in
     * your language the decimal point is written with a comma. The symbols should be replaced by the
     * local equivalents, using the appropriate `NumberSymbol` for your language.
     *
     * Here are the special characters used in number patterns:
     *
     * | Symbol | Meaning |
     * |--------|---------|
     * | . | Replaced automatically by the character used for the decimal point. |
     * | , | Replaced by the "grouping" (thousands) separator. |
     * | 0 | Replaced by a digit (or zero if there aren't enough digits). |
     * | # | Replaced by a digit (or nothing if there aren't enough). |
     * | ¤ | Replaced by a currency symbol, such as $ or USD. |
     * | % | Marks a percent format. The % symbol may change position, but must be retained. |
     * | E | Marks a scientific format. The E symbol may change position, but must be retained. |
     * | ' | Special characters used as literal characters are quoted with ASCII single quotes. |
     *
     * @see `NumberFormatStyle` / [CLDR website](http://cldr.unicode.org/translation/number-patterns) / [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @param {?} locale A locale code for the locale format rules to use.
     * @param {?} type The type of numeric value to be formatted (such as `Decimal` or `Currency`.)
     * @return {?} The localized format string.
     */


    function getLocaleNumberFormat(locale, type) {
      /** @type {?} */
      var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale);
      return data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].NumberFormats][type];
    }
    /**
     * Retrieves the symbol used to represent the currency for the main country
     * corresponding to a given locale. For example, '$' for `en-US`.
     *
     * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @param {?} locale A locale code for the locale format rules to use.
     * @return {?} The localized symbol character,
     * or `null` if the main country cannot be determined.
     */


    function getLocaleCurrencySymbol(locale) {
      /** @type {?} */
      var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale);
      return data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].CurrencySymbol] || null;
    }
    /**
     * Retrieves the name of the currency for the main country corresponding
     * to a given locale. For example, 'US Dollar' for `en-US`.
     * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @param {?} locale A locale code for the locale format rules to use.
     * @return {?} The currency name,
     * or `null` if the main country cannot be determined.
     */


    function getLocaleCurrencyName(locale) {
      /** @type {?} */
      var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale);
      return data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].CurrencyName] || null;
    }
    /**
     * Retrieves the default currency code for the given locale.
     *
     * The default is defined as the first currency which is still in use.
     *
     * \@publicApi
     * @param {?} locale The code of the locale whose currency code we want.
     * @return {?} The code of the default currency for the given locale.
     *
     */


    function getLocaleCurrencyCode(locale) {
      return Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵgetLocaleCurrencyCode"])(locale);
    }
    /**
     * Retrieves the currency values for a given locale.
     * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     * @param {?} locale A locale code for the locale format rules to use.
     * @return {?} The currency values.
     */


    function getLocaleCurrencies(locale) {
      /** @type {?} */
      var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale);
      return data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].Currencies];
    }
    /**
     * \@alias core/ɵgetLocalePluralCase
     * \@publicApi
     * @type {?}
     */


    var getLocalePluralCase = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵgetLocalePluralCase"];
    /**
     * @param {?} data
     * @return {?}
     */

    function checkFullData(data) {
      if (!data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].ExtraData]) {
        throw new Error("Missing extra locale data for the locale \"".concat(data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].LocaleId], "\". Use \"registerLocaleData\" to load new data. See the \"I18n guide\" on angular.io to know more."));
      }
    }
    /**
     * Retrieves locale-specific rules used to determine which day period to use
     * when more than one period is defined for a locale.
     *
     * There is a rule for each defined day period. The
     * first rule is applied to the first day period and so on.
     * Fall back to AM/PM when no rules are available.
     *
     * A rule can specify a period as time range, or as a single time value.
     *
     * This functionality is only available when you have loaded the full locale data.
     * See the ["I18n guide"](guide/i18n#i18n-pipes).
     *
     * @see `getLocaleExtraDayPeriods()` / [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @param {?} locale A locale code for the locale format rules to use.
     * @return {?} The rules for the locale, a single time value or array of *from-time, to-time*,
     * or null if no periods are available.
     *
     */


    function getLocaleExtraDayPeriodRules(locale) {
      /** @type {?} */
      var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale);
      checkFullData(data);
      /** @type {?} */

      var rules = data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].ExtraData][2
      /* ExtraDayPeriodsRules */
      ] || [];
      return rules.map(
      /**
      * @param {?} rule
      * @return {?}
      */
      function (rule) {
        if (typeof rule === 'string') {
          return extractTime(rule);
        }

        return [extractTime(rule[0]), extractTime(rule[1])];
      });
    }
    /**
     * Retrieves locale-specific day periods, which indicate roughly how a day is broken up
     * in different languages.
     * For example, for `en-US`, periods are morning, noon, afternoon, evening, and midnight.
     *
     * This functionality is only available when you have loaded the full locale data.
     * See the ["I18n guide"](guide/i18n#i18n-pipes).
     *
     * @see `getLocaleExtraDayPeriodRules()` / [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @param {?} locale A locale code for the locale format rules to use.
     * @param {?} formStyle The required grammatical form.
     * @param {?} width The required character width.
     * @return {?} The translated day-period strings.
     */


    function getLocaleExtraDayPeriods(locale, formStyle, width) {
      /** @type {?} */
      var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale);
      checkFullData(data);
      /** @type {?} */

      var dayPeriodsData =
      /** @type {?} */
      [data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].ExtraData][0
      /* ExtraDayPeriodFormats */
      ], data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].ExtraData][1
      /* ExtraDayPeriodStandalone */
      ]];
      /** @type {?} */

      var dayPeriods = getLastDefinedValue(dayPeriodsData, formStyle) || [];
      return getLastDefinedValue(dayPeriods, width) || [];
    }
    /**
     * Retrieves the writing direction of a specified locale
     * \@publicApi
     * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     * @param {?} locale A locale code for the locale format rules to use.
     * @return {?} 'rtl' or 'ltr'
     */


    function getLocaleDirection(locale) {
      /** @type {?} */
      var data = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵfindLocaleData"])(locale);
      return data[_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵLocaleDataIndex"].Directionality];
    }
    /**
     * Retrieves the first value that is defined in an array, going backwards from an index position.
     *
     * To avoid repeating the same data (as when the "format" and "standalone" forms are the same)
     * add the first value to the locale data arrays, and add other values only if they are different.
     *
     * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @template T
     * @param {?} data The data array to retrieve from.
     * @param {?} index A 0-based index into the array to start from.
     * @return {?} The value immediately before the given index position.
     */


    function getLastDefinedValue(data, index) {
      for (var i = index; i > -1; i--) {
        if (typeof data[i] !== 'undefined') {
          return data[i];
        }
      }

      throw new Error('Locale data API: locale data undefined');
    }
    /**
     * Extracts the hours and minutes from a string like "15:45"
     * @param {?} time
     * @return {?}
     */


    function extractTime(time) {
      var _time$split = time.split(':'),
          _time$split2 = _slicedToArray(_time$split, 2),
          h = _time$split2[0],
          m = _time$split2[1];

      return {
        hours: +h,
        minutes: +m
      };
    }
    /**
     * Retrieves the currency symbol for a given currency code.
     *
     * For example, for the default `en-US` locale, the code `USD` can
     * be represented by the narrow symbol `$` or the wide symbol `US$`.
     *
     * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @param {?} code The currency code.
     * @param {?} format The format, `wide` or `narrow`.
     * @param {?=} locale A locale code for the locale format rules to use.
     *
     * @return {?} The symbol, or the currency code if no symbol is available.
     */


    function getCurrencySymbol(code, format) {
      var locale = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 'en';

      /** @type {?} */
      var currency = getLocaleCurrencies(locale)[code] || CURRENCIES_EN[code] || [];
      /** @type {?} */

      var symbolNarrow = currency[1
      /* SymbolNarrow */
      ];

      if (format === 'narrow' && typeof symbolNarrow === 'string') {
        return symbolNarrow;
      }

      return currency[0
      /* Symbol */
      ] || code;
    } // Most currencies have cents, that's why the default is 2

    /** @type {?} */


    var DEFAULT_NB_OF_CURRENCY_DIGITS = 2;
    /**
     * Reports the number of decimal digits for a given currency.
     * The value depends upon the presence of cents in that particular currency.
     *
     * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @param {?} code The currency code.
     * @return {?} The number of decimal digits, typically 0 or 2.
     */

    function getNumberOfCurrencyDigits(code) {
      /** @type {?} */
      var digits;
      /** @type {?} */

      var currency = CURRENCIES_EN[code];

      if (currency) {
        digits = currency[2
        /* NbOfDigits */
        ];
      }

      return typeof digits === 'number' ? digits : DEFAULT_NB_OF_CURRENCY_DIGITS;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/i18n/format_date.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var ISO8601_DATE_REGEX = /^(\d{4})-?(\d\d)-?(\d\d)(?:T(\d\d)(?::?(\d\d)(?::?(\d\d)(?:\.(\d+))?)?)?(Z|([+-])(\d\d):?(\d\d))?)?$/; //    1        2       3         4          5          6          7          8  9     10      11

    /** @type {?} */

    var NAMED_FORMATS = {};
    /** @type {?} */

    var DATE_FORMATS_SPLIT = /((?:[^GyMLwWdEabBhHmsSzZO']+)|(?:'(?:[^']|'')*')|(?:G{1,5}|y{1,4}|M{1,5}|L{1,5}|w{1,2}|W{1}|d{1,2}|E{1,6}|a{1,5}|b{1,5}|B{1,5}|h{1,2}|H{1,2}|m{1,2}|s{1,2}|S{1,3}|z{1,4}|Z{1,5}|O{1,4}))([\s\S]*)/;
    /** @enum {number} */

    var ZoneWidth = {
      Short: 0,
      ShortGMT: 1,
      Long: 2,
      Extended: 3
    };
    ZoneWidth[ZoneWidth.Short] = 'Short';
    ZoneWidth[ZoneWidth.ShortGMT] = 'ShortGMT';
    ZoneWidth[ZoneWidth.Long] = 'Long';
    ZoneWidth[ZoneWidth.Extended] = 'Extended';
    /** @enum {number} */

    var DateType = {
      FullYear: 0,
      Month: 1,
      Date: 2,
      Hours: 3,
      Minutes: 4,
      Seconds: 5,
      FractionalSeconds: 6,
      Day: 7
    };
    DateType[DateType.FullYear] = 'FullYear';
    DateType[DateType.Month] = 'Month';
    DateType[DateType.Date] = 'Date';
    DateType[DateType.Hours] = 'Hours';
    DateType[DateType.Minutes] = 'Minutes';
    DateType[DateType.Seconds] = 'Seconds';
    DateType[DateType.FractionalSeconds] = 'FractionalSeconds';
    DateType[DateType.Day] = 'Day';
    /** @enum {number} */

    var TranslationType = {
      DayPeriods: 0,
      Days: 1,
      Months: 2,
      Eras: 3
    };
    TranslationType[TranslationType.DayPeriods] = 'DayPeriods';
    TranslationType[TranslationType.Days] = 'Days';
    TranslationType[TranslationType.Months] = 'Months';
    TranslationType[TranslationType.Eras] = 'Eras';
    /**
     * \@ngModule CommonModule
     * \@description
     *
     * Formats a date according to locale rules.
     *
     * @see `DatePipe` / [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @param {?} value The date to format, as a Date, or a number (milliseconds since UTC epoch)
     * or an [ISO date-time string](https://www.w3.org/TR/NOTE-datetime).
     * @param {?} format The date-time components to include. See `DatePipe` for details.
     * @param {?} locale A locale code for the locale format rules to use.
     * @param {?=} timezone The time zone. A time zone offset from GMT (such as `'+0430'`),
     * or a standard UTC/GMT or continental US time zone abbreviation.
     * If not specified, uses host system settings.
     *
     * @return {?} The formatted date string.
     *
     */

    function formatDate(value, format, locale, timezone) {
      /** @type {?} */
      var date = toDate(value);
      /** @type {?} */

      var namedFormat = getNamedFormat(locale, format);
      format = namedFormat || format;
      /** @type {?} */

      var parts = [];
      /** @type {?} */

      var match;

      while (format) {
        match = DATE_FORMATS_SPLIT.exec(format);

        if (match) {
          parts = parts.concat(match.slice(1));
          /** @type {?} */

          var part = parts.pop();

          if (!part) {
            break;
          }

          format = part;
        } else {
          parts.push(format);
          break;
        }
      }
      /** @type {?} */


      var dateTimezoneOffset = date.getTimezoneOffset();

      if (timezone) {
        dateTimezoneOffset = timezoneToOffset(timezone, dateTimezoneOffset);
        date = convertTimezoneToLocal(date, timezone, true);
      }
      /** @type {?} */


      var text = '';
      parts.forEach(
      /**
      * @param {?} value
      * @return {?}
      */
      function (value) {
        /** @type {?} */
        var dateFormatter = getDateFormatter(value);
        text += dateFormatter ? dateFormatter(date, locale, dateTimezoneOffset) : value === '\'\'' ? '\'' : value.replace(/(^'|'$)/g, '').replace(/''/g, '\'');
      });
      return text;
    }
    /**
     * @param {?} locale
     * @param {?} format
     * @return {?}
     */


    function getNamedFormat(locale, format) {
      /** @type {?} */
      var localeId = getLocaleId(locale);
      NAMED_FORMATS[localeId] = NAMED_FORMATS[localeId] || {};

      if (NAMED_FORMATS[localeId][format]) {
        return NAMED_FORMATS[localeId][format];
      }
      /** @type {?} */


      var formatValue = '';

      switch (format) {
        case 'shortDate':
          formatValue = getLocaleDateFormat(locale, FormatWidth.Short);
          break;

        case 'mediumDate':
          formatValue = getLocaleDateFormat(locale, FormatWidth.Medium);
          break;

        case 'longDate':
          formatValue = getLocaleDateFormat(locale, FormatWidth.Long);
          break;

        case 'fullDate':
          formatValue = getLocaleDateFormat(locale, FormatWidth.Full);
          break;

        case 'shortTime':
          formatValue = getLocaleTimeFormat(locale, FormatWidth.Short);
          break;

        case 'mediumTime':
          formatValue = getLocaleTimeFormat(locale, FormatWidth.Medium);
          break;

        case 'longTime':
          formatValue = getLocaleTimeFormat(locale, FormatWidth.Long);
          break;

        case 'fullTime':
          formatValue = getLocaleTimeFormat(locale, FormatWidth.Full);
          break;

        case 'short':
          /** @type {?} */
          var shortTime = getNamedFormat(locale, 'shortTime');
          /** @type {?} */

          var shortDate = getNamedFormat(locale, 'shortDate');
          formatValue = formatDateTime(getLocaleDateTimeFormat(locale, FormatWidth.Short), [shortTime, shortDate]);
          break;

        case 'medium':
          /** @type {?} */
          var mediumTime = getNamedFormat(locale, 'mediumTime');
          /** @type {?} */

          var mediumDate = getNamedFormat(locale, 'mediumDate');
          formatValue = formatDateTime(getLocaleDateTimeFormat(locale, FormatWidth.Medium), [mediumTime, mediumDate]);
          break;

        case 'long':
          /** @type {?} */
          var longTime = getNamedFormat(locale, 'longTime');
          /** @type {?} */

          var longDate = getNamedFormat(locale, 'longDate');
          formatValue = formatDateTime(getLocaleDateTimeFormat(locale, FormatWidth.Long), [longTime, longDate]);
          break;

        case 'full':
          /** @type {?} */
          var fullTime = getNamedFormat(locale, 'fullTime');
          /** @type {?} */

          var fullDate = getNamedFormat(locale, 'fullDate');
          formatValue = formatDateTime(getLocaleDateTimeFormat(locale, FormatWidth.Full), [fullTime, fullDate]);
          break;
      }

      if (formatValue) {
        NAMED_FORMATS[localeId][format] = formatValue;
      }

      return formatValue;
    }
    /**
     * @param {?} str
     * @param {?} opt_values
     * @return {?}
     */


    function formatDateTime(str, opt_values) {
      if (opt_values) {
        str = str.replace(/\{([^}]+)}/g,
        /**
        * @param {?} match
        * @param {?} key
        * @return {?}
        */
        function (match, key) {
          return opt_values != null && key in opt_values ? opt_values[key] : match;
        });
      }

      return str;
    }
    /**
     * @param {?} num
     * @param {?} digits
     * @param {?=} minusSign
     * @param {?=} trim
     * @param {?=} negWrap
     * @return {?}
     */


    function padNumber(num, digits) {
      var minusSign = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : '-';
      var trim = arguments.length > 3 ? arguments[3] : undefined;
      var negWrap = arguments.length > 4 ? arguments[4] : undefined;

      /** @type {?} */
      var neg = '';

      if (num < 0 || negWrap && num <= 0) {
        if (negWrap) {
          num = -num + 1;
        } else {
          num = -num;
          neg = minusSign;
        }
      }
      /** @type {?} */


      var strNum = String(num);

      while (strNum.length < digits) {
        strNum = '0' + strNum;
      }

      if (trim) {
        strNum = strNum.substr(strNum.length - digits);
      }

      return neg + strNum;
    }
    /**
     * @param {?} milliseconds
     * @param {?} digits
     * @return {?}
     */


    function formatFractionalSeconds(milliseconds, digits) {
      /** @type {?} */
      var strMs = padNumber(milliseconds, 3);
      return strMs.substr(0, digits);
    }
    /**
     * Returns a date formatter that transforms a date into its locale digit representation
     * @param {?} name
     * @param {?} size
     * @param {?=} offset
     * @param {?=} trim
     * @param {?=} negWrap
     * @return {?}
     */


    function dateGetter(name, size) {
      var offset = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;
      var trim = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : false;
      var negWrap = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : false;
      return (
        /**
        * @param {?} date
        * @param {?} locale
        * @return {?}
        */
        function (date, locale) {
          /** @type {?} */
          var part = getDatePart(name, date);

          if (offset > 0 || part > -offset) {
            part += offset;
          }

          if (name === DateType.Hours) {
            if (part === 0 && offset === -12) {
              part = 12;
            }
          } else if (name === DateType.FractionalSeconds) {
            return formatFractionalSeconds(part, size);
          }
          /** @type {?} */


          var localeMinus = getLocaleNumberSymbol(locale, NumberSymbol.MinusSign);
          return padNumber(part, size, localeMinus, trim, negWrap);
        }
      );
    }
    /**
     * @param {?} part
     * @param {?} date
     * @return {?}
     */


    function getDatePart(part, date) {
      switch (part) {
        case DateType.FullYear:
          return date.getFullYear();

        case DateType.Month:
          return date.getMonth();

        case DateType.Date:
          return date.getDate();

        case DateType.Hours:
          return date.getHours();

        case DateType.Minutes:
          return date.getMinutes();

        case DateType.Seconds:
          return date.getSeconds();

        case DateType.FractionalSeconds:
          return date.getMilliseconds();

        case DateType.Day:
          return date.getDay();

        default:
          throw new Error("Unknown DateType value \"".concat(part, "\"."));
      }
    }
    /**
     * Returns a date formatter that transforms a date into its locale string representation
     * @param {?} name
     * @param {?} width
     * @param {?=} form
     * @param {?=} extended
     * @return {?}
     */


    function dateStrGetter(name, width) {
      var form = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : FormStyle.Format;
      var extended = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : false;
      return (
        /**
        * @param {?} date
        * @param {?} locale
        * @return {?}
        */
        function (date, locale) {
          return getDateTranslation(date, locale, name, width, form, extended);
        }
      );
    }
    /**
     * Returns the locale translation of a date for a given form, type and width
     * @param {?} date
     * @param {?} locale
     * @param {?} name
     * @param {?} width
     * @param {?} form
     * @param {?} extended
     * @return {?}
     */


    function getDateTranslation(date, locale, name, width, form, extended) {
      switch (name) {
        case TranslationType.Months:
          return getLocaleMonthNames(locale, form, width)[date.getMonth()];

        case TranslationType.Days:
          return getLocaleDayNames(locale, form, width)[date.getDay()];

        case TranslationType.DayPeriods:
          /** @type {?} */
          var currentHours = date.getHours();
          /** @type {?} */

          var currentMinutes = date.getMinutes();

          if (extended) {
            /** @type {?} */
            var rules = getLocaleExtraDayPeriodRules(locale);
            /** @type {?} */

            var dayPeriods = getLocaleExtraDayPeriods(locale, form, width);
            /** @type {?} */

            var result;
            rules.forEach(
            /**
            * @param {?} rule
            * @param {?} index
            * @return {?}
            */
            function (rule, index) {
              if (Array.isArray(rule)) {
                // morning, afternoon, evening, night
                var _rule$ = rule[0],
                    hoursFrom = _rule$.hours,
                    minutesFrom = _rule$.minutes;
                var _rule$2 = rule[1],
                    hoursTo = _rule$2.hours,
                    minutesTo = _rule$2.minutes;

                if (currentHours >= hoursFrom && currentMinutes >= minutesFrom && (currentHours < hoursTo || currentHours === hoursTo && currentMinutes < minutesTo)) {
                  result = dayPeriods[index];
                }
              } else {
                // noon or midnight
                // noon or midnight
                var hours = rule.hours,
                    minutes = rule.minutes;

                if (hours === currentHours && minutes === currentMinutes) {
                  result = dayPeriods[index];
                }
              }
            });

            if (result) {
              return result;
            }
          } // if no rules for the day periods, we use am/pm by default


          return getLocaleDayPeriods(locale, form,
          /** @type {?} */
          width)[currentHours < 12 ? 0 : 1];

        case TranslationType.Eras:
          return getLocaleEraNames(locale,
          /** @type {?} */
          width)[date.getFullYear() <= 0 ? 0 : 1];

        default:
          // This default case is not needed by TypeScript compiler, as the switch is exhaustive.
          // However Closure Compiler does not understand that and reports an error in typed mode.
          // The `throw new Error` below works around the problem, and the unexpected: never variable
          // makes sure tsc still checks this code is unreachable.

          /** @type {?} */
          var unexpected = name;
          throw new Error("unexpected translation type ".concat(unexpected));
      }
    }
    /**
     * Returns a date formatter that transforms a date and an offset into a timezone with ISO8601 or
     * GMT format depending on the width (eg: short = +0430, short:GMT = GMT+4, long = GMT+04:30,
     * extended = +04:30)
     * @param {?} width
     * @return {?}
     */


    function timeZoneGetter(width) {
      return (
        /**
        * @param {?} date
        * @param {?} locale
        * @param {?} offset
        * @return {?}
        */
        function (date, locale, offset) {
          /** @type {?} */
          var zone = -1 * offset;
          /** @type {?} */

          var minusSign = getLocaleNumberSymbol(locale, NumberSymbol.MinusSign);
          /** @type {?} */

          var hours = zone > 0 ? Math.floor(zone / 60) : Math.ceil(zone / 60);

          switch (width) {
            case ZoneWidth.Short:
              return (zone >= 0 ? '+' : '') + padNumber(hours, 2, minusSign) + padNumber(Math.abs(zone % 60), 2, minusSign);

            case ZoneWidth.ShortGMT:
              return 'GMT' + (zone >= 0 ? '+' : '') + padNumber(hours, 1, minusSign);

            case ZoneWidth.Long:
              return 'GMT' + (zone >= 0 ? '+' : '') + padNumber(hours, 2, minusSign) + ':' + padNumber(Math.abs(zone % 60), 2, minusSign);

            case ZoneWidth.Extended:
              if (offset === 0) {
                return 'Z';
              } else {
                return (zone >= 0 ? '+' : '') + padNumber(hours, 2, minusSign) + ':' + padNumber(Math.abs(zone % 60), 2, minusSign);
              }

            default:
              throw new Error("Unknown zone width \"".concat(width, "\""));
          }
        }
      );
    }
    /** @type {?} */


    var JANUARY = 0;
    /** @type {?} */

    var THURSDAY = 4;
    /**
     * @param {?} year
     * @return {?}
     */

    function getFirstThursdayOfYear(year) {
      /** @type {?} */
      var firstDayOfYear = new Date(year, JANUARY, 1).getDay();
      return new Date(year, 0, 1 + (firstDayOfYear <= THURSDAY ? THURSDAY : THURSDAY + 7) - firstDayOfYear);
    }
    /**
     * @param {?} datetime
     * @return {?}
     */


    function getThursdayThisWeek(datetime) {
      return new Date(datetime.getFullYear(), datetime.getMonth(), datetime.getDate() + (THURSDAY - datetime.getDay()));
    }
    /**
     * @param {?} size
     * @param {?=} monthBased
     * @return {?}
     */


    function weekGetter(size) {
      var monthBased = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
      return (
        /**
        * @param {?} date
        * @param {?} locale
        * @return {?}
        */
        function (date, locale) {
          /** @type {?} */
          var result;

          if (monthBased) {
            /** @type {?} */
            var nbDaysBefore1stDayOfMonth = new Date(date.getFullYear(), date.getMonth(), 1).getDay() - 1;
            /** @type {?} */

            var today = date.getDate();
            result = 1 + Math.floor((today + nbDaysBefore1stDayOfMonth) / 7);
          } else {
            /** @type {?} */
            var firstThurs = getFirstThursdayOfYear(date.getFullYear());
            /** @type {?} */

            var thisThurs = getThursdayThisWeek(date);
            /** @type {?} */

            var diff = thisThurs.getTime() - firstThurs.getTime();
            result = 1 + Math.round(diff / 6.048e8); // 6.048e8 ms per week
          }

          return padNumber(result, size, getLocaleNumberSymbol(locale, NumberSymbol.MinusSign));
        }
      );
    }
    /** @type {?} */


    var DATE_FORMATS = {}; // Based on CLDR formats:
    // See complete list: http://www.unicode.org/reports/tr35/tr35-dates.html#Date_Field_Symbol_Table
    // See also explanations: http://cldr.unicode.org/translation/date-time
    // TODO(ocombe): support all missing cldr formats: Y, U, Q, D, F, e, c, j, J, C, A, v, V, X, x

    /**
     * @param {?} format
     * @return {?}
     */

    function getDateFormatter(format) {
      if (DATE_FORMATS[format]) {
        return DATE_FORMATS[format];
      }
      /** @type {?} */


      var formatter;

      switch (format) {
        // Era name (AD/BC)
        case 'G':
        case 'GG':
        case 'GGG':
          formatter = dateStrGetter(TranslationType.Eras, TranslationWidth.Abbreviated);
          break;

        case 'GGGG':
          formatter = dateStrGetter(TranslationType.Eras, TranslationWidth.Wide);
          break;

        case 'GGGGG':
          formatter = dateStrGetter(TranslationType.Eras, TranslationWidth.Narrow);
          break;
        // 1 digit representation of the year, e.g. (AD 1 => 1, AD 199 => 199)

        case 'y':
          formatter = dateGetter(DateType.FullYear, 1, 0, false, true);
          break;
        // 2 digit representation of the year, padded (00-99). (e.g. AD 2001 => 01, AD 2010 => 10)

        case 'yy':
          formatter = dateGetter(DateType.FullYear, 2, 0, true, true);
          break;
        // 3 digit representation of the year, padded (000-999). (e.g. AD 2001 => 01, AD 2010 => 10)

        case 'yyy':
          formatter = dateGetter(DateType.FullYear, 3, 0, false, true);
          break;
        // 4 digit representation of the year (e.g. AD 1 => 0001, AD 2010 => 2010)

        case 'yyyy':
          formatter = dateGetter(DateType.FullYear, 4, 0, false, true);
          break;
        // Month of the year (1-12), numeric

        case 'M':
        case 'L':
          formatter = dateGetter(DateType.Month, 1, 1);
          break;

        case 'MM':
        case 'LL':
          formatter = dateGetter(DateType.Month, 2, 1);
          break;
        // Month of the year (January, ...), string, format

        case 'MMM':
          formatter = dateStrGetter(TranslationType.Months, TranslationWidth.Abbreviated);
          break;

        case 'MMMM':
          formatter = dateStrGetter(TranslationType.Months, TranslationWidth.Wide);
          break;

        case 'MMMMM':
          formatter = dateStrGetter(TranslationType.Months, TranslationWidth.Narrow);
          break;
        // Month of the year (January, ...), string, standalone

        case 'LLL':
          formatter = dateStrGetter(TranslationType.Months, TranslationWidth.Abbreviated, FormStyle.Standalone);
          break;

        case 'LLLL':
          formatter = dateStrGetter(TranslationType.Months, TranslationWidth.Wide, FormStyle.Standalone);
          break;

        case 'LLLLL':
          formatter = dateStrGetter(TranslationType.Months, TranslationWidth.Narrow, FormStyle.Standalone);
          break;
        // Week of the year (1, ... 52)

        case 'w':
          formatter = weekGetter(1);
          break;

        case 'ww':
          formatter = weekGetter(2);
          break;
        // Week of the month (1, ...)

        case 'W':
          formatter = weekGetter(1, true);
          break;
        // Day of the month (1-31)

        case 'd':
          formatter = dateGetter(DateType.Date, 1);
          break;

        case 'dd':
          formatter = dateGetter(DateType.Date, 2);
          break;
        // Day of the Week

        case 'E':
        case 'EE':
        case 'EEE':
          formatter = dateStrGetter(TranslationType.Days, TranslationWidth.Abbreviated);
          break;

        case 'EEEE':
          formatter = dateStrGetter(TranslationType.Days, TranslationWidth.Wide);
          break;

        case 'EEEEE':
          formatter = dateStrGetter(TranslationType.Days, TranslationWidth.Narrow);
          break;

        case 'EEEEEE':
          formatter = dateStrGetter(TranslationType.Days, TranslationWidth.Short);
          break;
        // Generic period of the day (am-pm)

        case 'a':
        case 'aa':
        case 'aaa':
          formatter = dateStrGetter(TranslationType.DayPeriods, TranslationWidth.Abbreviated);
          break;

        case 'aaaa':
          formatter = dateStrGetter(TranslationType.DayPeriods, TranslationWidth.Wide);
          break;

        case 'aaaaa':
          formatter = dateStrGetter(TranslationType.DayPeriods, TranslationWidth.Narrow);
          break;
        // Extended period of the day (midnight, at night, ...), standalone

        case 'b':
        case 'bb':
        case 'bbb':
          formatter = dateStrGetter(TranslationType.DayPeriods, TranslationWidth.Abbreviated, FormStyle.Standalone, true);
          break;

        case 'bbbb':
          formatter = dateStrGetter(TranslationType.DayPeriods, TranslationWidth.Wide, FormStyle.Standalone, true);
          break;

        case 'bbbbb':
          formatter = dateStrGetter(TranslationType.DayPeriods, TranslationWidth.Narrow, FormStyle.Standalone, true);
          break;
        // Extended period of the day (midnight, night, ...), standalone

        case 'B':
        case 'BB':
        case 'BBB':
          formatter = dateStrGetter(TranslationType.DayPeriods, TranslationWidth.Abbreviated, FormStyle.Format, true);
          break;

        case 'BBBB':
          formatter = dateStrGetter(TranslationType.DayPeriods, TranslationWidth.Wide, FormStyle.Format, true);
          break;

        case 'BBBBB':
          formatter = dateStrGetter(TranslationType.DayPeriods, TranslationWidth.Narrow, FormStyle.Format, true);
          break;
        // Hour in AM/PM, (1-12)

        case 'h':
          formatter = dateGetter(DateType.Hours, 1, -12);
          break;

        case 'hh':
          formatter = dateGetter(DateType.Hours, 2, -12);
          break;
        // Hour of the day (0-23)

        case 'H':
          formatter = dateGetter(DateType.Hours, 1);
          break;
        // Hour in day, padded (00-23)

        case 'HH':
          formatter = dateGetter(DateType.Hours, 2);
          break;
        // Minute of the hour (0-59)

        case 'm':
          formatter = dateGetter(DateType.Minutes, 1);
          break;

        case 'mm':
          formatter = dateGetter(DateType.Minutes, 2);
          break;
        // Second of the minute (0-59)

        case 's':
          formatter = dateGetter(DateType.Seconds, 1);
          break;

        case 'ss':
          formatter = dateGetter(DateType.Seconds, 2);
          break;
        // Fractional second

        case 'S':
          formatter = dateGetter(DateType.FractionalSeconds, 1);
          break;

        case 'SS':
          formatter = dateGetter(DateType.FractionalSeconds, 2);
          break;

        case 'SSS':
          formatter = dateGetter(DateType.FractionalSeconds, 3);
          break;
        // Timezone ISO8601 short format (-0430)

        case 'Z':
        case 'ZZ':
        case 'ZZZ':
          formatter = timeZoneGetter(ZoneWidth.Short);
          break;
        // Timezone ISO8601 extended format (-04:30)

        case 'ZZZZZ':
          formatter = timeZoneGetter(ZoneWidth.Extended);
          break;
        // Timezone GMT short format (GMT+4)

        case 'O':
        case 'OO':
        case 'OOO': // Should be location, but fallback to format O instead because we don't have the data yet

        case 'z':
        case 'zz':
        case 'zzz':
          formatter = timeZoneGetter(ZoneWidth.ShortGMT);
          break;
        // Timezone GMT long format (GMT+0430)

        case 'OOOO':
        case 'ZZZZ': // Should be location, but fallback to format O instead because we don't have the data yet

        case 'zzzz':
          formatter = timeZoneGetter(ZoneWidth.Long);
          break;

        default:
          return null;
      }

      DATE_FORMATS[format] = formatter;
      return formatter;
    }
    /**
     * @param {?} timezone
     * @param {?} fallback
     * @return {?}
     */


    function timezoneToOffset(timezone, fallback) {
      // Support: IE 9-11 only, Edge 13-15+
      // IE/Edge do not "understand" colon (`:`) in timezone
      timezone = timezone.replace(/:/g, '');
      /** @type {?} */

      var requestedTimezoneOffset = Date.parse('Jan 01, 1970 00:00:00 ' + timezone) / 60000;
      return isNaN(requestedTimezoneOffset) ? fallback : requestedTimezoneOffset;
    }
    /**
     * @param {?} date
     * @param {?} minutes
     * @return {?}
     */


    function addDateMinutes(date, minutes) {
      date = new Date(date.getTime());
      date.setMinutes(date.getMinutes() + minutes);
      return date;
    }
    /**
     * @param {?} date
     * @param {?} timezone
     * @param {?} reverse
     * @return {?}
     */


    function convertTimezoneToLocal(date, timezone, reverse) {
      /** @type {?} */
      var reverseValue = reverse ? -1 : 1;
      /** @type {?} */

      var dateTimezoneOffset = date.getTimezoneOffset();
      /** @type {?} */

      var timezoneOffset = timezoneToOffset(timezone, dateTimezoneOffset);
      return addDateMinutes(date, reverseValue * (timezoneOffset - dateTimezoneOffset));
    }
    /**
     * Converts a value to date.
     *
     * Supported input formats:
     * - `Date`
     * - number: timestamp
     * - string: numeric (e.g. "1234"), ISO and date strings in a format supported by
     *   [Date.parse()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/parse).
     *   Note: ISO strings without time return a date without timeoffset.
     *
     * Throws if unable to convert to a date.
     * @param {?} value
     * @return {?}
     */


    function toDate(value) {
      if (isDate(value)) {
        return value;
      }

      if (typeof value === 'number' && !isNaN(value)) {
        return new Date(value);
      }

      if (typeof value === 'string') {
        value = value.trim();
        /** @type {?} */

        var parsedNb = parseFloat(value); // any string that only contains numbers, like "1234" but not like "1234hello"

        if (!isNaN(
        /** @type {?} */
        value - parsedNb)) {
          return new Date(parsedNb);
        }

        if (/^(\d{4}-\d{1,2}-\d{1,2})$/.test(value)) {
          /* For ISO Strings without time the day, month and year must be extracted from the ISO String
                before Date creation to avoid time offset and errors in the new Date.
                If we only replace '-' with ',' in the ISO String ("2015,01,01"), and try to create a new
                date, some browsers (e.g. IE 9) will throw an invalid Date error.
                If we leave the '-' ("2015-01-01") and try to create a new Date("2015-01-01") the timeoffset
                is applied.
                Note: ISO months are 0 for January, 1 for February, ... */
          var _value$split$map = value.split('-').map(
          /**
          * @param {?} val
          * @return {?}
          */
          function (val) {
            return +val;
          }),
              _value$split$map2 = _slicedToArray(_value$split$map, 3),
              y = _value$split$map2[0],
              m = _value$split$map2[1],
              d = _value$split$map2[2];

          return new Date(y, m - 1, d);
        }
        /** @type {?} */


        var match;

        if (match = value.match(ISO8601_DATE_REGEX)) {
          return isoStringToDate(match);
        }
      }
      /** @type {?} */


      var date = new Date(
      /** @type {?} */
      value);

      if (!isDate(date)) {
        throw new Error("Unable to convert \"".concat(value, "\" into a date"));
      }

      return date;
    }
    /**
     * Converts a date in ISO8601 to a Date.
     * Used instead of `Date.parse` because of browser discrepancies.
     * @param {?} match
     * @return {?}
     */


    function isoStringToDate(match) {
      /** @type {?} */
      var date = new Date(0);
      /** @type {?} */

      var tzHour = 0;
      /** @type {?} */

      var tzMin = 0; // match[8] means that the string contains "Z" (UTC) or a timezone like "+01:00" or "+0100"

      /** @type {?} */

      var dateSetter = match[8] ? date.setUTCFullYear : date.setFullYear;
      /** @type {?} */

      var timeSetter = match[8] ? date.setUTCHours : date.setHours; // if there is a timezone defined like "+01:00" or "+0100"

      if (match[9]) {
        tzHour = Number(match[9] + match[10]);
        tzMin = Number(match[9] + match[11]);
      }

      dateSetter.call(date, Number(match[1]), Number(match[2]) - 1, Number(match[3]));
      /** @type {?} */

      var h = Number(match[4] || 0) - tzHour;
      /** @type {?} */

      var m = Number(match[5] || 0) - tzMin;
      /** @type {?} */

      var s = Number(match[6] || 0);
      /** @type {?} */

      var ms = Math.round(parseFloat('0.' + (match[7] || 0)) * 1000);
      timeSetter.call(date, h, m, s, ms);
      return date;
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function isDate(value) {
      return value instanceof Date && !isNaN(value.valueOf());
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/i18n/format_number.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var NUMBER_FORMAT_REGEXP = /^(\d+)?\.((\d+)(-(\d+))?)?$/;
    /** @type {?} */

    var MAX_DIGITS = 22;
    /** @type {?} */

    var DECIMAL_SEP = '.';
    /** @type {?} */

    var ZERO_CHAR = '0';
    /** @type {?} */

    var PATTERN_SEP = ';';
    /** @type {?} */

    var GROUP_SEP = ',';
    /** @type {?} */

    var DIGIT_CHAR = '#';
    /** @type {?} */

    var CURRENCY_CHAR = '¤';
    /** @type {?} */

    var PERCENT_CHAR = '%';
    /**
     * Transforms a number to a locale string based on a style and a format.
     * @param {?} value
     * @param {?} pattern
     * @param {?} locale
     * @param {?} groupSymbol
     * @param {?} decimalSymbol
     * @param {?=} digitsInfo
     * @param {?=} isPercent
     * @return {?}
     */

    function formatNumberToLocaleString(value, pattern, locale, groupSymbol, decimalSymbol, digitsInfo) {
      var isPercent = arguments.length > 6 && arguments[6] !== undefined ? arguments[6] : false;

      /** @type {?} */
      var formattedText = '';
      /** @type {?} */

      var isZero = false;

      if (!isFinite(value)) {
        formattedText = getLocaleNumberSymbol(locale, NumberSymbol.Infinity);
      } else {
        /** @type {?} */
        var parsedNumber = parseNumber(value);

        if (isPercent) {
          parsedNumber = toPercent(parsedNumber);
        }
        /** @type {?} */


        var minInt = pattern.minInt;
        /** @type {?} */

        var minFraction = pattern.minFrac;
        /** @type {?} */

        var maxFraction = pattern.maxFrac;

        if (digitsInfo) {
          /** @type {?} */
          var parts = digitsInfo.match(NUMBER_FORMAT_REGEXP);

          if (parts === null) {
            throw new Error("".concat(digitsInfo, " is not a valid digit info"));
          }
          /** @type {?} */


          var minIntPart = parts[1];
          /** @type {?} */

          var minFractionPart = parts[3];
          /** @type {?} */

          var maxFractionPart = parts[5];

          if (minIntPart != null) {
            minInt = parseIntAutoRadix(minIntPart);
          }

          if (minFractionPart != null) {
            minFraction = parseIntAutoRadix(minFractionPart);
          }

          if (maxFractionPart != null) {
            maxFraction = parseIntAutoRadix(maxFractionPart);
          } else if (minFractionPart != null && minFraction > maxFraction) {
            maxFraction = minFraction;
          }
        }

        roundNumber(parsedNumber, minFraction, maxFraction);
        /** @type {?} */

        var digits = parsedNumber.digits;
        /** @type {?} */

        var integerLen = parsedNumber.integerLen;
        /** @type {?} */

        var exponent = parsedNumber.exponent;
        /** @type {?} */

        var decimals = [];
        isZero = digits.every(
        /**
        * @param {?} d
        * @return {?}
        */
        function (d) {
          return !d;
        }); // pad zeros for small numbers

        for (; integerLen < minInt; integerLen++) {
          digits.unshift(0);
        } // pad zeros for small numbers


        for (; integerLen < 0; integerLen++) {
          digits.unshift(0);
        } // extract decimals digits


        if (integerLen > 0) {
          decimals = digits.splice(integerLen, digits.length);
        } else {
          decimals = digits;
          digits = [0];
        } // format the integer digits with grouping separators

        /** @type {?} */


        var groups = [];

        if (digits.length >= pattern.lgSize) {
          groups.unshift(digits.splice(-pattern.lgSize, digits.length).join(''));
        }

        while (digits.length > pattern.gSize) {
          groups.unshift(digits.splice(-pattern.gSize, digits.length).join(''));
        }

        if (digits.length) {
          groups.unshift(digits.join(''));
        }

        formattedText = groups.join(getLocaleNumberSymbol(locale, groupSymbol)); // append the decimal digits

        if (decimals.length) {
          formattedText += getLocaleNumberSymbol(locale, decimalSymbol) + decimals.join('');
        }

        if (exponent) {
          formattedText += getLocaleNumberSymbol(locale, NumberSymbol.Exponential) + '+' + exponent;
        }
      }

      if (value < 0 && !isZero) {
        formattedText = pattern.negPre + formattedText + pattern.negSuf;
      } else {
        formattedText = pattern.posPre + formattedText + pattern.posSuf;
      }

      return formattedText;
    }
    /**
     * \@ngModule CommonModule
     * \@description
     *
     * Formats a number as currency using locale rules.
     *
     * @see `formatNumber()` / `DecimalPipe` / [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @param {?} value The number to format.
     * @param {?} locale A locale code for the locale format rules to use.
     * @param {?} currency A string containing the currency symbol or its name,
     * such as "$" or "Canadian Dollar". Used in output string, but does not affect the operation
     * of the function.
     * @param {?=} currencyCode The [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217)
     * currency code, such as `USD` for the US dollar and `EUR` for the euro.
     * Used to determine the number of digits in the decimal part.
     * @param {?=} digitsInfo
     * @return {?} The formatted currency value.
     *
     */


    function formatCurrency(value, locale, currency, currencyCode, digitsInfo) {
      /** @type {?} */
      var format = getLocaleNumberFormat(locale, NumberFormatStyle.Currency);
      /** @type {?} */

      var pattern = parseNumberFormat(format, getLocaleNumberSymbol(locale, NumberSymbol.MinusSign));
      pattern.minFrac = getNumberOfCurrencyDigits(
      /** @type {?} */
      currencyCode);
      pattern.maxFrac = pattern.minFrac;
      /** @type {?} */

      var res = formatNumberToLocaleString(value, pattern, locale, NumberSymbol.CurrencyGroup, NumberSymbol.CurrencyDecimal, digitsInfo);
      return res.replace(CURRENCY_CHAR, currency) // if we have 2 time the currency character, the second one is ignored
      .replace(CURRENCY_CHAR, '') // If there is a spacing between currency character and the value and
      // the currency character is supressed by passing an empty string, the
      // spacing character would remain as part of the string. Then we
      // should remove it.
      .trim();
    }
    /**
     * \@ngModule CommonModule
     * \@description
     *
     * Formats a number as a percentage according to locale rules.
     *
     * @see `formatNumber()` / `DecimalPipe` / [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     * \@publicApi
     *
     * @param {?} value The number to format.
     * @param {?} locale A locale code for the locale format rules to use.
     * @param {?=} digitsInfo
     * @return {?} The formatted percentage value.
     *
     */


    function formatPercent(value, locale, digitsInfo) {
      /** @type {?} */
      var format = getLocaleNumberFormat(locale, NumberFormatStyle.Percent);
      /** @type {?} */

      var pattern = parseNumberFormat(format, getLocaleNumberSymbol(locale, NumberSymbol.MinusSign));
      /** @type {?} */

      var res = formatNumberToLocaleString(value, pattern, locale, NumberSymbol.Group, NumberSymbol.Decimal, digitsInfo, true);
      return res.replace(new RegExp(PERCENT_CHAR, 'g'), getLocaleNumberSymbol(locale, NumberSymbol.PercentSign));
    }
    /**
     * \@ngModule CommonModule
     * \@description
     *
     * Formats a number as text, with group sizing, separator, and other
     * parameters based on the locale.
     *
     * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     *
     * \@publicApi
     * @param {?} value The number to format.
     * @param {?} locale A locale code for the locale format rules to use.
     * @param {?=} digitsInfo
     * @return {?} The formatted text string.
     */


    function formatNumber(value, locale, digitsInfo) {
      /** @type {?} */
      var format = getLocaleNumberFormat(locale, NumberFormatStyle.Decimal);
      /** @type {?} */

      var pattern = parseNumberFormat(format, getLocaleNumberSymbol(locale, NumberSymbol.MinusSign));
      return formatNumberToLocaleString(value, pattern, locale, NumberSymbol.Group, NumberSymbol.Decimal, digitsInfo);
    }
    /**
     * @record
     */


    function ParsedNumberFormat() {}

    if (false) {}
    /**
     * @param {?} format
     * @param {?=} minusSign
     * @return {?}
     */


    function parseNumberFormat(format) {
      var minusSign = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '-';

      /** @type {?} */
      var p = {
        minInt: 1,
        minFrac: 0,
        maxFrac: 0,
        posPre: '',
        posSuf: '',
        negPre: '',
        negSuf: '',
        gSize: 0,
        lgSize: 0
      };
      /** @type {?} */

      var patternParts = format.split(PATTERN_SEP);
      /** @type {?} */

      var positive = patternParts[0];
      /** @type {?} */

      var negative = patternParts[1];
      /** @type {?} */

      var positiveParts = positive.indexOf(DECIMAL_SEP) !== -1 ? positive.split(DECIMAL_SEP) : [positive.substring(0, positive.lastIndexOf(ZERO_CHAR) + 1), positive.substring(positive.lastIndexOf(ZERO_CHAR) + 1)];
      /** @type {?} */

      var integer = positiveParts[0];
      /** @type {?} */

      var fraction = positiveParts[1] || '';
      p.posPre = integer.substr(0, integer.indexOf(DIGIT_CHAR));

      for (var i = 0; i < fraction.length; i++) {
        /** @type {?} */
        var ch = fraction.charAt(i);

        if (ch === ZERO_CHAR) {
          p.minFrac = p.maxFrac = i + 1;
        } else if (ch === DIGIT_CHAR) {
          p.maxFrac = i + 1;
        } else {
          p.posSuf += ch;
        }
      }
      /** @type {?} */


      var groups = integer.split(GROUP_SEP);
      p.gSize = groups[1] ? groups[1].length : 0;
      p.lgSize = groups[2] || groups[1] ? (groups[2] || groups[1]).length : 0;

      if (negative) {
        /** @type {?} */
        var trunkLen = positive.length - p.posPre.length - p.posSuf.length;
        /** @type {?} */

        var pos = negative.indexOf(DIGIT_CHAR);
        p.negPre = negative.substr(0, pos).replace(/'/g, '');
        p.negSuf = negative.substr(pos + trunkLen).replace(/'/g, '');
      } else {
        p.negPre = minusSign + p.posPre;
        p.negSuf = p.posSuf;
      }

      return p;
    }
    /**
     * @record
     */


    function ParsedNumber() {}

    if (false) {} // Transforms a parsed number into a percentage by multiplying it by 100

    /**
     * @param {?} parsedNumber
     * @return {?}
     */


    function toPercent(parsedNumber) {
      // if the number is 0, don't do anything
      if (parsedNumber.digits[0] === 0) {
        return parsedNumber;
      } // Getting the current number of decimals

      /** @type {?} */


      var fractionLen = parsedNumber.digits.length - parsedNumber.integerLen;

      if (parsedNumber.exponent) {
        parsedNumber.exponent += 2;
      } else {
        if (fractionLen === 0) {
          parsedNumber.digits.push(0, 0);
        } else if (fractionLen === 1) {
          parsedNumber.digits.push(0);
        }

        parsedNumber.integerLen += 2;
      }

      return parsedNumber;
    }
    /**
     * Parses a number.
     * Significant bits of this parse algorithm came from https://github.com/MikeMcl/big.js/
     * @param {?} num
     * @return {?}
     */


    function parseNumber(num) {
      /** @type {?} */
      var numStr = Math.abs(num) + '';
      /** @type {?} */

      var exponent = 0;
      /** @type {?} */

      var digits;
      /** @type {?} */

      var integerLen;
      /** @type {?} */

      var i;
      /** @type {?} */

      var j;
      /** @type {?} */

      var zeros; // Decimal point?

      if ((integerLen = numStr.indexOf(DECIMAL_SEP)) > -1) {
        numStr = numStr.replace(DECIMAL_SEP, '');
      } // Exponential form?


      if ((i = numStr.search(/e/i)) > 0) {
        // Work out the exponent.
        if (integerLen < 0) integerLen = i;
        integerLen += +numStr.slice(i + 1);
        numStr = numStr.substring(0, i);
      } else if (integerLen < 0) {
        // There was no decimal point or exponent so it is an integer.
        integerLen = numStr.length;
      } // Count the number of leading zeros.


      for (i = 0; numStr.charAt(i) === ZERO_CHAR; i++) {
        /* empty */
      }

      if (i === (zeros = numStr.length)) {
        // The digits are all zero.
        digits = [0];
        integerLen = 1;
      } else {
        // Count the number of trailing zeros
        zeros--;

        while (numStr.charAt(zeros) === ZERO_CHAR) {
          zeros--;
        } // Trailing zeros are insignificant so ignore them


        integerLen -= i;
        digits = []; // Convert string to array of digits without leading/trailing zeros.

        for (j = 0; i <= zeros; i++, j++) {
          digits[j] = Number(numStr.charAt(i));
        }
      } // If the number overflows the maximum allowed digits then use an exponent.


      if (integerLen > MAX_DIGITS) {
        digits = digits.splice(0, MAX_DIGITS - 1);
        exponent = integerLen - 1;
        integerLen = 1;
      }

      return {
        digits: digits,
        exponent: exponent,
        integerLen: integerLen
      };
    }
    /**
     * Round the parsed number to the specified number of decimal places
     * This function changes the parsedNumber in-place
     * @param {?} parsedNumber
     * @param {?} minFrac
     * @param {?} maxFrac
     * @return {?}
     */


    function roundNumber(parsedNumber, minFrac, maxFrac) {
      if (minFrac > maxFrac) {
        throw new Error("The minimum number of digits after fraction (".concat(minFrac, ") is higher than the maximum (").concat(maxFrac, ")."));
      }
      /** @type {?} */


      var digits = parsedNumber.digits;
      /** @type {?} */

      var fractionLen = digits.length - parsedNumber.integerLen;
      /** @type {?} */

      var fractionSize = Math.min(Math.max(minFrac, fractionLen), maxFrac); // The index of the digit to where rounding is to occur

      /** @type {?} */

      var roundAt = fractionSize + parsedNumber.integerLen;
      /** @type {?} */

      var digit = digits[roundAt];

      if (roundAt > 0) {
        // Drop fractional digits beyond `roundAt`
        digits.splice(Math.max(parsedNumber.integerLen, roundAt)); // Set non-fractional digits beyond `roundAt` to 0

        for (var j = roundAt; j < digits.length; j++) {
          digits[j] = 0;
        }
      } else {
        // We rounded to zero so reset the parsedNumber
        fractionLen = Math.max(0, fractionLen);
        parsedNumber.integerLen = 1;
        digits.length = Math.max(1, roundAt = fractionSize + 1);
        digits[0] = 0;

        for (var i = 1; i < roundAt; i++) {
          digits[i] = 0;
        }
      }

      if (digit >= 5) {
        if (roundAt - 1 < 0) {
          for (var k = 0; k > roundAt; k--) {
            digits.unshift(0);
            parsedNumber.integerLen++;
          }

          digits.unshift(1);
          parsedNumber.integerLen++;
        } else {
          digits[roundAt - 1]++;
        }
      } // Pad out with zeros to get the required fraction length


      for (; fractionLen < Math.max(0, fractionSize); fractionLen++) {
        digits.push(0);
      }
      /** @type {?} */


      var dropTrailingZeros = fractionSize !== 0; // Minimal length = nb of decimals required + current nb of integers
      // Any number besides that is optional and can be removed if it's a trailing 0

      /** @type {?} */

      var minLen = minFrac + parsedNumber.integerLen; // Do any carrying, e.g. a digit was rounded up to 10

      /** @type {?} */

      var carry = digits.reduceRight(
      /**
      * @param {?} carry
      * @param {?} d
      * @param {?} i
      * @param {?} digits
      * @return {?}
      */
      function (carry, d, i, digits) {
        d = d + carry;
        digits[i] = d < 10 ? d : d - 10; // d % 10

        if (dropTrailingZeros) {
          // Do not keep meaningless fractional trailing zeros (e.g. 15.52000 --> 15.52)
          if (digits[i] === 0 && i >= minLen) {
            digits.pop();
          } else {
            dropTrailingZeros = false;
          }
        }

        return d >= 10 ? 1 : 0; // Math.floor(d / 10);
      }, 0);

      if (carry) {
        digits.unshift(carry);
        parsedNumber.integerLen++;
      }
    }
    /**
     * @param {?} text
     * @return {?}
     */


    function parseIntAutoRadix(text) {
      /** @type {?} */
      var result = parseInt(text);

      if (isNaN(result)) {
        throw new Error('Invalid integer literal when parsing ' + text);
      }

      return result;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/i18n/localization.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@publicApi
     * @abstract
     */


    var NgLocalization = function NgLocalization() {
      _classCallCheck(this, NgLocalization);
    };

    if (false) {}
    /**
     * Returns the plural category for a given value.
     * - "=value" when the case exists,
     * - the plural category otherwise
     * @param {?} value
     * @param {?} cases
     * @param {?} ngLocalization
     * @param {?=} locale
     * @return {?}
     */


    function getPluralCategory(value, cases, ngLocalization, locale) {
      /** @type {?} */
      var key = "=".concat(value);

      if (cases.indexOf(key) > -1) {
        return key;
      }

      key = ngLocalization.getPluralCategory(value, locale);

      if (cases.indexOf(key) > -1) {
        return key;
      }

      if (cases.indexOf('other') > -1) {
        return 'other';
      }

      throw new Error("No plural message found for value \"".concat(value, "\""));
    }
    /**
     * Returns the plural case based on the locale
     *
     * \@publicApi
     */


    var NgLocaleLocalization = /*#__PURE__*/function (_NgLocalization) {
      _inherits(NgLocaleLocalization, _NgLocalization);

      var _super23 = _createSuper(NgLocaleLocalization);

      /**
       * @param {?} locale
       */
      function NgLocaleLocalization(locale) {
        var _this127;

        _classCallCheck(this, NgLocaleLocalization);

        _this127 = _super23.call(this);
        _this127.locale = locale;
        return _this127;
      }
      /**
       * @param {?} value
       * @param {?=} locale
       * @return {?}
       */


      _createClass2(NgLocaleLocalization, [{
        key: "getPluralCategory",
        value: function getPluralCategory(value, locale) {
          /** @type {?} */
          var plural = getLocalePluralCase(locale || this.locale)(value);

          switch (plural) {
            case Plural.Zero:
              return 'zero';

            case Plural.One:
              return 'one';

            case Plural.Two:
              return 'two';

            case Plural.Few:
              return 'few';

            case Plural.Many:
              return 'many';

            default:
              return 'other';
          }
        }
      }]);

      return NgLocaleLocalization;
    }(NgLocalization);

    NgLocaleLocalization.ɵfac = function NgLocaleLocalization_Factory(t) {
      return new (t || NgLocaleLocalization)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"]));
    };

    NgLocaleLocalization.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({
      token: NgLocaleLocalization,
      factory: NgLocaleLocalization.ɵfac
    });
    /** @nocollapse */

    NgLocaleLocalization.ctorParameters = function () {
      return [{
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"]]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NgLocaleLocalization, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"]
      }], function () {
        return [{
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"]]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/i18n/locale_data.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Register global data to be used internally by Angular. See the
     * ["I18n guide"](guide/i18n#i18n-pipes) to know how to import additional locale data.
     *
     * The signature registerLocaleData(data: any, extraData?: any) is deprecated since v5.1
     *
     * \@publicApi
     * @param {?} data
     * @param {?=} localeId
     * @param {?=} extraData
     * @return {?}
     */


    function registerLocaleData(data, localeId, extraData) {
      return Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵregisterLocaleData"])(data, localeId, extraData);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/cookie.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * @param {?} cookieStr
     * @param {?} name
     * @return {?}
     */


    function parseCookieValue(cookieStr, name) {
      name = encodeURIComponent(name);

      var _iterator7 = _createForOfIteratorHelper(cookieStr.split(';')),
          _step7;

      try {
        for (_iterator7.s(); !(_step7 = _iterator7.n()).done;) {
          var cookie = _step7.value;

          /** @type {?} */
          var eqIndex = cookie.indexOf('=');

          var _ref4 = eqIndex == -1 ? [cookie, ''] : [cookie.slice(0, eqIndex), cookie.slice(eqIndex + 1)],
              _ref5 = _slicedToArray(_ref4, 2),
              cookieName = _ref5[0],
              cookieValue = _ref5[1];

          if (cookieName.trim() === name) {
            return decodeURIComponent(cookieValue);
          }
        }
      } catch (err) {
        _iterator7.e(err);
      } finally {
        _iterator7.f();
      }

      return null;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/directives/ng_class.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@ngModule CommonModule
     *
     * \@usageNotes
     * ```
     *     <some-element [ngClass]="'first second'">...</some-element>
     *
     *     <some-element [ngClass]="['first', 'second']">...</some-element>
     *
     *     <some-element [ngClass]="{'first': true, 'second': true, 'third': false}">...</some-element>
     *
     *     <some-element [ngClass]="stringExp|arrayExp|objExp">...</some-element>
     *
     *     <some-element [ngClass]="{'class1 class2 class3' : true}">...</some-element>
     * ```
     *
     * \@description
     *
     * Adds and removes CSS classes on an HTML element.
     *
     * The CSS classes are updated as follows, depending on the type of the expression evaluation:
     * - `string` - the CSS classes listed in the string (space delimited) are added,
     * - `Array` - the CSS classes declared as Array elements are added,
     * - `Object` - keys are CSS classes that get added when the expression given in the value
     *              evaluates to a truthy value, otherwise they are removed.
     *
     * \@publicApi
     */


    var NgClass = /*#__PURE__*/function () {
      /**
       * @param {?} _iterableDiffers
       * @param {?} _keyValueDiffers
       * @param {?} _ngEl
       * @param {?} _renderer
       */
      function NgClass(_iterableDiffers, _keyValueDiffers, _ngEl, _renderer) {
        _classCallCheck(this, NgClass);

        this._iterableDiffers = _iterableDiffers;
        this._keyValueDiffers = _keyValueDiffers;
        this._ngEl = _ngEl;
        this._renderer = _renderer;
        this._iterableDiffer = null;
        this._keyValueDiffer = null;
        this._initialClasses = [];
        this._rawClass = null;
      }
      /**
       * @param {?} value
       * @return {?}
       */


      _createClass2(NgClass, [{
        key: "ngDoCheck",

        /**
         * @return {?}
         */
        value: function ngDoCheck() {
          if (this._iterableDiffer) {
            /** @type {?} */
            var iterableChanges = this._iterableDiffer.diff(
            /** @type {?} */
            this._rawClass);

            if (iterableChanges) {
              this._applyIterableChanges(iterableChanges);
            }
          } else if (this._keyValueDiffer) {
            /** @type {?} */
            var keyValueChanges = this._keyValueDiffer.diff(
            /** @type {?} */
            this._rawClass);

            if (keyValueChanges) {
              this._applyKeyValueChanges(keyValueChanges);
            }
          }
        }
        /**
         * @private
         * @param {?} changes
         * @return {?}
         */

      }, {
        key: "_applyKeyValueChanges",
        value: function _applyKeyValueChanges(changes) {
          var _this128 = this;

          changes.forEachAddedItem(
          /**
          * @param {?} record
          * @return {?}
          */
          function (record) {
            return _this128._toggleClass(record.key, record.currentValue);
          });
          changes.forEachChangedItem(
          /**
          * @param {?} record
          * @return {?}
          */
          function (record) {
            return _this128._toggleClass(record.key, record.currentValue);
          });
          changes.forEachRemovedItem(
          /**
          * @param {?} record
          * @return {?}
          */
          function (record) {
            if (record.previousValue) {
              _this128._toggleClass(record.key, false);
            }
          });
        }
        /**
         * @private
         * @param {?} changes
         * @return {?}
         */

      }, {
        key: "_applyIterableChanges",
        value: function _applyIterableChanges(changes) {
          var _this129 = this;

          changes.forEachAddedItem(
          /**
          * @param {?} record
          * @return {?}
          */
          function (record) {
            if (typeof record.item === 'string') {
              _this129._toggleClass(record.item, true);
            } else {
              throw new Error("NgClass can only toggle CSS classes expressed as strings, got ".concat(Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵstringify"])(record.item)));
            }
          });
          changes.forEachRemovedItem(
          /**
          * @param {?} record
          * @return {?}
          */
          function (record) {
            return _this129._toggleClass(record.item, false);
          });
        }
        /**
         * Applies a collection of CSS classes to the DOM element.
         *
         * For argument of type Set and Array CSS class names contained in those collections are always
         * added.
         * For argument of type Map CSS class name in the map's key is toggled based on the value (added
         * for truthy and removed for falsy).
         * @private
         * @param {?} rawClassVal
         * @return {?}
         */

      }, {
        key: "_applyClasses",
        value: function _applyClasses(rawClassVal) {
          var _this130 = this;

          if (rawClassVal) {
            if (Array.isArray(rawClassVal) || rawClassVal instanceof Set) {
              /** @type {?} */
              rawClassVal.forEach(
              /**
              * @param {?} klass
              * @return {?}
              */
              function (klass) {
                return _this130._toggleClass(klass, true);
              });
            } else {
              Object.keys(rawClassVal).forEach(
              /**
              * @param {?} klass
              * @return {?}
              */
              function (klass) {
                return _this130._toggleClass(klass, !!rawClassVal[klass]);
              });
            }
          }
        }
        /**
         * Removes a collection of CSS classes from the DOM element. This is mostly useful for cleanup
         * purposes.
         * @private
         * @param {?} rawClassVal
         * @return {?}
         */

      }, {
        key: "_removeClasses",
        value: function _removeClasses(rawClassVal) {
          var _this131 = this;

          if (rawClassVal) {
            if (Array.isArray(rawClassVal) || rawClassVal instanceof Set) {
              /** @type {?} */
              rawClassVal.forEach(
              /**
              * @param {?} klass
              * @return {?}
              */
              function (klass) {
                return _this131._toggleClass(klass, false);
              });
            } else {
              Object.keys(rawClassVal).forEach(
              /**
              * @param {?} klass
              * @return {?}
              */
              function (klass) {
                return _this131._toggleClass(klass, false);
              });
            }
          }
        }
        /**
         * @private
         * @param {?} klass
         * @param {?} enabled
         * @return {?}
         */

      }, {
        key: "_toggleClass",
        value: function _toggleClass(klass, enabled) {
          var _this132 = this;

          klass = klass.trim();

          if (klass) {
            klass.split(/\s+/g).forEach(
            /**
            * @param {?} klass
            * @return {?}
            */
            function (klass) {
              if (enabled) {
                _this132._renderer.addClass(_this132._ngEl.nativeElement, klass);
              } else {
                _this132._renderer.removeClass(_this132._ngEl.nativeElement, klass);
              }
            });
          }
        }
      }, {
        key: "klass",
        set: function set(value) {
          this._removeClasses(this._initialClasses);

          this._initialClasses = typeof value === 'string' ? value.split(/\s+/) : [];

          this._applyClasses(this._initialClasses);

          this._applyClasses(this._rawClass);
        }
        /**
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "ngClass",
        set: function set(value) {
          this._removeClasses(this._rawClass);

          this._applyClasses(this._initialClasses);

          this._iterableDiffer = null;
          this._keyValueDiffer = null;
          this._rawClass = typeof value === 'string' ? value.split(/\s+/) : value;

          if (this._rawClass) {
            if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵisListLikeIterable"])(this._rawClass)) {
              this._iterableDiffer = this._iterableDiffers.find(this._rawClass).create();
            } else {
              this._keyValueDiffer = this._keyValueDiffers.find(this._rawClass).create();
            }
          }
        }
      }]);

      return NgClass;
    }();

    NgClass.ɵfac = function NgClass_Factory(t) {
      return new (t || NgClass)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["IterableDiffers"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["KeyValueDiffers"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]));
    };

    NgClass.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: NgClass,
      selectors: [["", "ngClass", ""]],
      inputs: {
        klass: ["class", "klass"],
        ngClass: "ngClass"
      }
    });
    /** @nocollapse */

    NgClass.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["IterableDiffers"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["KeyValueDiffers"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
      }];
    };

    NgClass.propDecorators = {
      klass: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['class']
      }],
      ngClass: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['ngClass']
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NgClass, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[ngClass]'
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["IterableDiffers"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["KeyValueDiffers"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
        }];
      }, {
        klass: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['class']
        }],
        ngClass: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['ngClass']
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/directives/ng_component_outlet.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Instantiates a single {\@link Component} type and inserts its Host View into current View.
     * `NgComponentOutlet` provides a declarative approach for dynamic component creation.
     *
     * `NgComponentOutlet` requires a component type, if a falsy value is set the view will clear and
     * any existing component will get destroyed.
     *
     * \@usageNotes
     *
     * ### Fine tune control
     *
     * You can control the component creation process by using the following optional attributes:
     *
     * * `ngComponentOutletInjector`: Optional custom {\@link Injector} that will be used as parent for
     * the Component. Defaults to the injector of the current view container.
     *
     * * `ngComponentOutletContent`: Optional list of projectable nodes to insert into the content
     * section of the component, if exists.
     *
     * * `ngComponentOutletNgModuleFactory`: Optional module factory to allow dynamically loading other
     * module, then load a component from that module.
     *
     * ### Syntax
     *
     * Simple
     * ```
     * <ng-container *ngComponentOutlet="componentTypeExpression"></ng-container>
     * ```
     *
     * Customized injector/content
     * ```
     * <ng-container *ngComponentOutlet="componentTypeExpression;
     *                                   injector: injectorExpression;
     *                                   content: contentNodesExpression;">
     * </ng-container>
     * ```
     *
     * Customized ngModuleFactory
     * ```
     * <ng-container *ngComponentOutlet="componentTypeExpression;
     *                                   ngModuleFactory: moduleFactory;">
     * </ng-container>
     * ```
     *
     * ### A simple example
     *
     * {\@example common/ngComponentOutlet/ts/module.ts region='SimpleExample'}
     *
     * A more complete example with additional options:
     *
     * {\@example common/ngComponentOutlet/ts/module.ts region='CompleteExample'}
     *
     * \@publicApi
     * \@ngModule CommonModule
     */


    var NgComponentOutlet = /*#__PURE__*/function () {
      /**
       * @param {?} _viewContainerRef
       */
      function NgComponentOutlet(_viewContainerRef) {
        _classCallCheck(this, NgComponentOutlet);

        this._viewContainerRef = _viewContainerRef;
        this._componentRef = null;
        this._moduleRef = null;
      }
      /**
       * @param {?} changes
       * @return {?}
       */


      _createClass2(NgComponentOutlet, [{
        key: "ngOnChanges",
        value: function ngOnChanges(changes) {
          this._viewContainerRef.clear();

          this._componentRef = null;

          if (this.ngComponentOutlet) {
            /** @type {?} */
            var elInjector = this.ngComponentOutletInjector || this._viewContainerRef.parentInjector;

            if (changes['ngComponentOutletNgModuleFactory']) {
              if (this._moduleRef) this._moduleRef.destroy();

              if (this.ngComponentOutletNgModuleFactory) {
                /** @type {?} */
                var parentModule = elInjector.get(_angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModuleRef"]);
                this._moduleRef = this.ngComponentOutletNgModuleFactory.create(parentModule.injector);
              } else {
                this._moduleRef = null;
              }
            }
            /** @type {?} */


            var componentFactoryResolver = this._moduleRef ? this._moduleRef.componentFactoryResolver : elInjector.get(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ComponentFactoryResolver"]);
            /** @type {?} */

            var componentFactory = componentFactoryResolver.resolveComponentFactory(this.ngComponentOutlet);
            this._componentRef = this._viewContainerRef.createComponent(componentFactory, this._viewContainerRef.length, elInjector, this.ngComponentOutletContent);
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          if (this._moduleRef) this._moduleRef.destroy();
        }
      }]);

      return NgComponentOutlet;
    }();

    NgComponentOutlet.ɵfac = function NgComponentOutlet_Factory(t) {
      return new (t || NgComponentOutlet)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]));
    };

    NgComponentOutlet.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: NgComponentOutlet,
      selectors: [["", "ngComponentOutlet", ""]],
      inputs: {
        ngComponentOutlet: "ngComponentOutlet",
        ngComponentOutletInjector: "ngComponentOutletInjector",
        ngComponentOutletContent: "ngComponentOutletContent",
        ngComponentOutletNgModuleFactory: "ngComponentOutletNgModuleFactory"
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵNgOnChangesFeature"]]
    });
    /** @nocollapse */

    NgComponentOutlet.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]
      }];
    };

    NgComponentOutlet.propDecorators = {
      ngComponentOutlet: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }],
      ngComponentOutletInjector: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }],
      ngComponentOutletContent: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }],
      ngComponentOutletNgModuleFactory: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NgComponentOutlet, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[ngComponentOutlet]'
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]
        }];
      }, {
        ngComponentOutlet: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }],
        ngComponentOutletInjector: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }],
        ngComponentOutletContent: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }],
        ngComponentOutletNgModuleFactory: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/directives/ng_for_of.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@publicApi
     * @template T, U
     */


    var NgForOfContext = /*#__PURE__*/function () {
      /**
       * @param {?} $implicit
       * @param {?} ngForOf
       * @param {?} index
       * @param {?} count
       */
      function NgForOfContext($implicit, ngForOf, index, count) {
        _classCallCheck(this, NgForOfContext);

        this.$implicit = $implicit;
        this.ngForOf = ngForOf;
        this.index = index;
        this.count = count;
      }
      /**
       * @return {?}
       */


      _createClass2(NgForOfContext, [{
        key: "first",
        get: function get() {
          return this.index === 0;
        }
        /**
         * @return {?}
         */

      }, {
        key: "last",
        get: function get() {
          return this.index === this.count - 1;
        }
        /**
         * @return {?}
         */

      }, {
        key: "even",
        get: function get() {
          return this.index % 2 === 0;
        }
        /**
         * @return {?}
         */

      }, {
        key: "odd",
        get: function get() {
          return !this.even;
        }
      }]);

      return NgForOfContext;
    }();

    if (false) {}
    /**
     * A [structural directive](guide/structural-directives) that renders
     * a template for each item in a collection.
     * The directive is placed on an element, which becomes the parent
     * of the cloned templates.
     *
     * The `ngForOf` directive is generally used in the
     * [shorthand form](guide/structural-directives#the-asterisk--prefix) `*ngFor`.
     * In this form, the template to be rendered for each iteration is the content
     * of an anchor element containing the directive.
     *
     * The following example shows the shorthand syntax with some options,
     * contained in an `<li>` element.
     *
     * ```
     * <li *ngFor="let item of items; index as i; trackBy: trackByFn">...</li>
     * ```
     *
     * The shorthand form expands into a long form that uses the `ngForOf` selector
     * on an `<ng-template>` element.
     * The content of the `<ng-template>` element is the `<li>` element that held the
     * short-form directive.
     *
     * Here is the expanded version of the short-form example.
     *
     * ```
     * <ng-template ngFor let-item [ngForOf]="items" let-i="index" [ngForTrackBy]="trackByFn">
     *   <li>...</li>
     * </ng-template>
     * ```
     *
     * Angular automatically expands the shorthand syntax as it compiles the template.
     * The context for each embedded view is logically merged to the current component
     * context according to its lexical position.
     *
     * When using the shorthand syntax, Angular allows only [one structural directive
     * on an element](guide/structural-directives#one-structural-directive-per-host-element).
     * If you want to iterate conditionally, for example,
     * put the `*ngIf` on a container element that wraps the `*ngFor` element.
     * For futher discussion, see
     * [Structural Directives](guide/structural-directives#one-per-element).
     *
     * \@usageNotes
     *
     * ### Local variables
     *
     * `NgForOf` provides exported values that can be aliased to local variables.
     * For example:
     *
     *  ```
     * <li *ngFor="let user of users; index as i; first as isFirst">
     *    {{i}}/{{users.length}}. {{user}} <span *ngIf="isFirst">default</span>
     * </li>
     * ```
     *
     * The following exported values can be aliased to local variables:
     *
     * - `$implicit: T`: The value of the individual items in the iterable (`ngForOf`).
     * - `ngForOf: NgIterable<T>`: The value of the iterable expression. Useful when the expression is
     * more complex then a property access, for example when using the async pipe (`userStreams |
     * async`).
     * - `index: number`: The index of the current item in the iterable.
     * - `count: number`: The length of the iterable.
     * - `first: boolean`: True when the item is the first item in the iterable.
     * - `last: boolean`: True when the item is the last item in the iterable.
     * - `even: boolean`: True when the item has an even index in the iterable.
     * - `odd: boolean`: True when the item has an odd index in the iterable.
     *
     * ### Change propagation
     *
     * When the contents of the iterator changes, `NgForOf` makes the corresponding changes to the DOM:
     *
     * * When an item is added, a new instance of the template is added to the DOM.
     * * When an item is removed, its template instance is removed from the DOM.
     * * When items are reordered, their respective templates are reordered in the DOM.
     *
     * Angular uses object identity to track insertions and deletions within the iterator and reproduce
     * those changes in the DOM. This has important implications for animations and any stateful
     * controls that are present, such as `<input>` elements that accept user input. Inserted rows can
     * be animated in, deleted rows can be animated out, and unchanged rows retain any unsaved state
     * such as user input.
     * For more on animations, see [Transitions and Triggers](guide/transition-and-triggers).
     *
     * The identities of elements in the iterator can change while the data does not.
     * This can happen, for example, if the iterator is produced from an RPC to the server, and that
     * RPC is re-run. Even if the data hasn't changed, the second response produces objects with
     * different identities, and Angular must tear down the entire DOM and rebuild it (as if all old
     * elements were deleted and all new elements inserted).
     *
     * To avoid this expensive operation, you can customize the default tracking algorithm.
     * by supplying the `trackBy` option to `NgForOf`.
     * `trackBy` takes a function that has two arguments: `index` and `item`.
     * If `trackBy` is given, Angular tracks changes by the return value of the function.
     *
     * @see [Structural Directives](guide/structural-directives)
     * \@ngModule CommonModule
     * \@publicApi
     * @template T, U
     */


    var NgForOf = /*#__PURE__*/function () {
      /**
       * @param {?} _viewContainer
       * @param {?} _template
       * @param {?} _differs
       */
      function NgForOf(_viewContainer, _template, _differs) {
        _classCallCheck(this, NgForOf);

        this._viewContainer = _viewContainer;
        this._template = _template;
        this._differs = _differs;
        this._ngForOf = null;
        this._ngForOfDirty = true;
        this._differ = null;
      }
      /**
       * The value of the iterable expression, which can be used as a
       * [template input variable](guide/structural-directives#template-input-variable).
       * @param {?} ngForOf
       * @return {?}
       */


      _createClass2(NgForOf, [{
        key: "ngDoCheck",

        /**
         * Applies the changes when needed.
         * @return {?}
         */
        value: function ngDoCheck() {
          if (this._ngForOfDirty) {
            this._ngForOfDirty = false; // React on ngForOf changes only once all inputs have been initialized

            /** @type {?} */

            var value = this._ngForOf;

            if (!this._differ && value) {
              try {
                this._differ = this._differs.find(value).create(this.ngForTrackBy);
              } catch (_a) {
                throw new Error("Cannot find a differ supporting object '".concat(value, "' of type '").concat(getTypeName(value), "'. NgFor only supports binding to Iterables such as Arrays."));
              }
            }
          }

          if (this._differ) {
            /** @type {?} */
            var changes = this._differ.diff(this._ngForOf);

            if (changes) this._applyChanges(changes);
          }
        }
        /**
         * @private
         * @param {?} changes
         * @return {?}
         */

      }, {
        key: "_applyChanges",
        value: function _applyChanges(changes) {
          var _this133 = this;

          /** @type {?} */
          var insertTuples = [];
          changes.forEachOperation(
          /**
          * @param {?} item
          * @param {?} adjustedPreviousIndex
          * @param {?} currentIndex
          * @return {?}
          */
          function (item, adjustedPreviousIndex, currentIndex) {
            if (item.previousIndex == null) {
              // NgForOf is never "null" or "undefined" here because the differ detected
              // that a new item needs to be inserted from the iterable. This implies that
              // there is an iterable value for "_ngForOf".

              /** @type {?} */
              var view = _this133._viewContainer.createEmbeddedView(_this133._template, new NgForOfContext(
              /** @type {?} */
              null,
              /** @type {?} */
              _this133._ngForOf, -1, -1), currentIndex === null ? undefined : currentIndex);
              /** @type {?} */


              var tuple = new RecordViewTuple(item, view);
              insertTuples.push(tuple);
            } else if (currentIndex == null) {
              _this133._viewContainer.remove(adjustedPreviousIndex === null ? undefined : adjustedPreviousIndex);
            } else if (adjustedPreviousIndex !== null) {
              /** @type {?} */
              var _view3 =
              /** @type {?} */
              _this133._viewContainer.get(adjustedPreviousIndex);

              _this133._viewContainer.move(_view3, currentIndex);
              /** @type {?} */


              var _tuple = new RecordViewTuple(item,
              /** @type {?} */
              _view3);

              insertTuples.push(_tuple);
            }
          });

          for (var i = 0; i < insertTuples.length; i++) {
            this._perViewChange(insertTuples[i].view, insertTuples[i].record);
          }

          for (var _i9 = 0, ilen = this._viewContainer.length; _i9 < ilen; _i9++) {
            /** @type {?} */
            var viewRef =
            /** @type {?} */
            this._viewContainer.get(_i9);

            viewRef.context.index = _i9;
            viewRef.context.count = ilen;
            viewRef.context.ngForOf =
            /** @type {?} */
            this._ngForOf;
          }

          changes.forEachIdentityChange(
          /**
          * @param {?} record
          * @return {?}
          */
          function (record) {
            /** @type {?} */
            var viewRef =
            /** @type {?} */
            _this133._viewContainer.get(record.currentIndex);

            viewRef.context.$implicit = record.item;
          });
        }
        /**
         * @private
         * @param {?} view
         * @param {?} record
         * @return {?}
         */

      }, {
        key: "_perViewChange",
        value: function _perViewChange(view, record) {
          view.context.$implicit = record.item;
        }
        /**
         * Asserts the correct type of the context for the template that `NgForOf` will render.
         *
         * The presence of this method is a signal to the Ivy template type-check compiler that the
         * `NgForOf` structural directive renders its template with a specific context type.
         * @template T, U
         * @param {?} dir
         * @param {?} ctx
         * @return {?}
         */

      }, {
        key: "ngForOf",
        set: function set(ngForOf) {
          this._ngForOf = ngForOf;
          this._ngForOfDirty = true;
        }
        /**
         * A function that defines how to track changes for items in the iterable.
         *
         * When items are added, moved, or removed in the iterable,
         * the directive must re-render the appropriate DOM nodes.
         * To minimize churn in the DOM, only nodes that have changed
         * are re-rendered.
         *
         * By default, the change detector assumes that
         * the object instance identifies the node in the iterable.
         * When this function is supplied, the directive uses
         * the result of calling this function to identify the item node,
         * rather than the identity of the object itself.
         *
         * The function receives two inputs,
         * the iteration index and the node object ID.
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "ngForTrackBy",
        set: function set(fn) {
          if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["isDevMode"])() && fn != null && typeof fn !== 'function') {
            // TODO(vicb): use a log service once there is a public one available
            if (
            /** @type {?} */
            console &&
            /** @type {?} */
            console.warn) {
              console.warn("trackBy must be a function, but received ".concat(JSON.stringify(fn), ". ") + "See https://angular.io/api/common/NgForOf#change-propagation for more information.");
            }
          }

          this._trackByFn = fn;
        }
        /**
         * @return {?}
         */
        ,
        get: function get() {
          return this._trackByFn;
        }
        /**
         * A reference to the template that is stamped out for each item in the iterable.
         * @see [template reference variable](guide/template-syntax#template-reference-variables--var-)
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "ngForTemplate",
        set: function set(value) {
          // TODO(TS2.1): make TemplateRef<Partial<NgForRowOf<T>>> once we move to TS v2.1
          // The current type is too restrictive; a template that just uses index, for example,
          // should be acceptable.
          if (value) {
            this._template = value;
          }
        }
      }], [{
        key: "ngTemplateContextGuard",
        value: function ngTemplateContextGuard(dir, ctx) {
          return true;
        }
      }]);

      return NgForOf;
    }();

    NgForOf.ɵfac = function NgForOf_Factory(t) {
      return new (t || NgForOf)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["IterableDiffers"]));
    };

    NgForOf.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: NgForOf,
      selectors: [["", "ngFor", "", "ngForOf", ""]],
      inputs: {
        ngForOf: "ngForOf",
        ngForTrackBy: "ngForTrackBy",
        ngForTemplate: "ngForTemplate"
      }
    });
    /** @nocollapse */

    NgForOf.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["IterableDiffers"]
      }];
    };

    NgForOf.propDecorators = {
      ngForOf: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }],
      ngForTrackBy: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }],
      ngForTemplate: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NgForOf, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[ngFor][ngForOf]'
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["IterableDiffers"]
        }];
      }, {
        ngForOf: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }],
        ngForTrackBy: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }],
        ngForTemplate: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * @template T, U
     */


    var RecordViewTuple =
    /**
     * @param {?} record
     * @param {?} view
     */
    function RecordViewTuple(record, view) {
      _classCallCheck(this, RecordViewTuple);

      this.record = record;
      this.view = view;
    };

    if (false) {}
    /**
     * @param {?} type
     * @return {?}
     */


    function getTypeName(type) {
      return type['name'] || typeof type;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/directives/ng_if.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * A structural directive that conditionally includes a template based on the value of
     * an expression coerced to Boolean.
     * When the expression evaluates to true, Angular renders the template
     * provided in a `then` clause, and when  false or null,
     * Angular renders the template provided in an optional `else` clause. The default
     * template for the `else` clause is blank.
     *
     * A [shorthand form](guide/structural-directives#the-asterisk--prefix) of the directive,
     * `*ngIf="condition"`, is generally used, provided
     * as an attribute of the anchor element for the inserted template.
     * Angular expands this into a more explicit version, in which the anchor element
     * is contained in an `<ng-template>` element.
     *
     * Simple form with shorthand syntax:
     *
     * ```
     * <div *ngIf="condition">Content to render when condition is true.</div>
     * ```
     *
     * Simple form with expanded syntax:
     *
     * ```
     * <ng-template [ngIf]="condition"><div>Content to render when condition is
     * true.</div></ng-template>
     * ```
     *
     * Form with an "else" block:
     *
     * ```
     * <div *ngIf="condition; else elseBlock">Content to render when condition is true.</div>
     * <ng-template #elseBlock>Content to render when condition is false.</ng-template>
     * ```
     *
     * Shorthand form with "then" and "else" blocks:
     *
     * ```
     * <div *ngIf="condition; then thenBlock else elseBlock"></div>
     * <ng-template #thenBlock>Content to render when condition is true.</ng-template>
     * <ng-template #elseBlock>Content to render when condition is false.</ng-template>
     * ```
     *
     * Form with storing the value locally:
     *
     * ```
     * <div *ngIf="condition as value; else elseBlock">{{value}}</div>
     * <ng-template #elseBlock>Content to render when value is null.</ng-template>
     * ```
     *
     * \@usageNotes
     *
     * The `*ngIf` directive is most commonly used to conditionally show an inline template,
     * as seen in the following  example.
     * The default `else` template is blank.
     *
     * {\@example common/ngIf/ts/module.ts region='NgIfSimple'}
     *
     * ### Showing an alternative template using `else`
     *
     * To display a template when `expression` evaluates to false, use an `else` template
     * binding as shown in the following example.
     * The `else` binding points to an `<ng-template>`  element labeled `#elseBlock`.
     * The template can be defined anywhere in the component view, but is typically placed right after
     * `ngIf` for readability.
     *
     * {\@example common/ngIf/ts/module.ts region='NgIfElse'}
     *
     * ### Using an external `then` template
     *
     * In the previous example, the then-clause template is specified inline, as the content of the
     * tag that contains the `ngIf` directive. You can also specify a template that is defined
     * externally, by referencing a labeled `<ng-template>` element. When you do this, you can
     * change which template to use at runtime, as shown in the following example.
     *
     * {\@example common/ngIf/ts/module.ts region='NgIfThenElse'}
     *
     * ### Storing a conditional result in a variable
     *
     * You might want to show a set of properties from the same object. If you are waiting
     * for asynchronous data, the object can be undefined.
     * In this case, you can use `ngIf` and store the result of the condition in a local
     * variable as shown in the the following example.
     *
     * {\@example common/ngIf/ts/module.ts region='NgIfAs'}
     *
     * This code uses only one `AsyncPipe`, so only one subscription is created.
     * The conditional statement stores the result of `userStream|async` in the local variable `user`.
     * You can then bind the local `user` repeatedly.
     *
     * The conditional displays the data only if `userStream` returns a value,
     * so you don't need to use the
     * [safe-navigation-operator](guide/template-syntax#safe-navigation-operator) (`?.`)
     * to guard against null values when accessing properties.
     * You can display an alternative template while waiting for the data.
     *
     * ### Shorthand syntax
     *
     * The shorthand syntax `*ngIf` expands into two separate template specifications
     * for the "then" and "else" clauses. For example, consider the following shorthand statement,
     * that is meant to show a loading page while waiting for data to be loaded.
     *
     * ```
     * <div class="hero-list" *ngIf="heroes else loading">
     *  ...
     * </div>
     *
     * <ng-template #loading>
     *  <div>Loading...</div>
     * </ng-template>
     * ```
     *
     * You can see that the "else" clause references the `<ng-template>`
     * with the `#loading` label, and the template for the "then" clause
     * is provided as the content of the anchor element.
     *
     * However, when Angular expands the shorthand syntax, it creates
     * another `<ng-template>` tag, with `ngIf` and `ngIfElse` directives.
     * The anchor element containing the template for the "then" clause becomes
     * the content of this unlabeled `<ng-template>` tag.
     *
     * ```
     * <ng-template [ngIf]="heroes" [ngIfElse]="loading">
     *  <div class="hero-list">
     *   ...
     *  </div>
     * </ng-template>
     *
     * <ng-template #loading>
     *  <div>Loading...</div>
     * </ng-template>
     * ```
     *
     * The presence of the implicit template object has implications for the nesting of
     * structural directives. For more on this subject, see
     * [Structural Directives](https://angular.io/guide/structural-directives#one-per-element).
     *
     * \@ngModule CommonModule
     * \@publicApi
     * @template T
     */


    var NgIf = /*#__PURE__*/function () {
      /**
       * @param {?} _viewContainer
       * @param {?} templateRef
       */
      function NgIf(_viewContainer, templateRef) {
        _classCallCheck(this, NgIf);

        this._viewContainer = _viewContainer;
        this._context = new NgIfContext();
        this._thenTemplateRef = null;
        this._elseTemplateRef = null;
        this._thenViewRef = null;
        this._elseViewRef = null;
        this._thenTemplateRef = templateRef;
      }
      /**
       * The Boolean expression to evaluate as the condition for showing a template.
       * @param {?} condition
       * @return {?}
       */


      _createClass2(NgIf, [{
        key: "_updateView",

        /**
         * @private
         * @return {?}
         */
        value: function _updateView() {
          if (this._context.$implicit) {
            if (!this._thenViewRef) {
              this._viewContainer.clear();

              this._elseViewRef = null;

              if (this._thenTemplateRef) {
                this._thenViewRef = this._viewContainer.createEmbeddedView(this._thenTemplateRef, this._context);
              }
            }
          } else {
            if (!this._elseViewRef) {
              this._viewContainer.clear();

              this._thenViewRef = null;

              if (this._elseTemplateRef) {
                this._elseViewRef = this._viewContainer.createEmbeddedView(this._elseTemplateRef, this._context);
              }
            }
          }
        }
        /**
         * Asserts the correct type of the context for the template that `NgIf` will render.
         *
         * The presence of this method is a signal to the Ivy template type-check compiler that the
         * `NgIf` structural directive renders its template with a specific context type.
         * @template T
         * @param {?} dir
         * @param {?} ctx
         * @return {?}
         */

      }, {
        key: "ngIf",
        set: function set(condition) {
          this._context.$implicit = this._context.ngIf = condition;

          this._updateView();
        }
        /**
         * A template to show if the condition expression evaluates to true.
         * @param {?} templateRef
         * @return {?}
         */

      }, {
        key: "ngIfThen",
        set: function set(templateRef) {
          assertTemplate('ngIfThen', templateRef);
          this._thenTemplateRef = templateRef;
          this._thenViewRef = null; // clear previous view if any.

          this._updateView();
        }
        /**
         * A template to show if the condition expression evaluates to false.
         * @param {?} templateRef
         * @return {?}
         */

      }, {
        key: "ngIfElse",
        set: function set(templateRef) {
          assertTemplate('ngIfElse', templateRef);
          this._elseTemplateRef = templateRef;
          this._elseViewRef = null; // clear previous view if any.

          this._updateView();
        }
      }], [{
        key: "ngTemplateContextGuard",
        value: function ngTemplateContextGuard(dir, ctx) {
          return true;
        }
      }]);

      return NgIf;
    }();

    NgIf.ɵfac = function NgIf_Factory(t) {
      return new (t || NgIf)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]));
    };

    NgIf.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: NgIf,
      selectors: [["", "ngIf", ""]],
      inputs: {
        ngIf: "ngIf",
        ngIfThen: "ngIfThen",
        ngIfElse: "ngIfElse"
      }
    });
    /** @nocollapse */

    NgIf.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]
      }];
    };

    NgIf.propDecorators = {
      ngIf: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }],
      ngIfThen: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }],
      ngIfElse: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NgIf, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[ngIf]'
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]
        }];
      }, {
        ngIf: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }],
        ngIfThen: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }],
        ngIfElse: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * \@publicApi
     * @template T
     */


    var NgIfContext = function NgIfContext() {
      _classCallCheck(this, NgIfContext);

      this.$implicit =
      /** @type {?} */
      null;
      this.ngIf =
      /** @type {?} */
      null;
    };

    if (false) {}
    /**
     * @param {?} property
     * @param {?} templateRef
     * @return {?}
     */


    function assertTemplate(property, templateRef) {
      /** @type {?} */
      var isTemplateRefOrNull = !!(!templateRef || templateRef.createEmbeddedView);

      if (!isTemplateRefOrNull) {
        throw new Error("".concat(property, " must be a TemplateRef, but received '").concat(Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵstringify"])(templateRef), "'."));
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/directives/ng_switch.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var SwitchView = /*#__PURE__*/function () {
      /**
       * @param {?} _viewContainerRef
       * @param {?} _templateRef
       */
      function SwitchView(_viewContainerRef, _templateRef) {
        _classCallCheck(this, SwitchView);

        this._viewContainerRef = _viewContainerRef;
        this._templateRef = _templateRef;
        this._created = false;
      }
      /**
       * @return {?}
       */


      _createClass2(SwitchView, [{
        key: "create",
        value: function create() {
          this._created = true;

          this._viewContainerRef.createEmbeddedView(this._templateRef);
        }
        /**
         * @return {?}
         */

      }, {
        key: "destroy",
        value: function destroy() {
          this._created = false;

          this._viewContainerRef.clear();
        }
        /**
         * @param {?} created
         * @return {?}
         */

      }, {
        key: "enforceState",
        value: function enforceState(created) {
          if (created && !this._created) {
            this.create();
          } else if (!created && this._created) {
            this.destroy();
          }
        }
      }]);

      return SwitchView;
    }();

    if (false) {}
    /**
     * \@ngModule CommonModule
     *
     * \@description
     * The `[ngSwitch]` directive on a container specifies an expression to match against.
     * The expressions to match are provided by `ngSwitchCase` directives on views within the container.
     * - Every view that matches is rendered.
     * - If there are no matches, a view with the `ngSwitchDefault` directive is rendered.
     * - Elements within the `[NgSwitch]` statement but outside of any `NgSwitchCase`
     * or `ngSwitchDefault` directive are preserved at the location.
     *
     * \@usageNotes
     * Define a container element for the directive, and specify the switch expression
     * to match against as an attribute:
     *
     * ```
     * <container-element [ngSwitch]="switch_expression">
     * ```
     *
     * Within the container, `*ngSwitchCase` statements specify the match expressions
     * as attributes. Include `*ngSwitchDefault` as the final case.
     *
     * ```
     * <container-element [ngSwitch]="switch_expression">
     *    <some-element *ngSwitchCase="match_expression_1">...</some-element>
     * ...
     *    <some-element *ngSwitchDefault>...</some-element>
     * </container-element>
     * ```
     *
     * ### Usage Examples
     *
     * The following example shows how to use more than one case to display the same view:
     *
     * ```
     * <container-element [ngSwitch]="switch_expression">
     *   <!-- the same view can be shown in more than one case -->
     *   <some-element *ngSwitchCase="match_expression_1">...</some-element>
     *   <some-element *ngSwitchCase="match_expression_2">...</some-element>
     *   <some-other-element *ngSwitchCase="match_expression_3">...</some-other-element>
     *   <!--default case when there are no matches -->
     *   <some-element *ngSwitchDefault>...</some-element>
     * </container-element>
     * ```
     *
     * The following example shows how cases can be nested:
     * ```
     * <container-element [ngSwitch]="switch_expression">
     *       <some-element *ngSwitchCase="match_expression_1">...</some-element>
     *       <some-element *ngSwitchCase="match_expression_2">...</some-element>
     *       <some-other-element *ngSwitchCase="match_expression_3">...</some-other-element>
     *       <ng-container *ngSwitchCase="match_expression_3">
     *         <!-- use a ng-container to group multiple root nodes -->
     *         <inner-element></inner-element>
     *         <inner-other-element></inner-other-element>
     *       </ng-container>
     *       <some-element *ngSwitchDefault>...</some-element>
     *     </container-element>
     * ```
     *
     * \@publicApi
     * @see `NgSwitchCase`
     * @see `NgSwitchDefault`
     * @see [Structural Directives](guide/structural-directives)
     *
     */


    var NgSwitch = /*#__PURE__*/function () {
      function NgSwitch() {
        _classCallCheck(this, NgSwitch);

        this._defaultUsed = false;
        this._caseCount = 0;
        this._lastCaseCheckIndex = 0;
        this._lastCasesMatched = false;
      }
      /**
       * @param {?} newValue
       * @return {?}
       */


      _createClass2(NgSwitch, [{
        key: "_addCase",

        /**
         * \@internal
         * @return {?}
         */
        value: function _addCase() {
          return this._caseCount++;
        }
        /**
         * \@internal
         * @param {?} view
         * @return {?}
         */

      }, {
        key: "_addDefault",
        value: function _addDefault(view) {
          if (!this._defaultViews) {
            this._defaultViews = [];
          }

          this._defaultViews.push(view);
        }
        /**
         * \@internal
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "_matchCase",
        value: function _matchCase(value) {
          /** @type {?} */
          var matched = value == this._ngSwitch;
          this._lastCasesMatched = this._lastCasesMatched || matched;
          this._lastCaseCheckIndex++;

          if (this._lastCaseCheckIndex === this._caseCount) {
            this._updateDefaultCases(!this._lastCasesMatched);

            this._lastCaseCheckIndex = 0;
            this._lastCasesMatched = false;
          }

          return matched;
        }
        /**
         * @private
         * @param {?} useDefault
         * @return {?}
         */

      }, {
        key: "_updateDefaultCases",
        value: function _updateDefaultCases(useDefault) {
          if (this._defaultViews && useDefault !== this._defaultUsed) {
            this._defaultUsed = useDefault;

            for (var i = 0; i < this._defaultViews.length; i++) {
              /** @type {?} */
              var defaultView = this._defaultViews[i];
              defaultView.enforceState(useDefault);
            }
          }
        }
      }, {
        key: "ngSwitch",
        set: function set(newValue) {
          this._ngSwitch = newValue;

          if (this._caseCount === 0) {
            this._updateDefaultCases(true);
          }
        }
      }]);

      return NgSwitch;
    }();

    NgSwitch.ɵfac = function NgSwitch_Factory(t) {
      return new (t || NgSwitch)();
    };

    NgSwitch.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: NgSwitch,
      selectors: [["", "ngSwitch", ""]],
      inputs: {
        ngSwitch: "ngSwitch"
      }
    });
    NgSwitch.propDecorators = {
      ngSwitch: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NgSwitch, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[ngSwitch]'
        }]
      }], function () {
        return [];
      }, {
        ngSwitch: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * \@ngModule CommonModule
     *
     * \@description
     * Provides a switch case expression to match against an enclosing `ngSwitch` expression.
     * When the expressions match, the given `NgSwitchCase` template is rendered.
     * If multiple match expressions match the switch expression value, all of them are displayed.
     *
     * \@usageNotes
     *
     * Within a switch container, `*ngSwitchCase` statements specify the match expressions
     * as attributes. Include `*ngSwitchDefault` as the final case.
     *
     * ```
     * <container-element [ngSwitch]="switch_expression">
     *   <some-element *ngSwitchCase="match_expression_1">...</some-element>
     *   ...
     *   <some-element *ngSwitchDefault>...</some-element>
     * </container-element>
     * ```
     *
     * Each switch-case statement contains an in-line HTML template or template reference
     * that defines the subtree to be selected if the value of the match expression
     * matches the value of the switch expression.
     *
     * Unlike JavaScript, which uses strict equality, Angular uses loose equality.
     * This means that the empty string, `""` matches 0.
     *
     * \@publicApi
     * @see `NgSwitch`
     * @see `NgSwitchDefault`
     *
     */


    var NgSwitchCase = /*#__PURE__*/function () {
      /**
       * @param {?} viewContainer
       * @param {?} templateRef
       * @param {?} ngSwitch
       */
      function NgSwitchCase(viewContainer, templateRef, ngSwitch) {
        _classCallCheck(this, NgSwitchCase);

        this.ngSwitch = ngSwitch;

        ngSwitch._addCase();

        this._view = new SwitchView(viewContainer, templateRef);
      }
      /**
       * Performs case matching. For internal use only.
       * @return {?}
       */


      _createClass2(NgSwitchCase, [{
        key: "ngDoCheck",
        value: function ngDoCheck() {
          this._view.enforceState(this.ngSwitch._matchCase(this.ngSwitchCase));
        }
      }]);

      return NgSwitchCase;
    }();

    NgSwitchCase.ɵfac = function NgSwitchCase_Factory(t) {
      return new (t || NgSwitchCase)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NgSwitch, 1));
    };

    NgSwitchCase.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: NgSwitchCase,
      selectors: [["", "ngSwitchCase", ""]],
      inputs: {
        ngSwitchCase: "ngSwitchCase"
      }
    });
    /** @nocollapse */

    NgSwitchCase.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]
      }, {
        type: NgSwitch,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"]
        }]
      }];
    };

    NgSwitchCase.propDecorators = {
      ngSwitchCase: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NgSwitchCase, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[ngSwitchCase]'
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]
        }, {
          type: NgSwitch,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"]
          }]
        }];
      }, {
        ngSwitchCase: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * \@ngModule CommonModule
     *
     * \@description
     *
     * Creates a view that is rendered when no `NgSwitchCase` expressions
     * match the `NgSwitch` expression.
     * This statement should be the final case in an `NgSwitch`.
     *
     * \@publicApi
     * @see `NgSwitch`
     * @see `NgSwitchCase`
     *
     */


    var NgSwitchDefault =
    /**
     * @param {?} viewContainer
     * @param {?} templateRef
     * @param {?} ngSwitch
     */
    function NgSwitchDefault(viewContainer, templateRef, ngSwitch) {
      _classCallCheck(this, NgSwitchDefault);

      ngSwitch._addDefault(new SwitchView(viewContainer, templateRef));
    };

    NgSwitchDefault.ɵfac = function NgSwitchDefault_Factory(t) {
      return new (t || NgSwitchDefault)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NgSwitch, 1));
    };

    NgSwitchDefault.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: NgSwitchDefault,
      selectors: [["", "ngSwitchDefault", ""]]
    });
    /** @nocollapse */

    NgSwitchDefault.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]
      }, {
        type: NgSwitch,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NgSwitchDefault, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[ngSwitchDefault]'
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]
        }, {
          type: NgSwitch,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"]
          }]
        }];
      }, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/directives/ng_plural.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@ngModule CommonModule
     *
     * \@usageNotes
     * ```
     * <some-element [ngPlural]="value">
     *   <ng-template ngPluralCase="=0">there is nothing</ng-template>
     *   <ng-template ngPluralCase="=1">there is one</ng-template>
     *   <ng-template ngPluralCase="few">there are a few</ng-template>
     * </some-element>
     * ```
     *
     * \@description
     *
     * Adds / removes DOM sub-trees based on a numeric value. Tailored for pluralization.
     *
     * Displays DOM sub-trees that match the switch expression value, or failing that, DOM sub-trees
     * that match the switch expression's pluralization category.
     *
     * To use this directive you must provide a container element that sets the `[ngPlural]` attribute
     * to a switch expression. Inner elements with a `[ngPluralCase]` will display based on their
     * expression:
     * - if `[ngPluralCase]` is set to a value starting with `=`, it will only display if the value
     *   matches the switch expression exactly,
     * - otherwise, the view will be treated as a "category match", and will only display if exact
     *   value matches aren't found and the value maps to its category for the defined locale.
     *
     * See http://cldr.unicode.org/index/cldr-spec/plural-rules
     *
     * \@publicApi
     */


    var NgPlural = /*#__PURE__*/function () {
      /**
       * @param {?} _localization
       */
      function NgPlural(_localization) {
        _classCallCheck(this, NgPlural);

        this._localization = _localization;
        this._caseViews = {};
      }
      /**
       * @param {?} value
       * @return {?}
       */


      _createClass2(NgPlural, [{
        key: "addCase",

        /**
         * @param {?} value
         * @param {?} switchView
         * @return {?}
         */
        value: function addCase(value, switchView) {
          this._caseViews[value] = switchView;
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_updateView",
        value: function _updateView() {
          this._clearViews();
          /** @type {?} */


          var cases = Object.keys(this._caseViews);
          /** @type {?} */

          var key = getPluralCategory(this._switchValue, cases, this._localization);

          this._activateView(this._caseViews[key]);
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_clearViews",
        value: function _clearViews() {
          if (this._activeView) this._activeView.destroy();
        }
        /**
         * @private
         * @param {?} view
         * @return {?}
         */

      }, {
        key: "_activateView",
        value: function _activateView(view) {
          if (view) {
            this._activeView = view;

            this._activeView.create();
          }
        }
      }, {
        key: "ngPlural",
        set: function set(value) {
          this._switchValue = value;

          this._updateView();
        }
      }]);

      return NgPlural;
    }();

    NgPlural.ɵfac = function NgPlural_Factory(t) {
      return new (t || NgPlural)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NgLocalization));
    };

    NgPlural.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: NgPlural,
      selectors: [["", "ngPlural", ""]],
      inputs: {
        ngPlural: "ngPlural"
      }
    });
    /** @nocollapse */

    NgPlural.ctorParameters = function () {
      return [{
        type: NgLocalization
      }];
    };

    NgPlural.propDecorators = {
      ngPlural: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NgPlural, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[ngPlural]'
        }]
      }], function () {
        return [{
          type: NgLocalization
        }];
      }, {
        ngPlural: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * \@ngModule CommonModule
     *
     * \@description
     *
     * Creates a view that will be added/removed from the parent {\@link NgPlural} when the
     * given expression matches the plural expression according to CLDR rules.
     *
     * \@usageNotes
     * ```
     * <some-element [ngPlural]="value">
     *   <ng-template ngPluralCase="=0">...</ng-template>
     *   <ng-template ngPluralCase="other">...</ng-template>
     * </some-element>
     * ```
     *
     * See {\@link NgPlural} for more details and example.
     *
     * \@publicApi
     */


    var NgPluralCase =
    /**
     * @param {?} value
     * @param {?} template
     * @param {?} viewContainer
     * @param {?} ngPlural
     */
    function NgPluralCase(value, template, viewContainer, ngPlural) {
      _classCallCheck(this, NgPluralCase);

      this.value = value;
      /** @type {?} */

      var isANumber = !isNaN(Number(value));
      ngPlural.addCase(isANumber ? "=".concat(value) : value, new SwitchView(viewContainer, template));
    };

    NgPluralCase.ɵfac = function NgPluralCase_Factory(t) {
      return new (t || NgPluralCase)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinjectAttribute"]('ngPluralCase'), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NgPlural, 1));
    };

    NgPluralCase.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: NgPluralCase,
      selectors: [["", "ngPluralCase", ""]]
    });
    /** @nocollapse */

    NgPluralCase.ctorParameters = function () {
      return [{
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Attribute"],
          args: ['ngPluralCase']
        }]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]
      }, {
        type: NgPlural,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NgPluralCase, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[ngPluralCase]'
        }]
      }], function () {
        return [{
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Attribute"],
            args: ['ngPluralCase']
          }]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]
        }, {
          type: NgPlural,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/directives/ng_style.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@ngModule CommonModule
     *
     * \@usageNotes
     *
     * Set the font of the containing element to the result of an expression.
     *
     * ```
     * <some-element [ngStyle]="{'font-style': styleExp}">...</some-element>
     * ```
     *
     * Set the width of the containing element to a pixel value returned by an expression.
     *
     * ```
     * <some-element [ngStyle]="{'max-width.px': widthExp}">...</some-element>
     * ```
     *
     * Set a collection of style values using an expression that returns key-value pairs.
     *
     * ```
     * <some-element [ngStyle]="objExp">...</some-element>
     * ```
     *
     * \@description
     *
     * An attribute directive that updates styles for the containing HTML element.
     * Sets one or more style properties, specified as colon-separated key-value pairs.
     * The key is a style name, with an optional `.<unit>` suffix
     * (such as 'top.px', 'font-style.em').
     * The value is an expression to be evaluated.
     * The resulting non-null value, expressed in the given unit,
     * is assigned to the given style property.
     * If the result of evaluation is null, the corresponding style is removed.
     *
     * \@publicApi
     */


    var NgStyle = /*#__PURE__*/function () {
      /**
       * @param {?} _ngEl
       * @param {?} _differs
       * @param {?} _renderer
       */
      function NgStyle(_ngEl, _differs, _renderer) {
        _classCallCheck(this, NgStyle);

        this._ngEl = _ngEl;
        this._differs = _differs;
        this._renderer = _renderer;
        this._ngStyle = null;
        this._differ = null;
      }
      /**
       * @param {?} values
       * @return {?}
       */


      _createClass2(NgStyle, [{
        key: "ngDoCheck",

        /**
         * @return {?}
         */
        value: function ngDoCheck() {
          if (this._differ) {
            /** @type {?} */
            var changes = this._differ.diff(
            /** @type {?} */
            this._ngStyle);

            if (changes) {
              this._applyChanges(changes);
            }
          }
        }
        /**
         * @private
         * @param {?} nameAndUnit
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "_setStyle",
        value: function _setStyle(nameAndUnit, value) {
          var _nameAndUnit$split = nameAndUnit.split('.'),
              _nameAndUnit$split2 = _slicedToArray(_nameAndUnit$split, 2),
              name = _nameAndUnit$split2[0],
              unit = _nameAndUnit$split2[1];

          value = value != null && unit ? "".concat(value).concat(unit) : value;

          if (value != null) {
            this._renderer.setStyle(this._ngEl.nativeElement, name,
            /** @type {?} */
            value);
          } else {
            this._renderer.removeStyle(this._ngEl.nativeElement, name);
          }
        }
        /**
         * @private
         * @param {?} changes
         * @return {?}
         */

      }, {
        key: "_applyChanges",
        value: function _applyChanges(changes) {
          var _this134 = this;

          changes.forEachRemovedItem(
          /**
          * @param {?} record
          * @return {?}
          */
          function (record) {
            return _this134._setStyle(record.key, null);
          });
          changes.forEachAddedItem(
          /**
          * @param {?} record
          * @return {?}
          */
          function (record) {
            return _this134._setStyle(record.key, record.currentValue);
          });
          changes.forEachChangedItem(
          /**
          * @param {?} record
          * @return {?}
          */
          function (record) {
            return _this134._setStyle(record.key, record.currentValue);
          });
        }
      }, {
        key: "ngStyle",
        set: function set(values) {
          this._ngStyle = values;

          if (!this._differ && values) {
            this._differ = this._differs.find(values).create();
          }
        }
      }]);

      return NgStyle;
    }();

    NgStyle.ɵfac = function NgStyle_Factory(t) {
      return new (t || NgStyle)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["KeyValueDiffers"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]));
    };

    NgStyle.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: NgStyle,
      selectors: [["", "ngStyle", ""]],
      inputs: {
        ngStyle: "ngStyle"
      }
    });
    /** @nocollapse */

    NgStyle.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["KeyValueDiffers"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
      }];
    };

    NgStyle.propDecorators = {
      ngStyle: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['ngStyle']
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NgStyle, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[ngStyle]'
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["KeyValueDiffers"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
        }];
      }, {
        ngStyle: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['ngStyle']
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/directives/ng_template_outlet.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@ngModule CommonModule
     *
     * \@description
     *
     * Inserts an embedded view from a prepared `TemplateRef`.
     *
     * You can attach a context object to the `EmbeddedViewRef` by setting `[ngTemplateOutletContext]`.
     * `[ngTemplateOutletContext]` should be an object, the object's keys will be available for binding
     * by the local template `let` declarations.
     *
     * \@usageNotes
     * ```
     * <ng-container *ngTemplateOutlet="templateRefExp; context: contextExp"></ng-container>
     * ```
     *
     * Using the key `$implicit` in the context object will set its value as default.
     *
     * ### Example
     *
     * {\@example common/ngTemplateOutlet/ts/module.ts region='NgTemplateOutlet'}
     *
     * \@publicApi
     */


    var NgTemplateOutlet = /*#__PURE__*/function () {
      /**
       * @param {?} _viewContainerRef
       */
      function NgTemplateOutlet(_viewContainerRef) {
        _classCallCheck(this, NgTemplateOutlet);

        this._viewContainerRef = _viewContainerRef;
        this._viewRef = null;
        /**
         * A context object to attach to the {\@link EmbeddedViewRef}. This should be an
         * object, the object's keys will be available for binding by the local template `let`
         * declarations.
         * Using the key `$implicit` in the context object will set its value as default.
         */

        this.ngTemplateOutletContext = null;
        /**
         * A string defining the template reference and optionally the context object for the template.
         */

        this.ngTemplateOutlet = null;
      }
      /**
       * @param {?} changes
       * @return {?}
       */


      _createClass2(NgTemplateOutlet, [{
        key: "ngOnChanges",
        value: function ngOnChanges(changes) {
          /** @type {?} */
          var recreateView = this._shouldRecreateView(changes);

          if (recreateView) {
            /** @type {?} */
            var viewContainerRef = this._viewContainerRef;

            if (this._viewRef) {
              viewContainerRef.remove(viewContainerRef.indexOf(this._viewRef));
            }

            this._viewRef = this.ngTemplateOutlet ? viewContainerRef.createEmbeddedView(this.ngTemplateOutlet, this.ngTemplateOutletContext) : null;
          } else if (this._viewRef && this.ngTemplateOutletContext) {
            this._updateExistingContext(this.ngTemplateOutletContext);
          }
        }
        /**
         * We need to re-create existing embedded view if:
         * - templateRef has changed
         * - context has changes
         *
         * We mark context object as changed when the corresponding object
         * shape changes (new properties are added or existing properties are removed).
         * In other words we consider context with the same properties as "the same" even
         * if object reference changes (see https://github.com/angular/angular/issues/13407).
         * @private
         * @param {?} changes
         * @return {?}
         */

      }, {
        key: "_shouldRecreateView",
        value: function _shouldRecreateView(changes) {
          /** @type {?} */
          var ctxChange = changes['ngTemplateOutletContext'];
          return !!changes['ngTemplateOutlet'] || ctxChange && this._hasContextShapeChanged(ctxChange);
        }
        /**
         * @private
         * @param {?} ctxChange
         * @return {?}
         */

      }, {
        key: "_hasContextShapeChanged",
        value: function _hasContextShapeChanged(ctxChange) {
          /** @type {?} */
          var prevCtxKeys = Object.keys(ctxChange.previousValue || {});
          /** @type {?} */

          var currCtxKeys = Object.keys(ctxChange.currentValue || {});

          if (prevCtxKeys.length === currCtxKeys.length) {
            var _iterator8 = _createForOfIteratorHelper(currCtxKeys),
                _step8;

            try {
              for (_iterator8.s(); !(_step8 = _iterator8.n()).done;) {
                var propName = _step8.value;

                if (prevCtxKeys.indexOf(propName) === -1) {
                  return true;
                }
              }
            } catch (err) {
              _iterator8.e(err);
            } finally {
              _iterator8.f();
            }

            return false;
          }

          return true;
        }
        /**
         * @private
         * @param {?} ctx
         * @return {?}
         */

      }, {
        key: "_updateExistingContext",
        value: function _updateExistingContext(ctx) {
          for (var _i10 = 0, _Object$keys = Object.keys(ctx); _i10 < _Object$keys.length; _i10++) {
            var propName = _Object$keys[_i10];

            /** @type {?} */

            /** @type {?} */
            this._viewRef.context[propName] =
            /** @type {?} */
            this.ngTemplateOutletContext[propName];
          }
        }
      }]);

      return NgTemplateOutlet;
    }();

    NgTemplateOutlet.ɵfac = function NgTemplateOutlet_Factory(t) {
      return new (t || NgTemplateOutlet)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]));
    };

    NgTemplateOutlet.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: NgTemplateOutlet,
      selectors: [["", "ngTemplateOutlet", ""]],
      inputs: {
        ngTemplateOutletContext: "ngTemplateOutletContext",
        ngTemplateOutlet: "ngTemplateOutlet"
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵNgOnChangesFeature"]]
    });
    /** @nocollapse */

    NgTemplateOutlet.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]
      }];
    };

    NgTemplateOutlet.propDecorators = {
      ngTemplateOutletContext: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }],
      ngTemplateOutlet: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NgTemplateOutlet, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[ngTemplateOutlet]'
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]
        }];
      }, {
        ngTemplateOutletContext: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }],
        ngTemplateOutlet: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/directives/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * A collection of Angular directives that are likely to be used in each and every Angular
     * application.
     * @type {?}
     */


    var COMMON_DIRECTIVES = [NgClass, NgComponentOutlet, NgForOf, NgIf, NgTemplateOutlet, NgStyle, NgSwitch, NgSwitchCase, NgSwitchDefault, NgPlural, NgPluralCase];
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/pipes/invalid_pipe_argument_error.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} type
     * @param {?} value
     * @return {?}
     */

    function invalidPipeArgumentError(type, value) {
      return Error("InvalidPipeArgument: '".concat(value, "' for pipe '").concat(Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵstringify"])(type), "'"));
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/pipes/async_pipe.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @record
     */


    function SubscriptionStrategy() {}

    if (false) {}

    var ObservableStrategy = /*#__PURE__*/function () {
      function ObservableStrategy() {
        _classCallCheck(this, ObservableStrategy);
      }

      _createClass2(ObservableStrategy, [{
        key: "createSubscription",

        /**
         * @param {?} async
         * @param {?} updateLatestValue
         * @return {?}
         */
        value: function createSubscription(async, updateLatestValue) {
          return async.subscribe({
            next: updateLatestValue,
            error:
            /**
            * @param {?} e
            * @return {?}
            */
            function error(e) {
              throw e;
            }
          });
        }
        /**
         * @param {?} subscription
         * @return {?}
         */

      }, {
        key: "dispose",
        value: function dispose(subscription) {
          subscription.unsubscribe();
        }
        /**
         * @param {?} subscription
         * @return {?}
         */

      }, {
        key: "onDestroy",
        value: function onDestroy(subscription) {
          subscription.unsubscribe();
        }
      }]);

      return ObservableStrategy;
    }();

    var PromiseStrategy = /*#__PURE__*/function () {
      function PromiseStrategy() {
        _classCallCheck(this, PromiseStrategy);
      }

      _createClass2(PromiseStrategy, [{
        key: "createSubscription",

        /**
         * @param {?} async
         * @param {?} updateLatestValue
         * @return {?}
         */
        value: function createSubscription(async, updateLatestValue) {
          return async.then(updateLatestValue,
          /**
          * @param {?} e
          * @return {?}
          */
          function (e) {
            throw e;
          });
        }
        /**
         * @param {?} subscription
         * @return {?}
         */

      }, {
        key: "dispose",
        value: function dispose(subscription) {}
        /**
         * @param {?} subscription
         * @return {?}
         */

      }, {
        key: "onDestroy",
        value: function onDestroy(subscription) {}
      }]);

      return PromiseStrategy;
    }();
    /** @type {?} */


    var _promiseStrategy = new PromiseStrategy();
    /** @type {?} */


    var _observableStrategy = new ObservableStrategy();
    /**
     * \@ngModule CommonModule
     * \@description
     *
     * Unwraps a value from an asynchronous primitive.
     *
     * The `async` pipe subscribes to an `Observable` or `Promise` and returns the latest value it has
     * emitted. When a new value is emitted, the `async` pipe marks the component to be checked for
     * changes. When the component gets destroyed, the `async` pipe unsubscribes automatically to avoid
     * potential memory leaks.
     *
     * \@usageNotes
     *
     * ### Examples
     *
     * This example binds a `Promise` to the view. Clicking the `Resolve` button resolves the
     * promise.
     *
     * {\@example common/pipes/ts/async_pipe.ts region='AsyncPipePromise'}
     *
     * It's also possible to use `async` with Observables. The example below binds the `time` Observable
     * to the view. The Observable continuously updates the view with the current time.
     *
     * {\@example common/pipes/ts/async_pipe.ts region='AsyncPipeObservable'}
     *
     * \@publicApi
     */


    var AsyncPipe = /*#__PURE__*/function () {
      /**
       * @param {?} _ref
       */
      function AsyncPipe(_ref) {
        _classCallCheck(this, AsyncPipe);

        this._ref = _ref;
        this._latestValue = null;
        this._latestReturnedValue = null;
        this._subscription = null;
        this._obj = null;
        this._strategy =
        /** @type {?} */
        null;
      }
      /**
       * @return {?}
       */


      _createClass2(AsyncPipe, [{
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          if (this._subscription) {
            this._dispose();
          }
        }
        /**
         * @param {?} obj
         * @return {?}
         */

      }, {
        key: "transform",
        value: function transform(obj) {
          if (!this._obj) {
            if (obj) {
              this._subscribe(obj);
            }

            this._latestReturnedValue = this._latestValue;
            return this._latestValue;
          }

          if (obj !== this._obj) {
            this._dispose();

            return this.transform(
            /** @type {?} */
            obj);
          }

          if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵlooseIdentical"])(this._latestValue, this._latestReturnedValue)) {
            return this._latestReturnedValue;
          }

          this._latestReturnedValue = this._latestValue;
          return _angular_core__WEBPACK_IMPORTED_MODULE_0__["WrappedValue"].wrap(this._latestValue);
        }
        /**
         * @private
         * @param {?} obj
         * @return {?}
         */

      }, {
        key: "_subscribe",
        value: function _subscribe(obj) {
          var _this135 = this;

          this._obj = obj;
          this._strategy = this._selectStrategy(obj);
          this._subscription = this._strategy.createSubscription(obj,
          /**
          * @param {?} value
          * @return {?}
          */
          function (value) {
            return _this135._updateLatestValue(obj, value);
          });
        }
        /**
         * @private
         * @param {?} obj
         * @return {?}
         */

      }, {
        key: "_selectStrategy",
        value: function _selectStrategy(obj) {
          if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵisPromise"])(obj)) {
            return _promiseStrategy;
          }

          if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵisObservable"])(obj)) {
            return _observableStrategy;
          }

          throw invalidPipeArgumentError(AsyncPipe, obj);
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_dispose",
        value: function _dispose() {
          this._strategy.dispose(
          /** @type {?} */
          this._subscription);

          this._latestValue = null;
          this._latestReturnedValue = null;
          this._subscription = null;
          this._obj = null;
        }
        /**
         * @private
         * @param {?} async
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "_updateLatestValue",
        value: function _updateLatestValue(async, value) {
          if (async === this._obj) {
            this._latestValue = value;

            this._ref.markForCheck();
          }
        }
      }]);

      return AsyncPipe;
    }();

    AsyncPipe.ɵfac = function AsyncPipe_Factory(t) {
      return new (t || AsyncPipe)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinjectPipeChangeDetectorRef"]());
    };

    AsyncPipe.ɵpipe = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefinePipe"]({
      name: "async",
      type: AsyncPipe,
      pure: false
    });
    /** @nocollapse */

    AsyncPipe.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ChangeDetectorRef"]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](AsyncPipe, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"],
        args: [{
          name: 'async',
          pure: false
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ChangeDetectorRef"]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/pipes/case_conversion_pipes.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Transforms text to all lower case.
     *
     * @see `UpperCasePipe`
     * @see `TitleCasePipe`
     * \@usageNotes
     *
     * The following example defines a view that allows the user to enter
     * text, and then uses the pipe to convert the input text to all lower case.
     *
     * <code-example path="common/pipes/ts/lowerupper_pipe.ts" region='LowerUpperPipe'></code-example>
     *
     * \@ngModule CommonModule
     * \@publicApi
     */


    var LowerCasePipe = /*#__PURE__*/function () {
      function LowerCasePipe() {
        _classCallCheck(this, LowerCasePipe);
      }

      _createClass2(LowerCasePipe, [{
        key: "transform",

        /**
         * @param {?} value The string to transform to lower case.
         * @return {?}
         */
        value: function transform(value) {
          if (!value) return value;

          if (typeof value !== 'string') {
            throw invalidPipeArgumentError(LowerCasePipe, value);
          }

          return value.toLowerCase();
        }
      }]);

      return LowerCasePipe;
    }();

    LowerCasePipe.ɵfac = function LowerCasePipe_Factory(t) {
      return new (t || LowerCasePipe)();
    };

    LowerCasePipe.ɵpipe = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefinePipe"]({
      name: "lowercase",
      type: LowerCasePipe,
      pure: true
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](LowerCasePipe, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"],
        args: [{
          name: 'lowercase'
        }]
      }], null, null);
    })(); //
    // Regex below matches any Unicode word and compatible with ES5. In ES2018 the same result
    // can be achieved by using /\p{L}\S*/gu and also known as Unicode Property Escapes
    // (http://2ality.com/2017/07/regexp-unicode-property-escapes.html). Since there is no
    // transpilation of this functionality down to ES5 without external tool, the only solution is
    // to use already transpiled form. Example can be found here -
    // https://mothereff.in/regexpu#input=var+regex+%3D+/%5Cp%7BL%7D/u%3B&unicodePropertyEscape=1
    //

    /** @type {?} */


    var unicodeWordMatch = /(?:[A-Za-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u08A0-\u08B4\u08B6-\u08BD\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16F1-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312E\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FEA\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF2D-\uDF40\uDF42-\uDF49\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF]|\uD801[\uDC00-\uDC9D\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC03-\uDC37\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC00-\uDC34\uDC47-\uDC4A\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDF00-\uDF19]|\uD806[\uDCA0-\uDCDF\uDCFF\uDE00\uDE0B-\uDE32\uDE3A\uDE50\uDE5C-\uDE83\uDE86-\uDE89\uDEC0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC2E\uDC40\uDC72-\uDC8F\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD30\uDD46]|\uD808[\uDC00-\uDF99]|\uD809[\uDC80-\uDD43]|[\uD80C\uD81C-\uD820\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50\uDF93-\uDF9F\uDFE0\uDFE1]|\uD821[\uDC00-\uDFEC]|\uD822[\uDC00-\uDEF2]|\uD82C[\uDC00-\uDD1E\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD83A[\uDC00-\uDCC4\uDD00-\uDD43]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D])\S*/g;
    /**
     * Transforms text to title case.
     * Capitalizes the first letter of each word, and transforms the
     * rest of the word to lower case.
     * Words are delimited by any whitespace character, such as a space, tab, or line-feed character.
     *
     * @see `LowerCasePipe`
     * @see `UpperCasePipe`
     *
     * \@usageNotes
     * The following example shows the result of transforming various strings into title case.
     *
     * <code-example path="common/pipes/ts/titlecase_pipe.ts" region='TitleCasePipe'></code-example>
     *
     * \@ngModule CommonModule
     * \@publicApi
     */

    var TitleCasePipe = /*#__PURE__*/function () {
      function TitleCasePipe() {
        _classCallCheck(this, TitleCasePipe);
      }

      _createClass2(TitleCasePipe, [{
        key: "transform",

        /**
         * @param {?} value The string to transform to title case.
         * @return {?}
         */
        value: function transform(value) {
          if (!value) return value;

          if (typeof value !== 'string') {
            throw invalidPipeArgumentError(TitleCasePipe, value);
          }

          return value.replace(unicodeWordMatch,
          /**
          * @param {?} txt
          * @return {?}
          */
          function (txt) {
            return txt[0].toUpperCase() + txt.substr(1).toLowerCase();
          });
        }
      }]);

      return TitleCasePipe;
    }();

    TitleCasePipe.ɵfac = function TitleCasePipe_Factory(t) {
      return new (t || TitleCasePipe)();
    };

    TitleCasePipe.ɵpipe = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefinePipe"]({
      name: "titlecase",
      type: TitleCasePipe,
      pure: true
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](TitleCasePipe, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"],
        args: [{
          name: 'titlecase'
        }]
      }], null, null);
    })();
    /**
     * Transforms text to all upper case.
     * @see `LowerCasePipe`
     * @see `TitleCasePipe`
     *
     * \@ngModule CommonModule
     * \@publicApi
     */


    var UpperCasePipe = /*#__PURE__*/function () {
      function UpperCasePipe() {
        _classCallCheck(this, UpperCasePipe);
      }

      _createClass2(UpperCasePipe, [{
        key: "transform",

        /**
         * @param {?} value The string to transform to upper case.
         * @return {?}
         */
        value: function transform(value) {
          if (!value) return value;

          if (typeof value !== 'string') {
            throw invalidPipeArgumentError(UpperCasePipe, value);
          }

          return value.toUpperCase();
        }
      }]);

      return UpperCasePipe;
    }();

    UpperCasePipe.ɵfac = function UpperCasePipe_Factory(t) {
      return new (t || UpperCasePipe)();
    };

    UpperCasePipe.ɵpipe = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefinePipe"]({
      name: "uppercase",
      type: UpperCasePipe,
      pure: true
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](UpperCasePipe, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"],
        args: [{
          name: 'uppercase'
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/pipes/date_pipe.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */
    // clang-format off

    /**
     * \@ngModule CommonModule
     * \@description
     *
     * Formats a date value according to locale rules.
     *
     * Only the `en-US` locale data comes with Angular. To localize dates
     * in another language, you must import the corresponding locale data.
     * See the [I18n guide](guide/i18n#i18n-pipes) for more information.
     *
     * @see `formatDate()`
     *
     *
     * \@usageNotes
     *
     * The result of this pipe is not reevaluated when the input is mutated. To avoid the need to
     * reformat the date on every change-detection cycle, treat the date as an immutable object
     * and change the reference when the pipe needs to run again.
     *
     * ### Pre-defined format options
     *
     * Examples are given in `en-US` locale.
     *
     * - `'short'`: equivalent to `'M/d/yy, h:mm a'` (`6/15/15, 9:03 AM`).
     * - `'medium'`: equivalent to `'MMM d, y, h:mm:ss a'` (`Jun 15, 2015, 9:03:01 AM`).
     * - `'long'`: equivalent to `'MMMM d, y, h:mm:ss a z'` (`June 15, 2015 at 9:03:01 AM
     * GMT+1`).
     * - `'full'`: equivalent to `'EEEE, MMMM d, y, h:mm:ss a zzzz'` (`Monday, June 15, 2015 at
     * 9:03:01 AM GMT+01:00`).
     * - `'shortDate'`: equivalent to `'M/d/yy'` (`6/15/15`).
     * - `'mediumDate'`: equivalent to `'MMM d, y'` (`Jun 15, 2015`).
     * - `'longDate'`: equivalent to `'MMMM d, y'` (`June 15, 2015`).
     * - `'fullDate'`: equivalent to `'EEEE, MMMM d, y'` (`Monday, June 15, 2015`).
     * - `'shortTime'`: equivalent to `'h:mm a'` (`9:03 AM`).
     * - `'mediumTime'`: equivalent to `'h:mm:ss a'` (`9:03:01 AM`).
     * - `'longTime'`: equivalent to `'h:mm:ss a z'` (`9:03:01 AM GMT+1`).
     * - `'fullTime'`: equivalent to `'h:mm:ss a zzzz'` (`9:03:01 AM GMT+01:00`).
     *
     * ### Custom format options
     *
     * You can construct a format string using symbols to specify the components
     * of a date-time value, as described in the following table.
     * Format details depend on the locale.
     * Fields marked with (*) are only available in the extra data set for the given locale.
     *
     *  | Field type         | Format      | Description                                                   | Example Value                                              |
     *  |--------------------|-------------|---------------------------------------------------------------|------------------------------------------------------------|
     *  | Era                | G, GG & GGG | Abbreviated                                                   | AD                                                         |
     *  |                    | GGGG        | Wide                                                          | Anno Domini                                                |
     *  |                    | GGGGG       | Narrow                                                        | A                                                          |
     *  | Year               | y           | Numeric: minimum digits                                       | 2, 20, 201, 2017, 20173                                    |
     *  |                    | yy          | Numeric: 2 digits + zero padded                               | 02, 20, 01, 17, 73                                         |
     *  |                    | yyy         | Numeric: 3 digits + zero padded                               | 002, 020, 201, 2017, 20173                                 |
     *  |                    | yyyy        | Numeric: 4 digits or more + zero padded                       | 0002, 0020, 0201, 2017, 20173                              |
     *  | Month              | M           | Numeric: 1 digit                                              | 9, 12                                                      |
     *  |                    | MM          | Numeric: 2 digits + zero padded                               | 09, 12                                                     |
     *  |                    | MMM         | Abbreviated                                                   | Sep                                                        |
     *  |                    | MMMM        | Wide                                                          | September                                                  |
     *  |                    | MMMMM       | Narrow                                                        | S                                                          |
     *  | Month standalone   | L           | Numeric: 1 digit                                              | 9, 12                                                      |
     *  |                    | LL          | Numeric: 2 digits + zero padded                               | 09, 12                                                     |
     *  |                    | LLL         | Abbreviated                                                   | Sep                                                        |
     *  |                    | LLLL        | Wide                                                          | September                                                  |
     *  |                    | LLLLL       | Narrow                                                        | S                                                          |
     *  | Week of year       | w           | Numeric: minimum digits                                       | 1... 53                                                    |
     *  |                    | ww          | Numeric: 2 digits + zero padded                               | 01... 53                                                   |
     *  | Week of month      | W           | Numeric: 1 digit                                              | 1... 5                                                     |
     *  | Day of month       | d           | Numeric: minimum digits                                       | 1                                                          |
     *  |                    | dd          | Numeric: 2 digits + zero padded                               | 01                                                          |
     *  | Week day           | E, EE & EEE | Abbreviated                                                   | Tue                                                        |
     *  |                    | EEEE        | Wide                                                          | Tuesday                                                    |
     *  |                    | EEEEE       | Narrow                                                        | T                                                          |
     *  |                    | EEEEEE      | Short                                                         | Tu                                                         |
     *  | Period             | a, aa & aaa | Abbreviated                                                   | am/pm or AM/PM                                             |
     *  |                    | aaaa        | Wide (fallback to `a` when missing)                           | ante meridiem/post meridiem                                |
     *  |                    | aaaaa       | Narrow                                                        | a/p                                                        |
     *  | Period*            | B, BB & BBB | Abbreviated                                                   | mid.                                                       |
     *  |                    | BBBB        | Wide                                                          | am, pm, midnight, noon, morning, afternoon, evening, night |
     *  |                    | BBBBB       | Narrow                                                        | md                                                         |
     *  | Period standalone* | b, bb & bbb | Abbreviated                                                   | mid.                                                       |
     *  |                    | bbbb        | Wide                                                          | am, pm, midnight, noon, morning, afternoon, evening, night |
     *  |                    | bbbbb       | Narrow                                                        | md                                                         |
     *  | Hour 1-12          | h           | Numeric: minimum digits                                       | 1, 12                                                      |
     *  |                    | hh          | Numeric: 2 digits + zero padded                               | 01, 12                                                     |
     *  | Hour 0-23          | H           | Numeric: minimum digits                                       | 0, 23                                                      |
     *  |                    | HH          | Numeric: 2 digits + zero padded                               | 00, 23                                                     |
     *  | Minute             | m           | Numeric: minimum digits                                       | 8, 59                                                      |
     *  |                    | mm          | Numeric: 2 digits + zero padded                               | 08, 59                                                     |
     *  | Second             | s           | Numeric: minimum digits                                       | 0... 59                                                    |
     *  |                    | ss          | Numeric: 2 digits + zero padded                               | 00... 59                                                   |
     *  | Fractional seconds | S           | Numeric: 1 digit                                              | 0... 9                                                     |
     *  |                    | SS          | Numeric: 2 digits + zero padded                               | 00... 99                                                   |
     *  |                    | SSS         | Numeric: 3 digits + zero padded (= milliseconds)              | 000... 999                                                 |
     *  | Zone               | z, zz & zzz | Short specific non location format (fallback to O)            | GMT-8                                                      |
     *  |                    | zzzz        | Long specific non location format (fallback to OOOO)          | GMT-08:00                                                  |
     *  |                    | Z, ZZ & ZZZ | ISO8601 basic format                                          | -0800                                                      |
     *  |                    | ZZZZ        | Long localized GMT format                                     | GMT-8:00                                                   |
     *  |                    | ZZZZZ       | ISO8601 extended format + Z indicator for offset 0 (= XXXXX)  | -08:00                                                     |
     *  |                    | O, OO & OOO | Short localized GMT format                                    | GMT-8                                                      |
     *  |                    | OOOO        | Long localized GMT format                                     | GMT-08:00                                                  |
     *
     * Note that timezone correction is not applied to an ISO string that has no time component, such as "2016-09-19"
     *
     * ### Format examples
     *
     * These examples transform a date into various formats,
     * assuming that `dateObj` is a JavaScript `Date` object for
     * year: 2015, month: 6, day: 15, hour: 21, minute: 43, second: 11,
     * given in the local time for the `en-US` locale.
     *
     * ```
     * {{ dateObj | date }}               // output is 'Jun 15, 2015'
     * {{ dateObj | date:'medium' }}      // output is 'Jun 15, 2015, 9:43:11 PM'
     * {{ dateObj | date:'shortTime' }}   // output is '9:43 PM'
     * {{ dateObj | date:'mm:ss' }}       // output is '43:11'
     * ```
     *
     * ### Usage example
     *
     * The following component uses a date pipe to display the current date in different formats.
     *
     * ```
     * \@Component({
     *  selector: 'date-pipe',
     *  template: `<div>
     *    <p>Today is {{today | date}}</p>
     *    <p>Or if you prefer, {{today | date:'fullDate'}}</p>
     *    <p>The time is {{today | date:'h:mm a z'}}</p>
     *  </div>`
     * })
     * // Get the current date and time as a date-time value.
     * export class DatePipeComponent {
     *   today: number = Date.now();
     * }
     * ```
     *
     * \@publicApi
     */
    // clang-format on


    var DatePipe = /*#__PURE__*/function () {
      /**
       * @param {?} locale
       */
      function DatePipe(locale) {
        _classCallCheck(this, DatePipe);

        this.locale = locale;
      }
      /**
       * @param {?} value The date expression: a `Date` object,  a number
       * (milliseconds since UTC epoch), or an ISO string (https://www.w3.org/TR/NOTE-datetime).
       * @param {?=} format The date/time components to include, using predefined options or a
       * custom format string.
       * @param {?=} timezone A timezone offset (such as `'+0430'`), or a standard
       * UTC/GMT or continental US timezone abbreviation.
       * When not supplied, uses the end-user's local system timezone.
       * @param {?=} locale A locale code for the locale format rules to use.
       * When not supplied, uses the value of `LOCALE_ID`, which is `en-US` by default.
       * See [Setting your app locale](guide/i18n#setting-up-the-locale-of-your-app).
       * @return {?} A date string in the desired format.
       */


      _createClass2(DatePipe, [{
        key: "transform",
        value: function transform(value) {
          var format = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'mediumDate';
          var timezone = arguments.length > 2 ? arguments[2] : undefined;
          var locale = arguments.length > 3 ? arguments[3] : undefined;
          if (value == null || value === '' || value !== value) return null;

          try {
            return formatDate(value, format, locale || this.locale, timezone);
          } catch (error) {
            throw invalidPipeArgumentError(DatePipe, error.message);
          }
        }
      }]);

      return DatePipe;
    }();

    DatePipe.ɵfac = function DatePipe_Factory(t) {
      return new (t || DatePipe)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"]));
    };

    DatePipe.ɵpipe = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefinePipe"]({
      name: "date",
      type: DatePipe,
      pure: true
    });
    /** @nocollapse */

    DatePipe.ctorParameters = function () {
      return [{
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"]]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](DatePipe, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"],
        args: [{
          name: 'date',
          pure: true
        }]
      }], function () {
        return [{
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"]]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/pipes/i18n_plural_pipe.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var _INTERPOLATION_REGEXP = /#/g;
    /**
     * \@ngModule CommonModule
     * \@description
     *
     * Maps a value to a string that pluralizes the value according to locale rules.
     *
     * \@usageNotes
     *
     * ### Example
     *
     * {\@example common/pipes/ts/i18n_pipe.ts region='I18nPluralPipeComponent'}
     *
     * \@publicApi
     */

    var I18nPluralPipe = /*#__PURE__*/function () {
      /**
       * @param {?} _localization
       */
      function I18nPluralPipe(_localization) {
        _classCallCheck(this, I18nPluralPipe);

        this._localization = _localization;
      }
      /**
       * @param {?} value the number to be formatted
       * @param {?} pluralMap an object that mimics the ICU format, see
       * http://userguide.icu-project.org/formatparse/messages.
       * @param {?=} locale a `string` defining the locale to use (uses the current {\@link LOCALE_ID} by
       * default).
       * @return {?}
       */


      _createClass2(I18nPluralPipe, [{
        key: "transform",
        value: function transform(value, pluralMap, locale) {
          if (value == null) return '';

          if (typeof pluralMap !== 'object' || pluralMap === null) {
            throw invalidPipeArgumentError(I18nPluralPipe, pluralMap);
          }
          /** @type {?} */


          var key = getPluralCategory(value, Object.keys(pluralMap), this._localization, locale);
          return pluralMap[key].replace(_INTERPOLATION_REGEXP, value.toString());
        }
      }]);

      return I18nPluralPipe;
    }();

    I18nPluralPipe.ɵfac = function I18nPluralPipe_Factory(t) {
      return new (t || I18nPluralPipe)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NgLocalization));
    };

    I18nPluralPipe.ɵpipe = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefinePipe"]({
      name: "i18nPlural",
      type: I18nPluralPipe,
      pure: true
    });
    /** @nocollapse */

    I18nPluralPipe.ctorParameters = function () {
      return [{
        type: NgLocalization
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](I18nPluralPipe, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"],
        args: [{
          name: 'i18nPlural',
          pure: true
        }]
      }], function () {
        return [{
          type: NgLocalization
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/pipes/i18n_select_pipe.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@ngModule CommonModule
     * \@description
     *
     * Generic selector that displays the string that matches the current value.
     *
     * If none of the keys of the `mapping` match the `value`, then the content
     * of the `other` key is returned when present, otherwise an empty string is returned.
     *
     * \@usageNotes
     *
     * ### Example
     *
     * {\@example common/pipes/ts/i18n_pipe.ts region='I18nSelectPipeComponent'}
     *
     * \@publicApi
     */


    var I18nSelectPipe = /*#__PURE__*/function () {
      function I18nSelectPipe() {
        _classCallCheck(this, I18nSelectPipe);
      }

      _createClass2(I18nSelectPipe, [{
        key: "transform",

        /**
         * @param {?} value a string to be internationalized.
         * @param {?} mapping an object that indicates the text that should be displayed
         * for different values of the provided `value`.
         * @return {?}
         */
        value: function transform(value, mapping) {
          if (value == null) return '';

          if (typeof mapping !== 'object' || typeof value !== 'string') {
            throw invalidPipeArgumentError(I18nSelectPipe, mapping);
          }

          if (mapping.hasOwnProperty(value)) {
            return mapping[value];
          }

          if (mapping.hasOwnProperty('other')) {
            return mapping['other'];
          }

          return '';
        }
      }]);

      return I18nSelectPipe;
    }();

    I18nSelectPipe.ɵfac = function I18nSelectPipe_Factory(t) {
      return new (t || I18nSelectPipe)();
    };

    I18nSelectPipe.ɵpipe = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefinePipe"]({
      name: "i18nSelect",
      type: I18nSelectPipe,
      pure: true
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](I18nSelectPipe, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"],
        args: [{
          name: 'i18nSelect',
          pure: true
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/pipes/json_pipe.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@ngModule CommonModule
     * \@description
     *
     * Converts a value into its JSON-format representation.  Useful for debugging.
     *
     * \@usageNotes
     *
     * The following component uses a JSON pipe to convert an object
     * to JSON format, and displays the string in both formats for comparison.
     *
     * {\@example common/pipes/ts/json_pipe.ts region='JsonPipe'}
     *
     * \@publicApi
     */


    var JsonPipe = /*#__PURE__*/function () {
      function JsonPipe() {
        _classCallCheck(this, JsonPipe);
      }

      _createClass2(JsonPipe, [{
        key: "transform",

        /**
         * @param {?} value A value of any type to convert into a JSON-format string.
         * @return {?}
         */
        value: function transform(value) {
          return JSON.stringify(value, null, 2);
        }
      }]);

      return JsonPipe;
    }();

    JsonPipe.ɵfac = function JsonPipe_Factory(t) {
      return new (t || JsonPipe)();
    };

    JsonPipe.ɵpipe = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefinePipe"]({
      name: "json",
      type: JsonPipe,
      pure: false
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](JsonPipe, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"],
        args: [{
          name: 'json',
          pure: false
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/pipes/keyvalue_pipe.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @template K, V
     * @param {?} key
     * @param {?} value
     * @return {?}
     */


    function makeKeyValuePair(key, value) {
      return {
        key: key,
        value: value
      };
    }
    /**
     * A key value pair.
     * Usually used to represent the key value pairs from a Map or Object.
     *
     * \@publicApi
     * @record
     * @template K, V
     */


    function KeyValue() {}

    if (false) {}
    /**
     * \@ngModule CommonModule
     * \@description
     *
     * Transforms Object or Map into an array of key value pairs.
     *
     * The output array will be ordered by keys.
     * By default the comparator will be by Unicode point value.
     * You can optionally pass a compareFn if your keys are complex types.
     *
     * \@usageNotes
     * ### Examples
     *
     * This examples show how an Object or a Map can be iterated by ngFor with the use of this keyvalue
     * pipe.
     *
     * {\@example common/pipes/ts/keyvalue_pipe.ts region='KeyValuePipe'}
     *
     * \@publicApi
     */


    var KeyValuePipe = /*#__PURE__*/function () {
      /**
       * @param {?} differs
       */
      function KeyValuePipe(differs) {
        _classCallCheck(this, KeyValuePipe);

        this.differs = differs;
        this.keyValues = [];
      }
      /**
       * @template K, V
       * @param {?} input
       * @param {?=} compareFn
       * @return {?}
       */


      _createClass2(KeyValuePipe, [{
        key: "transform",
        value: function transform(input) {
          var _this136 = this;

          var compareFn = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : defaultComparator;

          if (!input || !(input instanceof Map) && typeof input !== 'object') {
            return null;
          }

          if (!this.differ) {
            // make a differ for whatever type we've been passed in
            this.differ = this.differs.find(input).create();
          }
          /** @type {?} */


          var differChanges = this.differ.diff(
          /** @type {?} */
          input);

          if (differChanges) {
            this.keyValues = [];
            differChanges.forEachItem(
            /**
            * @param {?} r
            * @return {?}
            */
            function (r) {
              _this136.keyValues.push(makeKeyValuePair(r.key,
              /** @type {?} */
              r.currentValue));
            });
            this.keyValues.sort(compareFn);
          }

          return this.keyValues;
        }
      }]);

      return KeyValuePipe;
    }();

    KeyValuePipe.ɵfac = function KeyValuePipe_Factory(t) {
      return new (t || KeyValuePipe)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["KeyValueDiffers"]));
    };

    KeyValuePipe.ɵpipe = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefinePipe"]({
      name: "keyvalue",
      type: KeyValuePipe,
      pure: false
    });
    /** @nocollapse */

    KeyValuePipe.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["KeyValueDiffers"]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](KeyValuePipe, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"],
        args: [{
          name: 'keyvalue',
          pure: false
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["KeyValueDiffers"]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @template K, V
     * @param {?} keyValueA
     * @param {?} keyValueB
     * @return {?}
     */


    function defaultComparator(keyValueA, keyValueB) {
      /** @type {?} */
      var a = keyValueA.key;
      /** @type {?} */

      var b = keyValueB.key; // if same exit with 0;

      if (a === b) return 0; // make sure that undefined are at the end of the sort.

      if (a === undefined) return 1;
      if (b === undefined) return -1; // make sure that nulls are at the end of the sort.

      if (a === null) return 1;
      if (b === null) return -1;

      if (typeof a == 'string' && typeof b == 'string') {
        return a < b ? -1 : 1;
      }

      if (typeof a == 'number' && typeof b == 'number') {
        return a - b;
      }

      if (typeof a == 'boolean' && typeof b == 'boolean') {
        return a < b ? -1 : 1;
      } // `a` and `b` are of different types. Compare their string values.

      /** @type {?} */


      var aString = String(a);
      /** @type {?} */

      var bString = String(b);
      return aString == bString ? 0 : aString < bString ? -1 : 1;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/pipes/number_pipe.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@ngModule CommonModule
     * \@description
     *
     * Transforms a number into a string,
     * formatted according to locale rules that determine group sizing and
     * separator, decimal-point character, and other locale-specific
     * configurations.
     *
     * If no parameters are specified, the function rounds off to the nearest value using this
     * [rounding method](https://en.wikibooks.org/wiki/Arithmetic/Rounding).
     * The behavior differs from that of the JavaScript ```Math.round()``` function.
     * In the following case for example, the pipe rounds down where
     * ```Math.round()``` rounds up:
     *
     * ```html
     * -2.5 | number:'1.0-0'
     * > -3
     * Math.round(-2.5)
     * > -2
     * ```
     *
     * @see `formatNumber()`
     *
     * \@usageNotes
     * The following code shows how the pipe transforms numbers
     * into text strings, according to various format specifications,
     * where the caller's default locale is `en-US`.
     *
     * ### Example
     *
     * <code-example path="common/pipes/ts/number_pipe.ts" region='NumberPipe'></code-example>
     *
     * \@publicApi
     */


    var DecimalPipe = /*#__PURE__*/function () {
      /**
       * @param {?} _locale
       */
      function DecimalPipe(_locale) {
        _classCallCheck(this, DecimalPipe);

        this._locale = _locale;
      }
      /**
       * @param {?} value The number to be formatted.
       * @param {?=} digitsInfo Decimal representation options, specified by a string
       * in the following format:<br>
       * <code>{minIntegerDigits}.{minFractionDigits}-{maxFractionDigits}</code>.
       *   - `minIntegerDigits`: The minimum number of integer digits before the decimal point.
       * Default is `1`.
       *   - `minFractionDigits`: The minimum number of digits after the decimal point.
       * Default is `0`.
       *   - `maxFractionDigits`: The maximum number of digits after the decimal point.
       * Default is `3`.
       * @param {?=} locale A locale code for the locale format rules to use.
       * When not supplied, uses the value of `LOCALE_ID`, which is `en-US` by default.
       * See [Setting your app locale](guide/i18n#setting-up-the-locale-of-your-app).
       * @return {?}
       */


      _createClass2(DecimalPipe, [{
        key: "transform",
        value: function transform(value, digitsInfo, locale) {
          if (isEmpty(value)) return null;
          locale = locale || this._locale;

          try {
            /** @type {?} */
            var num = strToNumber(value);
            return formatNumber(num, locale, digitsInfo);
          } catch (error) {
            throw invalidPipeArgumentError(DecimalPipe, error.message);
          }
        }
      }]);

      return DecimalPipe;
    }();

    DecimalPipe.ɵfac = function DecimalPipe_Factory(t) {
      return new (t || DecimalPipe)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"]));
    };

    DecimalPipe.ɵpipe = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefinePipe"]({
      name: "number",
      type: DecimalPipe,
      pure: true
    });
    /** @nocollapse */

    DecimalPipe.ctorParameters = function () {
      return [{
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"]]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](DecimalPipe, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"],
        args: [{
          name: 'number'
        }]
      }], function () {
        return [{
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"]]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * \@ngModule CommonModule
     * \@description
     *
     * Transforms a number to a percentage
     * string, formatted according to locale rules that determine group sizing and
     * separator, decimal-point character, and other locale-specific
     * configurations.
     *
     * @see `formatPercent()`
     *
     * \@usageNotes
     * The following code shows how the pipe transforms numbers
     * into text strings, according to various format specifications,
     * where the caller's default locale is `en-US`.
     *
     * <code-example path="common/pipes/ts/percent_pipe.ts" region='PercentPipe'></code-example>
     *
     * \@publicApi
     */


    var PercentPipe = /*#__PURE__*/function () {
      /**
       * @param {?} _locale
       */
      function PercentPipe(_locale) {
        _classCallCheck(this, PercentPipe);

        this._locale = _locale;
      }
      /**
       *
       * @param {?} value The number to be formatted as a percentage.
       * @param {?=} digitsInfo Decimal representation options, specified by a string
       * in the following format:<br>
       * <code>{minIntegerDigits}.{minFractionDigits}-{maxFractionDigits}</code>.
       *   - `minIntegerDigits`: The minimum number of integer digits before the decimal point.
       * Default is `1`.
       *   - `minFractionDigits`: The minimum number of digits after the decimal point.
       * Default is `0`.
       *   - `maxFractionDigits`: The maximum number of digits after the decimal point.
       * Default is `0`.
       * @param {?=} locale A locale code for the locale format rules to use.
       * When not supplied, uses the value of `LOCALE_ID`, which is `en-US` by default.
       * See [Setting your app locale](guide/i18n#setting-up-the-locale-of-your-app).
       * @return {?}
       */


      _createClass2(PercentPipe, [{
        key: "transform",
        value: function transform(value, digitsInfo, locale) {
          if (isEmpty(value)) return null;
          locale = locale || this._locale;

          try {
            /** @type {?} */
            var num = strToNumber(value);
            return formatPercent(num, locale, digitsInfo);
          } catch (error) {
            throw invalidPipeArgumentError(PercentPipe, error.message);
          }
        }
      }]);

      return PercentPipe;
    }();

    PercentPipe.ɵfac = function PercentPipe_Factory(t) {
      return new (t || PercentPipe)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"]));
    };

    PercentPipe.ɵpipe = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefinePipe"]({
      name: "percent",
      type: PercentPipe,
      pure: true
    });
    /** @nocollapse */

    PercentPipe.ctorParameters = function () {
      return [{
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"]]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](PercentPipe, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"],
        args: [{
          name: 'percent'
        }]
      }], function () {
        return [{
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"]]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * \@ngModule CommonModule
     * \@description
     *
     * Transforms a number to a currency string, formatted according to locale rules
     * that determine group sizing and separator, decimal-point character,
     * and other locale-specific configurations.
     *
     * {\@a currency-code-deprecation}
     * <div class="alert is-helpful">
     *
     * **Deprecation notice:**
     *
     * The default currency code is currently always `USD` but this is deprecated from v9.
     *
     * **In v11 the default currency code will be taken from the current locale identified by
     * the `LOCAL_ID` token. See the [i18n guide](guide/i18n#setting-up-the-locale-of-your-app) for
     * more information.**
     *
     * If you need the previous behavior then set it by creating a `DEFAULT_CURRENCY_CODE` provider in
     * your application `NgModule`:
     *
     * ```ts
     * {provide: DEFAULT_CURRENCY_CODE, useValue: 'USD'}
     * ```
     *
     * </div>
     *
     * @see `getCurrencySymbol()`
     * @see `formatCurrency()`
     *
     * \@usageNotes
     * The following code shows how the pipe transforms numbers
     * into text strings, according to various format specifications,
     * where the caller's default locale is `en-US`.
     *
     * <code-example path="common/pipes/ts/currency_pipe.ts" region='CurrencyPipe'></code-example>
     *
     * \@publicApi
     */


    var CurrencyPipe = /*#__PURE__*/function () {
      /**
       * @param {?} _locale
       * @param {?=} _defaultCurrencyCode
       */
      function CurrencyPipe(_locale) {
        var _defaultCurrencyCode = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'USD';

        _classCallCheck(this, CurrencyPipe);

        this._locale = _locale;
        this._defaultCurrencyCode = _defaultCurrencyCode;
      }
      /**
       *
       * @param {?} value The number to be formatted as currency.
       * @param {?=} currencyCode The [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) currency code,
       * such as `USD` for the US dollar and `EUR` for the euro. The default currency code can be
       * configured using the `DEFAULT_CURRENCY_CODE` injection token.
       * @param {?=} display The format for the currency indicator. One of the following:
       *   - `code`: Show the code (such as `USD`).
       *   - `symbol`(default): Show the symbol (such as `$`).
       *   - `symbol-narrow`: Use the narrow symbol for locales that have two symbols for their
       * currency.
       * For example, the Canadian dollar CAD has the symbol `CA$` and the symbol-narrow `$`. If the
       * locale has no narrow symbol, uses the standard symbol for the locale.
       *   - String: Use the given string value instead of a code or a symbol.
       * For example, an empty string will suppress the currency & symbol.
       *   - Boolean (marked deprecated in v5): `true` for symbol and false for `code`.
       *
       * @param {?=} digitsInfo Decimal representation options, specified by a string
       * in the following format:<br>
       * <code>{minIntegerDigits}.{minFractionDigits}-{maxFractionDigits}</code>.
       *   - `minIntegerDigits`: The minimum number of integer digits before the decimal point.
       * Default is `1`.
       *   - `minFractionDigits`: The minimum number of digits after the decimal point.
       * Default is `2`.
       *   - `maxFractionDigits`: The maximum number of digits after the decimal point.
       * Default is `2`.
       * If not provided, the number will be formatted with the proper amount of digits,
       * depending on what the [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) specifies.
       * For example, the Canadian dollar has 2 digits, whereas the Chilean peso has none.
       * @param {?=} locale A locale code for the locale format rules to use.
       * When not supplied, uses the value of `LOCALE_ID`, which is `en-US` by default.
       * See [Setting your app locale](guide/i18n#setting-up-the-locale-of-your-app).
       * @return {?}
       */


      _createClass2(CurrencyPipe, [{
        key: "transform",
        value: function transform(value, currencyCode) {
          var display = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 'symbol';
          var digitsInfo = arguments.length > 3 ? arguments[3] : undefined;
          var locale = arguments.length > 4 ? arguments[4] : undefined;
          if (isEmpty(value)) return null;
          locale = locale || this._locale;

          if (typeof display === 'boolean') {
            if (
            /** @type {?} */
            console &&
            /** @type {?} */
            console.warn) {
              console.warn("Warning: the currency pipe has been changed in Angular v5. The symbolDisplay option (third parameter) is now a string instead of a boolean. The accepted values are \"code\", \"symbol\" or \"symbol-narrow\".");
            }

            display = display ? 'symbol' : 'code';
          }
          /** @type {?} */


          var currency = currencyCode || this._defaultCurrencyCode;

          if (display !== 'code') {
            if (display === 'symbol' || display === 'symbol-narrow') {
              currency = getCurrencySymbol(currency, display === 'symbol' ? 'wide' : 'narrow', locale);
            } else {
              currency = display;
            }
          }

          try {
            /** @type {?} */
            var num = strToNumber(value);
            return formatCurrency(num, locale, currency, currencyCode, digitsInfo);
          } catch (error) {
            throw invalidPipeArgumentError(CurrencyPipe, error.message);
          }
        }
      }]);

      return CurrencyPipe;
    }();

    CurrencyPipe.ɵfac = function CurrencyPipe_Factory(t) {
      return new (t || CurrencyPipe)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["DEFAULT_CURRENCY_CODE"]));
    };

    CurrencyPipe.ɵpipe = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefinePipe"]({
      name: "currency",
      type: CurrencyPipe,
      pure: true
    });
    /** @nocollapse */

    CurrencyPipe.ctorParameters = function () {
      return [{
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"]]
        }]
      }, {
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["DEFAULT_CURRENCY_CODE"]]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](CurrencyPipe, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"],
        args: [{
          name: 'currency'
        }]
      }], function () {
        return [{
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"]]
          }]
        }, {
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["DEFAULT_CURRENCY_CODE"]]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @param {?} value
     * @return {?}
     */


    function isEmpty(value) {
      return value == null || value === '' || value !== value;
    }
    /**
     * Transforms a string into a number (if needed).
     * @param {?} value
     * @return {?}
     */


    function strToNumber(value) {
      // Convert strings to numbers
      if (typeof value === 'string' && !isNaN(Number(value) - parseFloat(value))) {
        return Number(value);
      }

      if (typeof value !== 'number') {
        throw new Error("".concat(value, " is not a number"));
      }

      return value;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/pipes/slice_pipe.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@ngModule CommonModule
     * \@description
     *
     * Creates a new `Array` or `String` containing a subset (slice) of the elements.
     *
     * \@usageNotes
     *
     * All behavior is based on the expected behavior of the JavaScript API `Array.prototype.slice()`
     * and `String.prototype.slice()`.
     *
     * When operating on an `Array`, the returned `Array` is always a copy even when all
     * the elements are being returned.
     *
     * When operating on a blank value, the pipe returns the blank value.
     *
     * ### List Example
     *
     * This `ngFor` example:
     *
     * {\@example common/pipes/ts/slice_pipe.ts region='SlicePipe_list'}
     *
     * produces the following:
     *
     * ```html
     * <li>b</li>
     * <li>c</li>
     * ```
     *
     * ### String Examples
     *
     * {\@example common/pipes/ts/slice_pipe.ts region='SlicePipe_string'}
     *
     * \@publicApi
     */


    var SlicePipe = /*#__PURE__*/function () {
      function SlicePipe() {
        _classCallCheck(this, SlicePipe);
      }

      _createClass2(SlicePipe, [{
        key: "transform",

        /**
         * @param {?} value
         * @param {?} start
         * @param {?=} end
         * @return {?}
         */
        value: function transform(value, start, end) {
          if (value == null) return value;

          if (!this.supports(value)) {
            throw invalidPipeArgumentError(SlicePipe, value);
          }

          return value.slice(start, end);
        }
        /**
         * @private
         * @param {?} obj
         * @return {?}
         */

      }, {
        key: "supports",
        value: function supports(obj) {
          return typeof obj === 'string' || Array.isArray(obj);
        }
      }]);

      return SlicePipe;
    }();

    SlicePipe.ɵfac = function SlicePipe_Factory(t) {
      return new (t || SlicePipe)();
    };

    SlicePipe.ɵpipe = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefinePipe"]({
      name: "slice",
      type: SlicePipe,
      pure: false
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](SlicePipe, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Pipe"],
        args: [{
          name: 'slice',
          pure: false
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/pipes/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * A collection of Angular pipes that are likely to be used in each and every application.
     * @type {?}
     */


    var COMMON_PIPES = [AsyncPipe, UpperCasePipe, LowerCasePipe, JsonPipe, SlicePipe, DecimalPipe, PercentPipe, TitleCasePipe, CurrencyPipe, DatePipe, I18nPluralPipe, I18nSelectPipe, KeyValuePipe];
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/common_module.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */
    // Note: This does not contain the location providers,
    // as they need some platform specific implementations to work.

    /**
     * Exports all the basic Angular directives and pipes,
     * such as `NgIf`, `NgForOf`, `DecimalPipe`, and so on.
     * Re-exported by `BrowserModule`, which is included automatically in the root
     * `AppModule` when you create a new app with the CLI `new` command.
     *
     * * The `providers` options configure the NgModule's injector to provide
     * localization dependencies to members.
     * * The `exports` options make the declared directives and pipes available for import
     * by other NgModules.
     *
     * \@publicApi
     */

    var CommonModule = function CommonModule() {
      _classCallCheck(this, CommonModule);
    };

    CommonModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: CommonModule
    });
    CommonModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function CommonModule_Factory(t) {
        return new (t || CommonModule)();
      },
      providers: [{
        provide: NgLocalization,
        useClass: NgLocaleLocalization
      }]
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](CommonModule, {
        declarations: [NgClass, NgComponentOutlet, NgForOf, NgIf, NgTemplateOutlet, NgStyle, NgSwitch, NgSwitchCase, NgSwitchDefault, NgPlural, NgPluralCase, AsyncPipe, UpperCasePipe, LowerCasePipe, JsonPipe, SlicePipe, DecimalPipe, PercentPipe, TitleCasePipe, CurrencyPipe, DatePipe, I18nPluralPipe, I18nSelectPipe, KeyValuePipe],
        exports: [NgClass, NgComponentOutlet, NgForOf, NgIf, NgTemplateOutlet, NgStyle, NgSwitch, NgSwitchCase, NgSwitchDefault, NgPlural, NgPluralCase, AsyncPipe, UpperCasePipe, LowerCasePipe, JsonPipe, SlicePipe, DecimalPipe, PercentPipe, TitleCasePipe, CurrencyPipe, DatePipe, I18nPluralPipe, I18nSelectPipe, KeyValuePipe]
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](CommonModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{
          declarations: [COMMON_DIRECTIVES, COMMON_PIPES],
          exports: [COMMON_DIRECTIVES, COMMON_PIPES],
          providers: [{
            provide: NgLocalization,
            useClass: NgLocaleLocalization
          }]
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/platform_id.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** @type {?} */


    var PLATFORM_BROWSER_ID = 'browser';
    /** @type {?} */

    var PLATFORM_SERVER_ID = 'server';
    /** @type {?} */

    var PLATFORM_WORKER_APP_ID = 'browserWorkerApp';
    /** @type {?} */

    var PLATFORM_WORKER_UI_ID = 'browserWorkerUi';
    /**
     * Returns whether a platform id represents a browser platform.
     * \@publicApi
     * @param {?} platformId
     * @return {?}
     */

    function isPlatformBrowser(platformId) {
      return platformId === PLATFORM_BROWSER_ID;
    }
    /**
     * Returns whether a platform id represents a server platform.
     * \@publicApi
     * @param {?} platformId
     * @return {?}
     */


    function isPlatformServer(platformId) {
      return platformId === PLATFORM_SERVER_ID;
    }
    /**
     * Returns whether a platform id represents a web worker app platform.
     * \@publicApi
     * @param {?} platformId
     * @return {?}
     */


    function isPlatformWorkerApp(platformId) {
      return platformId === PLATFORM_WORKER_APP_ID;
    }
    /**
     * Returns whether a platform id represents a web worker UI platform.
     * \@publicApi
     * @param {?} platformId
     * @return {?}
     */


    function isPlatformWorkerUi(platformId) {
      return platformId === PLATFORM_WORKER_UI_ID;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/version.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@publicApi
     * @type {?}
     */


    var VERSION = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["Version"]('9.1.4');
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/viewport_scroller.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Defines a scroll position manager. Implemented by `BrowserViewportScroller`.
     *
     * \@publicApi
     * @abstract
     */

    var ViewportScroller = function ViewportScroller() {
      _classCallCheck(this, ViewportScroller);
    }; // De-sugared tree-shakable injection
    // See #23917

    /** @nocollapse */


    ViewportScroller.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"])({
      token: ViewportScroller,
      providedIn: 'root',
      factory:
      /**
      * @return {?}
      */
      function factory() {
        return new BrowserViewportScroller(Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"])(DOCUMENT), window, Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"])(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ErrorHandler"]));
      }
    });

    if (false) {}
    /**
     * Manages the scroll position for a browser window.
     */


    var BrowserViewportScroller = /*#__PURE__*/function () {
      /**
       * @param {?} document
       * @param {?} window
       * @param {?} errorHandler
       */
      function BrowserViewportScroller(document, window, errorHandler) {
        _classCallCheck(this, BrowserViewportScroller);

        this.document = document;
        this.window = window;
        this.errorHandler = errorHandler;

        this.offset =
        /**
        * @return {?}
        */
        function () {
          return [0, 0];
        };
      }
      /**
       * Configures the top offset used when scrolling to an anchor.
       * @param {?} offset A position in screen coordinates (a tuple with x and y values)
       * or a function that returns the top offset position.
       *
       * @return {?}
       */


      _createClass2(BrowserViewportScroller, [{
        key: "setOffset",
        value: function setOffset(offset) {
          if (Array.isArray(offset)) {
            this.offset =
            /**
            * @return {?}
            */
            function () {
              return offset;
            };
          } else {
            this.offset = offset;
          }
        }
        /**
         * Retrieves the current scroll position.
         * @return {?} The position in screen coordinates.
         */

      }, {
        key: "getScrollPosition",
        value: function getScrollPosition() {
          if (this.supportScrollRestoration()) {
            return [this.window.scrollX, this.window.scrollY];
          } else {
            return [0, 0];
          }
        }
        /**
         * Sets the scroll position.
         * @param {?} position The new position in screen coordinates.
         * @return {?}
         */

      }, {
        key: "scrollToPosition",
        value: function scrollToPosition(position) {
          if (this.supportScrollRestoration()) {
            this.window.scrollTo(position[0], position[1]);
          }
        }
        /**
         * Scrolls to an anchor element.
         * @param {?} anchor The ID of the anchor element.
         * @return {?}
         */

      }, {
        key: "scrollToAnchor",
        value: function scrollToAnchor(anchor) {
          if (this.supportScrollRestoration()) {
            // Escape anything passed to `querySelector` as it can throw errors and stop the application
            // from working if invalid values are passed.
            if (this.window.CSS && this.window.CSS.escape) {
              anchor = this.window.CSS.escape(anchor);
            } else {
              anchor = anchor.replace(/(\"|\'\ |:|\.|\[|\]|,|=)/g, '\\$1');
            }

            try {
              /** @type {?} */
              var elSelectedById = this.document.querySelector("#".concat(anchor));

              if (elSelectedById) {
                this.scrollToElement(elSelectedById);
                return;
              }
              /** @type {?} */


              var elSelectedByName = this.document.querySelector("[name='".concat(anchor, "']"));

              if (elSelectedByName) {
                this.scrollToElement(elSelectedByName);
                return;
              }
            } catch (e) {
              this.errorHandler.handleError(e);
            }
          }
        }
        /**
         * Disables automatic scroll restoration provided by the browser.
         * @param {?} scrollRestoration
         * @return {?}
         */

      }, {
        key: "setHistoryScrollRestoration",
        value: function setHistoryScrollRestoration(scrollRestoration) {
          if (this.supportScrollRestoration()) {
            /** @type {?} */
            var history = this.window.history;

            if (history && history.scrollRestoration) {
              history.scrollRestoration = scrollRestoration;
            }
          }
        }
        /**
         * @private
         * @param {?} el
         * @return {?}
         */

      }, {
        key: "scrollToElement",
        value: function scrollToElement(el) {
          /** @type {?} */
          var rect = el.getBoundingClientRect();
          /** @type {?} */

          var left = rect.left + this.window.pageXOffset;
          /** @type {?} */

          var top = rect.top + this.window.pageYOffset;
          /** @type {?} */

          var offset = this.offset();
          this.window.scrollTo(left - offset[0], top - offset[1]);
        }
        /**
         * We only support scroll restoration when we can get a hold of window.
         * This means that we do not support this behavior when running in a web worker.
         *
         * Lifting this restriction right now would require more changes in the dom adapter.
         * Since webworkers aren't widely used, we will lift it once RouterScroller is
         * battle-tested.
         * @private
         * @return {?}
         */

      }, {
        key: "supportScrollRestoration",
        value: function supportScrollRestoration() {
          try {
            return !!this.window && !!this.window.scrollTo;
          } catch (_a) {
            return false;
          }
        }
      }]);

      return BrowserViewportScroller;
    }();

    if (false) {}
    /**
     * Provides an empty implementation of the viewport scroller. This will
     * live in \@angular/common as it will be used by both platform-server and platform-webworker.
     */


    var NullViewportScroller = /*#__PURE__*/function () {
      function NullViewportScroller() {
        _classCallCheck(this, NullViewportScroller);
      }

      _createClass2(NullViewportScroller, [{
        key: "setOffset",

        /**
         * Empty implementation
         * @param {?} offset
         * @return {?}
         */
        value: function setOffset(offset) {}
        /**
         * Empty implementation
         * @return {?}
         */

      }, {
        key: "getScrollPosition",
        value: function getScrollPosition() {
          return [0, 0];
        }
        /**
         * Empty implementation
         * @param {?} position
         * @return {?}
         */

      }, {
        key: "scrollToPosition",
        value: function scrollToPosition(position) {}
        /**
         * Empty implementation
         * @param {?} anchor
         * @return {?}
         */

      }, {
        key: "scrollToAnchor",
        value: function scrollToAnchor(anchor) {}
        /**
         * Empty implementation
         * @param {?} scrollRestoration
         * @return {?}
         */

      }, {
        key: "setHistoryScrollRestoration",
        value: function setHistoryScrollRestoration(scrollRestoration) {}
      }]);

      return NullViewportScroller;
    }();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/src/common.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/public_api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=common.js.map

    /***/

  },

  /***/
  "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/http.js":
  /*!********************************************************************!*\
    !*** ./node_modules/@angular/common/__ivy_ngcc__/fesm2015/http.js ***!
    \********************************************************************/

  /*! exports provided: HTTP_INTERCEPTORS, HttpBackend, HttpClient, HttpClientJsonpModule, HttpClientModule, HttpClientXsrfModule, HttpErrorResponse, HttpEventType, HttpHandler, HttpHeaderResponse, HttpHeaders, HttpParams, HttpRequest, HttpResponse, HttpResponseBase, HttpUrlEncodingCodec, HttpXhrBackend, HttpXsrfTokenExtractor, JsonpClientBackend, JsonpInterceptor, XhrFactory, ɵHttpInterceptingHandler, ɵangular_packages_common_http_http_a, ɵangular_packages_common_http_http_b, ɵangular_packages_common_http_http_c, ɵangular_packages_common_http_http_d, ɵangular_packages_common_http_http_e, ɵangular_packages_common_http_http_f, ɵangular_packages_common_http_http_g, ɵangular_packages_common_http_http_h */

  /***/
  function node_modulesAngularCommon__ivy_ngcc__Fesm2015HttpJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HTTP_INTERCEPTORS", function () {
      return HTTP_INTERCEPTORS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HttpBackend", function () {
      return HttpBackend;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HttpClient", function () {
      return HttpClient;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HttpClientJsonpModule", function () {
      return HttpClientJsonpModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HttpClientModule", function () {
      return HttpClientModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HttpClientXsrfModule", function () {
      return HttpClientXsrfModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HttpErrorResponse", function () {
      return HttpErrorResponse;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HttpEventType", function () {
      return HttpEventType;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HttpHandler", function () {
      return HttpHandler;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HttpHeaderResponse", function () {
      return HttpHeaderResponse;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HttpHeaders", function () {
      return HttpHeaders;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HttpParams", function () {
      return HttpParams;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HttpRequest", function () {
      return HttpRequest;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HttpResponse", function () {
      return HttpResponse;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HttpResponseBase", function () {
      return HttpResponseBase;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HttpUrlEncodingCodec", function () {
      return HttpUrlEncodingCodec;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HttpXhrBackend", function () {
      return HttpXhrBackend;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HttpXsrfTokenExtractor", function () {
      return HttpXsrfTokenExtractor;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "JsonpClientBackend", function () {
      return JsonpClientBackend;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "JsonpInterceptor", function () {
      return JsonpInterceptor;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "XhrFactory", function () {
      return XhrFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵHttpInterceptingHandler", function () {
      return HttpInterceptingHandler;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_http_http_a", function () {
      return NoopInterceptor;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_http_http_b", function () {
      return JsonpCallbackContext;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_http_http_c", function () {
      return jsonpCallbackContext;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_http_http_d", function () {
      return BrowserXhr;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_http_http_e", function () {
      return XSRF_COOKIE_NAME;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_http_http_f", function () {
      return XSRF_HEADER_NAME;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_http_http_g", function () {
      return HttpXsrfCookieExtractor;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_common_http_http_h", function () {
      return HttpXsrfInterceptor;
    });
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var rxjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! rxjs */
    "./node_modules/rxjs/_esm2015/index.js");
    /* harmony import */


    var rxjs_operators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! rxjs/operators */
    "./node_modules/rxjs/_esm2015/operators/index.js");
    /* harmony import */


    var _angular_common__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! @angular/common */
    "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/common.js");
    /**
     * @license Angular v9.1.4
     * (c) 2010-2020 Google LLC. https://angular.io/
     * License: MIT
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/http/src/backend.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Transforms an `HttpRequest` into a stream of `HttpEvent`s, one of which will likely be a
     * `HttpResponse`.
     *
     * `HttpHandler` is injectable. When injected, the handler instance dispatches requests to the
     * first interceptor in the chain, which dispatches to the second, etc, eventually reaching the
     * `HttpBackend`.
     *
     * In an `HttpInterceptor`, the `HttpHandler` parameter is the next interceptor in the chain.
     *
     * \@publicApi
     * @abstract
     */


    var HttpHandler = function HttpHandler() {
      _classCallCheck(this, HttpHandler);
    };

    if (false) {}
    /**
     * A final `HttpHandler` which will dispatch the request via browser HTTP APIs to a backend.
     *
     * Interceptors sit between the `HttpClient` interface and the `HttpBackend`.
     *
     * When injected, `HttpBackend` dispatches requests directly to the backend, without going
     * through the interceptor chain.
     *
     * \@publicApi
     * @abstract
     */


    var HttpBackend = function HttpBackend() {
      _classCallCheck(this, HttpBackend);
    };

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/http/src/headers.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * @record
     */


    function Update() {}

    if (false) {}
    /**
     * Represents the header configuration options for an HTTP request.
     * Instances are immutable. Modifying methods return a cloned
     * instance with the change. The original object is never changed.
     *
     * \@publicApi
     */


    var HttpHeaders = /*#__PURE__*/function () {
      /**
       * Constructs a new HTTP header object with the given values.
       * @param {?=} headers
       */
      function HttpHeaders(headers) {
        var _this137 = this;

        _classCallCheck(this, HttpHeaders);

        /**
         * Internal map of lowercased header names to the normalized
         * form of the name (the form seen first).
         */
        this.normalizedNames = new Map();
        /**
         * Queued updates to be materialized the next initialization.
         */

        this.lazyUpdate = null;

        if (!headers) {
          this.headers = new Map();
        } else if (typeof headers === 'string') {
          this.lazyInit =
          /**
          * @return {?}
          */
          function () {
            _this137.headers = new Map();
            headers.split('\n').forEach(
            /**
            * @param {?} line
            * @return {?}
            */
            function (line) {
              /** @type {?} */
              var index = line.indexOf(':');

              if (index > 0) {
                /** @type {?} */
                var name = line.slice(0, index);
                /** @type {?} */

                var key = name.toLowerCase();
                /** @type {?} */

                var value = line.slice(index + 1).trim();

                _this137.maybeSetNormalizedName(name, key);

                if (_this137.headers.has(key)) {
                  /** @type {?} */
                  _this137.headers.get(key).push(value);
                } else {
                  _this137.headers.set(key, [value]);
                }
              }
            });
          };
        } else {
          this.lazyInit =
          /**
          * @return {?}
          */
          function () {
            _this137.headers = new Map();
            Object.keys(headers).forEach(
            /**
            * @param {?} name
            * @return {?}
            */
            function (name) {
              /** @type {?} */
              var values = headers[name];
              /** @type {?} */

              var key = name.toLowerCase();

              if (typeof values === 'string') {
                values = [values];
              }

              if (values.length > 0) {
                _this137.headers.set(key, values);

                _this137.maybeSetNormalizedName(name, key);
              }
            });
          };
        }
      }
      /**
       * Checks for existence of a given header.
       *
       * @param {?} name The header name to check for existence.
       *
       * @return {?} True if the header exists, false otherwise.
       */


      _createClass2(HttpHeaders, [{
        key: "has",
        value: function has(name) {
          this.init();
          return this.headers.has(name.toLowerCase());
        }
        /**
         * Retrieves the first value of a given header.
         *
         * @param {?} name The header name.
         *
         * @return {?} The value string if the header exists, null otherwise
         */

      }, {
        key: "get",
        value: function get(name) {
          this.init();
          /** @type {?} */

          var values = this.headers.get(name.toLowerCase());
          return values && values.length > 0 ? values[0] : null;
        }
        /**
         * Retrieves the names of the headers.
         *
         * @return {?} A list of header names.
         */

      }, {
        key: "keys",
        value: function keys() {
          this.init();
          return Array.from(this.normalizedNames.values());
        }
        /**
         * Retrieves a list of values for a given header.
         *
         * @param {?} name The header name from which to retrieve values.
         *
         * @return {?} A string of values if the header exists, null otherwise.
         */

      }, {
        key: "getAll",
        value: function getAll(name) {
          this.init();
          return this.headers.get(name.toLowerCase()) || null;
        }
        /**
         * Appends a new value to the existing set of values for a header
         * and returns them in a clone of the original instance.
         *
         * @param {?} name The header name for which to append the values.
         * @param {?} value The value to append.
         *
         * @return {?} A clone of the HTTP headers object with the value appended to the given header.
         */

      }, {
        key: "append",
        value: function append(name, value) {
          return this.clone({
            name: name,
            value: value,
            op: 'a'
          });
        }
        /**
         * Sets or modifies a value for a given header in a clone of the original instance.
         * If the header already exists, its value is replaced with the given value
         * in the returned object.
         *
         * @param {?} name The header name.
         * @param {?} value The value or values to set or overide for the given header.
         *
         * @return {?} A clone of the HTTP headers object with the newly set header value.
         */

      }, {
        key: "set",
        value: function set(name, value) {
          return this.clone({
            name: name,
            value: value,
            op: 's'
          });
        }
        /**
         * Deletes values for a given header in a clone of the original instance.
         *
         * @param {?} name The header name.
         * @param {?=} value The value or values to delete for the given header.
         *
         * @return {?} A clone of the HTTP headers object with the given value deleted.
         */

      }, {
        key: "delete",
        value: function _delete(name, value) {
          return this.clone({
            name: name,
            value: value,
            op: 'd'
          });
        }
        /**
         * @private
         * @param {?} name
         * @param {?} lcName
         * @return {?}
         */

      }, {
        key: "maybeSetNormalizedName",
        value: function maybeSetNormalizedName(name, lcName) {
          if (!this.normalizedNames.has(lcName)) {
            this.normalizedNames.set(lcName, name);
          }
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "init",
        value: function init() {
          var _this138 = this;

          if (!!this.lazyInit) {
            if (this.lazyInit instanceof HttpHeaders) {
              this.copyFrom(this.lazyInit);
            } else {
              this.lazyInit();
            }

            this.lazyInit = null;

            if (!!this.lazyUpdate) {
              this.lazyUpdate.forEach(
              /**
              * @param {?} update
              * @return {?}
              */
              function (update) {
                return _this138.applyUpdate(update);
              });
              this.lazyUpdate = null;
            }
          }
        }
        /**
         * @private
         * @param {?} other
         * @return {?}
         */

      }, {
        key: "copyFrom",
        value: function copyFrom(other) {
          var _this139 = this;

          other.init();
          Array.from(other.headers.keys()).forEach(
          /**
          * @param {?} key
          * @return {?}
          */
          function (key) {
            _this139.headers.set(key,
            /** @type {?} */
            other.headers.get(key));

            _this139.normalizedNames.set(key,
            /** @type {?} */
            other.normalizedNames.get(key));
          });
        }
        /**
         * @private
         * @param {?} update
         * @return {?}
         */

      }, {
        key: "clone",
        value: function clone(update) {
          /** @type {?} */
          var clone = new HttpHeaders();
          clone.lazyInit = !!this.lazyInit && this.lazyInit instanceof HttpHeaders ? this.lazyInit : this;
          clone.lazyUpdate = (this.lazyUpdate || []).concat([update]);
          return clone;
        }
        /**
         * @private
         * @param {?} update
         * @return {?}
         */

      }, {
        key: "applyUpdate",
        value: function applyUpdate(update) {
          /** @type {?} */
          var key = update.name.toLowerCase();

          switch (update.op) {
            case 'a':
            case 's':
              /** @type {?} */
              var value =
              /** @type {?} */
              update.value;

              if (typeof value === 'string') {
                value = [value];
              }

              if (value.length === 0) {
                return;
              }

              this.maybeSetNormalizedName(update.name, key);
              /** @type {?} */

              var base = (update.op === 'a' ? this.headers.get(key) : undefined) || [];
              base.push.apply(base, _toConsumableArray(value));
              this.headers.set(key, base);
              break;

            case 'd':
              /** @type {?} */
              var toDelete =
              /** @type {?} */
              update.value;

              if (!toDelete) {
                this.headers["delete"](key);
                this.normalizedNames["delete"](key);
              } else {
                /** @type {?} */
                var existing = this.headers.get(key);

                if (!existing) {
                  return;
                }

                existing = existing.filter(
                /**
                * @param {?} value
                * @return {?}
                */
                function (value) {
                  return toDelete.indexOf(value) === -1;
                });

                if (existing.length === 0) {
                  this.headers["delete"](key);
                  this.normalizedNames["delete"](key);
                } else {
                  this.headers.set(key, existing);
                }
              }

              break;
          }
        }
        /**
         * \@internal
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "forEach",
        value: function forEach(fn) {
          var _this140 = this;

          this.init();
          Array.from(this.normalizedNames.keys()).forEach(
          /**
          * @param {?} key
          * @return {?}
          */
          function (key) {
            return fn(
            /** @type {?} */
            _this140.normalizedNames.get(key),
            /** @type {?} */
            _this140.headers.get(key));
          });
        }
      }]);

      return HttpHeaders;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/http/src/params.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * A codec for encoding and decoding parameters in URLs.
     *
     * Used by `HttpParams`.
     *
     * \@publicApi
     *
     * @record
     */


    function HttpParameterCodec() {}

    if (false) {}
    /**
     * Provides encoding and decoding of URL parameter and query-string values.
     *
     * Serializes and parses URL parameter keys and values to encode and decode them.
     * If you pass URL query parameters without encoding,
     * the query parameters can be misinterpreted at the receiving end.
     *
     *
     * \@publicApi
     */


    var HttpUrlEncodingCodec = /*#__PURE__*/function () {
      function HttpUrlEncodingCodec() {
        _classCallCheck(this, HttpUrlEncodingCodec);
      }

      _createClass2(HttpUrlEncodingCodec, [{
        key: "encodeKey",

        /**
         * Encodes a key name for a URL parameter or query-string.
         * @param {?} key The key name.
         * @return {?} The encoded key name.
         */
        value: function encodeKey(key) {
          return standardEncoding(key);
        }
        /**
         * Encodes the value of a URL parameter or query-string.
         * @param {?} value The value.
         * @return {?} The encoded value.
         */

      }, {
        key: "encodeValue",
        value: function encodeValue(value) {
          return standardEncoding(value);
        }
        /**
         * Decodes an encoded URL parameter or query-string key.
         * @param {?} key The encoded key name.
         * @return {?} The decoded key name.
         */

      }, {
        key: "decodeKey",
        value: function decodeKey(key) {
          return decodeURIComponent(key);
        }
        /**
         * Decodes an encoded URL parameter or query-string value.
         * @param {?} value The encoded value.
         * @return {?} The decoded value.
         */

      }, {
        key: "decodeValue",
        value: function decodeValue(value) {
          return decodeURIComponent(value);
        }
      }]);

      return HttpUrlEncodingCodec;
    }();
    /**
     * @param {?} rawParams
     * @param {?} codec
     * @return {?}
     */


    function paramParser(rawParams, codec) {
      /** @type {?} */
      var map = new Map();

      if (rawParams.length > 0) {
        /** @type {?} */
        var params = rawParams.split('&');
        params.forEach(
        /**
        * @param {?} param
        * @return {?}
        */
        function (param) {
          /** @type {?} */
          var eqIdx = param.indexOf('=');

          var _ref6 = eqIdx == -1 ? [codec.decodeKey(param), ''] : [codec.decodeKey(param.slice(0, eqIdx)), codec.decodeValue(param.slice(eqIdx + 1))],
              _ref7 = _slicedToArray(_ref6, 2),
              key = _ref7[0],
              val = _ref7[1];
          /** @type {?} */


          var list = map.get(key) || [];
          list.push(val);
          map.set(key, list);
        });
      }

      return map;
    }
    /**
     * @param {?} v
     * @return {?}
     */


    function standardEncoding(v) {
      return encodeURIComponent(v).replace(/%40/gi, '@').replace(/%3A/gi, ':').replace(/%24/gi, '$').replace(/%2C/gi, ',').replace(/%3B/gi, ';').replace(/%2B/gi, '+').replace(/%3D/gi, '=').replace(/%3F/gi, '?').replace(/%2F/gi, '/');
    }
    /**
     * @record
     */


    function Update$1() {}

    if (false) {}
    /**
     * Options used to construct an `HttpParams` instance.
     *
     * \@publicApi
     * @record
     */


    function HttpParamsOptions() {}

    if (false) {}
    /**
     * An HTTP request/response body that represents serialized parameters,
     * per the MIME type `application/x-www-form-urlencoded`.
     *
     * This class is immutable; all mutation operations return a new instance.
     *
     * \@publicApi
     */


    var HttpParams = /*#__PURE__*/function () {
      /**
       * @param {?=} options
       */
      function HttpParams() {
        var _this141 = this;

        var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] :
        /** @type {?} */
        {};

        _classCallCheck(this, HttpParams);

        this.updates = null;
        this.cloneFrom = null;
        this.encoder = options.encoder || new HttpUrlEncodingCodec();

        if (!!options.fromString) {
          if (!!options.fromObject) {
            throw new Error("Cannot specify both fromString and fromObject.");
          }

          this.map = paramParser(options.fromString, this.encoder);
        } else if (!!options.fromObject) {
          this.map = new Map();
          Object.keys(options.fromObject).forEach(
          /**
          * @param {?} key
          * @return {?}
          */
          function (key) {
            /** @type {?} */
            var value =
            /** @type {?} */
            options.fromObject[key];

            /** @type {?} */
            _this141.map.set(key, Array.isArray(value) ? value : [value]);
          });
        } else {
          this.map = null;
        }
      }
      /**
       * Reports whether the body includes one or more values for a given parameter.
       * @param {?} param The parameter name.
       * @return {?} True if the parameter has one or more values,
       * false if it has no value or is not present.
       */


      _createClass2(HttpParams, [{
        key: "has",
        value: function has(param) {
          this.init();
          return (
            /** @type {?} */
            this.map.has(param)
          );
        }
        /**
         * Retrieves the first value for a parameter.
         * @param {?} param The parameter name.
         * @return {?} The first value of the given parameter,
         * or `null` if the parameter is not present.
         */

      }, {
        key: "get",
        value: function get(param) {
          this.init();
          /** @type {?} */

          var res =
          /** @type {?} */
          this.map.get(param);
          return !!res ? res[0] : null;
        }
        /**
         * Retrieves all values for a  parameter.
         * @param {?} param The parameter name.
         * @return {?} All values in a string array,
         * or `null` if the parameter not present.
         */

      }, {
        key: "getAll",
        value: function getAll(param) {
          this.init();
          return (
            /** @type {?} */
            this.map.get(param) || null
          );
        }
        /**
         * Retrieves all the parameters for this body.
         * @return {?} The parameter names in a string array.
         */

      }, {
        key: "keys",
        value: function keys() {
          this.init();
          return Array.from(
          /** @type {?} */
          this.map.keys());
        }
        /**
         * Appends a new value to existing values for a parameter.
         * @param {?} param The parameter name.
         * @param {?} value The new value to add.
         * @return {?} A new body with the appended value.
         */

      }, {
        key: "append",
        value: function append(param, value) {
          return this.clone({
            param: param,
            value: value,
            op: 'a'
          });
        }
        /**
         * Replaces the value for a parameter.
         * @param {?} param The parameter name.
         * @param {?} value The new value.
         * @return {?} A new body with the new value.
         */

      }, {
        key: "set",
        value: function set(param, value) {
          return this.clone({
            param: param,
            value: value,
            op: 's'
          });
        }
        /**
         * Removes a given value or all values from a parameter.
         * @param {?} param The parameter name.
         * @param {?=} value The value to remove, if provided.
         * @return {?} A new body with the given value removed, or with all values
         * removed if no value is specified.
         */

      }, {
        key: "delete",
        value: function _delete(param, value) {
          return this.clone({
            param: param,
            value: value,
            op: 'd'
          });
        }
        /**
         * Serializes the body to an encoded string, where key-value pairs (separated by `=`) are
         * separated by `&`s.
         * @return {?}
         */

      }, {
        key: "toString",
        value: function toString() {
          var _this142 = this;

          this.init();
          return this.keys().map(
          /**
          * @param {?} key
          * @return {?}
          */
          function (key) {
            /** @type {?} */
            var eKey = _this142.encoder.encodeKey(key); // `a: ['1']` produces `'a=1'`
            // `b: []` produces `''`
            // `c: ['1', '2']` produces `'c=1&c=2'`


            return (
              /** @type {?} */

              /** @type {?} */
              _this142.map.get(key).map(
              /**
              * @param {?} value
              * @return {?}
              */
              function (value) {
                return eKey + '=' + _this142.encoder.encodeValue(value);
              }).join('&')
            );
          }) // filter out empty values because `b: []` produces `''`
          // which results in `a=1&&c=1&c=2` instead of `a=1&c=1&c=2` if we don't
          .filter(
          /**
          * @param {?} param
          * @return {?}
          */
          function (param) {
            return param !== '';
          }).join('&');
        }
        /**
         * @private
         * @param {?} update
         * @return {?}
         */

      }, {
        key: "clone",
        value: function clone(update) {
          /** @type {?} */
          var clone = new HttpParams(
          /** @type {?} */
          {
            encoder: this.encoder
          });
          clone.cloneFrom = this.cloneFrom || this;
          clone.updates = (this.updates || []).concat([update]);
          return clone;
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "init",
        value: function init() {
          var _this143 = this;

          if (this.map === null) {
            this.map = new Map();
          }

          if (this.cloneFrom !== null) {
            this.cloneFrom.init();
            this.cloneFrom.keys().forEach(
            /**
            * @param {?} key
            * @return {?}
            */
            function (key) {
              return (
                /** @type {?} */
                _this143.map.set(key,
                /** @type {?} */

                /** @type {?} */

                /** @type {?} */
                _this143.cloneFrom.map.get(key))
              );
            });

            /** @type {?} */
            this.updates.forEach(
            /**
            * @param {?} update
            * @return {?}
            */
            function (update) {
              switch (update.op) {
                case 'a':
                case 's':
                  /** @type {?} */
                  var base = (update.op === 'a' ?
                  /** @type {?} */
                  _this143.map.get(update.param) : undefined) || [];
                  base.push(
                  /** @type {?} */
                  update.value);

                  /** @type {?} */
                  _this143.map.set(update.param, base);

                  break;

                case 'd':
                  if (update.value !== undefined) {
                    /** @type {?} */
                    var _base =
                    /** @type {?} */
                    _this143.map.get(update.param) || [];
                    /** @type {?} */


                    var idx = _base.indexOf(update.value);

                    if (idx !== -1) {
                      _base.splice(idx, 1);
                    }

                    if (_base.length > 0) {
                      /** @type {?} */
                      _this143.map.set(update.param, _base);
                    } else {
                      /** @type {?} */
                      _this143.map["delete"](update.param);
                    }
                  } else {
                    /** @type {?} */
                    _this143.map["delete"](update.param);

                    break;
                  }

              }
            });
            this.cloneFrom = this.updates = null;
          }
        }
      }]);

      return HttpParams;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/http/src/request.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Construction interface for `HttpRequest`s.
     *
     * All values are optional and will override default values if provided.
     * @record
     */


    function HttpRequestInit() {}

    if (false) {}
    /**
     * Determine whether the given HTTP method may include a body.
     * @param {?} method
     * @return {?}
     */


    function mightHaveBody(method) {
      switch (method) {
        case 'DELETE':
        case 'GET':
        case 'HEAD':
        case 'OPTIONS':
        case 'JSONP':
          return false;

        default:
          return true;
      }
    }
    /**
     * Safely assert whether the given value is an ArrayBuffer.
     *
     * In some execution environments ArrayBuffer is not defined.
     * @param {?} value
     * @return {?}
     */


    function isArrayBuffer(value) {
      return typeof ArrayBuffer !== 'undefined' && value instanceof ArrayBuffer;
    }
    /**
     * Safely assert whether the given value is a Blob.
     *
     * In some execution environments Blob is not defined.
     * @param {?} value
     * @return {?}
     */


    function isBlob(value) {
      return typeof Blob !== 'undefined' && value instanceof Blob;
    }
    /**
     * Safely assert whether the given value is a FormData instance.
     *
     * In some execution environments FormData is not defined.
     * @param {?} value
     * @return {?}
     */


    function isFormData(value) {
      return typeof FormData !== 'undefined' && value instanceof FormData;
    }
    /**
     * An outgoing HTTP request with an optional typed body.
     *
     * `HttpRequest` represents an outgoing request, including URL, method,
     * headers, body, and other request configuration options. Instances should be
     * assumed to be immutable. To modify a `HttpRequest`, the `clone`
     * method should be used.
     *
     * \@publicApi
     * @template T
     */


    var HttpRequest = /*#__PURE__*/function () {
      /**
       * @param {?} method
       * @param {?} url
       * @param {?=} third
       * @param {?=} fourth
       */
      function HttpRequest(method, url, third, fourth) {
        _classCallCheck(this, HttpRequest);

        this.url = url;
        /**
         * The request body, or `null` if one isn't set.
         *
         * Bodies are not enforced to be immutable, as they can include a reference to any
         * user-defined data type. However, interceptors should take care to preserve
         * idempotence by treating them as such.
         */

        this.body = null;
        /**
         * Whether this request should be made in a way that exposes progress events.
         *
         * Progress events are expensive (change detection runs on each event) and so
         * they should only be requested if the consumer intends to monitor them.
         */

        this.reportProgress = false;
        /**
         * Whether this request should be sent with outgoing credentials (cookies).
         */

        this.withCredentials = false;
        /**
         * The expected response type of the server.
         *
         * This is used to parse the response appropriately before returning it to
         * the requestee.
         */

        this.responseType = 'json';
        this.method = method.toUpperCase(); // Next, need to figure out which argument holds the HttpRequestInit
        // options, if any.

        /** @type {?} */

        var options; // Check whether a body argument is expected. The only valid way to omit
        // the body argument is to use a known no-body method like GET.

        if (mightHaveBody(this.method) || !!fourth) {
          // Body is the third argument, options are the fourth.
          this.body = third !== undefined ?
          /** @type {?} */
          third : null;
          options = fourth;
        } else {
          // No body required, options are the third argument. The body stays null.
          options =
          /** @type {?} */
          third;
        } // If options have been passed, interpret them.


        if (options) {
          // Normalize reportProgress and withCredentials.
          this.reportProgress = !!options.reportProgress;
          this.withCredentials = !!options.withCredentials; // Override default response type of 'json' if one is provided.

          if (!!options.responseType) {
            this.responseType = options.responseType;
          } // Override headers if they're provided.


          if (!!options.headers) {
            this.headers = options.headers;
          }

          if (!!options.params) {
            this.params = options.params;
          }
        } // If no headers have been passed in, construct a new HttpHeaders instance.


        if (!this.headers) {
          this.headers = new HttpHeaders();
        } // If no parameters have been passed in, construct a new HttpUrlEncodedParams instance.


        if (!this.params) {
          this.params = new HttpParams();
          this.urlWithParams = url;
        } else {
          // Encode the parameters to a string in preparation for inclusion in the URL.

          /** @type {?} */
          var params = this.params.toString();

          if (params.length === 0) {
            // No parameters, the visible URL is just the URL given at creation time.
            this.urlWithParams = url;
          } else {
            // Does the URL already have query parameters? Look for '?'.

            /** @type {?} */
            var qIdx = url.indexOf('?'); // There are 3 cases to handle:
            // 1) No existing parameters -> append '?' followed by params.
            // 2) '?' exists and is followed by existing query string ->
            //    append '&' followed by params.
            // 3) '?' exists at the end of the url -> append params directly.
            // This basically amounts to determining the character, if any, with
            // which to join the URL and parameters.

            /** @type {?} */

            var sep = qIdx === -1 ? '?' : qIdx < url.length - 1 ? '&' : '';
            this.urlWithParams = url + sep + params;
          }
        }
      }
      /**
       * Transform the free-form body into a serialized format suitable for
       * transmission to the server.
       * @return {?}
       */


      _createClass2(HttpRequest, [{
        key: "serializeBody",
        value: function serializeBody() {
          // If no body is present, no need to serialize it.
          if (this.body === null) {
            return null;
          } // Check whether the body is already in a serialized form. If so,
          // it can just be returned directly.


          if (isArrayBuffer(this.body) || isBlob(this.body) || isFormData(this.body) || typeof this.body === 'string') {
            return this.body;
          } // Check whether the body is an instance of HttpUrlEncodedParams.


          if (this.body instanceof HttpParams) {
            return this.body.toString();
          } // Check whether the body is an object or array, and serialize with JSON if so.


          if (typeof this.body === 'object' || typeof this.body === 'boolean' || Array.isArray(this.body)) {
            return JSON.stringify(this.body);
          } // Fall back on toString() for everything else.


          return (
            /** @type {?} */
            this.body.toString()
          );
        }
        /**
         * Examine the body and attempt to infer an appropriate MIME type
         * for it.
         *
         * If no such type can be inferred, this method will return `null`.
         * @return {?}
         */

      }, {
        key: "detectContentTypeHeader",
        value: function detectContentTypeHeader() {
          // An empty body has no content type.
          if (this.body === null) {
            return null;
          } // FormData bodies rely on the browser's content type assignment.


          if (isFormData(this.body)) {
            return null;
          } // Blobs usually have their own content type. If it doesn't, then
          // no type can be inferred.


          if (isBlob(this.body)) {
            return this.body.type || null;
          } // Array buffers have unknown contents and thus no type can be inferred.


          if (isArrayBuffer(this.body)) {
            return null;
          } // Technically, strings could be a form of JSON data, but it's safe enough
          // to assume they're plain strings.


          if (typeof this.body === 'string') {
            return 'text/plain';
          } // `HttpUrlEncodedParams` has its own content-type.


          if (this.body instanceof HttpParams) {
            return 'application/x-www-form-urlencoded;charset=UTF-8';
          } // Arrays, objects, and numbers will be encoded as JSON.


          if (typeof this.body === 'object' || typeof this.body === 'number' || Array.isArray(this.body)) {
            return 'application/json';
          } // No type could be inferred.


          return null;
        }
        /**
         * @param {?=} update
         * @return {?}
         */

      }, {
        key: "clone",
        value: function clone() {
          var update = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
          // For method, url, and responseType, take the current value unless
          // it is overridden in the update hash.

          /** @type {?} */
          var method = update.method || this.method;
          /** @type {?} */

          var url = update.url || this.url;
          /** @type {?} */

          var responseType = update.responseType || this.responseType; // The body is somewhat special - a `null` value in update.body means
          // whatever current body is present is being overridden with an empty
          // body, whereas an `undefined` value in update.body implies no
          // override.

          /** @type {?} */

          var body = update.body !== undefined ? update.body : this.body; // Carefully handle the boolean options to differentiate between
          // `false` and `undefined` in the update args.

          /** @type {?} */

          var withCredentials = update.withCredentials !== undefined ? update.withCredentials : this.withCredentials;
          /** @type {?} */

          var reportProgress = update.reportProgress !== undefined ? update.reportProgress : this.reportProgress; // Headers and params may be appended to if `setHeaders` or
          // `setParams` are used.

          /** @type {?} */

          var headers = update.headers || this.headers;
          /** @type {?} */

          var params = update.params || this.params; // Check whether the caller has asked to add headers.

          if (update.setHeaders !== undefined) {
            // Set every requested header.
            headers = Object.keys(update.setHeaders).reduce(
            /**
            * @param {?} headers
            * @param {?} name
            * @return {?}
            */
            function (headers, name) {
              return headers.set(name,
              /** @type {?} */
              update.setHeaders[name]);
            }, headers);
          } // Check whether the caller has asked to set params.


          if (update.setParams) {
            // Set every requested param.
            params = Object.keys(update.setParams).reduce(
            /**
            * @param {?} params
            * @param {?} param
            * @return {?}
            */
            function (params, param) {
              return params.set(param,
              /** @type {?} */
              update.setParams[param]);
            }, params);
          } // Finally, construct the new HttpRequest using the pieces from above.


          return new HttpRequest(method, url, body, {
            params: params,
            headers: headers,
            reportProgress: reportProgress,
            responseType: responseType,
            withCredentials: withCredentials
          });
        }
      }]);

      return HttpRequest;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/http/src/response.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @enum {number} */


    var HttpEventType = {
      /**
       * The request was sent out over the wire.
       */
      Sent: 0,

      /**
       * An upload progress event was received.
       */
      UploadProgress: 1,

      /**
       * The response status code and headers were received.
       */
      ResponseHeader: 2,

      /**
       * A download progress event was received.
       */
      DownloadProgress: 3,

      /**
       * The full response including the body was received.
       */
      Response: 4,

      /**
       * A custom event from an interceptor or a backend.
       */
      User: 5
    };
    HttpEventType[HttpEventType.Sent] = 'Sent';
    HttpEventType[HttpEventType.UploadProgress] = 'UploadProgress';
    HttpEventType[HttpEventType.ResponseHeader] = 'ResponseHeader';
    HttpEventType[HttpEventType.DownloadProgress] = 'DownloadProgress';
    HttpEventType[HttpEventType.Response] = 'Response';
    HttpEventType[HttpEventType.User] = 'User';
    /**
     * Base interface for progress events.
     *
     * \@publicApi
     * @record
     */

    function HttpProgressEvent() {}

    if (false) {}
    /**
     * A download progress event.
     *
     * \@publicApi
     * @record
     */


    function HttpDownloadProgressEvent() {}

    if (false) {}
    /**
     * An upload progress event.
     *
     * \@publicApi
     * @record
     */


    function HttpUploadProgressEvent() {}

    if (false) {}
    /**
     * An event indicating that the request was sent to the server. Useful
     * when a request may be retried multiple times, to distinguish between
     * retries on the final event stream.
     *
     * \@publicApi
     * @record
     */


    function HttpSentEvent() {}

    if (false) {}
    /**
     * A user-defined event.
     *
     * Grouping all custom events under this type ensures they will be handled
     * and forwarded by all implementations of interceptors.
     *
     * \@publicApi
     * @record
     * @template T
     */


    function HttpUserEvent() {}

    if (false) {}
    /**
     * An error that represents a failed attempt to JSON.parse text coming back
     * from the server.
     *
     * It bundles the Error object with the actual response body that failed to parse.
     *
     *
     * @record
     */


    function HttpJsonParseError() {}

    if (false) {}
    /**
     * Base class for both `HttpResponse` and `HttpHeaderResponse`.
     *
     * \@publicApi
     * @abstract
     */


    var HttpResponseBase =
    /**
     * Super-constructor for all responses.
     *
     * The single parameter accepted is an initialization hash. Any properties
     * of the response passed there will override the default values.
     * @param {?} init
     * @param {?=} defaultStatus
     * @param {?=} defaultStatusText
     */
    function HttpResponseBase(init) {
      var defaultStatus = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 200;
      var defaultStatusText = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 'OK';

      _classCallCheck(this, HttpResponseBase);

      // If the hash has values passed, use them to initialize the response.
      // Otherwise use the default values.
      this.headers = init.headers || new HttpHeaders();
      this.status = init.status !== undefined ? init.status : defaultStatus;
      this.statusText = init.statusText || defaultStatusText;
      this.url = init.url || null; // Cache the ok value to avoid defining a getter.

      this.ok = this.status >= 200 && this.status < 300;
    };

    if (false) {}
    /**
     * A partial HTTP response which only includes the status and header data,
     * but no response body.
     *
     * `HttpHeaderResponse` is a `HttpEvent` available on the response
     * event stream, only when progress events are requested.
     *
     * \@publicApi
     */


    var HttpHeaderResponse = /*#__PURE__*/function (_HttpResponseBase) {
      _inherits(HttpHeaderResponse, _HttpResponseBase);

      var _super24 = _createSuper(HttpHeaderResponse);

      /**
       * Create a new `HttpHeaderResponse` with the given parameters.
       * @param {?=} init
       */
      function HttpHeaderResponse() {
        var _this144;

        var init = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};

        _classCallCheck(this, HttpHeaderResponse);

        _this144 = _super24.call(this, init);
        _this144.type = HttpEventType.ResponseHeader;
        return _this144;
      }
      /**
       * Copy this `HttpHeaderResponse`, overriding its contents with the
       * given parameter hash.
       * @param {?=} update
       * @return {?}
       */


      _createClass2(HttpHeaderResponse, [{
        key: "clone",
        value: function clone() {
          var update = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
          // Perform a straightforward initialization of the new HttpHeaderResponse,
          // overriding the current parameters with new ones if given.
          return new HttpHeaderResponse({
            headers: update.headers || this.headers,
            status: update.status !== undefined ? update.status : this.status,
            statusText: update.statusText || this.statusText,
            url: update.url || this.url || undefined
          });
        }
      }]);

      return HttpHeaderResponse;
    }(HttpResponseBase);

    if (false) {}
    /**
     * A full HTTP response, including a typed response body (which may be `null`
     * if one was not returned).
     *
     * `HttpResponse` is a `HttpEvent` available on the response event
     * stream.
     *
     * \@publicApi
     * @template T
     */


    var HttpResponse = /*#__PURE__*/function (_HttpResponseBase2) {
      _inherits(HttpResponse, _HttpResponseBase2);

      var _super25 = _createSuper(HttpResponse);

      /**
       * Construct a new `HttpResponse`.
       * @param {?=} init
       */
      function HttpResponse() {
        var _this145;

        var init = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};

        _classCallCheck(this, HttpResponse);

        _this145 = _super25.call(this, init);
        _this145.type = HttpEventType.Response;
        _this145.body = init.body !== undefined ? init.body : null;
        return _this145;
      }
      /**
       * @param {?=} update
       * @return {?}
       */


      _createClass2(HttpResponse, [{
        key: "clone",
        value: function clone() {
          var update = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
          return new HttpResponse({
            body: update.body !== undefined ? update.body : this.body,
            headers: update.headers || this.headers,
            status: update.status !== undefined ? update.status : this.status,
            statusText: update.statusText || this.statusText,
            url: update.url || this.url || undefined
          });
        }
      }]);

      return HttpResponse;
    }(HttpResponseBase);

    if (false) {}
    /**
     * A response that represents an error or failure, either from a
     * non-successful HTTP status, an error while executing the request,
     * or some other failure which occurred during the parsing of the response.
     *
     * Any error returned on the `Observable` response stream will be
     * wrapped in an `HttpErrorResponse` to provide additional context about
     * the state of the HTTP layer when the error occurred. The error property
     * will contain either a wrapped Error object or the error response returned
     * from the server.
     *
     * \@publicApi
     */


    var HttpErrorResponse = /*#__PURE__*/function (_HttpResponseBase3) {
      _inherits(HttpErrorResponse, _HttpResponseBase3);

      var _super26 = _createSuper(HttpErrorResponse);

      /**
       * @param {?} init
       */
      function HttpErrorResponse(init) {
        var _this146;

        _classCallCheck(this, HttpErrorResponse);

        // Initialize with a default status of 0 / Unknown Error.
        _this146 = _super26.call(this, init, 0, 'Unknown Error');
        _this146.name = 'HttpErrorResponse';
        /**
         * Errors are never okay, even when the status code is in the 2xx success range.
         */

        _this146.ok = false; // If the response was successful, then this was a parse error. Otherwise, it was
        // a protocol-level failure of some sort. Either the request failed in transit
        // or the server returned an unsuccessful status code.

        if (_this146.status >= 200 && _this146.status < 300) {
          _this146.message = "Http failure during parsing for ".concat(init.url || '(unknown url)');
        } else {
          _this146.message = "Http failure response for ".concat(init.url || '(unknown url)', ": ").concat(init.status, " ").concat(init.statusText);
        }

        _this146.error = init.error || null;
        return _this146;
      }

      return HttpErrorResponse;
    }(HttpResponseBase);

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/http/src/client.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Constructs an instance of `HttpRequestOptions<T>` from a source `HttpMethodOptions` and
     * the given `body`. This function clones the object and adds the body.
     *
     * Note that the `responseType` *options* value is a String that identifies the
     * single data type of the response.
     * A single overload version of the method handles each response type.
     * The value of `responseType` cannot be a union, as the combined signature could imply.
     *
     * @template T
     * @param {?} options
     * @param {?} body
     * @return {?}
     */


    function addBody(options, body) {
      return {
        body: body,
        headers: options.headers,
        observe: options.observe,
        params: options.params,
        reportProgress: options.reportProgress,
        responseType: options.responseType,
        withCredentials: options.withCredentials
      };
    }
    /**
     * Performs HTTP requests.
     * This service is available as an injectable class, with methods to perform HTTP requests.
     * Each request method has multiple signatures, and the return type varies based on
     * the signature that is called (mainly the values of `observe` and `responseType`).
     *
     * Note that the `responseType` *options* value is a String that identifies the
     * single data type of the response.
     * A single overload version of the method handles each response type.
     * The value of `responseType` cannot be a union, as the combined signature could imply.
     *
     * \@usageNotes
     * Sample HTTP requests for the [Tour of Heroes](/tutorial/toh-pt0) application.
     *
     * ### HTTP Request Example
     *
     * ```
     *  // GET heroes whose name contains search term
     * searchHeroes(term: string): observable<Hero[]>{
     *
     *  const params = new HttpParams({fromString: 'name=term'});
     *    return this.httpClient.request('GET', this.heroesUrl, {responseType:'json', params});
     * }
     * ```
     * ### JSONP Example
     * ```
     * requestJsonp(url, callback = 'callback') {
     *  return this.httpClient.jsonp(this.heroesURL, callback);
     * }
     * ```
     *
     * ### PATCH Example
     * ```
     * // PATCH one of the heroes' name
     * patchHero (id: number, heroName: string): Observable<{}> {
     * const url = `${this.heroesUrl}/${id}`;   // PATCH api/heroes/42
     *  return this.httpClient.patch(url, {name: heroName}, httpOptions)
     *    .pipe(catchError(this.handleError('patchHero')));
     * }
     * ```
     *
     * @see [HTTP Guide](guide/http)
     *
     * \@publicApi
     */


    var HttpClient = /*#__PURE__*/function () {
      /**
       * @param {?} handler
       */
      function HttpClient(handler) {
        _classCallCheck(this, HttpClient);

        this.handler = handler;
      }
      /**
       * Constructs an observable for a generic HTTP request that, when subscribed,
       * fires the request through the chain of registered interceptors and on to the
       * server.
       *
       * You can pass an `HttpRequest` directly as the only parameter. In this case,
       * the call returns an observable of the raw `HttpEvent` stream.
       *
       * Alternatively you can pass an HTTP method as the first parameter,
       * a URL string as the second, and an options hash containing the request body as the third.
       * See `addBody()`. In this case, the specified `responseType` and `observe` options determine the
       * type of returned observable.
       *   * The `responseType` value determines how a successful response body is parsed.
       *   * If `responseType` is the default `json`, you can pass a type interface for the resulting
       * object as a type parameter to the call.
       *
       * The `observe` value determines the return type, according to what you are interested in
       * observing.
       *   * An `observe` value of events returns an observable of the raw `HttpEvent` stream, including
       * progress events by default.
       *   * An `observe` value of response returns an observable of `HttpResponse<T>`,
       * where the `T` parameter depends on the `responseType` and any optionally provided type
       * parameter.
       *   * An `observe` value of body returns an observable of `<T>` with the same `T` body type.
       *
       * @param {?} first
       * @param {?=} url
       * @param {?=} options
       * @return {?}
       */


      _createClass2(HttpClient, [{
        key: "request",
        value: function request(first, url) {
          var _this147 = this;

          var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};

          /** @type {?} */
          var req; // First, check whether the primary argument is an instance of `HttpRequest`.

          if (first instanceof HttpRequest) {
            // It is. The other arguments must be undefined (per the signatures) and can be
            // ignored.
            req = first;
          } else {
            // It's a string, so it represents a URL. Construct a request based on it,
            // and incorporate the remaining arguments (assuming `GET` unless a method is
            // provided.
            // Figure out the headers.

            /** @type {?} */
            var headers = undefined;

            if (options.headers instanceof HttpHeaders) {
              headers = options.headers;
            } else {
              headers = new HttpHeaders(options.headers);
            } // Sort out parameters.

            /** @type {?} */


            var params = undefined;

            if (!!options.params) {
              if (options.params instanceof HttpParams) {
                params = options.params;
              } else {
                params = new HttpParams(
                /** @type {?} */
                {
                  fromObject: options.params
                });
              }
            } // Construct the request.


            req = new HttpRequest(first,
            /** @type {?} */
            url, options.body !== undefined ? options.body : null, {
              headers: headers,
              params: params,
              reportProgress: options.reportProgress,
              // By default, JSON is assumed to be returned for all calls.
              responseType: options.responseType || 'json',
              withCredentials: options.withCredentials
            });
          } // Start with an Observable.of() the initial request, and run the handler (which
          // includes all interceptors) inside a concatMap(). This way, the handler runs
          // inside an Observable chain, which causes interceptors to be re-run on every
          // subscription (this also makes retries re-run the handler, including interceptors).

          /** @type {?} */


          var events$ = Object(rxjs__WEBPACK_IMPORTED_MODULE_1__["of"])(req).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_2__["concatMap"])(
          /**
          * @param {?} req
          * @return {?}
          */
          function (req) {
            return _this147.handler.handle(req);
          })); // If coming via the API signature which accepts a previously constructed HttpRequest,
          // the only option is to get the event stream. Otherwise, return the event stream if
          // that is what was requested.

          if (first instanceof HttpRequest || options.observe === 'events') {
            return events$;
          } // The requested stream contains either the full response or the body. In either
          // case, the first step is to filter the event stream to extract a stream of
          // responses(s).

          /** @type {?} */


          var res$ =
          /** @type {?} */
          events$.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_2__["filter"])(
          /**
          * @param {?} event
          * @return {?}
          */
          function (event) {
            return event instanceof HttpResponse;
          })); // Decide which stream to return.

          switch (options.observe || 'body') {
            case 'body':
              // The requested stream is the body. Map the response stream to the response
              // body. This could be done more simply, but a misbehaving interceptor might
              // transform the response body into a different format and ignore the requested
              // responseType. Guard against this by validating that the response is of the
              // requested type.
              switch (req.responseType) {
                case 'arraybuffer':
                  return res$.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_2__["map"])(
                  /**
                  * @param {?} res
                  * @return {?}
                  */
                  function (res) {
                    // Validate that the body is an ArrayBuffer.
                    if (res.body !== null && !(res.body instanceof ArrayBuffer)) {
                      throw new Error('Response is not an ArrayBuffer.');
                    }

                    return res.body;
                  }));

                case 'blob':
                  return res$.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_2__["map"])(
                  /**
                  * @param {?} res
                  * @return {?}
                  */
                  function (res) {
                    // Validate that the body is a Blob.
                    if (res.body !== null && !(res.body instanceof Blob)) {
                      throw new Error('Response is not a Blob.');
                    }

                    return res.body;
                  }));

                case 'text':
                  return res$.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_2__["map"])(
                  /**
                  * @param {?} res
                  * @return {?}
                  */
                  function (res) {
                    // Validate that the body is a string.
                    if (res.body !== null && typeof res.body !== 'string') {
                      throw new Error('Response is not a string.');
                    }

                    return res.body;
                  }));

                case 'json':
                default:
                  // No validation needed for JSON responses, as they can be of any type.
                  return res$.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_2__["map"])(
                  /**
                  * @param {?} res
                  * @return {?}
                  */
                  function (res) {
                    return res.body;
                  }));
              }

            case 'response':
              // The response stream was requested directly, so return it.
              return res$;

            default:
              // Guard against new future observe types being added.
              throw new Error("Unreachable: unhandled observe type ".concat(options.observe, "}"));
          }
        }
        /**
         * Constructs an observable that, when subscribed, causes the configured
         * `DELETE` request to execute on the server. See the individual overloads for
         * details on the return type.
         *
         * @param {?} url     The endpoint URL.
         * @param {?=} options The HTTP options to send with the request.
         *
         * @return {?}
         */

      }, {
        key: "delete",
        value: function _delete(url) {
          var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
          return this.request('DELETE', url,
          /** @type {?} */
          options);
        }
        /**
         * Constructs an observable that, when subscribed, causes the configured
         * `GET` request to execute on the server. See the individual overloads for
         * details on the return type.
         * @param {?} url
         * @param {?=} options
         * @return {?}
         */

      }, {
        key: "get",
        value: function get(url) {
          var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
          return this.request('GET', url,
          /** @type {?} */
          options);
        }
        /**
         * Constructs an observable that, when subscribed, causes the configured
         * `HEAD` request to execute on the server. The `HEAD` method returns
         * meta information about the resource without transferring the
         * resource itself. See the individual overloads for
         * details on the return type.
         * @param {?} url
         * @param {?=} options
         * @return {?}
         */

      }, {
        key: "head",
        value: function head(url) {
          var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
          return this.request('HEAD', url,
          /** @type {?} */
          options);
        }
        /**
         * Constructs an `Observable` that, when subscribed, causes a request with the special method
         * `JSONP` to be dispatched via the interceptor pipeline.
         * The [JSONP pattern](https://en.wikipedia.org/wiki/JSONP) works around limitations of certain
         * API endpoints that don't support newer,
         * and preferable [CORS](https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS) protocol.
         * JSONP treats the endpoint API as a JavaScript file and tricks the browser to process the
         * requests even if the API endpoint is not located on the same domain (origin) as the client-side
         * application making the request.
         * The endpoint API must support JSONP callback for JSONP requests to work.
         * The resource API returns the JSON response wrapped in a callback function.
         * You can pass the callback function name as one of the query parameters.
         * Note that JSONP requests can only be used with `GET` requests.
         *
         * @template T
         * @param {?} url The resource URL.
         * @param {?} callbackParam The callback function name.
         *
         * @return {?}
         */

      }, {
        key: "jsonp",
        value: function jsonp(url, callbackParam) {
          return this.request('JSONP', url, {
            params: new HttpParams().append(callbackParam, 'JSONP_CALLBACK'),
            observe: 'body',
            responseType: 'json'
          });
        }
        /**
         * Constructs an `Observable` that, when subscribed, causes the configured
         * `OPTIONS` request to execute on the server. This method allows the client
         * to determine the supported HTTP methods and other capabilites of an endpoint,
         * without implying a resource action. See the individual overloads for
         * details on the return type.
         * @param {?} url
         * @param {?=} options
         * @return {?}
         */

      }, {
        key: "options",
        value: function options(url) {
          var _options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};

          return this.request('OPTIONS', url,
          /** @type {?} */
          _options);
        }
        /**
         * Constructs an observable that, when subscribed, causes the configured
         * `PATCH` request to execute on the server. See the individual overloads for
         * details on the return type.
         * @param {?} url
         * @param {?} body
         * @param {?=} options
         * @return {?}
         */

      }, {
        key: "patch",
        value: function patch(url, body) {
          var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
          return this.request('PATCH', url, addBody(options, body));
        }
        /**
         * Constructs an observable that, when subscribed, causes the configured
         * `POST` request to execute on the server. The server responds with the location of
         * the replaced resource. See the individual overloads for
         * details on the return type.
         * @param {?} url
         * @param {?} body
         * @param {?=} options
         * @return {?}
         */

      }, {
        key: "post",
        value: function post(url, body) {
          var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
          return this.request('POST', url, addBody(options, body));
        }
        /**
         * Constructs an observable that, when subscribed, causes the configured
         * `PUT` request to execute on the server. The `PUT` method replaces an existing resource
         * with a new set of values.
         * See the individual overloads for details on the return type.
         * @param {?} url
         * @param {?} body
         * @param {?=} options
         * @return {?}
         */

      }, {
        key: "put",
        value: function put(url, body) {
          var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
          return this.request('PUT', url, addBody(options, body));
        }
      }]);

      return HttpClient;
    }();

    HttpClient.ɵfac = function HttpClient_Factory(t) {
      return new (t || HttpClient)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](HttpHandler));
    };

    HttpClient.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({
      token: HttpClient,
      factory: HttpClient.ɵfac
    });
    /** @nocollapse */

    HttpClient.ctorParameters = function () {
      return [{
        type: HttpHandler
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](HttpClient, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"]
      }], function () {
        return [{
          type: HttpHandler
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/http/src/interceptor.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Intercepts and handles an `HttpRequest` or `HttpResponse`.
     *
     * Most interceptors transform the outgoing request before passing it to the
     * next interceptor in the chain, by calling `next.handle(transformedReq)`.
     * An interceptor may transform the
     * response event stream as well, by applying additional RxJS operators on the stream
     * returned by `next.handle()`.
     *
     * More rarely, an interceptor may handle the request entirely,
     * and compose a new event stream instead of invoking `next.handle()`. This is an
     * acceptable behavior, but keep in mind that further interceptors will be skipped entirely.
     *
     * It is also rare but valid for an interceptor to return multiple responses on the
     * event stream for a single request.
     *
     * \@publicApi
     *
     * @see [HTTP Guide](guide/http#intercepting-requests-and-responses)
     *
     * \@usageNotes
     *
     * To use the same instance of `HttpInterceptors` for the entire app, import the `HttpClientModule`
     * only in your `AppModule`, and add the interceptors to the root application injector .
     * If you import `HttpClientModule` multiple times across different modules (for example, in lazy
     * loading modules), each import creates a new copy of the `HttpClientModule`, which overwrites the
     * interceptors provided in the root module.
     *
     * @record
     */


    function HttpInterceptor() {}

    if (false) {}
    /**
     * `HttpHandler` which applies an `HttpInterceptor` to an `HttpRequest`.
     *
     *
     */


    var HttpInterceptorHandler = /*#__PURE__*/function () {
      /**
       * @param {?} next
       * @param {?} interceptor
       */
      function HttpInterceptorHandler(next, interceptor) {
        _classCallCheck(this, HttpInterceptorHandler);

        this.next = next;
        this.interceptor = interceptor;
      }
      /**
       * @param {?} req
       * @return {?}
       */


      _createClass2(HttpInterceptorHandler, [{
        key: "handle",
        value: function handle(req) {
          return this.interceptor.intercept(req, this.next);
        }
      }]);

      return HttpInterceptorHandler;
    }();

    if (false) {}
    /**
     * A multi-provider token that represents the array of registered
     * `HttpInterceptor` objects.
     *
     * \@publicApi
     * @type {?}
     */


    var HTTP_INTERCEPTORS = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('HTTP_INTERCEPTORS');

    var NoopInterceptor = /*#__PURE__*/function () {
      function NoopInterceptor() {
        _classCallCheck(this, NoopInterceptor);
      }

      _createClass2(NoopInterceptor, [{
        key: "intercept",

        /**
         * @param {?} req
         * @param {?} next
         * @return {?}
         */
        value: function intercept(req, next) {
          return next.handle(req);
        }
      }]);

      return NoopInterceptor;
    }();

    NoopInterceptor.ɵfac = function NoopInterceptor_Factory(t) {
      return new (t || NoopInterceptor)();
    };

    NoopInterceptor.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({
      token: NoopInterceptor,
      factory: NoopInterceptor.ɵfac
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NoopInterceptor, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/http/src/jsonp.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */
    // Every request made through JSONP needs a callback name that's unique across the
    // whole page. Each request is assigned an id and the callback name is constructed
    // from that. The next id to be assigned is tracked in a global variable here that
    // is shared among all applications on the page.

    /** @type {?} */


    var nextRequestId = 0; // Error text given when a JSONP script is injected, but doesn't invoke the callback
    // passed in its URL.

    /** @type {?} */

    var JSONP_ERR_NO_CALLBACK = 'JSONP injected script did not invoke callback.'; // Error text given when a request is passed to the JsonpClientBackend that doesn't
    // have a request method JSONP.

    /** @type {?} */

    var JSONP_ERR_WRONG_METHOD = 'JSONP requests must use JSONP request method.';
    /** @type {?} */

    var JSONP_ERR_WRONG_RESPONSE_TYPE = 'JSONP requests must use Json response type.';
    /**
     * DI token/abstract type representing a map of JSONP callbacks.
     *
     * In the browser, this should always be the `window` object.
     *
     *
     * @abstract
     */

    var JsonpCallbackContext = function JsonpCallbackContext() {
      _classCallCheck(this, JsonpCallbackContext);
    };
    /**
     * Processes an `HttpRequest` with the JSONP method,
     * by performing JSONP style requests.
     * @see `HttpHandler`
     * @see `HttpXhrBackend`
     *
     * \@publicApi
     */


    var JsonpClientBackend = /*#__PURE__*/function () {
      /**
       * @param {?} callbackMap
       * @param {?} document
       */
      function JsonpClientBackend(callbackMap, document) {
        _classCallCheck(this, JsonpClientBackend);

        this.callbackMap = callbackMap;
        this.document = document;
      }
      /**
       * Get the name of the next callback method, by incrementing the global `nextRequestId`.
       * @private
       * @return {?}
       */


      _createClass2(JsonpClientBackend, [{
        key: "nextCallback",
        value: function nextCallback() {
          return "ng_jsonp_callback_".concat(nextRequestId++);
        }
        /**
         * Processes a JSONP request and returns an event stream of the results.
         * @param {?} req The request object.
         * @return {?} An observable of the response events.
         *
         */

      }, {
        key: "handle",
        value: function handle(req) {
          var _this148 = this;

          // Firstly, check both the method and response type. If either doesn't match
          // then the request was improperly routed here and cannot be handled.
          if (req.method !== 'JSONP') {
            throw new Error(JSONP_ERR_WRONG_METHOD);
          } else if (req.responseType !== 'json') {
            throw new Error(JSONP_ERR_WRONG_RESPONSE_TYPE);
          } // Everything else happens inside the Observable boundary.


          return new rxjs__WEBPACK_IMPORTED_MODULE_1__["Observable"](
          /**
          * @param {?} observer
          * @return {?}
          */
          function (observer) {
            // The first step to make a request is to generate the callback name, and replace the
            // callback placeholder in the URL with the name. Care has to be taken here to ensure
            // a trailing &, if matched, gets inserted back into the URL in the correct place.

            /** @type {?} */
            var callback = _this148.nextCallback();
            /** @type {?} */


            var url = req.urlWithParams.replace(/=JSONP_CALLBACK(&|$)/, "=".concat(callback, "$1")); // Construct the <script> tag and point it at the URL.

            /** @type {?} */

            var node = _this148.document.createElement('script');

            node.src = url; // A JSONP request requires waiting for multiple callbacks. These variables
            // are closed over and track state across those callbacks.
            // The response object, if one has been received, or null otherwise.

            /** @type {?} */

            var body = null; // Whether the response callback has been called.

            /** @type {?} */

            var finished = false; // Whether the request has been cancelled (and thus any other callbacks)
            // should be ignored.

            /** @type {?} */

            var cancelled = false; // Set the response callback in this.callbackMap (which will be the window
            // object in the browser. The script being loaded via the <script> tag will
            // eventually call this callback.

            _this148.callbackMap[callback] =
            /**
            * @param {?=} data
            * @return {?}
            */
            function (data) {
              // Data has been received from the JSONP script. Firstly, delete this callback.
              delete _this148.callbackMap[callback]; // Next, make sure the request wasn't cancelled in the meantime.

              if (cancelled) {
                return;
              } // Set state to indicate data was received.


              body = data;
              finished = true;
            }; // cleanup() is a utility closure that removes the <script> from the page and
            // the response callback from the window. This logic is used in both the
            // success, error, and cancellation paths, so it's extracted out for convenience.

            /** @type {?} */


            var cleanup =
            /**
            * @return {?}
            */
            function cleanup() {
              // Remove the <script> tag if it's still on the page.
              if (node.parentNode) {
                node.parentNode.removeChild(node);
              } // Remove the response callback from the callbackMap (window object in the
              // browser).


              delete _this148.callbackMap[callback];
            }; // onLoad() is the success callback which runs after the response callback
            // if the JSONP script loads successfully. The event itself is unimportant.
            // If something went wrong, onLoad() may run without the response callback
            // having been invoked.

            /** @type {?} */


            var onLoad =
            /**
            * @param {?} event
            * @return {?}
            */
            function onLoad(event) {
              // Do nothing if the request has been cancelled.
              if (cancelled) {
                return;
              } // Cleanup the page.


              cleanup(); // Check whether the response callback has run.

              if (!finished) {
                // It hasn't, something went wrong with the request. Return an error via
                // the Observable error path. All JSONP errors have status 0.
                observer.error(new HttpErrorResponse({
                  url: url,
                  status: 0,
                  statusText: 'JSONP Error',
                  error: new Error(JSONP_ERR_NO_CALLBACK)
                }));
                return;
              } // Success. body either contains the response body or null if none was
              // returned.


              observer.next(new HttpResponse({
                body: body,
                status: 200,
                statusText: 'OK',
                url: url
              })); // Complete the stream, the response is over.

              observer.complete();
            }; // onError() is the error callback, which runs if the script returned generates
            // a Javascript error. It emits the error via the Observable error channel as
            // a HttpErrorResponse.

            /** @type {?} */


            var onError =
            /**
            * @param {?} error
            * @return {?}
            */
            function onError(error) {
              // If the request was already cancelled, no need to emit anything.
              if (cancelled) {
                return;
              }

              cleanup(); // Wrap the error in a HttpErrorResponse.

              observer.error(new HttpErrorResponse({
                error: error,
                status: 0,
                statusText: 'JSONP Error',
                url: url
              }));
            }; // Subscribe to both the success (load) and error events on the <script> tag,
            // and add it to the page.


            node.addEventListener('load', onLoad);
            node.addEventListener('error', onError);

            _this148.document.body.appendChild(node); // The request has now been successfully sent.


            observer.next({
              type: HttpEventType.Sent
            }); // Cancellation handler.

            return (
              /**
              * @return {?}
              */
              function () {
                // Track the cancellation so event listeners won't do anything even if already scheduled.
                cancelled = true; // Remove the event listeners so they won't run if the events later fire.

                node.removeEventListener('load', onLoad);
                node.removeEventListener('error', onError); // And finally, clean up the page.

                cleanup();
              }
            );
          });
        }
      }]);

      return JsonpClientBackend;
    }();

    JsonpClientBackend.ɵfac = function JsonpClientBackend_Factory(t) {
      return new (t || JsonpClientBackend)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](JsonpCallbackContext), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_3__["DOCUMENT"]));
    };

    JsonpClientBackend.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({
      token: JsonpClientBackend,
      factory: JsonpClientBackend.ɵfac
    });
    /** @nocollapse */

    JsonpClientBackend.ctorParameters = function () {
      return [{
        type: JsonpCallbackContext
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_3__["DOCUMENT"]]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](JsonpClientBackend, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"]
      }], function () {
        return [{
          type: JsonpCallbackContext
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_3__["DOCUMENT"]]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * Identifies requests with the method JSONP and
     * shifts them to the `JsonpClientBackend`.
     *
     * @see `HttpInterceptor`
     *
     * \@publicApi
     */


    var JsonpInterceptor = /*#__PURE__*/function () {
      /**
       * @param {?} jsonp
       */
      function JsonpInterceptor(jsonp) {
        _classCallCheck(this, JsonpInterceptor);

        this.jsonp = jsonp;
      }
      /**
       * Identifies and handles a given JSONP request.
       * @param {?} req The outgoing request object to handle.
       * @param {?} next The next interceptor in the chain, or the backend
       * if no interceptors remain in the chain.
       * @return {?} An observable of the event stream.
       */


      _createClass2(JsonpInterceptor, [{
        key: "intercept",
        value: function intercept(req, next) {
          if (req.method === 'JSONP') {
            return this.jsonp.handle(
            /** @type {?} */
            req);
          } // Fall through for normal HTTP requests.


          return next.handle(req);
        }
      }]);

      return JsonpInterceptor;
    }();

    JsonpInterceptor.ɵfac = function JsonpInterceptor_Factory(t) {
      return new (t || JsonpInterceptor)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](JsonpClientBackend));
    };

    JsonpInterceptor.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({
      token: JsonpInterceptor,
      factory: JsonpInterceptor.ɵfac
    });
    /** @nocollapse */

    JsonpInterceptor.ctorParameters = function () {
      return [{
        type: JsonpClientBackend
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](JsonpInterceptor, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"]
      }], function () {
        return [{
          type: JsonpClientBackend
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/http/src/xhr.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var XSSI_PREFIX = /^\)\]\}',?\n/;
    /**
     * Determine an appropriate URL for the response, by checking either
     * XMLHttpRequest.responseURL or the X-Request-URL header.
     * @param {?} xhr
     * @return {?}
     */

    function getResponseUrl(xhr) {
      if ('responseURL' in xhr && xhr.responseURL) {
        return xhr.responseURL;
      }

      if (/^X-Request-URL:/m.test(xhr.getAllResponseHeaders())) {
        return xhr.getResponseHeader('X-Request-URL');
      }

      return null;
    }
    /**
     * A wrapper around the `XMLHttpRequest` constructor.
     *
     * \@publicApi
     * @abstract
     */


    var XhrFactory = function XhrFactory() {
      _classCallCheck(this, XhrFactory);
    };

    if (false) {}
    /**
     * A factory for `HttpXhrBackend` that uses the `XMLHttpRequest` browser API.
     *
     */


    var BrowserXhr = /*#__PURE__*/function () {
      function BrowserXhr() {
        _classCallCheck(this, BrowserXhr);
      }
      /**
       * @return {?}
       */


      _createClass2(BrowserXhr, [{
        key: "build",
        value: function build() {
          return (
            /** @type {?} */
            new XMLHttpRequest()
          );
        }
      }]);

      return BrowserXhr;
    }();

    BrowserXhr.ɵfac = function BrowserXhr_Factory(t) {
      return new (t || BrowserXhr)();
    };

    BrowserXhr.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({
      token: BrowserXhr,
      factory: BrowserXhr.ɵfac
    });
    /** @nocollapse */

    BrowserXhr.ctorParameters = function () {
      return [];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](BrowserXhr, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"]
      }], function () {
        return [];
      }, null);
    })();
    /**
     * Tracks a response from the server that does not yet have a body.
     * @record
     */


    function PartialResponse() {}

    if (false) {}
    /**
     * Uses `XMLHttpRequest` to send requests to a backend server.
     * @see `HttpHandler`
     * @see `JsonpClientBackend`
     *
     * \@publicApi
     */


    var HttpXhrBackend = /*#__PURE__*/function () {
      /**
       * @param {?} xhrFactory
       */
      function HttpXhrBackend(xhrFactory) {
        _classCallCheck(this, HttpXhrBackend);

        this.xhrFactory = xhrFactory;
      }
      /**
       * Processes a request and returns a stream of response events.
       * @param {?} req The request object.
       * @return {?} An observable of the response events.
       */


      _createClass2(HttpXhrBackend, [{
        key: "handle",
        value: function handle(req) {
          var _this149 = this;

          // Quick check to give a better error message when a user attempts to use
          // HttpClient.jsonp() without installing the JsonpClientModule
          if (req.method === 'JSONP') {
            throw new Error("Attempted to construct Jsonp request without JsonpClientModule installed.");
          } // Everything happens on Observable subscription.


          return new rxjs__WEBPACK_IMPORTED_MODULE_1__["Observable"](
          /**
          * @param {?} observer
          * @return {?}
          */
          function (observer) {
            // Start by setting up the XHR object with request method, URL, and withCredentials flag.

            /** @type {?} */
            var xhr = _this149.xhrFactory.build();

            xhr.open(req.method, req.urlWithParams);

            if (!!req.withCredentials) {
              xhr.withCredentials = true;
            } // Add all the requested headers.


            req.headers.forEach(
            /**
            * @param {?} name
            * @param {?} values
            * @return {?}
            */
            function (name, values) {
              return xhr.setRequestHeader(name, values.join(','));
            }); // Add an Accept header if one isn't present already.

            if (!req.headers.has('Accept')) {
              xhr.setRequestHeader('Accept', 'application/json, text/plain, */*');
            } // Auto-detect the Content-Type header if one isn't present already.


            if (!req.headers.has('Content-Type')) {
              /** @type {?} */
              var detectedType = req.detectContentTypeHeader(); // Sometimes Content-Type detection fails.

              if (detectedType !== null) {
                xhr.setRequestHeader('Content-Type', detectedType);
              }
            } // Set the responseType if one was requested.


            if (req.responseType) {
              /** @type {?} */
              var responseType = req.responseType.toLowerCase(); // JSON responses need to be processed as text. This is because if the server
              // returns an XSSI-prefixed JSON response, the browser will fail to parse it,
              // xhr.response will be null, and xhr.responseText cannot be accessed to
              // retrieve the prefixed JSON data in order to strip the prefix. Thus, all JSON
              // is parsed by first requesting text and then applying JSON.parse.

              xhr.responseType =
              /** @type {?} */
              responseType !== 'json' ? responseType : 'text';
            } // Serialize the request body if one is present. If not, this will be set to null.

            /** @type {?} */


            var reqBody = req.serializeBody(); // If progress events are enabled, response headers will be delivered
            // in two events - the HttpHeaderResponse event and the full HttpResponse
            // event. However, since response headers don't change in between these
            // two events, it doesn't make sense to parse them twice. So headerResponse
            // caches the data extracted from the response whenever it's first parsed,
            // to ensure parsing isn't duplicated.

            /** @type {?} */

            var headerResponse = null; // partialFromXhr extracts the HttpHeaderResponse from the current XMLHttpRequest
            // state, and memoizes it into headerResponse.

            /** @type {?} */

            var partialFromXhr =
            /**
            * @return {?}
            */
            function partialFromXhr() {
              if (headerResponse !== null) {
                return headerResponse;
              } // Read status and normalize an IE9 bug (http://bugs.jquery.com/ticket/1450).

              /** @type {?} */


              var status = xhr.status === 1223 ? 204 : xhr.status;
              /** @type {?} */

              var statusText = xhr.statusText || 'OK'; // Parse headers from XMLHttpRequest - this step is lazy.

              /** @type {?} */

              var headers = new HttpHeaders(xhr.getAllResponseHeaders()); // Read the response URL from the XMLHttpResponse instance and fall back on the
              // request URL.

              /** @type {?} */

              var url = getResponseUrl(xhr) || req.url; // Construct the HttpHeaderResponse and memoize it.

              headerResponse = new HttpHeaderResponse({
                headers: headers,
                status: status,
                statusText: statusText,
                url: url
              });
              return headerResponse;
            }; // Next, a few closures are defined for the various events which XMLHttpRequest can
            // emit. This allows them to be unregistered as event listeners later.
            // First up is the load event, which represents a response being fully available.

            /** @type {?} */


            var onLoad =
            /**
            * @return {?}
            */
            function onLoad() {
              // Read response state from the memoized partial data.
              var _partialFromXhr = partialFromXhr(),
                  headers = _partialFromXhr.headers,
                  status = _partialFromXhr.status,
                  statusText = _partialFromXhr.statusText,
                  url = _partialFromXhr.url; // The body will be read out if present.

              /** @type {?} */


              var body = null;

              if (status !== 204) {
                // Use XMLHttpRequest.response if set, responseText otherwise.
                body = typeof xhr.response === 'undefined' ? xhr.responseText : xhr.response;
              } // Normalize another potential bug (this one comes from CORS).


              if (status === 0) {
                status = !!body ? 200 : 0;
              } // ok determines whether the response will be transmitted on the event or
              // error channel. Unsuccessful status codes (not 2xx) will always be errors,
              // but a successful status code can still result in an error if the user
              // asked for JSON data and the body cannot be parsed as such.

              /** @type {?} */


              var ok = status >= 200 && status < 300; // Check whether the body needs to be parsed as JSON (in many cases the browser
              // will have done that already).

              if (req.responseType === 'json' && typeof body === 'string') {
                // Save the original body, before attempting XSSI prefix stripping.

                /** @type {?} */
                var originalBody = body;
                body = body.replace(XSSI_PREFIX, '');

                try {
                  // Attempt the parse. If it fails, a parse error should be delivered to the user.
                  body = body !== '' ? JSON.parse(body) : null;
                } catch (error) {
                  // Since the JSON.parse failed, it's reasonable to assume this might not have been a
                  // JSON response. Restore the original body (including any XSSI prefix) to deliver
                  // a better error response.
                  body = originalBody; // If this was an error request to begin with, leave it as a string, it probably
                  // just isn't JSON. Otherwise, deliver the parsing error to the user.

                  if (ok) {
                    // Even though the response status was 2xx, this is still an error.
                    ok = false; // The parse error contains the text of the body that failed to parse.

                    body =
                    /** @type {?} */
                    {
                      error: error,
                      text: body
                    };
                  }
                }
              }

              if (ok) {
                // A successful response is delivered on the event stream.
                observer.next(new HttpResponse({
                  body: body,
                  headers: headers,
                  status: status,
                  statusText: statusText,
                  url: url || undefined
                })); // The full body has been received and delivered, no further events
                // are possible. This request is complete.

                observer.complete();
              } else {
                // An unsuccessful request is delivered on the error channel.
                observer.error(new HttpErrorResponse({
                  // The error in this case is the response body (error from the server).
                  error: body,
                  headers: headers,
                  status: status,
                  statusText: statusText,
                  url: url || undefined
                }));
              }
            }; // The onError callback is called when something goes wrong at the network level.
            // Connection timeout, DNS error, offline, etc. These are actual errors, and are
            // transmitted on the error channel.

            /** @type {?} */


            var onError =
            /**
            * @param {?} error
            * @return {?}
            */
            function onError(error) {
              var _partialFromXhr2 = partialFromXhr(),
                  url = _partialFromXhr2.url;
              /** @type {?} */


              var res = new HttpErrorResponse({
                error: error,
                status: xhr.status || 0,
                statusText: xhr.statusText || 'Unknown Error',
                url: url || undefined
              });
              observer.error(res);
            }; // The sentHeaders flag tracks whether the HttpResponseHeaders event
            // has been sent on the stream. This is necessary to track if progress
            // is enabled since the event will be sent on only the first download
            // progerss event.

            /** @type {?} */


            var sentHeaders = false; // The download progress event handler, which is only registered if
            // progress events are enabled.

            /** @type {?} */

            var onDownProgress =
            /**
            * @param {?} event
            * @return {?}
            */
            function onDownProgress(event) {
              // Send the HttpResponseHeaders event if it hasn't been sent already.
              if (!sentHeaders) {
                observer.next(partialFromXhr());
                sentHeaders = true;
              } // Start building the download progress event to deliver on the response
              // event stream.

              /** @type {?} */


              var progressEvent = {
                type: HttpEventType.DownloadProgress,
                loaded: event.loaded
              }; // Set the total number of bytes in the event if it's available.

              if (event.lengthComputable) {
                progressEvent.total = event.total;
              } // If the request was for text content and a partial response is
              // available on XMLHttpRequest, include it in the progress event
              // to allow for streaming reads.


              if (req.responseType === 'text' && !!xhr.responseText) {
                progressEvent.partialText = xhr.responseText;
              } // Finally, fire the event.


              observer.next(progressEvent);
            }; // The upload progress event handler, which is only registered if
            // progress events are enabled.

            /** @type {?} */


            var onUpProgress =
            /**
            * @param {?} event
            * @return {?}
            */
            function onUpProgress(event) {
              // Upload progress events are simpler. Begin building the progress
              // event.

              /** @type {?} */
              var progress = {
                type: HttpEventType.UploadProgress,
                loaded: event.loaded
              }; // If the total number of bytes being uploaded is available, include
              // it.

              if (event.lengthComputable) {
                progress.total = event.total;
              } // Send the event.


              observer.next(progress);
            }; // By default, register for load and error events.


            xhr.addEventListener('load', onLoad);
            xhr.addEventListener('error', onError); // Progress events are only enabled if requested.

            if (req.reportProgress) {
              // Download progress is always enabled if requested.
              xhr.addEventListener('progress', onDownProgress); // Upload progress depends on whether there is a body to upload.

              if (reqBody !== null && xhr.upload) {
                xhr.upload.addEventListener('progress', onUpProgress);
              }
            } // Fire the request, and notify the event stream that it was fired.


            xhr.send(
            /** @type {?} */
            reqBody);
            observer.next({
              type: HttpEventType.Sent
            }); // This is the return from the Observable function, which is the
            // request cancellation handler.

            return (
              /**
              * @return {?}
              */
              function () {
                // On a cancellation, remove all registered event listeners.
                xhr.removeEventListener('error', onError);
                xhr.removeEventListener('load', onLoad);

                if (req.reportProgress) {
                  xhr.removeEventListener('progress', onDownProgress);

                  if (reqBody !== null && xhr.upload) {
                    xhr.upload.removeEventListener('progress', onUpProgress);
                  }
                } // Finally, abort the in-flight request.


                xhr.abort();
              }
            );
          });
        }
      }]);

      return HttpXhrBackend;
    }();

    HttpXhrBackend.ɵfac = function HttpXhrBackend_Factory(t) {
      return new (t || HttpXhrBackend)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](XhrFactory));
    };

    HttpXhrBackend.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({
      token: HttpXhrBackend,
      factory: HttpXhrBackend.ɵfac
    });
    /** @nocollapse */

    HttpXhrBackend.ctorParameters = function () {
      return [{
        type: XhrFactory
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](HttpXhrBackend, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"]
      }], function () {
        return [{
          type: XhrFactory
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/http/src/xsrf.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var XSRF_COOKIE_NAME = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('XSRF_COOKIE_NAME');
    /** @type {?} */

    var XSRF_HEADER_NAME = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('XSRF_HEADER_NAME');
    /**
     * Retrieves the current XSRF token to use with the next outgoing request.
     *
     * \@publicApi
     * @abstract
     */

    var HttpXsrfTokenExtractor = function HttpXsrfTokenExtractor() {
      _classCallCheck(this, HttpXsrfTokenExtractor);
    };

    if (false) {}
    /**
     * `HttpXsrfTokenExtractor` which retrieves the token from a cookie.
     */


    var HttpXsrfCookieExtractor = /*#__PURE__*/function () {
      /**
       * @param {?} doc
       * @param {?} platform
       * @param {?} cookieName
       */
      function HttpXsrfCookieExtractor(doc, platform, cookieName) {
        _classCallCheck(this, HttpXsrfCookieExtractor);

        this.doc = doc;
        this.platform = platform;
        this.cookieName = cookieName;
        this.lastCookieString = '';
        this.lastToken = null;
        /**
         * \@internal for testing
         */

        this.parseCount = 0;
      }
      /**
       * @return {?}
       */


      _createClass2(HttpXsrfCookieExtractor, [{
        key: "getToken",
        value: function getToken() {
          if (this.platform === 'server') {
            return null;
          }
          /** @type {?} */


          var cookieString = this.doc.cookie || '';

          if (cookieString !== this.lastCookieString) {
            this.parseCount++;
            this.lastToken = Object(_angular_common__WEBPACK_IMPORTED_MODULE_3__["ɵparseCookieValue"])(cookieString, this.cookieName);
            this.lastCookieString = cookieString;
          }

          return this.lastToken;
        }
      }]);

      return HttpXsrfCookieExtractor;
    }();

    HttpXsrfCookieExtractor.ɵfac = function HttpXsrfCookieExtractor_Factory(t) {
      return new (t || HttpXsrfCookieExtractor)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_3__["DOCUMENT"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["PLATFORM_ID"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](XSRF_COOKIE_NAME));
    };

    HttpXsrfCookieExtractor.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({
      token: HttpXsrfCookieExtractor,
      factory: HttpXsrfCookieExtractor.ɵfac
    });
    /** @nocollapse */

    HttpXsrfCookieExtractor.ctorParameters = function () {
      return [{
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_3__["DOCUMENT"]]
        }]
      }, {
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["PLATFORM_ID"]]
        }]
      }, {
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [XSRF_COOKIE_NAME]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](HttpXsrfCookieExtractor, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"]
      }], function () {
        return [{
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_3__["DOCUMENT"]]
          }]
        }, {
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["PLATFORM_ID"]]
          }]
        }, {
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [XSRF_COOKIE_NAME]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * `HttpInterceptor` which adds an XSRF token to eligible outgoing requests.
     */


    var HttpXsrfInterceptor = /*#__PURE__*/function () {
      /**
       * @param {?} tokenService
       * @param {?} headerName
       */
      function HttpXsrfInterceptor(tokenService, headerName) {
        _classCallCheck(this, HttpXsrfInterceptor);

        this.tokenService = tokenService;
        this.headerName = headerName;
      }
      /**
       * @param {?} req
       * @param {?} next
       * @return {?}
       */


      _createClass2(HttpXsrfInterceptor, [{
        key: "intercept",
        value: function intercept(req, next) {
          /** @type {?} */
          var lcUrl = req.url.toLowerCase(); // Skip both non-mutating requests and absolute URLs.
          // Non-mutating requests don't require a token, and absolute URLs require special handling
          // anyway as the cookie set
          // on our origin is not the same as the token expected by another origin.

          if (req.method === 'GET' || req.method === 'HEAD' || lcUrl.startsWith('http://') || lcUrl.startsWith('https://')) {
            return next.handle(req);
          }
          /** @type {?} */


          var token = this.tokenService.getToken(); // Be careful not to overwrite an existing header of the same name.

          if (token !== null && !req.headers.has(this.headerName)) {
            req = req.clone({
              headers: req.headers.set(this.headerName, token)
            });
          }

          return next.handle(req);
        }
      }]);

      return HttpXsrfInterceptor;
    }();

    HttpXsrfInterceptor.ɵfac = function HttpXsrfInterceptor_Factory(t) {
      return new (t || HttpXsrfInterceptor)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](HttpXsrfTokenExtractor), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](XSRF_HEADER_NAME));
    };

    HttpXsrfInterceptor.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({
      token: HttpXsrfInterceptor,
      factory: HttpXsrfInterceptor.ɵfac
    });
    /** @nocollapse */

    HttpXsrfInterceptor.ctorParameters = function () {
      return [{
        type: HttpXsrfTokenExtractor
      }, {
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [XSRF_HEADER_NAME]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](HttpXsrfInterceptor, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"]
      }], function () {
        return [{
          type: HttpXsrfTokenExtractor
        }, {
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [XSRF_HEADER_NAME]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/http/src/module.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * An injectable `HttpHandler` that applies multiple interceptors
     * to a request before passing it to the given `HttpBackend`.
     *
     * The interceptors are loaded lazily from the injector, to allow
     * interceptors to themselves inject classes depending indirectly
     * on `HttpInterceptingHandler` itself.
     * @see `HttpInterceptor`
     */


    var HttpInterceptingHandler = /*#__PURE__*/function () {
      /**
       * @param {?} backend
       * @param {?} injector
       */
      function HttpInterceptingHandler(backend, injector) {
        _classCallCheck(this, HttpInterceptingHandler);

        this.backend = backend;
        this.injector = injector;
        this.chain = null;
      }
      /**
       * @param {?} req
       * @return {?}
       */


      _createClass2(HttpInterceptingHandler, [{
        key: "handle",
        value: function handle(req) {
          if (this.chain === null) {
            /** @type {?} */
            var interceptors = this.injector.get(HTTP_INTERCEPTORS, []);
            this.chain = interceptors.reduceRight(
            /**
            * @param {?} next
            * @param {?} interceptor
            * @return {?}
            */
            function (next, interceptor) {
              return new HttpInterceptorHandler(next, interceptor);
            }, this.backend);
          }

          return this.chain.handle(req);
        }
      }]);

      return HttpInterceptingHandler;
    }();

    HttpInterceptingHandler.ɵfac = function HttpInterceptingHandler_Factory(t) {
      return new (t || HttpInterceptingHandler)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](HttpBackend), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injector"]));
    };

    HttpInterceptingHandler.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({
      token: HttpInterceptingHandler,
      factory: HttpInterceptingHandler.ɵfac
    });
    /** @nocollapse */

    HttpInterceptingHandler.ctorParameters = function () {
      return [{
        type: HttpBackend
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injector"]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](HttpInterceptingHandler, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"]
      }], function () {
        return [{
          type: HttpBackend
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injector"]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * Constructs an `HttpHandler` that applies interceptors
     * to a request before passing it to the given `HttpBackend`.
     *
     * Use as a factory function within `HttpClientModule`.
     *
     *
     * @param {?} backend
     * @param {?=} interceptors
     * @return {?}
     */


    function interceptingHandler(backend) {
      var interceptors = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];

      if (!interceptors) {
        return backend;
      }

      return interceptors.reduceRight(
      /**
      * @param {?} next
      * @param {?} interceptor
      * @return {?}
      */
      function (next, interceptor) {
        return new HttpInterceptorHandler(next, interceptor);
      }, backend);
    }
    /**
     * Factory function that determines where to store JSONP callbacks.
     *
     * Ordinarily JSONP callbacks are stored on the `window` object, but this may not exist
     * in test environments. In that case, callbacks are stored on an anonymous object instead.
     *
     *
     * @return {?}
     */


    function jsonpCallbackContext() {
      if (typeof window === 'object') {
        return window;
      }

      return {};
    }
    /**
     * Configures XSRF protection support for outgoing requests.
     *
     * For a server that supports a cookie-based XSRF protection system,
     * use directly to configure XSRF protection with the correct
     * cookie and header names.
     *
     * If no names are supplied, the default cookie name is `XSRF-TOKEN`
     * and the default header name is `X-XSRF-TOKEN`.
     *
     * \@publicApi
     */


    var HttpClientXsrfModule = /*#__PURE__*/function () {
      function HttpClientXsrfModule() {
        _classCallCheck(this, HttpClientXsrfModule);
      }

      _createClass2(HttpClientXsrfModule, null, [{
        key: "disable",

        /**
         * Disable the default XSRF protection.
         * @return {?}
         */
        value: function disable() {
          return {
            ngModule: HttpClientXsrfModule,
            providers: [{
              provide: HttpXsrfInterceptor,
              useClass: NoopInterceptor
            }]
          };
        }
        /**
         * Configure XSRF protection.
         * @param {?=} options An object that can specify either or both
         * cookie name or header name.
         * - Cookie name default is `XSRF-TOKEN`.
         * - Header name default is `X-XSRF-TOKEN`.
         *
         * @return {?}
         */

      }, {
        key: "withOptions",
        value: function withOptions() {
          var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
          return {
            ngModule: HttpClientXsrfModule,
            providers: [options.cookieName ? {
              provide: XSRF_COOKIE_NAME,
              useValue: options.cookieName
            } : [], options.headerName ? {
              provide: XSRF_HEADER_NAME,
              useValue: options.headerName
            } : []]
          };
        }
      }]);

      return HttpClientXsrfModule;
    }();

    HttpClientXsrfModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: HttpClientXsrfModule
    });
    HttpClientXsrfModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function HttpClientXsrfModule_Factory(t) {
        return new (t || HttpClientXsrfModule)();
      },
      providers: [HttpXsrfInterceptor, {
        provide: HTTP_INTERCEPTORS,
        useExisting: HttpXsrfInterceptor,
        multi: true
      }, {
        provide: HttpXsrfTokenExtractor,
        useClass: HttpXsrfCookieExtractor
      }, {
        provide: XSRF_COOKIE_NAME,
        useValue: 'XSRF-TOKEN'
      }, {
        provide: XSRF_HEADER_NAME,
        useValue: 'X-XSRF-TOKEN'
      }]
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](HttpClientXsrfModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{
          providers: [HttpXsrfInterceptor, {
            provide: HTTP_INTERCEPTORS,
            useExisting: HttpXsrfInterceptor,
            multi: true
          }, {
            provide: HttpXsrfTokenExtractor,
            useClass: HttpXsrfCookieExtractor
          }, {
            provide: XSRF_COOKIE_NAME,
            useValue: 'XSRF-TOKEN'
          }, {
            provide: XSRF_HEADER_NAME,
            useValue: 'X-XSRF-TOKEN'
          }]
        }]
      }], null, null);
    })();
    /**
     * Configures the [dependency injector](guide/glossary#injector) for `HttpClient`
     * with supporting services for XSRF. Automatically imported by `HttpClientModule`.
     *
     * You can add interceptors to the chain behind `HttpClient` by binding them to the
     * multiprovider for built-in [DI token](guide/glossary#di-token) `HTTP_INTERCEPTORS`.
     *
     * \@publicApi
     */


    var HttpClientModule = function HttpClientModule() {
      _classCallCheck(this, HttpClientModule);
    };

    HttpClientModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: HttpClientModule
    });
    HttpClientModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function HttpClientModule_Factory(t) {
        return new (t || HttpClientModule)();
      },
      providers: [HttpClient, {
        provide: HttpHandler,
        useClass: HttpInterceptingHandler
      }, HttpXhrBackend, {
        provide: HttpBackend,
        useExisting: HttpXhrBackend
      }, BrowserXhr, {
        provide: XhrFactory,
        useExisting: BrowserXhr
      }],
      imports: [[HttpClientXsrfModule.withOptions({
        cookieName: 'XSRF-TOKEN',
        headerName: 'X-XSRF-TOKEN'
      })]]
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](HttpClientModule, {
        imports: [HttpClientXsrfModule]
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](HttpClientModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{
          /**
           * Optional configuration for XSRF protection.
           */
          imports: [HttpClientXsrfModule.withOptions({
            cookieName: 'XSRF-TOKEN',
            headerName: 'X-XSRF-TOKEN'
          })],

          /**
           * Configures the [dependency injector](guide/glossary#injector) where it is imported
           * with supporting services for HTTP communications.
           */
          providers: [HttpClient, {
            provide: HttpHandler,
            useClass: HttpInterceptingHandler
          }, HttpXhrBackend, {
            provide: HttpBackend,
            useExisting: HttpXhrBackend
          }, BrowserXhr, {
            provide: XhrFactory,
            useExisting: BrowserXhr
          }]
        }]
      }], null, null);
    })();
    /**
     * Configures the [dependency injector](guide/glossary#injector) for `HttpClient`
     * with supporting services for JSONP.
     * Without this module, Jsonp requests reach the backend
     * with method JSONP, where they are rejected.
     *
     * You can add interceptors to the chain behind `HttpClient` by binding them to the
     * multiprovider for built-in [DI token](guide/glossary#di-token) `HTTP_INTERCEPTORS`.
     *
     * \@publicApi
     */


    var HttpClientJsonpModule = function HttpClientJsonpModule() {
      _classCallCheck(this, HttpClientJsonpModule);
    };

    HttpClientJsonpModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: HttpClientJsonpModule
    });
    HttpClientJsonpModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function HttpClientJsonpModule_Factory(t) {
        return new (t || HttpClientJsonpModule)();
      },
      providers: [JsonpClientBackend, {
        provide: JsonpCallbackContext,
        useFactory: jsonpCallbackContext
      }, {
        provide: HTTP_INTERCEPTORS,
        useClass: JsonpInterceptor,
        multi: true
      }]
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](HttpClientJsonpModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{
          providers: [JsonpClientBackend, {
            provide: JsonpCallbackContext,
            useFactory: jsonpCallbackContext
          }, {
            provide: HTTP_INTERCEPTORS,
            useClass: JsonpInterceptor,
            multi: true
          }]
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/http/public_api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/common/http/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=http.js.map

    /***/

  },

  /***/
  "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js":
  /*!******************************************************************!*\
    !*** ./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js ***!
    \******************************************************************/

  /*! exports provided: ANALYZE_FOR_ENTRY_COMPONENTS, APP_BOOTSTRAP_LISTENER, APP_ID, APP_INITIALIZER, ApplicationInitStatus, ApplicationModule, ApplicationRef, Attribute, COMPILER_OPTIONS, CUSTOM_ELEMENTS_SCHEMA, ChangeDetectionStrategy, ChangeDetectorRef, Compiler, CompilerFactory, Component, ComponentFactory, ComponentFactoryResolver, ComponentRef, ContentChild, ContentChildren, DEFAULT_CURRENCY_CODE, DebugElement, DebugEventListener, DebugNode, DefaultIterableDiffer, Directive, ElementRef, EmbeddedViewRef, ErrorHandler, EventEmitter, Host, HostBinding, HostListener, INJECTOR, Inject, InjectFlags, Injectable, InjectionToken, Injector, Input, IterableDiffers, KeyValueDiffers, LOCALE_ID, MissingTranslationStrategy, ModuleWithComponentFactories, NO_ERRORS_SCHEMA, NgModule, NgModuleFactory, NgModuleFactoryLoader, NgModuleRef, NgProbeToken, NgZone, Optional, Output, PACKAGE_ROOT_URL, PLATFORM_ID, PLATFORM_INITIALIZER, Pipe, PlatformRef, Query, QueryList, ReflectiveInjector, ReflectiveKey, Renderer2, RendererFactory2, RendererStyleFlags2, ResolvedReflectiveFactory, Sanitizer, SecurityContext, Self, SimpleChange, SkipSelf, SystemJsNgModuleLoader, SystemJsNgModuleLoaderConfig, TRANSLATIONS, TRANSLATIONS_FORMAT, TemplateRef, Testability, TestabilityRegistry, Type, VERSION, Version, ViewChild, ViewChildren, ViewContainerRef, ViewEncapsulation, ViewRef, WrappedValue, asNativeElements, assertPlatform, createPlatform, createPlatformFactory, defineInjectable, destroyPlatform, enableProdMode, forwardRef, getDebugNode, getModuleFactory, getPlatform, inject, isDevMode, platformCore, resolveForwardRef, setTestabilityGetter, ɵALLOW_MULTIPLE_PLATFORMS, ɵAPP_ID_RANDOM_PROVIDER, ɵChangeDetectorStatus, ɵCodegenComponentFactoryResolver, ɵCompiler_compileModuleAndAllComponentsAsync__POST_R3__, ɵCompiler_compileModuleAndAllComponentsSync__POST_R3__, ɵCompiler_compileModuleAsync__POST_R3__, ɵCompiler_compileModuleSync__POST_R3__, ɵComponentFactory, ɵConsole, ɵDEFAULT_LOCALE_ID, ɵEMPTY_ARRAY, ɵEMPTY_MAP, ɵINJECTOR_IMPL__POST_R3__, ɵINJECTOR_SCOPE, ɵLifecycleHooksFeature, ɵLocaleDataIndex, ɵNG_COMP_DEF, ɵNG_DIR_DEF, ɵNG_ELEMENT_ID, ɵNG_INJ_DEF, ɵNG_MOD_DEF, ɵNG_PIPE_DEF, ɵNG_PROV_DEF, ɵNOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR, ɵNO_CHANGE, ɵNgModuleFactory, ɵNoopNgZone, ɵReflectionCapabilities, ɵRender3ComponentFactory, ɵRender3ComponentRef, ɵRender3NgModuleRef, ɵSWITCH_CHANGE_DETECTOR_REF_FACTORY__POST_R3__, ɵSWITCH_COMPILE_COMPONENT__POST_R3__, ɵSWITCH_COMPILE_DIRECTIVE__POST_R3__, ɵSWITCH_COMPILE_INJECTABLE__POST_R3__, ɵSWITCH_COMPILE_NGMODULE__POST_R3__, ɵSWITCH_COMPILE_PIPE__POST_R3__, ɵSWITCH_ELEMENT_REF_FACTORY__POST_R3__, ɵSWITCH_IVY_ENABLED__POST_R3__, ɵSWITCH_RENDERER2_FACTORY__POST_R3__, ɵSWITCH_TEMPLATE_REF_FACTORY__POST_R3__, ɵSWITCH_VIEW_CONTAINER_REF_FACTORY__POST_R3__, ɵ_sanitizeHtml, ɵ_sanitizeStyle, ɵ_sanitizeUrl, ɵallowSanitizationBypassAndThrow, ɵand, ɵangular_packages_core_core_a, ɵangular_packages_core_core_b, ɵangular_packages_core_core_ba, ɵangular_packages_core_core_bb, ɵangular_packages_core_core_bc, ɵangular_packages_core_core_bd, ɵangular_packages_core_core_bf, ɵangular_packages_core_core_bg, ɵangular_packages_core_core_bh, ɵangular_packages_core_core_bi, ɵangular_packages_core_core_bj, ɵangular_packages_core_core_bk, ɵangular_packages_core_core_bl, ɵangular_packages_core_core_bm, ɵangular_packages_core_core_bn, ɵangular_packages_core_core_bp, ɵangular_packages_core_core_bq, ɵangular_packages_core_core_c, ɵangular_packages_core_core_d, ɵangular_packages_core_core_e, ɵangular_packages_core_core_f, ɵangular_packages_core_core_g, ɵangular_packages_core_core_h, ɵangular_packages_core_core_i, ɵangular_packages_core_core_j, ɵangular_packages_core_core_k, ɵangular_packages_core_core_l, ɵangular_packages_core_core_m, ɵangular_packages_core_core_n, ɵangular_packages_core_core_o, ɵangular_packages_core_core_p, ɵangular_packages_core_core_q, ɵangular_packages_core_core_r, ɵangular_packages_core_core_s, ɵangular_packages_core_core_t, ɵangular_packages_core_core_u, ɵangular_packages_core_core_v, ɵangular_packages_core_core_w, ɵangular_packages_core_core_x, ɵangular_packages_core_core_y, ɵangular_packages_core_core_z, ɵbypassSanitizationTrustHtml, ɵbypassSanitizationTrustResourceUrl, ɵbypassSanitizationTrustScript, ɵbypassSanitizationTrustStyle, ɵbypassSanitizationTrustUrl, ɵccf, ɵclearOverrides, ɵclearResolutionOfComponentResourcesQueue, ɵcmf, ɵcompileComponent, ɵcompileDirective, ɵcompileNgModule, ɵcompileNgModuleDefs, ɵcompileNgModuleFactory__POST_R3__, ɵcompilePipe, ɵcreateInjector, ɵcrt, ɵdefaultIterableDiffers, ɵdefaultKeyValueDiffers, ɵdetectChanges, ɵdevModeEqual, ɵdid, ɵeld, ɵfindLocaleData, ɵflushModuleScopingQueueAsMuchAsPossible, ɵgetComponentViewDefinitionFactory, ɵgetDebugNodeR2, ɵgetDebugNode__POST_R3__, ɵgetDirectives, ɵgetHostElement, ɵgetInjectableDef, ɵgetLContext, ɵgetLocaleCurrencyCode, ɵgetLocalePluralCase, ɵgetModuleFactory__POST_R3__, ɵgetSanitizationBypassType, ɵglobal, ɵinitServicesIfNeeded, ɵinlineInterpolate, ɵinterpolate, ɵisBoundToModule__POST_R3__, ɵisDefaultChangeDetectionStrategy, ɵisListLikeIterable, ɵisObservable, ɵisPromise, ɵivyEnabled, ɵlooseIdentical, ɵmakeDecorator, ɵmarkDirty, ɵmod, ɵmpd, ɵncd, ɵnov, ɵoverrideComponentView, ɵoverrideProvider, ɵpad, ɵpatchComponentDefWithScope, ɵpid, ɵpod, ɵppd, ɵprd, ɵpublishDefaultGlobalUtils, ɵpublishGlobalUtil, ɵqud, ɵregisterLocaleData, ɵregisterModuleFactory, ɵregisterNgModuleType, ɵrenderComponent, ɵresetCompiledComponents, ɵresetJitOptions, ɵresolveComponentResources, ɵsetClassMetadata, ɵsetCurrentInjector, ɵsetDocument, ɵsetLocaleId, ɵstore, ɵstringify, ɵted, ɵtransitiveScopesFor, ɵunregisterLocaleData, ɵunv, ɵunwrapSafeValue, ɵvid, ɵwhenRendered, ɵɵCopyDefinitionFeature, ɵɵInheritDefinitionFeature, ɵɵNgOnChangesFeature, ɵɵProvidersFeature, ɵɵadvance, ɵɵattribute, ɵɵattributeInterpolate1, ɵɵattributeInterpolate2, ɵɵattributeInterpolate3, ɵɵattributeInterpolate4, ɵɵattributeInterpolate5, ɵɵattributeInterpolate6, ɵɵattributeInterpolate7, ɵɵattributeInterpolate8, ɵɵattributeInterpolateV, ɵɵclassMap, ɵɵclassMapInterpolate1, ɵɵclassMapInterpolate2, ɵɵclassMapInterpolate3, ɵɵclassMapInterpolate4, ɵɵclassMapInterpolate5, ɵɵclassMapInterpolate6, ɵɵclassMapInterpolate7, ɵɵclassMapInterpolate8, ɵɵclassMapInterpolateV, ɵɵclassProp, ɵɵcomponentHostSyntheticListener, ɵɵcontainer, ɵɵcontainerRefreshEnd, ɵɵcontainerRefreshStart, ɵɵcontentQuery, ɵɵdefaultStyleSanitizer, ɵɵdefineComponent, ɵɵdefineDirective, ɵɵdefineInjectable, ɵɵdefineInjector, ɵɵdefineNgModule, ɵɵdefinePipe, ɵɵdirectiveInject, ɵɵdisableBindings, ɵɵelement, ɵɵelementContainer, ɵɵelementContainerEnd, ɵɵelementContainerStart, ɵɵelementEnd, ɵɵelementStart, ɵɵembeddedViewEnd, ɵɵembeddedViewStart, ɵɵenableBindings, ɵɵgetCurrentView, ɵɵgetFactoryOf, ɵɵgetInheritedFactory, ɵɵhostProperty, ɵɵi18n, ɵɵi18nApply, ɵɵi18nAttributes, ɵɵi18nEnd, ɵɵi18nExp, ɵɵi18nPostprocess, ɵɵi18nStart, ɵɵinject, ɵɵinjectAttribute, ɵɵinjectPipeChangeDetectorRef, ɵɵinvalidFactory, ɵɵinvalidFactoryDep, ɵɵlistener, ɵɵloadQuery, ɵɵnamespaceHTML, ɵɵnamespaceMathML, ɵɵnamespaceSVG, ɵɵnextContext, ɵɵpipe, ɵɵpipeBind1, ɵɵpipeBind2, ɵɵpipeBind3, ɵɵpipeBind4, ɵɵpipeBindV, ɵɵprojection, ɵɵprojectionDef, ɵɵproperty, ɵɵpropertyInterpolate, ɵɵpropertyInterpolate1, ɵɵpropertyInterpolate2, ɵɵpropertyInterpolate3, ɵɵpropertyInterpolate4, ɵɵpropertyInterpolate5, ɵɵpropertyInterpolate6, ɵɵpropertyInterpolate7, ɵɵpropertyInterpolate8, ɵɵpropertyInterpolateV, ɵɵpureFunction0, ɵɵpureFunction1, ɵɵpureFunction2, ɵɵpureFunction3, ɵɵpureFunction4, ɵɵpureFunction5, ɵɵpureFunction6, ɵɵpureFunction7, ɵɵpureFunction8, ɵɵpureFunctionV, ɵɵqueryRefresh, ɵɵreference, ɵɵresolveBody, ɵɵresolveDocument, ɵɵresolveWindow, ɵɵrestoreView, ɵɵsanitizeHtml, ɵɵsanitizeResourceUrl, ɵɵsanitizeScript, ɵɵsanitizeStyle, ɵɵsanitizeUrl, ɵɵsanitizeUrlOrResourceUrl, ɵɵselect, ɵɵsetComponentScope, ɵɵsetNgModuleScope, ɵɵstaticContentQuery, ɵɵstaticViewQuery, ɵɵstyleMap, ɵɵstyleMapInterpolate1, ɵɵstyleMapInterpolate2, ɵɵstyleMapInterpolate3, ɵɵstyleMapInterpolate4, ɵɵstyleMapInterpolate5, ɵɵstyleMapInterpolate6, ɵɵstyleMapInterpolate7, ɵɵstyleMapInterpolate8, ɵɵstyleMapInterpolateV, ɵɵstyleProp, ɵɵstylePropInterpolate1, ɵɵstylePropInterpolate2, ɵɵstylePropInterpolate3, ɵɵstylePropInterpolate4, ɵɵstylePropInterpolate5, ɵɵstylePropInterpolate6, ɵɵstylePropInterpolate7, ɵɵstylePropInterpolate8, ɵɵstylePropInterpolateV, ɵɵstyleSanitizer, ɵɵtemplate, ɵɵtemplateRefExtractor, ɵɵtext, ɵɵtextInterpolate, ɵɵtextInterpolate1, ɵɵtextInterpolate2, ɵɵtextInterpolate3, ɵɵtextInterpolate4, ɵɵtextInterpolate5, ɵɵtextInterpolate6, ɵɵtextInterpolate7, ɵɵtextInterpolate8, ɵɵtextInterpolateV, ɵɵupdateSyntheticHostBinding, ɵɵviewQuery */

  /***/
  function node_modulesAngularCore__ivy_ngcc__Fesm2015CoreJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ANALYZE_FOR_ENTRY_COMPONENTS", function () {
      return ANALYZE_FOR_ENTRY_COMPONENTS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "APP_BOOTSTRAP_LISTENER", function () {
      return APP_BOOTSTRAP_LISTENER;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "APP_ID", function () {
      return APP_ID;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "APP_INITIALIZER", function () {
      return APP_INITIALIZER;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ApplicationInitStatus", function () {
      return ApplicationInitStatus;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ApplicationModule", function () {
      return ApplicationModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ApplicationRef", function () {
      return ApplicationRef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Attribute", function () {
      return Attribute;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "COMPILER_OPTIONS", function () {
      return COMPILER_OPTIONS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CUSTOM_ELEMENTS_SCHEMA", function () {
      return CUSTOM_ELEMENTS_SCHEMA;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ChangeDetectionStrategy", function () {
      return ChangeDetectionStrategy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ChangeDetectorRef", function () {
      return ChangeDetectorRef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Compiler", function () {
      return Compiler;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CompilerFactory", function () {
      return CompilerFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Component", function () {
      return Component;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ComponentFactory", function () {
      return ComponentFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ComponentFactoryResolver", function () {
      return ComponentFactoryResolver;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ComponentRef", function () {
      return ComponentRef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ContentChild", function () {
      return ContentChild;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ContentChildren", function () {
      return ContentChildren;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DEFAULT_CURRENCY_CODE", function () {
      return DEFAULT_CURRENCY_CODE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DebugElement", function () {
      return DebugElement;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DebugEventListener", function () {
      return DebugEventListener;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DebugNode", function () {
      return DebugNode$1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DefaultIterableDiffer", function () {
      return DefaultIterableDiffer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Directive", function () {
      return Directive;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ElementRef", function () {
      return ElementRef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "EmbeddedViewRef", function () {
      return EmbeddedViewRef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ErrorHandler", function () {
      return ErrorHandler;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "EventEmitter", function () {
      return EventEmitter;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Host", function () {
      return Host;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HostBinding", function () {
      return HostBinding;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HostListener", function () {
      return HostListener;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "INJECTOR", function () {
      return INJECTOR;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Inject", function () {
      return Inject;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "InjectFlags", function () {
      return InjectFlags;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Injectable", function () {
      return Injectable;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "InjectionToken", function () {
      return InjectionToken;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Injector", function () {
      return Injector;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Input", function () {
      return Input;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "IterableDiffers", function () {
      return IterableDiffers;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "KeyValueDiffers", function () {
      return KeyValueDiffers;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "LOCALE_ID", function () {
      return LOCALE_ID$1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MissingTranslationStrategy", function () {
      return MissingTranslationStrategy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ModuleWithComponentFactories", function () {
      return ModuleWithComponentFactories;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NO_ERRORS_SCHEMA", function () {
      return NO_ERRORS_SCHEMA;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgModule", function () {
      return NgModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgModuleFactory", function () {
      return NgModuleFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgModuleFactoryLoader", function () {
      return NgModuleFactoryLoader;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgModuleRef", function () {
      return NgModuleRef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgProbeToken", function () {
      return NgProbeToken;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgZone", function () {
      return NgZone;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Optional", function () {
      return Optional;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Output", function () {
      return Output;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "PACKAGE_ROOT_URL", function () {
      return PACKAGE_ROOT_URL;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "PLATFORM_ID", function () {
      return PLATFORM_ID;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "PLATFORM_INITIALIZER", function () {
      return PLATFORM_INITIALIZER;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Pipe", function () {
      return Pipe;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "PlatformRef", function () {
      return PlatformRef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Query", function () {
      return Query;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "QueryList", function () {
      return QueryList;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ReflectiveInjector", function () {
      return ReflectiveInjector;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ReflectiveKey", function () {
      return ReflectiveKey;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Renderer2", function () {
      return Renderer2;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RendererFactory2", function () {
      return RendererFactory2;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RendererStyleFlags2", function () {
      return RendererStyleFlags2;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ResolvedReflectiveFactory", function () {
      return ResolvedReflectiveFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Sanitizer", function () {
      return Sanitizer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SecurityContext", function () {
      return SecurityContext;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Self", function () {
      return Self;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SimpleChange", function () {
      return SimpleChange;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SkipSelf", function () {
      return SkipSelf;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SystemJsNgModuleLoader", function () {
      return SystemJsNgModuleLoader;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SystemJsNgModuleLoaderConfig", function () {
      return SystemJsNgModuleLoaderConfig;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "TRANSLATIONS", function () {
      return TRANSLATIONS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "TRANSLATIONS_FORMAT", function () {
      return TRANSLATIONS_FORMAT;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "TemplateRef", function () {
      return TemplateRef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Testability", function () {
      return Testability;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "TestabilityRegistry", function () {
      return TestabilityRegistry;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Type", function () {
      return Type;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "VERSION", function () {
      return VERSION;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Version", function () {
      return Version;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ViewChild", function () {
      return ViewChild;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ViewChildren", function () {
      return ViewChildren;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ViewContainerRef", function () {
      return ViewContainerRef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ViewEncapsulation", function () {
      return ViewEncapsulation$1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ViewRef", function () {
      return ViewRef$1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "WrappedValue", function () {
      return WrappedValue;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "asNativeElements", function () {
      return asNativeElements;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "assertPlatform", function () {
      return assertPlatform;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "createPlatform", function () {
      return createPlatform;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "createPlatformFactory", function () {
      return createPlatformFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "defineInjectable", function () {
      return defineInjectable;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "destroyPlatform", function () {
      return destroyPlatform;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "enableProdMode", function () {
      return enableProdMode;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "forwardRef", function () {
      return forwardRef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getDebugNode", function () {
      return getDebugNode$1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getModuleFactory", function () {
      return getModuleFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getPlatform", function () {
      return getPlatform;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "inject", function () {
      return inject;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "isDevMode", function () {
      return isDevMode;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "platformCore", function () {
      return platformCore;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "resolveForwardRef", function () {
      return resolveForwardRef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "setTestabilityGetter", function () {
      return setTestabilityGetter;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵALLOW_MULTIPLE_PLATFORMS", function () {
      return ALLOW_MULTIPLE_PLATFORMS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵAPP_ID_RANDOM_PROVIDER", function () {
      return APP_ID_RANDOM_PROVIDER;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵChangeDetectorStatus", function () {
      return ChangeDetectorStatus;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵCodegenComponentFactoryResolver", function () {
      return CodegenComponentFactoryResolver;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵCompiler_compileModuleAndAllComponentsAsync__POST_R3__", function () {
      return Compiler_compileModuleAndAllComponentsAsync__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵCompiler_compileModuleAndAllComponentsSync__POST_R3__", function () {
      return Compiler_compileModuleAndAllComponentsSync__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵCompiler_compileModuleAsync__POST_R3__", function () {
      return Compiler_compileModuleAsync__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵCompiler_compileModuleSync__POST_R3__", function () {
      return Compiler_compileModuleSync__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵComponentFactory", function () {
      return ComponentFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵConsole", function () {
      return Console;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵDEFAULT_LOCALE_ID", function () {
      return DEFAULT_LOCALE_ID;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵEMPTY_ARRAY", function () {
      return EMPTY_ARRAY$4;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵEMPTY_MAP", function () {
      return EMPTY_MAP;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵINJECTOR_IMPL__POST_R3__", function () {
      return INJECTOR_IMPL__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵINJECTOR_SCOPE", function () {
      return INJECTOR_SCOPE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵLifecycleHooksFeature", function () {
      return LifecycleHooksFeature;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵLocaleDataIndex", function () {
      return LocaleDataIndex;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵNG_COMP_DEF", function () {
      return NG_COMP_DEF;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵNG_DIR_DEF", function () {
      return NG_DIR_DEF;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵNG_ELEMENT_ID", function () {
      return NG_ELEMENT_ID;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵNG_INJ_DEF", function () {
      return NG_INJ_DEF;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵNG_MOD_DEF", function () {
      return NG_MOD_DEF;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵNG_PIPE_DEF", function () {
      return NG_PIPE_DEF;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵNG_PROV_DEF", function () {
      return NG_PROV_DEF;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵNOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR", function () {
      return NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵNO_CHANGE", function () {
      return NO_CHANGE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵNgModuleFactory", function () {
      return NgModuleFactory$1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵNoopNgZone", function () {
      return NoopNgZone;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵReflectionCapabilities", function () {
      return ReflectionCapabilities;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵRender3ComponentFactory", function () {
      return ComponentFactory$1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵRender3ComponentRef", function () {
      return ComponentRef$1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵRender3NgModuleRef", function () {
      return NgModuleRef$1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵSWITCH_CHANGE_DETECTOR_REF_FACTORY__POST_R3__", function () {
      return SWITCH_CHANGE_DETECTOR_REF_FACTORY__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵSWITCH_COMPILE_COMPONENT__POST_R3__", function () {
      return SWITCH_COMPILE_COMPONENT__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵSWITCH_COMPILE_DIRECTIVE__POST_R3__", function () {
      return SWITCH_COMPILE_DIRECTIVE__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵSWITCH_COMPILE_INJECTABLE__POST_R3__", function () {
      return SWITCH_COMPILE_INJECTABLE__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵSWITCH_COMPILE_NGMODULE__POST_R3__", function () {
      return SWITCH_COMPILE_NGMODULE__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵSWITCH_COMPILE_PIPE__POST_R3__", function () {
      return SWITCH_COMPILE_PIPE__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵSWITCH_ELEMENT_REF_FACTORY__POST_R3__", function () {
      return SWITCH_ELEMENT_REF_FACTORY__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵSWITCH_IVY_ENABLED__POST_R3__", function () {
      return SWITCH_IVY_ENABLED__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵSWITCH_RENDERER2_FACTORY__POST_R3__", function () {
      return SWITCH_RENDERER2_FACTORY__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵSWITCH_TEMPLATE_REF_FACTORY__POST_R3__", function () {
      return SWITCH_TEMPLATE_REF_FACTORY__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵSWITCH_VIEW_CONTAINER_REF_FACTORY__POST_R3__", function () {
      return SWITCH_VIEW_CONTAINER_REF_FACTORY__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵ_sanitizeHtml", function () {
      return _sanitizeHtml;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵ_sanitizeStyle", function () {
      return _sanitizeStyle;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵ_sanitizeUrl", function () {
      return _sanitizeUrl;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵallowSanitizationBypassAndThrow", function () {
      return allowSanitizationBypassAndThrow;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵand", function () {
      return anchorDef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_a", function () {
      return isForwardRef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_b", function () {
      return injectInjectorOnly;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_ba", function () {
      return getLView;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bb", function () {
      return getPreviousOrParentTNode;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bc", function () {
      return getBindingRoot;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bd", function () {
      return nextContextImpl;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bf", function () {
      return pureFunction1Internal;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bg", function () {
      return pureFunction2Internal;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bh", function () {
      return pureFunction3Internal;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bi", function () {
      return pureFunction4Internal;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bj", function () {
      return pureFunctionVInternal;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bk", function () {
      return getUrlSanitizer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bl", function () {
      return makeParamDecorator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bm", function () {
      return makePropDecorator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bn", function () {
      return getClosureSafeProperty;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bp", function () {
      return noSideEffects;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bq", function () {
      return getRootContext;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_c", function () {
      return NullInjector;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_d", function () {
      return ReflectiveInjector_;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_e", function () {
      return ReflectiveDependency;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_f", function () {
      return resolveReflectiveProviders;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_g", function () {
      return _appIdRandomProviderFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_h", function () {
      return createElementRef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_i", function () {
      return createTemplateRef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_j", function () {
      return getModuleFactory__PRE_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_k", function () {
      return DebugNode__PRE_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_l", function () {
      return DebugElement__PRE_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_m", function () {
      return getDebugNodeR2__PRE_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_n", function () {
      return DefaultIterableDifferFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_o", function () {
      return DefaultKeyValueDifferFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_p", function () {
      return _iterableDiffersFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_q", function () {
      return _keyValueDiffersFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_r", function () {
      return _localeFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_s", function () {
      return APPLICATION_MODULE_PROVIDERS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_t", function () {
      return zoneSchedulerFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_u", function () {
      return USD_CURRENCY_CODE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_v", function () {
      return _def;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_w", function () {
      return DebugContext;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_x", function () {
      return SCHEDULER;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_y", function () {
      return injectAttributeImpl;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_z", function () {
      return instructionState;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵbypassSanitizationTrustHtml", function () {
      return bypassSanitizationTrustHtml;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵbypassSanitizationTrustResourceUrl", function () {
      return bypassSanitizationTrustResourceUrl;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵbypassSanitizationTrustScript", function () {
      return bypassSanitizationTrustScript;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵbypassSanitizationTrustStyle", function () {
      return bypassSanitizationTrustStyle;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵbypassSanitizationTrustUrl", function () {
      return bypassSanitizationTrustUrl;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵccf", function () {
      return createComponentFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵclearOverrides", function () {
      return clearOverrides;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵclearResolutionOfComponentResourcesQueue", function () {
      return clearResolutionOfComponentResourcesQueue;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵcmf", function () {
      return createNgModuleFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵcompileComponent", function () {
      return compileComponent;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵcompileDirective", function () {
      return compileDirective;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵcompileNgModule", function () {
      return compileNgModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵcompileNgModuleDefs", function () {
      return compileNgModuleDefs;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵcompileNgModuleFactory__POST_R3__", function () {
      return compileNgModuleFactory__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵcompilePipe", function () {
      return compilePipe;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵcreateInjector", function () {
      return createInjector;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵcrt", function () {
      return createRendererType2;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵdefaultIterableDiffers", function () {
      return defaultIterableDiffers;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵdefaultKeyValueDiffers", function () {
      return defaultKeyValueDiffers;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵdetectChanges", function () {
      return detectChanges;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵdevModeEqual", function () {
      return devModeEqual$1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵdid", function () {
      return directiveDef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵeld", function () {
      return elementDef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵfindLocaleData", function () {
      return findLocaleData;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵflushModuleScopingQueueAsMuchAsPossible", function () {
      return flushModuleScopingQueueAsMuchAsPossible;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵgetComponentViewDefinitionFactory", function () {
      return getComponentViewDefinitionFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵgetDebugNodeR2", function () {
      return getDebugNodeR2;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵgetDebugNode__POST_R3__", function () {
      return getDebugNode__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵgetDirectives", function () {
      return getDirectives;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵgetHostElement", function () {
      return getHostElement;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵgetInjectableDef", function () {
      return getInjectableDef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵgetLContext", function () {
      return getLContext;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵgetLocaleCurrencyCode", function () {
      return getLocaleCurrencyCode;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵgetLocalePluralCase", function () {
      return getLocalePluralCase;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵgetModuleFactory__POST_R3__", function () {
      return getModuleFactory__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵgetSanitizationBypassType", function () {
      return getSanitizationBypassType;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵglobal", function () {
      return _global;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵinitServicesIfNeeded", function () {
      return initServicesIfNeeded;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵinlineInterpolate", function () {
      return inlineInterpolate;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵinterpolate", function () {
      return interpolate;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵisBoundToModule__POST_R3__", function () {
      return isBoundToModule__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵisDefaultChangeDetectionStrategy", function () {
      return isDefaultChangeDetectionStrategy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵisListLikeIterable", function () {
      return isListLikeIterable$1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵisObservable", function () {
      return isObservable;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵisPromise", function () {
      return isPromise;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵivyEnabled", function () {
      return ivyEnabled;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵlooseIdentical", function () {
      return looseIdentical;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵmakeDecorator", function () {
      return makeDecorator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵmarkDirty", function () {
      return markDirty;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵmod", function () {
      return moduleDef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵmpd", function () {
      return moduleProvideDef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵncd", function () {
      return ngContentDef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵnov", function () {
      return nodeValue;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵoverrideComponentView", function () {
      return overrideComponentView;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵoverrideProvider", function () {
      return overrideProvider;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵpad", function () {
      return pureArrayDef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵpatchComponentDefWithScope", function () {
      return patchComponentDefWithScope;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵpid", function () {
      return pipeDef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵpod", function () {
      return pureObjectDef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵppd", function () {
      return purePipeDef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵprd", function () {
      return providerDef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵpublishDefaultGlobalUtils", function () {
      return publishDefaultGlobalUtils;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵpublishGlobalUtil", function () {
      return publishGlobalUtil;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵqud", function () {
      return queryDef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵregisterLocaleData", function () {
      return registerLocaleData;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵregisterModuleFactory", function () {
      return registerModuleFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵregisterNgModuleType", function () {
      return registerNgModuleType;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵrenderComponent", function () {
      return renderComponent$1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵresetCompiledComponents", function () {
      return resetCompiledComponents;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵresetJitOptions", function () {
      return resetJitOptions;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵresolveComponentResources", function () {
      return resolveComponentResources;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵsetClassMetadata", function () {
      return setClassMetadata;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵsetCurrentInjector", function () {
      return setCurrentInjector;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵsetDocument", function () {
      return setDocument;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵsetLocaleId", function () {
      return setLocaleId;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵstore", function () {
      return store;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵstringify", function () {
      return stringify;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵted", function () {
      return textDef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵtransitiveScopesFor", function () {
      return transitiveScopesFor;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵunregisterLocaleData", function () {
      return unregisterAllLocaleData;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵunv", function () {
      return unwrapValue;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵunwrapSafeValue", function () {
      return unwrapSafeValue;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵvid", function () {
      return viewDef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵwhenRendered", function () {
      return whenRendered;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵCopyDefinitionFeature", function () {
      return ɵɵCopyDefinitionFeature;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵInheritDefinitionFeature", function () {
      return ɵɵInheritDefinitionFeature;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵNgOnChangesFeature", function () {
      return ɵɵNgOnChangesFeature;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵProvidersFeature", function () {
      return ɵɵProvidersFeature;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵadvance", function () {
      return ɵɵadvance;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵattribute", function () {
      return ɵɵattribute;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵattributeInterpolate1", function () {
      return ɵɵattributeInterpolate1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵattributeInterpolate2", function () {
      return ɵɵattributeInterpolate2;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵattributeInterpolate3", function () {
      return ɵɵattributeInterpolate3;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵattributeInterpolate4", function () {
      return ɵɵattributeInterpolate4;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵattributeInterpolate5", function () {
      return ɵɵattributeInterpolate5;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵattributeInterpolate6", function () {
      return ɵɵattributeInterpolate6;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵattributeInterpolate7", function () {
      return ɵɵattributeInterpolate7;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵattributeInterpolate8", function () {
      return ɵɵattributeInterpolate8;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵattributeInterpolateV", function () {
      return ɵɵattributeInterpolateV;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵclassMap", function () {
      return ɵɵclassMap;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵclassMapInterpolate1", function () {
      return ɵɵclassMapInterpolate1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵclassMapInterpolate2", function () {
      return ɵɵclassMapInterpolate2;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵclassMapInterpolate3", function () {
      return ɵɵclassMapInterpolate3;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵclassMapInterpolate4", function () {
      return ɵɵclassMapInterpolate4;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵclassMapInterpolate5", function () {
      return ɵɵclassMapInterpolate5;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵclassMapInterpolate6", function () {
      return ɵɵclassMapInterpolate6;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵclassMapInterpolate7", function () {
      return ɵɵclassMapInterpolate7;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵclassMapInterpolate8", function () {
      return ɵɵclassMapInterpolate8;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵclassMapInterpolateV", function () {
      return ɵɵclassMapInterpolateV;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵclassProp", function () {
      return ɵɵclassProp;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵcomponentHostSyntheticListener", function () {
      return ɵɵcomponentHostSyntheticListener;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵcontainer", function () {
      return ɵɵcontainer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵcontainerRefreshEnd", function () {
      return ɵɵcontainerRefreshEnd;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵcontainerRefreshStart", function () {
      return ɵɵcontainerRefreshStart;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵcontentQuery", function () {
      return ɵɵcontentQuery;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵdefaultStyleSanitizer", function () {
      return ɵɵdefaultStyleSanitizer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵdefineComponent", function () {
      return ɵɵdefineComponent;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵdefineDirective", function () {
      return ɵɵdefineDirective;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵdefineInjectable", function () {
      return ɵɵdefineInjectable;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵdefineInjector", function () {
      return ɵɵdefineInjector;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵdefineNgModule", function () {
      return ɵɵdefineNgModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵdefinePipe", function () {
      return ɵɵdefinePipe;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵdirectiveInject", function () {
      return ɵɵdirectiveInject;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵdisableBindings", function () {
      return ɵɵdisableBindings;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵelement", function () {
      return ɵɵelement;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵelementContainer", function () {
      return ɵɵelementContainer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵelementContainerEnd", function () {
      return ɵɵelementContainerEnd;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵelementContainerStart", function () {
      return ɵɵelementContainerStart;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵelementEnd", function () {
      return ɵɵelementEnd;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵelementStart", function () {
      return ɵɵelementStart;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵembeddedViewEnd", function () {
      return ɵɵembeddedViewEnd;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵembeddedViewStart", function () {
      return ɵɵembeddedViewStart;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵenableBindings", function () {
      return ɵɵenableBindings;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵgetCurrentView", function () {
      return ɵɵgetCurrentView;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵgetFactoryOf", function () {
      return ɵɵgetFactoryOf;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵgetInheritedFactory", function () {
      return ɵɵgetInheritedFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵhostProperty", function () {
      return ɵɵhostProperty;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵi18n", function () {
      return ɵɵi18n;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵi18nApply", function () {
      return ɵɵi18nApply;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵi18nAttributes", function () {
      return ɵɵi18nAttributes;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵi18nEnd", function () {
      return ɵɵi18nEnd;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵi18nExp", function () {
      return ɵɵi18nExp;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵi18nPostprocess", function () {
      return ɵɵi18nPostprocess;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵi18nStart", function () {
      return ɵɵi18nStart;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵinject", function () {
      return ɵɵinject;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵinjectAttribute", function () {
      return ɵɵinjectAttribute;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵinjectPipeChangeDetectorRef", function () {
      return ɵɵinjectPipeChangeDetectorRef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵinvalidFactory", function () {
      return ɵɵinvalidFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵinvalidFactoryDep", function () {
      return ɵɵinvalidFactoryDep;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵlistener", function () {
      return ɵɵlistener;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵloadQuery", function () {
      return ɵɵloadQuery;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵnamespaceHTML", function () {
      return ɵɵnamespaceHTML;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵnamespaceMathML", function () {
      return ɵɵnamespaceMathML;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵnamespaceSVG", function () {
      return ɵɵnamespaceSVG;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵnextContext", function () {
      return ɵɵnextContext;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpipe", function () {
      return ɵɵpipe;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpipeBind1", function () {
      return ɵɵpipeBind1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpipeBind2", function () {
      return ɵɵpipeBind2;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpipeBind3", function () {
      return ɵɵpipeBind3;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpipeBind4", function () {
      return ɵɵpipeBind4;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpipeBindV", function () {
      return ɵɵpipeBindV;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵprojection", function () {
      return ɵɵprojection;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵprojectionDef", function () {
      return ɵɵprojectionDef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵproperty", function () {
      return ɵɵproperty;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpropertyInterpolate", function () {
      return ɵɵpropertyInterpolate;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpropertyInterpolate1", function () {
      return ɵɵpropertyInterpolate1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpropertyInterpolate2", function () {
      return ɵɵpropertyInterpolate2;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpropertyInterpolate3", function () {
      return ɵɵpropertyInterpolate3;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpropertyInterpolate4", function () {
      return ɵɵpropertyInterpolate4;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpropertyInterpolate5", function () {
      return ɵɵpropertyInterpolate5;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpropertyInterpolate6", function () {
      return ɵɵpropertyInterpolate6;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpropertyInterpolate7", function () {
      return ɵɵpropertyInterpolate7;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpropertyInterpolate8", function () {
      return ɵɵpropertyInterpolate8;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpropertyInterpolateV", function () {
      return ɵɵpropertyInterpolateV;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpureFunction0", function () {
      return ɵɵpureFunction0;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpureFunction1", function () {
      return ɵɵpureFunction1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpureFunction2", function () {
      return ɵɵpureFunction2;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpureFunction3", function () {
      return ɵɵpureFunction3;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpureFunction4", function () {
      return ɵɵpureFunction4;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpureFunction5", function () {
      return ɵɵpureFunction5;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpureFunction6", function () {
      return ɵɵpureFunction6;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpureFunction7", function () {
      return ɵɵpureFunction7;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpureFunction8", function () {
      return ɵɵpureFunction8;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵpureFunctionV", function () {
      return ɵɵpureFunctionV;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵqueryRefresh", function () {
      return ɵɵqueryRefresh;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵreference", function () {
      return ɵɵreference;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵresolveBody", function () {
      return ɵɵresolveBody;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵresolveDocument", function () {
      return ɵɵresolveDocument;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵresolveWindow", function () {
      return ɵɵresolveWindow;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵrestoreView", function () {
      return ɵɵrestoreView;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵsanitizeHtml", function () {
      return ɵɵsanitizeHtml;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵsanitizeResourceUrl", function () {
      return ɵɵsanitizeResourceUrl;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵsanitizeScript", function () {
      return ɵɵsanitizeScript;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵsanitizeStyle", function () {
      return ɵɵsanitizeStyle;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵsanitizeUrl", function () {
      return ɵɵsanitizeUrl;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵsanitizeUrlOrResourceUrl", function () {
      return ɵɵsanitizeUrlOrResourceUrl;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵselect", function () {
      return ɵɵselect;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵsetComponentScope", function () {
      return ɵɵsetComponentScope;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵsetNgModuleScope", function () {
      return ɵɵsetNgModuleScope;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstaticContentQuery", function () {
      return ɵɵstaticContentQuery;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstaticViewQuery", function () {
      return ɵɵstaticViewQuery;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstyleMap", function () {
      return ɵɵstyleMap;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstyleMapInterpolate1", function () {
      return ɵɵstyleMapInterpolate1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstyleMapInterpolate2", function () {
      return ɵɵstyleMapInterpolate2;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstyleMapInterpolate3", function () {
      return ɵɵstyleMapInterpolate3;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstyleMapInterpolate4", function () {
      return ɵɵstyleMapInterpolate4;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstyleMapInterpolate5", function () {
      return ɵɵstyleMapInterpolate5;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstyleMapInterpolate6", function () {
      return ɵɵstyleMapInterpolate6;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstyleMapInterpolate7", function () {
      return ɵɵstyleMapInterpolate7;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstyleMapInterpolate8", function () {
      return ɵɵstyleMapInterpolate8;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstyleMapInterpolateV", function () {
      return ɵɵstyleMapInterpolateV;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstyleProp", function () {
      return ɵɵstyleProp;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstylePropInterpolate1", function () {
      return ɵɵstylePropInterpolate1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstylePropInterpolate2", function () {
      return ɵɵstylePropInterpolate2;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstylePropInterpolate3", function () {
      return ɵɵstylePropInterpolate3;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstylePropInterpolate4", function () {
      return ɵɵstylePropInterpolate4;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstylePropInterpolate5", function () {
      return ɵɵstylePropInterpolate5;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstylePropInterpolate6", function () {
      return ɵɵstylePropInterpolate6;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstylePropInterpolate7", function () {
      return ɵɵstylePropInterpolate7;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstylePropInterpolate8", function () {
      return ɵɵstylePropInterpolate8;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstylePropInterpolateV", function () {
      return ɵɵstylePropInterpolateV;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵstyleSanitizer", function () {
      return ɵɵstyleSanitizer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵtemplate", function () {
      return ɵɵtemplate;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵtemplateRefExtractor", function () {
      return ɵɵtemplateRefExtractor;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵtext", function () {
      return ɵɵtext;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵtextInterpolate", function () {
      return ɵɵtextInterpolate;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵtextInterpolate1", function () {
      return ɵɵtextInterpolate1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵtextInterpolate2", function () {
      return ɵɵtextInterpolate2;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵtextInterpolate3", function () {
      return ɵɵtextInterpolate3;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵtextInterpolate4", function () {
      return ɵɵtextInterpolate4;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵtextInterpolate5", function () {
      return ɵɵtextInterpolate5;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵtextInterpolate6", function () {
      return ɵɵtextInterpolate6;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵtextInterpolate7", function () {
      return ɵɵtextInterpolate7;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵtextInterpolate8", function () {
      return ɵɵtextInterpolate8;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵtextInterpolateV", function () {
      return ɵɵtextInterpolateV;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵupdateSyntheticHostBinding", function () {
      return ɵɵupdateSyntheticHostBinding;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵɵviewQuery", function () {
      return ɵɵviewQuery;
    });
    /* harmony import */


    var rxjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! rxjs */
    "./node_modules/rxjs/_esm2015/index.js");
    /* harmony import */


    var rxjs_operators__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! rxjs/operators */
    "./node_modules/rxjs/_esm2015/operators/index.js");
    /**
     * @license Angular v9.1.4
     * (c) 2010-2020 Google LLC. https://angular.io/
     * License: MIT
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Convince closure compiler that the wrapped function has no side-effects.
     *
     * Closure compiler always assumes that `toString` has no side-effects. We use this quirk to
     * allow us to execute a function but have closure compiler mark the call as no-side-effects.
     * It is important that the return value for the `noSideEffects` function be assigned
     * to something which is retained otherwise the call to `noSideEffects` will be removed by closure
     * compiler.
     */


    function noSideEffects(fn) {
      return {
        toString: fn
      }.toString();
    }
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */


    var ANNOTATIONS = '__annotations__';
    var PARAMETERS = '__parameters__';
    var PROP_METADATA = '__prop__metadata__';
    /**
     * @suppress {globalThis}
     */

    function makeDecorator(name, props, parentClass, additionalProcessing, typeFn) {
      return noSideEffects(function () {
        var metaCtor = makeMetadataCtor(props);

        function DecoratorFactory() {
          for (var _len7 = arguments.length, args = new Array(_len7), _key8 = 0; _key8 < _len7; _key8++) {
            args[_key8] = arguments[_key8];
          }

          if (this instanceof DecoratorFactory) {
            metaCtor.call.apply(metaCtor, [this].concat(args));
            return this;
          }

          var annotationInstance = _construct(DecoratorFactory, args);

          return function TypeDecorator(cls) {
            if (typeFn) typeFn.apply(void 0, [cls].concat(args)); // Use of Object.defineProperty is important since it creates non-enumerable property which
            // prevents the property is copied during subclassing.

            var annotations = cls.hasOwnProperty(ANNOTATIONS) ? cls[ANNOTATIONS] : Object.defineProperty(cls, ANNOTATIONS, {
              value: []
            })[ANNOTATIONS];
            annotations.push(annotationInstance);
            if (additionalProcessing) additionalProcessing(cls);
            return cls;
          };
        }

        if (parentClass) {
          DecoratorFactory.prototype = Object.create(parentClass.prototype);
        }

        DecoratorFactory.prototype.ngMetadataName = name;
        DecoratorFactory.annotationCls = DecoratorFactory;
        return DecoratorFactory;
      });
    }

    function makeMetadataCtor(props) {
      return function ctor() {
        if (props) {
          var values = props.apply(void 0, arguments);

          for (var propName in values) {
            this[propName] = values[propName];
          }
        }
      };
    }

    function makeParamDecorator(name, props, parentClass) {
      return noSideEffects(function () {
        var metaCtor = makeMetadataCtor(props);

        function ParamDecoratorFactory() {
          for (var _len8 = arguments.length, args = new Array(_len8), _key9 = 0; _key9 < _len8; _key9++) {
            args[_key9] = arguments[_key9];
          }

          if (this instanceof ParamDecoratorFactory) {
            metaCtor.apply(this, args);
            return this;
          }

          var annotationInstance = _construct(ParamDecoratorFactory, args);

          ParamDecorator.annotation = annotationInstance;
          return ParamDecorator;

          function ParamDecorator(cls, unusedKey, index) {
            // Use of Object.defineProperty is important since it creates non-enumerable property which
            // prevents the property is copied during subclassing.
            var parameters = cls.hasOwnProperty(PARAMETERS) ? cls[PARAMETERS] : Object.defineProperty(cls, PARAMETERS, {
              value: []
            })[PARAMETERS]; // there might be gaps if some in between parameters do not have annotations.
            // we pad with nulls.

            while (parameters.length <= index) {
              parameters.push(null);
            }

            (parameters[index] = parameters[index] || []).push(annotationInstance);
            return cls;
          }
        }

        if (parentClass) {
          ParamDecoratorFactory.prototype = Object.create(parentClass.prototype);
        }

        ParamDecoratorFactory.prototype.ngMetadataName = name;
        ParamDecoratorFactory.annotationCls = ParamDecoratorFactory;
        return ParamDecoratorFactory;
      });
    }

    function makePropDecorator(name, props, parentClass, additionalProcessing) {
      return noSideEffects(function () {
        var metaCtor = makeMetadataCtor(props);

        function PropDecoratorFactory() {
          for (var _len9 = arguments.length, args = new Array(_len9), _key10 = 0; _key10 < _len9; _key10++) {
            args[_key10] = arguments[_key10];
          }

          if (this instanceof PropDecoratorFactory) {
            metaCtor.apply(this, args);
            return this;
          }

          var decoratorInstance = _construct(PropDecoratorFactory, args);

          function PropDecorator(target, name) {
            var constructor = target.constructor; // Use of Object.defineProperty is important since it creates non-enumerable property which
            // prevents the property is copied during subclassing.

            var meta = constructor.hasOwnProperty(PROP_METADATA) ? constructor[PROP_METADATA] : Object.defineProperty(constructor, PROP_METADATA, {
              value: {}
            })[PROP_METADATA];
            meta[name] = meta.hasOwnProperty(name) && meta[name] || [];
            meta[name].unshift(decoratorInstance);
            if (additionalProcessing) additionalProcessing.apply(void 0, [target, name].concat(args));
          }

          return PropDecorator;
        }

        if (parentClass) {
          PropDecoratorFactory.prototype = Object.create(parentClass.prototype);
        }

        PropDecoratorFactory.prototype.ngMetadataName = name;
        PropDecoratorFactory.annotationCls = PropDecoratorFactory;
        return PropDecoratorFactory;
      });
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/di/metadata.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Type of the Inject decorator / constructor function.
     *
     * \@publicApi
     * @record
     */


    function InjectDecorator() {} // WARNING: interface has both a type and a value, skipping emit


    var ɵ0 =
    /**
    * @param {?} token
    * @return {?}
    */
    function ɵ0(token) {
      return {
        token: token
      };
    };
    /**
     * Inject decorator and metadata.
     *
     * \@Annotation
     * \@publicApi
     * @type {?}
     */


    var Inject = makeParamDecorator('Inject', ɵ0);
    /**
     * Type of the Optional decorator / constructor function.
     *
     * \@publicApi
     * @record
     */

    function OptionalDecorator() {} // WARNING: interface has both a type and a value, skipping emit

    /**
     * Optional decorator and metadata.
     *
     * \@Annotation
     * \@publicApi
     * @type {?}
     */


    var Optional = makeParamDecorator('Optional');
    /**
     * Type of the Self decorator / constructor function.
     *
     * \@publicApi
     * @record
     */

    function SelfDecorator() {} // WARNING: interface has both a type and a value, skipping emit

    /**
     * Self decorator and metadata.
     *
     * \@Annotation
     * \@publicApi
     * @type {?}
     */


    var Self = makeParamDecorator('Self');
    /**
     * Type of the SkipSelf decorator / constructor function.
     *
     * \@publicApi
     * @record
     */

    function SkipSelfDecorator() {} // WARNING: interface has both a type and a value, skipping emit

    /**
     * SkipSelf decorator and metadata.
     *
     * \@Annotation
     * \@publicApi
     * @type {?}
     */


    var SkipSelf = makeParamDecorator('SkipSelf');
    /**
     * Type of the Host decorator / constructor function.
     *
     * \@publicApi
     * @record
     */

    function HostDecorator() {} // WARNING: interface has both a type and a value, skipping emit

    /**
     * Host decorator and metadata.
     *
     * \@Annotation
     * \@publicApi
     * @type {?}
     */


    var Host = makeParamDecorator('Host');
    /**
     * Type of the Attribute decorator / constructor function.
     *
     * \@publicApi
     * @record
     */

    function AttributeDecorator() {} // WARNING: interface has both a type and a value, skipping emit


    var ɵ1 =
    /**
    * @param {?=} attributeName
    * @return {?}
    */
    function ɵ1(attributeName) {
      return {
        attributeName: attributeName
      };
    };
    /**
     * Attribute decorator and metadata.
     *
     * \@Annotation
     * \@publicApi
     * @type {?}
     */


    var Attribute = makeParamDecorator('Attribute', ɵ1);
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Injection flags for DI.
     *
     * @publicApi
     */

    var InjectFlags;

    (function (InjectFlags) {
      // TODO(alxhub): make this 'const' when ngc no longer writes exports of it into ngfactory files.

      /** Check self and check parent injector if needed */
      InjectFlags[InjectFlags["Default"] = 0] = "Default";
      /**
       * Specifies that an injector should retrieve a dependency from any injector until reaching the
       * host element of the current component. (Only used with Element Injector)
       */

      InjectFlags[InjectFlags["Host"] = 1] = "Host";
      /** Don't ascend to ancestors of the node requesting injection. */

      InjectFlags[InjectFlags["Self"] = 2] = "Self";
      /** Skip the node that is requesting injection. */

      InjectFlags[InjectFlags["SkipSelf"] = 4] = "SkipSelf";
      /** Inject `defaultValue` instead if token not found. */

      InjectFlags[InjectFlags["Optional"] = 8] = "Optional";
    })(InjectFlags || (InjectFlags = {}));
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */


    function getClosureSafeProperty(objWithPropertyToExtract) {
      for (var key in objWithPropertyToExtract) {
        if (objWithPropertyToExtract[key] === getClosureSafeProperty) {
          return key;
        }
      }

      throw Error('Could not find renamed property on target object.');
    }
    /**
     * Sets properties on a target object from a source object, but only if
     * the property doesn't already exist on the target object.
     * @param target The target to set properties on
     * @param source The source of the property keys and values to set
     */


    function fillProperties(target, source) {
      for (var key in source) {
        if (source.hasOwnProperty(key) && !target.hasOwnProperty(key)) {
          target[key] = source[key];
        }
      }
    }
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Construct an `InjectableDef` which defines how a token will be constructed by the DI system, and
     * in which injectors (if any) it will be available.
     *
     * This should be assigned to a static `ɵprov` field on a type, which will then be an
     * `InjectableType`.
     *
     * Options:
     * * `providedIn` determines which injectors will include the injectable, by either associating it
     *   with an `@NgModule` or other `InjectorType`, or by specifying that this injectable should be
     *   provided in the `'root'` injector, which will be the application-level injector in most apps.
     * * `factory` gives the zero argument function which will create an instance of the injectable.
     *   The factory can call `inject` to access the `Injector` and request injection of dependencies.
     *
     * @codeGenApi
     */


    function ɵɵdefineInjectable(opts) {
      return {
        token: opts.token,
        providedIn: opts.providedIn || null,
        factory: opts.factory,
        value: undefined
      };
    }
    /**
     * @deprecated in v8, delete after v10. This API should be used only be generated code, and that
     * code should now use ɵɵdefineInjectable instead.
     * @publicApi
     */


    var defineInjectable = ɵɵdefineInjectable;
    /**
     * Construct an `InjectorDef` which configures an injector.
     *
     * This should be assigned to a static injector def (`ɵinj`) field on a type, which will then be an
     * `InjectorType`.
     *
     * Options:
     *
     * * `factory`: an `InjectorType` is an instantiable type, so a zero argument `factory` function to
     *   create the type must be provided. If that factory function needs to inject arguments, it can
     *   use the `inject` function.
     * * `providers`: an optional array of providers to add to the injector. Each provider must
     *   either have a factory or point to a type which has a `ɵprov` static property (the
     *   type must be an `InjectableType`).
     * * `imports`: an optional array of imports of other `InjectorType`s or `InjectorTypeWithModule`s
     *   whose providers will also be added to the injector. Locally provided types will override
     *   providers from imports.
     *
     * @publicApi
     */

    function ɵɵdefineInjector(options) {
      return {
        factory: options.factory,
        providers: options.providers || [],
        imports: options.imports || []
      };
    }
    /**
     * Read the injectable def (`ɵprov`) for `type` in a way which is immune to accidentally reading
     * inherited value.
     *
     * @param type A type which may have its own (non-inherited) `ɵprov`.
     */


    function getInjectableDef(type) {
      return getOwnDefinition(type, type[NG_PROV_DEF]) || getOwnDefinition(type, type[NG_INJECTABLE_DEF]);
    }
    /**
     * Return `def` only if it is defined directly on `type` and is not inherited from a base
     * class of `type`.
     *
     * The function `Object.hasOwnProperty` is not sufficient to distinguish this case because in older
     * browsers (e.g. IE10) static property inheritance is implemented by copying the properties.
     *
     * Instead, the definition's `token` is compared to the `type`, and if they don't match then the
     * property was not defined directly on the type itself, and was likely inherited. The definition
     * is only returned if the `type` matches the `def.token`.
     */


    function getOwnDefinition(type, def) {
      return def && def.token === type ? def : null;
    }
    /**
     * Read the injectable def (`ɵprov`) for `type` or read the `ɵprov` from one of its ancestors.
     *
     * @param type A type which may have `ɵprov`, via inheritance.
     *
     * @deprecated Will be removed in v10, where an error will occur in the scenario if we find the
     * `ɵprov` on an ancestor only.
     */


    function getInheritedInjectableDef(type) {
      // See `jit/injectable.ts#compileInjectable` for context on NG_PROV_DEF_FALLBACK.
      var def = type && (type[NG_PROV_DEF] || type[NG_INJECTABLE_DEF] || type[NG_PROV_DEF_FALLBACK] && type[NG_PROV_DEF_FALLBACK]());

      if (def) {
        var _typeName = getTypeName(type); // TODO(FW-1307): Re-add ngDevMode when closure can handle it
        // ngDevMode &&


        console.warn("DEPRECATED: DI is instantiating a token \"".concat(_typeName, "\" that inherits its @Injectable decorator but does not provide one itself.\n") + "This will become an error in v10. Please add @Injectable() to the \"".concat(_typeName, "\" class."));
        return def;
      } else {
        return null;
      }
    }
    /** Gets the name of a type, accounting for some cross-browser differences. */


    function getTypeName(type) {
      // `Function.prototype.name` behaves differently between IE and other browsers. In most browsers
      // it'll always return the name of the function itself, no matter how many other functions it
      // inherits from. On IE the function doesn't have its own `name` property, but it takes it from
      // the lowest level in the prototype chain. E.g. if we have `class Foo extends Parent` most
      // browsers will evaluate `Foo.name` to `Foo` while IE will return `Parent`. We work around
      // the issue by converting the function to a string and parsing its name out that way via a regex.
      if (type.hasOwnProperty('name')) {
        return type.name;
      }

      var match = ('' + type).match(/^function\s*([^\s(]+)/);
      return match === null ? '' : match[1];
    }
    /**
     * Read the injector def type in a way which is immune to accidentally reading inherited value.
     *
     * @param type type which may have an injector def (`ɵinj`)
     */


    function getInjectorDef(type) {
      return type && (type.hasOwnProperty(NG_INJ_DEF) || type.hasOwnProperty(NG_INJECTOR_DEF)) ? type[NG_INJ_DEF] : null;
    }

    var NG_PROV_DEF = getClosureSafeProperty({
      ɵprov: getClosureSafeProperty
    });
    var NG_INJ_DEF = getClosureSafeProperty({
      ɵinj: getClosureSafeProperty
    }); // On IE10 properties defined via `defineProperty` won't be inherited by child classes,
    // which will break inheriting the injectable definition from a grandparent through an
    // undecorated parent class. We work around it by defining a fallback method which will be
    // used to retrieve the definition. This should only be a problem in JIT mode, because in
    // AOT TypeScript seems to have a workaround for static properties. When inheriting from an
    // undecorated parent is no longer supported in v10, this can safely be removed.

    var NG_PROV_DEF_FALLBACK = getClosureSafeProperty({
      ɵprovFallback: getClosureSafeProperty
    }); // We need to keep these around so we can read off old defs if new defs are unavailable

    var NG_INJECTABLE_DEF = getClosureSafeProperty({
      ngInjectableDef: getClosureSafeProperty
    });
    var NG_INJECTOR_DEF = getClosureSafeProperty({
      ngInjectorDef: getClosureSafeProperty
    });
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    function stringify(token) {
      if (typeof token === 'string') {
        return token;
      }

      if (Array.isArray(token)) {
        return '[' + token.map(stringify).join(', ') + ']';
      }

      if (token == null) {
        return '' + token;
      }

      if (token.overriddenName) {
        return "".concat(token.overriddenName);
      }

      if (token.name) {
        return "".concat(token.name);
      }

      var res = token.toString();

      if (res == null) {
        return '' + res;
      }

      var newLineIndex = res.indexOf('\n');
      return newLineIndex === -1 ? res : res.substring(0, newLineIndex);
    }
    /**
     * Concatenates two strings with separator, allocating new strings only when necessary.
     *
     * @param before before string.
     * @param separator separator string.
     * @param after after string.
     * @returns concatenated string.
     */


    function concatStringsWithSpace(before, after) {
      return before == null || before === '' ? after === null ? '' : after : after == null || after === '' ? before : before + ' ' + after;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/di/forward_ref.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * An interface that a function passed into {\@link forwardRef} has to implement.
     *
     * \@usageNotes
     * ### Example
     *
     * {\@example core/di/ts/forward_ref/forward_ref_spec.ts region='forward_ref_fn'}
     * \@publicApi
     * @record
     */


    function ForwardRefFn() {}
    /** @type {?} */


    var __forward_ref__ = getClosureSafeProperty({
      __forward_ref__: getClosureSafeProperty
    });
    /**
     * Allows to refer to references which are not yet defined.
     *
     * For instance, `forwardRef` is used when the `token` which we need to refer to for the purposes of
     * DI is declared, but not yet defined. It is also used when the `token` which we use when creating
     * a query is not yet defined.
     *
     * \@usageNotes
     * ### Example
     * {\@example core/di/ts/forward_ref/forward_ref_spec.ts region='forward_ref'}
     * \@publicApi
     * @param {?} forwardRefFn
     * @return {?}
     */


    function forwardRef(forwardRefFn) {
      /** @type {?} */
      forwardRefFn.__forward_ref__ = forwardRef;

      /** @type {?} */
      forwardRefFn.toString =
      /**
      * @return {?}
      */
      function () {
        return stringify(this());
      };

      return (
        /** @type {?} */

        /** @type {?} */
        forwardRefFn
      );
    }
    /**
     * Lazily retrieves the reference value from a forwardRef.
     *
     * Acts as the identity function when given a non-forward-ref value.
     *
     * \@usageNotes
     * ### Example
     *
     * {\@example core/di/ts/forward_ref/forward_ref_spec.ts region='resolve_forward_ref'}
     *
     * @see `forwardRef`
     * \@publicApi
     * @template T
     * @param {?} type
     * @return {?}
     */


    function resolveForwardRef(type) {
      return isForwardRef(type) ? type() : type;
    }
    /**
     * Checks whether a function is wrapped by a `forwardRef`.
     * @param {?} fn
     * @return {?}
     */


    function isForwardRef(fn) {
      return typeof fn === 'function' && fn.hasOwnProperty(__forward_ref__) && fn.__forward_ref__ === forwardRef;
    }
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */


    var __globalThis = typeof globalThis !== 'undefined' && globalThis;

    var __window = typeof window !== 'undefined' && window;

    var __self = typeof self !== 'undefined' && typeof WorkerGlobalScope !== 'undefined' && self instanceof WorkerGlobalScope && self;

    var __global = typeof global !== 'undefined' && global; // Always use __globalThis if available, which is the spec-defined global variable across all
    // environments, then fallback to __global first, because in Node tests both __global and
    // __window may be defined and _global should be __global in that case.


    var _global = __globalThis || __global || __window || __self;
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */


    var R3ResolvedDependencyType;

    (function (R3ResolvedDependencyType) {
      R3ResolvedDependencyType[R3ResolvedDependencyType["Token"] = 0] = "Token";
      R3ResolvedDependencyType[R3ResolvedDependencyType["Attribute"] = 1] = "Attribute";
      R3ResolvedDependencyType[R3ResolvedDependencyType["ChangeDetectorRef"] = 2] = "ChangeDetectorRef";
      R3ResolvedDependencyType[R3ResolvedDependencyType["Invalid"] = 3] = "Invalid";
    })(R3ResolvedDependencyType || (R3ResolvedDependencyType = {}));

    var R3FactoryTarget;

    (function (R3FactoryTarget) {
      R3FactoryTarget[R3FactoryTarget["Directive"] = 0] = "Directive";
      R3FactoryTarget[R3FactoryTarget["Component"] = 1] = "Component";
      R3FactoryTarget[R3FactoryTarget["Injectable"] = 2] = "Injectable";
      R3FactoryTarget[R3FactoryTarget["Pipe"] = 3] = "Pipe";
      R3FactoryTarget[R3FactoryTarget["NgModule"] = 4] = "NgModule";
    })(R3FactoryTarget || (R3FactoryTarget = {}));

    var ViewEncapsulation;

    (function (ViewEncapsulation) {
      ViewEncapsulation[ViewEncapsulation["Emulated"] = 0] = "Emulated";
      ViewEncapsulation[ViewEncapsulation["Native"] = 1] = "Native";
      ViewEncapsulation[ViewEncapsulation["None"] = 2] = "None";
      ViewEncapsulation[ViewEncapsulation["ShadowDom"] = 3] = "ShadowDom";
    })(ViewEncapsulation || (ViewEncapsulation = {}));
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */


    function getCompilerFacade() {
      var globalNg = _global['ng'];

      if (!globalNg || !globalNg.ɵcompilerFacade) {
        throw new Error("Angular JIT compilation failed: '@angular/compiler' not loaded!\n" + "  - JIT compilation is discouraged for production use-cases! Consider AOT mode instead.\n" + "  - Did you bootstrap using '@angular/platform-browser-dynamic' or '@angular/platform-server'?\n" + "  - Alternatively provide the compiler with 'import \"@angular/compiler\";' before bootstrapping.");
      }

      return globalNg.ɵcompilerFacade;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/fields.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var NG_COMP_DEF = getClosureSafeProperty({
      ɵcmp: getClosureSafeProperty
    });
    /** @type {?} */

    var NG_DIR_DEF = getClosureSafeProperty({
      ɵdir: getClosureSafeProperty
    });
    /** @type {?} */

    var NG_PIPE_DEF = getClosureSafeProperty({
      ɵpipe: getClosureSafeProperty
    });
    /** @type {?} */

    var NG_MOD_DEF = getClosureSafeProperty({
      ɵmod: getClosureSafeProperty
    });
    /** @type {?} */

    var NG_LOC_ID_DEF = getClosureSafeProperty({
      ɵloc: getClosureSafeProperty
    });
    /** @type {?} */

    var NG_FACTORY_DEF = getClosureSafeProperty({
      ɵfac: getClosureSafeProperty
    }); // TODO(misko): This is wrong. The NG_ELEMENT_ID should never be minified.

    /**
     * If a directive is diPublic, bloomAdd sets a property on the type with this constant as
     * the key and the directive's unique ID as the value. This allows us to map directives to their
     * bloom filter bit for DI.
     * @type {?}
     */

    var NG_ELEMENT_ID = getClosureSafeProperty({
      __NG_ELEMENT_ID__: getClosureSafeProperty
    });
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    function ngDevModeResetPerfCounters() {
      var locationString = typeof location !== 'undefined' ? location.toString() : '';
      var newCounters = {
        namedConstructors: locationString.indexOf('ngDevMode=namedConstructors') != -1,
        firstCreatePass: 0,
        tNode: 0,
        tView: 0,
        rendererCreateTextNode: 0,
        rendererSetText: 0,
        rendererCreateElement: 0,
        rendererAddEventListener: 0,
        rendererSetAttribute: 0,
        rendererRemoveAttribute: 0,
        rendererSetProperty: 0,
        rendererSetClassName: 0,
        rendererAddClass: 0,
        rendererRemoveClass: 0,
        rendererSetStyle: 0,
        rendererRemoveStyle: 0,
        rendererDestroy: 0,
        rendererDestroyNode: 0,
        rendererMoveNode: 0,
        rendererRemoveNode: 0,
        rendererAppendChild: 0,
        rendererInsertBefore: 0,
        rendererCreateComment: 0
      }; // Make sure to refer to ngDevMode as ['ngDevMode'] for closure.

      var allowNgDevModeTrue = locationString.indexOf('ngDevMode=false') === -1;
      _global['ngDevMode'] = allowNgDevModeTrue && newCounters;
      return newCounters;
    }
    /**
     * This function checks to see if the `ngDevMode` has been set. If yes,
     * then we honor it, otherwise we default to dev mode with additional checks.
     *
     * The idea is that unless we are doing production build where we explicitly
     * set `ngDevMode == false` we should be helping the developer by providing
     * as much early warning and errors as possible.
     *
     * `ɵɵdefineComponent` is guaranteed to have been called before any component template functions
     * (and thus Ivy instructions), so a single initialization there is sufficient to ensure ngDevMode
     * is defined for the entire instruction set.
     *
     * When using checking `ngDevMode` on toplevel, always init it before referencing it
     * (e.g. `((typeof ngDevMode === 'undefined' || ngDevMode) && initNgDevMode())`), otherwise you can
     *  get a `ReferenceError` like in https://github.com/angular/angular/issues/31595.
     *
     * Details on possible values for `ngDevMode` can be found on its docstring.
     *
     * NOTE:
     * - changes to the `ngDevMode` name must be synced with `compiler-cli/src/tooling.ts`.
     */


    function initNgDevMode() {
      // The below checks are to ensure that calling `initNgDevMode` multiple times does not
      // reset the counters.
      // If the `ngDevMode` is not an object, then it means we have not created the perf counters
      // yet.
      if (typeof ngDevMode === 'undefined' || ngDevMode) {
        if (typeof ngDevMode !== 'object') {
          ngDevModeResetPerfCounters();
        }

        return !!ngDevMode;
      }

      return false;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/di/injection_token.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Creates a token that can be used in a DI Provider.
     *
     * Use an `InjectionToken` whenever the type you are injecting is not reified (does not have a
     * runtime representation) such as when injecting an interface, callable type, array or
     * parameterized type.
     *
     * `InjectionToken` is parameterized on `T` which is the type of object which will be returned by
     * the `Injector`. This provides additional level of type safety.
     *
     * ```
     * interface MyInterface {...}
     * var myInterface = injector.get(new InjectionToken<MyInterface>('SomeToken'));
     * // myInterface is inferred to be MyInterface.
     * ```
     *
     * When creating an `InjectionToken`, you can optionally specify a factory function which returns
     * (possibly by creating) a default value of the parameterized type `T`. This sets up the
     * `InjectionToken` using this factory as a provider as if it was defined explicitly in the
     * application's root injector. If the factory function, which takes zero arguments, needs to inject
     * dependencies, it can do so using the `inject` function. See below for an example.
     *
     * Additionally, if a `factory` is specified you can also specify the `providedIn` option, which
     * overrides the above behavior and marks the token as belonging to a particular `\@NgModule`. As
     * mentioned above, `'root'` is the default value for `providedIn`.
     *
     * \@usageNotes
     * ### Basic Example
     *
     * ### Plain InjectionToken
     *
     * {\@example core/di/ts/injector_spec.ts region='InjectionToken'}
     *
     * ### Tree-shakable InjectionToken
     *
     * {\@example core/di/ts/injector_spec.ts region='ShakableInjectionToken'}
     *
     *
     * \@publicApi
     * @template T
     */


    var InjectionToken = /*#__PURE__*/function () {
      /**
       * @param {?} _desc
       * @param {?=} options
       */
      function InjectionToken(_desc, options) {
        _classCallCheck(this, InjectionToken);

        this._desc = _desc;
        /**
         * \@internal
         */

        this.ngMetadataName = 'InjectionToken';
        this.ɵprov = undefined;

        if (typeof options == 'number') {
          // This is a special hack to assign __NG_ELEMENT_ID__ to this instance.
          // __NG_ELEMENT_ID__ is Used by Ivy to determine bloom filter id.
          // We are using it to assign `-1` which is used to identify `Injector`.

          /** @type {?} */
          this.__NG_ELEMENT_ID__ = options;
        } else if (options !== undefined) {
          this.ɵprov = ɵɵdefineInjectable({
            token: this,
            providedIn: options.providedIn || 'root',
            factory: options.factory
          });
        }
      }
      /**
       * @return {?}
       */


      _createClass2(InjectionToken, [{
        key: "toString",
        value: function toString() {
          return "InjectionToken ".concat(this._desc);
        }
      }]);

      return InjectionToken;
    }();

    if (false) {}
    /**
     * @record
     * @template T
     */


    function InjectableDefToken() {}

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/di/injector_compatibility.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * An InjectionToken that gets the current `Injector` for `createInjector()`-style injectors.
     *
     * Requesting this token instead of `Injector` allows `StaticInjector` to be tree-shaken from a
     * project.
     *
     * \@publicApi
     * @type {?}
     */


    var INJECTOR = new InjectionToken('INJECTOR',
    /** @type {?} */
    -1);
    /** @type {?} */

    var _THROW_IF_NOT_FOUND = {};
    /** @type {?} */

    var THROW_IF_NOT_FOUND = _THROW_IF_NOT_FOUND;
    /** @type {?} */

    var NG_TEMP_TOKEN_PATH = 'ngTempTokenPath';
    /** @type {?} */

    var NG_TOKEN_PATH = 'ngTokenPath';
    /** @type {?} */

    var NEW_LINE = /\n/gm;
    /** @type {?} */

    var NO_NEW_LINE = 'ɵ';
    /** @type {?} */

    var SOURCE = '__source';
    var ɵ0$1 = getClosureSafeProperty;
    /** @type {?} */

    var USE_VALUE = getClosureSafeProperty({
      provide: String,
      useValue: ɵ0$1
    });
    /**
     * Current injector value used by `inject`.
     * - `undefined`: it is an error to call `inject`
     * - `null`: `inject` can be called but there is no injector (limp-mode).
     * - Injector instance: Use the injector for resolution.
     * @type {?}
     */

    var _currentInjector = undefined;
    /**
     * @param {?} injector
     * @return {?}
     */

    function setCurrentInjector(injector) {
      /** @type {?} */
      var former = _currentInjector;
      _currentInjector = injector;
      return former;
    }
    /**
     * Current implementation of inject.
     *
     * By default, it is `injectInjectorOnly`, which makes it `Injector`-only aware. It can be changed
     * to `directiveInject`, which brings in the `NodeInjector` system of ivy. It is designed this
     * way for two reasons:
     *  1. `Injector` should not depend on ivy logic.
     *  2. To maintain tree shake-ability we don't want to bring in unnecessary code.
     * @type {?}
     */


    var _injectImplementation;
    /**
     * Sets the current inject implementation.
     * @param {?} impl
     * @return {?}
     */


    function setInjectImplementation(impl) {
      /** @type {?} */
      var previous = _injectImplementation;
      _injectImplementation = impl;
      return previous;
    }
    /**
     * @template T
     * @param {?} token
     * @param {?=} flags
     * @return {?}
     */


    function injectInjectorOnly(token) {
      var flags = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : InjectFlags.Default;

      if (_currentInjector === undefined) {
        throw new Error("inject() must be called from an injection context");
      } else if (_currentInjector === null) {
        return injectRootLimpMode(token, undefined, flags);
      } else {
        return _currentInjector.get(token, flags & InjectFlags.Optional ? null : undefined, flags);
      }
    }
    /**
     * @template T
     * @param {?} token
     * @param {?=} flags
     * @return {?}
     */


    function ɵɵinject(token) {
      var flags = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : InjectFlags.Default;
      return (_injectImplementation || injectInjectorOnly)(resolveForwardRef(token), flags);
    }
    /**
     * Throws an error indicating that a factory function could not be generated by the compiler for a
     * particular class.
     *
     * This instruction allows the actual error message to be optimized away when ngDevMode is turned
     * off, saving bytes of generated code while still providing a good experience in dev mode.
     *
     * The name of the class is not mentioned here, but will be in the generated factory function name
     * and thus in the stack trace.
     *
     * \@codeGenApi
     * @param {?} index
     * @return {?}
     */


    function ɵɵinvalidFactoryDep(index) {
      /** @type {?} */
      var msg = ngDevMode ? "This constructor is not compatible with Angular Dependency Injection because its dependency at index ".concat(index, " of the parameter list is invalid.\nThis can happen if the dependency type is a primitive like a string or if an ancestor of this class is missing an Angular decorator.\n\nPlease check that 1) the type for the parameter at index ").concat(index, " is correct and 2) the correct Angular decorators are defined for this class and its ancestors.") : 'invalid';
      throw new Error(msg);
    }
    /**
     * Injects a token from the currently active injector.
     *
     * Must be used in the context of a factory function such as one defined for an
     * `InjectionToken`. Throws an error if not called from such a context.
     *
     * Within such a factory function, using this function to request injection of a dependency
     * is faster and more type-safe than providing an additional array of dependencies
     * (as has been common with `useFactory` providers).
     *
     * \@param token The injection token for the dependency to be injected.
     * \@param flags Optional flags that control how injection is executed.
     * The flags correspond to injection strategies that can be specified with
     * parameter decorators `\@Host`, `\@Self`, `\@SkipSef`, and `\@Optional`.
     * \@return True if injection is successful, null otherwise.
     *
     * \@usageNotes
     *
     * ### Example
     *
     * {\@example core/di/ts/injector_spec.ts region='ShakableInjectionToken'}
     *
     * \@publicApi
     * @type {?}
     */


    var inject = ɵɵinject;
    /**
     * Injects `root` tokens in limp mode.
     *
     * If no injector exists, we can still inject tree-shakable providers which have `providedIn` set to
     * `"root"`. This is known as the limp mode injection. In such case the value is stored in the
     * `InjectableDef`.
     * @template T
     * @param {?} token
     * @param {?} notFoundValue
     * @param {?} flags
     * @return {?}
     */

    function injectRootLimpMode(token, notFoundValue, flags) {
      /** @type {?} */
      var injectableDef = getInjectableDef(token);

      if (injectableDef && injectableDef.providedIn == 'root') {
        return injectableDef.value === undefined ? injectableDef.value = injectableDef.factory() : injectableDef.value;
      }

      if (flags & InjectFlags.Optional) return null;
      if (notFoundValue !== undefined) return notFoundValue;
      throw new Error("Injector: NOT_FOUND [".concat(stringify(token), "]"));
    }
    /**
     * @param {?} types
     * @return {?}
     */


    function injectArgs(types) {
      /** @type {?} */
      var args = [];

      for (var i = 0; i < types.length; i++) {
        /** @type {?} */
        var arg = resolveForwardRef(types[i]);

        if (Array.isArray(arg)) {
          if (arg.length === 0) {
            throw new Error('Arguments array must have arguments.');
          }
          /** @type {?} */


          var type = undefined;
          /** @type {?} */

          var flags = InjectFlags.Default;

          for (var j = 0; j < arg.length; j++) {
            /** @type {?} */
            var meta = arg[j];

            if (meta instanceof Optional || meta.ngMetadataName === 'Optional' || meta === Optional) {
              flags |= InjectFlags.Optional;
            } else if (meta instanceof SkipSelf || meta.ngMetadataName === 'SkipSelf' || meta === SkipSelf) {
              flags |= InjectFlags.SkipSelf;
            } else if (meta instanceof Self || meta.ngMetadataName === 'Self' || meta === Self) {
              flags |= InjectFlags.Self;
            } else if (meta instanceof Inject || meta === Inject) {
              type = meta.token;
            } else {
              type = meta;
            }
          }

          args.push(ɵɵinject(
          /** @type {?} */
          type, flags));
        } else {
          args.push(ɵɵinject(arg));
        }
      }

      return args;
    }

    var NullInjector = /*#__PURE__*/function () {
      function NullInjector() {
        _classCallCheck(this, NullInjector);
      }

      _createClass2(NullInjector, [{
        key: "get",

        /**
         * @param {?} token
         * @param {?=} notFoundValue
         * @return {?}
         */
        value: function get(token) {
          var notFoundValue = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : THROW_IF_NOT_FOUND;

          if (notFoundValue === THROW_IF_NOT_FOUND) {
            // Intentionally left behind: With dev tools open the debugger will stop here. There is no
            // reason why correctly written application should cause this exception.
            // TODO(misko): uncomment the next line once `ngDevMode` works with closure.
            // if (ngDevMode) debugger;

            /** @type {?} */
            var error = new Error("NullInjectorError: No provider for ".concat(stringify(token), "!"));
            error.name = 'NullInjectorError';
            throw error;
          }

          return notFoundValue;
        }
      }]);

      return NullInjector;
    }();
    /**
     * @param {?} e
     * @param {?} token
     * @param {?} injectorErrorName
     * @param {?} source
     * @return {?}
     */


    function catchInjectorError(e, token, injectorErrorName, source) {
      /** @type {?} */
      var tokenPath = e[NG_TEMP_TOKEN_PATH];

      if (token[SOURCE]) {
        tokenPath.unshift(token[SOURCE]);
      }

      e.message = formatError('\n' + e.message, tokenPath, injectorErrorName, source);
      e[NG_TOKEN_PATH] = tokenPath;
      e[NG_TEMP_TOKEN_PATH] = null;
      throw e;
    }
    /**
     * @param {?} text
     * @param {?} obj
     * @param {?} injectorErrorName
     * @param {?=} source
     * @return {?}
     */


    function formatError(text, obj, injectorErrorName) {
      var source = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : null;
      text = text && text.charAt(0) === '\n' && text.charAt(1) == NO_NEW_LINE ? text.substr(2) : text;
      /** @type {?} */

      var context = stringify(obj);

      if (Array.isArray(obj)) {
        context = obj.map(stringify).join(' -> ');
      } else if (typeof obj === 'object') {
        /** @type {?} */
        var parts =
        /** @type {?} */
        [];

        for (var key in obj) {
          if (obj.hasOwnProperty(key)) {
            /** @type {?} */
            var value = obj[key];
            parts.push(key + ':' + (typeof value === 'string' ? JSON.stringify(value) : stringify(value)));
          }
        }

        context = "{".concat(parts.join(', '), "}");
      }

      return "".concat(injectorErrorName).concat(source ? '(' + source + ')' : '', "[").concat(context, "]: ").concat(text.replace(NEW_LINE, '\n  '));
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/di/jit/environment.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * A mapping of the \@angular/core API surface used in generated expressions to the actual symbols.
     *
     * This should be kept up to date with the public exports of \@angular/core.
     * @type {?}
     */


    var angularCoreDiEnv = {
      'ɵɵdefineInjectable': ɵɵdefineInjectable,
      'ɵɵdefineInjector': ɵɵdefineInjector,
      'ɵɵinject': ɵɵinject,
      'ɵɵgetFactoryOf': getFactoryOf,
      'ɵɵinvalidFactoryDep': ɵɵinvalidFactoryDep
    };
    /**
     * @template T
     * @param {?} type
     * @return {?}
     */

    function getFactoryOf(type) {
      /** @type {?} */
      var typeAny =
      /** @type {?} */
      type;

      if (isForwardRef(type)) {
        return (
          /** @type {?} */

          /**
          * @return {?}
          */
          function () {
            /** @type {?} */
            var factory = getFactoryOf(resolveForwardRef(typeAny));
            return factory ? factory() : null;
          }
        );
      }
      /** @type {?} */


      var def = getInjectableDef(typeAny) || getInjectorDef(typeAny);

      if (!def || def.factory === undefined) {
        return null;
      }

      return def.factory;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/linker/ng_module_factory.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Represents an instance of an NgModule created via a {\@link NgModuleFactory}.
     *
     * `NgModuleRef` provides access to the NgModule Instance as well other objects related to this
     * NgModule Instance.
     *
     * \@publicApi
     * @abstract
     * @template T
     */


    var NgModuleRef = function NgModuleRef() {
      _classCallCheck(this, NgModuleRef);
    };

    if (false) {}
    /**
     * @record
     * @template T
     */


    function InternalNgModuleRef() {}

    if (false) {}
    /**
     * \@publicApi
     * @abstract
     * @template T
     */


    var NgModuleFactory = function NgModuleFactory() {
      _classCallCheck(this, NgModuleFactory);
    };

    if (false) {}
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */


    function assertNumber(actual, msg) {
      if (!(typeof actual === 'number')) {
        throwError(msg, typeof actual, 'number', '===');
      }
    }

    function assertNumberInRange(actual, minInclusive, maxInclusive) {
      assertNumber(actual, 'Expected a number');
      assertLessThanOrEqual(actual, maxInclusive, 'Expected number to be less than or equal to');
      assertGreaterThanOrEqual(actual, minInclusive, 'Expected number to be greater than or equal to');
    }

    function assertString(actual, msg) {
      if (!(typeof actual === 'string')) {
        throwError(msg, actual === null ? 'null' : typeof actual, 'string', '===');
      }
    }

    function assertEqual(actual, expected, msg) {
      if (!(actual == expected)) {
        throwError(msg, actual, expected, '==');
      }
    }

    function assertNotEqual(actual, expected, msg) {
      if (!(actual != expected)) {
        throwError(msg, actual, expected, '!=');
      }
    }

    function assertSame(actual, expected, msg) {
      if (!(actual === expected)) {
        throwError(msg, actual, expected, '===');
      }
    }

    function assertNotSame(actual, expected, msg) {
      if (!(actual !== expected)) {
        throwError(msg, actual, expected, '!==');
      }
    }

    function assertLessThan(actual, expected, msg) {
      if (!(actual < expected)) {
        throwError(msg, actual, expected, '<');
      }
    }

    function assertLessThanOrEqual(actual, expected, msg) {
      if (!(actual <= expected)) {
        throwError(msg, actual, expected, '<=');
      }
    }

    function assertGreaterThan(actual, expected, msg) {
      if (!(actual > expected)) {
        throwError(msg, actual, expected, '>');
      }
    }

    function assertGreaterThanOrEqual(actual, expected, msg) {
      if (!(actual >= expected)) {
        throwError(msg, actual, expected, '>=');
      }
    }

    function assertNotDefined(actual, msg) {
      if (actual != null) {
        throwError(msg, actual, null, '==');
      }
    }

    function assertDefined(actual, msg) {
      if (actual == null) {
        throwError(msg, actual, null, '!=');
      }
    }

    function throwError(msg, actual, expected, comparison) {
      throw new Error("ASSERTION ERROR: ".concat(msg) + (comparison == null ? '' : " [Expected=> ".concat(expected, " ").concat(comparison, " ").concat(actual, " <=Actual]")));
    }

    function assertDomNode(node) {
      // If we're in a worker, `Node` will not be defined.
      assertEqual(typeof Node !== 'undefined' && node instanceof Node || typeof node === 'object' && node != null && node.constructor.name === 'WebWorkerRenderNode', true, "The provided value must be an instance of a DOM Node but got ".concat(stringify(node)));
    }

    function assertDataInRange(arr, index) {
      var maxLen = arr ? arr.length : 0;
      assertLessThan(index, maxLen, "Index expected to be less than ".concat(maxLen, " but got ").concat(index));
    }
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Equivalent to ES6 spread, add each item to an array.
     *
     * @param items The items to add
     * @param arr The array to which you want to add the items
     */


    function addAllToArray(items, arr) {
      for (var i = 0; i < items.length; i++) {
        arr.push(items[i]);
      }
    }
    /**
     * Flattens an array.
     */


    function flatten(list, dst) {
      if (dst === undefined) dst = list;

      for (var i = 0; i < list.length; i++) {
        var item = list[i];

        if (Array.isArray(item)) {
          // we need to inline it.
          if (dst === list) {
            // Our assumption that the list was already flat was wrong and
            // we need to clone flat since we need to write to it.
            dst = list.slice(0, i);
          }

          flatten(item, dst);
        } else if (dst !== list) {
          dst.push(item);
        }
      }

      return dst;
    }

    function deepForEach(input, fn) {
      input.forEach(function (value) {
        return Array.isArray(value) ? deepForEach(value, fn) : fn(value);
      });
    }

    function addToArray(arr, index, value) {
      // perf: array.push is faster than array.splice!
      if (index >= arr.length) {
        arr.push(value);
      } else {
        arr.splice(index, 0, value);
      }
    }

    function removeFromArray(arr, index) {
      // perf: array.pop is faster than array.splice!
      if (index >= arr.length - 1) {
        return arr.pop();
      } else {
        return arr.splice(index, 1)[0];
      }
    }

    function newArray(size, value) {
      var list = [];

      for (var i = 0; i < size; i++) {
        list.push(value);
      }

      return list;
    }
    /**
     * Remove item from array (Same as `Array.splice()` but faster.)
     *
     * `Array.splice()` is not as fast because it has to allocate an array for the elements which were
     * removed. This causes memory pressure and slows down code when most of the time we don't
     * care about the deleted items array.
     *
     * https://jsperf.com/fast-array-splice (About 20x faster)
     *
     * @param array Array to splice
     * @param index Index of element in array to remove.
     * @param count Number of items to remove.
     */


    function arraySplice(array, index, count) {
      var length = array.length - count;

      while (index < length) {
        array[index] = array[index + count];
        index++;
      }

      while (count--) {
        array.pop(); // shrink the array
      }
    }
    /**
     * Same as `Array.splice(index, 0, value)` but faster.
     *
     * `Array.splice()` is not fast because it has to allocate an array for the elements which were
     * removed. This causes memory pressure and slows down code when most of the time we don't
     * care about the deleted items array.
     *
     * @param array Array to splice.
     * @param index Index in array where the `value` should be added.
     * @param value Value to add to array.
     */


    function arrayInsert(array, index, value) {
      ngDevMode && assertLessThanOrEqual(index, array.length, 'Can\'t insert past array end.');
      var end = array.length;

      while (end > index) {
        var previousEnd = end - 1;
        array[end] = array[previousEnd];
        end = previousEnd;
      }

      array[index] = value;
    }
    /**
     * Same as `Array.splice2(index, 0, value1, value2)` but faster.
     *
     * `Array.splice()` is not fast because it has to allocate an array for the elements which were
     * removed. This causes memory pressure and slows down code when most of the time we don't
     * care about the deleted items array.
     *
     * @param array Array to splice.
     * @param index Index in array where the `value` should be added.
     * @param value1 Value to add to array.
     * @param value2 Value to add to array.
     */


    function arrayInsert2(array, index, value1, value2) {
      ngDevMode && assertLessThanOrEqual(index, array.length, 'Can\'t insert past array end.');
      var end = array.length;

      if (end == index) {
        // inserting at the end.
        array.push(value1, value2);
      } else if (end === 1) {
        // corner case when we have less items in array than we have items to insert.
        array.push(value2, array[0]);
        array[0] = value1;
      } else {
        end--;
        array.push(array[end - 1], array[end]);

        while (end > index) {
          var previousEnd = end - 2;
          array[end] = array[previousEnd];
          end--;
        }

        array[index] = value1;
        array[index + 1] = value2;
      }
    }
    /**
     * Insert a `value` into an `array` so that the array remains sorted.
     *
     * NOTE:
     * - Duplicates are not allowed, and are ignored.
     * - This uses binary search algorithm for fast inserts.
     *
     * @param array A sorted array to insert into.
     * @param value The value to insert.
     * @returns index of the inserted value.
     */


    function arrayInsertSorted(array, value) {
      var index = arrayIndexOfSorted(array, value);

      if (index < 0) {
        // if we did not find it insert it.
        index = ~index;
        arrayInsert(array, index, value);
      }

      return index;
    }
    /**
     * Remove `value` from a sorted `array`.
     *
     * NOTE:
     * - This uses binary search algorithm for fast removals.
     *
     * @param array A sorted array to remove from.
     * @param value The value to remove.
     * @returns index of the removed value.
     *   - positive index if value found and removed.
     *   - negative index if value not found. (`~index` to get the value where it should have been
     *     inserted)
     */


    function arrayRemoveSorted(array, value) {
      var index = arrayIndexOfSorted(array, value);

      if (index >= 0) {
        arraySplice(array, index, 1);
      }

      return index;
    }
    /**
     * Get an index of an `value` in a sorted `array`.
     *
     * NOTE:
     * - This uses binary search algorithm for fast removals.
     *
     * @param array A sorted array to binary search.
     * @param value The value to look for.
     * @returns index of the value.
     *   - positive index if value found.
     *   - negative index if value not found. (`~index` to get the value where it should have been
     *     located)
     */


    function arrayIndexOfSorted(array, value) {
      return _arrayIndexOfSorted(array, value, 0);
    }
    /**
     * Set a `value` for a `key`.
     *
     * @param keyValueArray to modify.
     * @param key The key to locate or create.
     * @param value The value to set for a `key`.
     * @returns index (always even) of where the value vas set.
     */


    function keyValueArraySet(keyValueArray, key, value) {
      var index = keyValueArrayIndexOf(keyValueArray, key);

      if (index >= 0) {
        // if we found it set it.
        keyValueArray[index | 1] = value;
      } else {
        index = ~index;
        arrayInsert2(keyValueArray, index, key, value);
      }

      return index;
    }
    /**
     * Retrieve a `value` for a `key` (on `undefined` if not found.)
     *
     * @param keyValueArray to search.
     * @param key The key to locate.
     * @return The `value` stored at the `key` location or `undefined if not found.
     */


    function keyValueArrayGet(keyValueArray, key) {
      var index = keyValueArrayIndexOf(keyValueArray, key);

      if (index >= 0) {
        // if we found it retrieve it.
        return keyValueArray[index | 1];
      }

      return undefined;
    }
    /**
     * Retrieve a `key` index value in the array or `-1` if not found.
     *
     * @param keyValueArray to search.
     * @param key The key to locate.
     * @returns index of where the key is (or should have been.)
     *   - positive (even) index if key found.
     *   - negative index if key not found. (`~index` (even) to get the index where it should have
     *     been inserted.)
     */


    function keyValueArrayIndexOf(keyValueArray, key) {
      return _arrayIndexOfSorted(keyValueArray, key, 1);
    }
    /**
     * Delete a `key` (and `value`) from the `KeyValueArray`.
     *
     * @param keyValueArray to modify.
     * @param key The key to locate or delete (if exist).
     * @returns index of where the key was (or should have been.)
     *   - positive (even) index if key found and deleted.
     *   - negative index if key not found. (`~index` (even) to get the index where it should have
     *     been.)
     */


    function keyValueArrayDelete(keyValueArray, key) {
      var index = keyValueArrayIndexOf(keyValueArray, key);

      if (index >= 0) {
        // if we found it remove it.
        arraySplice(keyValueArray, index, 2);
      }

      return index;
    }
    /**
     * INTERNAL: Get an index of an `value` in a sorted `array` by grouping search by `shift`.
     *
     * NOTE:
     * - This uses binary search algorithm for fast removals.
     *
     * @param array A sorted array to binary search.
     * @param value The value to look for.
     * @param shift grouping shift.
     *   - `0` means look at every location
     *   - `1` means only look at every other (even) location (the odd locations are to be ignored as
     *         they are values.)
     * @returns index of the value.
     *   - positive index if value found.
     *   - negative index if value not found. (`~index` to get the value where it should have been
     * inserted)
     */


    function _arrayIndexOfSorted(array, value, shift) {
      ngDevMode && assertEqual(Array.isArray(array), true, 'Expecting an array');
      var start = 0;
      var end = array.length >> shift;

      while (end !== start) {
        var middle = start + (end - start >> 1); // find the middle.

        var current = array[middle << shift];

        if (value === current) {
          return middle << shift;
        } else if (current > value) {
          end = middle;
        } else {
          start = middle + 1; // We already searched middle so make it non-inclusive by adding 1
        }
      }

      return ~(end << shift);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/change_detection/constants.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** @enum {number} */


    var ChangeDetectionStrategy = {
      /**
       * Use the `CheckOnce` strategy, meaning that automatic change detection is deactivated
       * until reactivated by setting the strategy to `Default` (`CheckAlways`).
       * Change detection can still be explicitly invoked.
       * This strategy applies to all child directives and cannot be overridden.
       */
      OnPush: 0,

      /**
       * Use the default `CheckAlways` strategy, in which change detection is automatic until
       * explicitly deactivated.
       */
      Default: 1
    };
    ChangeDetectionStrategy[ChangeDetectionStrategy.OnPush] = 'OnPush';
    ChangeDetectionStrategy[ChangeDetectionStrategy.Default] = 'Default';
    /** @enum {number} */

    var ChangeDetectorStatus = {
      /**
       * A state in which, after calling `detectChanges()`, the change detector
       * state becomes `Checked`, and must be explicitly invoked or reactivated.
       */
      CheckOnce: 0,

      /**
       * A state in which change detection is skipped until the change detector mode
       * becomes `CheckOnce`.
       */
      Checked: 1,

      /**
       * A state in which change detection continues automatically until explicitly
       * deactivated.
       */
      CheckAlways: 2,

      /**
       * A state in which a change detector sub tree is not a part of the main tree and
       * should be skipped.
       */
      Detached: 3,

      /**
       * Indicates that the change detector encountered an error checking a binding
       * or calling a directive lifecycle method and is now in an inconsistent state. Change
       * detectors in this state do not detect changes.
       */
      Errored: 4,

      /**
       * Indicates that the change detector has been destroyed.
       */
      Destroyed: 5
    };
    ChangeDetectorStatus[ChangeDetectorStatus.CheckOnce] = 'CheckOnce';
    ChangeDetectorStatus[ChangeDetectorStatus.Checked] = 'Checked';
    ChangeDetectorStatus[ChangeDetectorStatus.CheckAlways] = 'CheckAlways';
    ChangeDetectorStatus[ChangeDetectorStatus.Detached] = 'Detached';
    ChangeDetectorStatus[ChangeDetectorStatus.Errored] = 'Errored';
    ChangeDetectorStatus[ChangeDetectorStatus.Destroyed] = 'Destroyed';
    /**
     * Reports whether a given strategy is currently the default for change detection.
     * @see `ChangeDetectorStatus` / `ChangeDetectorRef`
     * @param {?} changeDetectionStrategy The strategy to check.
     * @return {?} True if the given strategy is the current default, false otherwise.
     */

    function isDefaultChangeDetectionStrategy(changeDetectionStrategy) {
      return changeDetectionStrategy == null || changeDetectionStrategy === ChangeDetectionStrategy.Default;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/metadata/view.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** @enum {number} */


    var ViewEncapsulation$1 = {
      /**
       * Emulate `Native` scoping of styles by adding an attribute containing surrogate id to the Host
       * Element and pre-processing the style rules provided via {@link Component#styles styles} or
       * {@link Component#styleUrls styleUrls}, and adding the new Host Element attribute to all
       * selectors.
       *
       * This is the default option.
       */
      Emulated: 0,

      /**
       * @deprecated v6.1.0 - use {ViewEncapsulation.ShadowDom} instead.
       * Use the native encapsulation mechanism of the renderer.
       *
       * For the DOM this means using the deprecated [Shadow DOM
       * v0](https://w3c.github.io/webcomponents/spec/shadow/) and
       * creating a ShadowRoot for Component's Host Element.
       */
      Native: 1,

      /**
       * Don't provide any template or style encapsulation.
       */
      None: 2,

      /**
       * Use Shadow DOM to encapsulate styles.
       *
       * For the DOM this means using modern [Shadow
       * DOM](https://w3c.github.io/webcomponents/spec/shadow/) and
       * creating a ShadowRoot for Component's Host Element.
       */
      ShadowDom: 3
    };
    ViewEncapsulation$1[ViewEncapsulation$1.Emulated] = 'Emulated';
    ViewEncapsulation$1[ViewEncapsulation$1.Native] = 'Native';
    ViewEncapsulation$1[ViewEncapsulation$1.None] = 'None';
    ViewEncapsulation$1[ViewEncapsulation$1.ShadowDom] = 'ShadowDom';
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/empty.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * This file contains reuseable "empty" symbols that can be used as default return values
     * in different parts of the rendering code. Because the same symbols are returned, this
     * allows for identity checks against these values to be consistently used by the framework
     * code.
     * @type {?}
     */

    var EMPTY_OBJ = {};
    /** @type {?} */

    var EMPTY_ARRAY = []; // freezing the values prevents any code from accidentally inserting new values in

    if ((typeof ngDevMode === 'undefined' || ngDevMode) && initNgDevMode()) {
      // These property accesses can be ignored because ngDevMode will be set to false
      // when optimizing code and the whole if statement will be dropped.
      // tslint:disable-next-line:no-toplevel-property-access
      Object.freeze(EMPTY_OBJ); // tslint:disable-next-line:no-toplevel-property-access

      Object.freeze(EMPTY_ARRAY);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/definition.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var _renderCompCount = 0;
    /**
     * Create a component definition object.
     *
     *
     * # Example
     * ```
     * class MyDirective {
     *   // Generated by Angular Template Compiler
     *   // [Symbol] syntax will not be supported by TypeScript until v2.7
     *   static ɵcmp = defineComponent({
     *     ...
     *   });
     * }
     * ```
     * \@codeGenApi
     * @template T
     * @param {?} componentDefinition
     * @return {?}
     */

    function ɵɵdefineComponent(componentDefinition) {
      return noSideEffects(
      /**
      * @return {?}
      */
      function () {
        // Initialize ngDevMode. This must be the first statement in ɵɵdefineComponent.
        // See the `initNgDevMode` docstring for more information.
        (typeof ngDevMode === 'undefined' || ngDevMode) && initNgDevMode();
        /** @type {?} */

        var type = componentDefinition.type;
        /** @type {?} */

        var typePrototype = type.prototype;
        /** @type {?} */

        var declaredInputs =
        /** @type {?} */
        {};
        /** @type {?} */

        var def = {
          type: type,
          providersResolver: null,
          decls: componentDefinition.decls,
          vars: componentDefinition.vars,
          factory: null,
          template: componentDefinition.template ||
          /** @type {?} */
          null,
          consts: componentDefinition.consts || null,
          ngContentSelectors: componentDefinition.ngContentSelectors,
          hostBindings: componentDefinition.hostBindings || null,
          hostVars: componentDefinition.hostVars || 0,
          hostAttrs: componentDefinition.hostAttrs || null,
          contentQueries: componentDefinition.contentQueries || null,
          declaredInputs: declaredInputs,
          inputs:
          /** @type {?} */
          null,
          // assigned in noSideEffects
          outputs:
          /** @type {?} */
          null,
          // assigned in noSideEffects
          exportAs: componentDefinition.exportAs || null,
          onChanges: null,
          onInit: typePrototype.ngOnInit || null,
          doCheck: typePrototype.ngDoCheck || null,
          afterContentInit: typePrototype.ngAfterContentInit || null,
          afterContentChecked: typePrototype.ngAfterContentChecked || null,
          afterViewInit: typePrototype.ngAfterViewInit || null,
          afterViewChecked: typePrototype.ngAfterViewChecked || null,
          onDestroy: typePrototype.ngOnDestroy || null,
          onPush: componentDefinition.changeDetection === ChangeDetectionStrategy.OnPush,
          directiveDefs:
          /** @type {?} */
          null,
          // assigned in noSideEffects
          pipeDefs:
          /** @type {?} */
          null,
          // assigned in noSideEffects
          selectors: componentDefinition.selectors || EMPTY_ARRAY,
          viewQuery: componentDefinition.viewQuery || null,
          features:
          /** @type {?} */
          componentDefinition.features || null,
          data: componentDefinition.data || {},
          // TODO(misko): convert ViewEncapsulation into const enum so that it can be used directly in
          // the next line. Also `None` should be 0 not 2.
          encapsulation: componentDefinition.encapsulation || ViewEncapsulation$1.Emulated,
          id: 'c',
          styles: componentDefinition.styles || EMPTY_ARRAY,
          _:
          /** @type {?} */
          null,
          setInput: null,
          schemas: componentDefinition.schemas || null,
          tView: null
        };
        /** @type {?} */

        var directiveTypes =
        /** @type {?} */
        componentDefinition.directives;
        /** @type {?} */

        var feature = componentDefinition.features;
        /** @type {?} */

        var pipeTypes =
        /** @type {?} */
        componentDefinition.pipes;
        def.id += _renderCompCount++;
        def.inputs = invertObject(componentDefinition.inputs, declaredInputs), def.outputs = invertObject(componentDefinition.outputs), feature && feature.forEach(
        /**
        * @param {?} fn
        * @return {?}
        */
        function (fn) {
          return fn(def);
        });
        def.directiveDefs = directiveTypes ?
        /**
        * @return {?}
        */
        function () {
          return (typeof directiveTypes === 'function' ? directiveTypes() : directiveTypes).map(extractDirectiveDef);
        } : null;
        def.pipeDefs = pipeTypes ?
        /**
        * @return {?}
        */
        function () {
          return (typeof pipeTypes === 'function' ? pipeTypes() : pipeTypes).map(extractPipeDef);
        } : null;
        return (
          /** @type {?} */
          def
        );
      });
    }
    /**
     * \@codeGenApi
     * @param {?} type
     * @param {?} directives
     * @param {?} pipes
     * @return {?}
     */


    function ɵɵsetComponentScope(type, directives, pipes) {
      /** @type {?} */
      var def =
      /** @type {?} */
      type.ɵcmp;

      def.directiveDefs =
      /**
      * @return {?}
      */
      function () {
        return directives.map(extractDirectiveDef);
      };

      def.pipeDefs =
      /**
      * @return {?}
      */
      function () {
        return pipes.map(extractPipeDef);
      };
    }
    /**
     * @param {?} type
     * @return {?}
     */


    function extractDirectiveDef(type) {
      /** @type {?} */
      var def = getComponentDef(type) || getDirectiveDef(type);

      if (ngDevMode && !def) {
        throw new Error("'".concat(type.name, "' is neither 'ComponentType' or 'DirectiveType'."));
      }

      return (
        /** @type {?} */
        def
      );
    }
    /**
     * @param {?} type
     * @return {?}
     */


    function extractPipeDef(type) {
      /** @type {?} */
      var def = getPipeDef(type);

      if (ngDevMode && !def) {
        throw new Error("'".concat(type.name, "' is not a 'PipeType'."));
      }

      return (
        /** @type {?} */
        def
      );
    }
    /** @type {?} */


    var autoRegisterModuleById = {};
    /**
     * \@codeGenApi
     * @template T
     * @param {?} def
     * @return {?}
     */

    function ɵɵdefineNgModule(def) {
      /** @type {?} */
      var res = {
        type: def.type,
        bootstrap: def.bootstrap || EMPTY_ARRAY,
        declarations: def.declarations || EMPTY_ARRAY,
        imports: def.imports || EMPTY_ARRAY,
        exports: def.exports || EMPTY_ARRAY,
        transitiveCompileScopes: null,
        schemas: def.schemas || null,
        id: def.id || null
      };

      if (def.id != null) {
        noSideEffects(
        /**
        * @return {?}
        */
        function () {
          autoRegisterModuleById[
          /** @type {?} */
          def.id] =
          /** @type {?} */

          /** @type {?} */
          def.type;
        });
      }

      return (
        /** @type {?} */
        res
      );
    }
    /**
     * Adds the module metadata that is necessary to compute the module's transitive scope to an
     * existing module definition.
     *
     * Scope metadata of modules is not used in production builds, so calls to this function can be
     * marked pure to tree-shake it from the bundle, allowing for all referenced declarations
     * to become eligible for tree-shaking as well.
     *
     * \@codeGenApi
     * @param {?} type
     * @param {?} scope
     * @return {?}
     */


    function ɵɵsetNgModuleScope(type, scope) {
      return (
        /** @type {?} */
        noSideEffects(
        /**
        * @return {?}
        */
        function () {
          /** @type {?} */
          var ngModuleDef = getNgModuleDef(type, true);
          ngModuleDef.declarations = scope.declarations || EMPTY_ARRAY;
          ngModuleDef.imports = scope.imports || EMPTY_ARRAY;
          ngModuleDef.exports = scope.exports || EMPTY_ARRAY;
        })
      );
    }
    /**
     * Inverts an inputs or outputs lookup such that the keys, which were the
     * minified keys, are part of the values, and the values are parsed so that
     * the publicName of the property is the new key
     *
     * e.g. for
     *
     * ```
     * class Comp {
     * \@Input()
     *   propName1: string;
     *
     * \@Input('publicName2')
     *   declaredPropName2: number;
     * }
     * ```
     *
     * will be serialized as
     *
     * ```
     * {
     *   propName1: 'propName1',
     *   declaredPropName2: ['publicName2', 'declaredPropName2'],
     * }
     * ```
     *
     * which is than translated by the minifier as:
     *
     * ```
     * {
     *   minifiedPropName1: 'propName1',
     *   minifiedPropName2: ['publicName2', 'declaredPropName2'],
     * }
     * ```
     *
     * becomes: (public name => minifiedName)
     *
     * ```
     * {
     *  'propName1': 'minifiedPropName1',
     *  'publicName2': 'minifiedPropName2',
     * }
     * ```
     *
     * Optionally the function can take `secondary` which will result in: (public name => declared name)
     *
     * ```
     * {
     *  'propName1': 'propName1',
     *  'publicName2': 'declaredPropName2',
     * }
     * ```
     *
     * @template T
     * @param {?=} obj
     * @param {?=} secondary
     * @return {?}
     */


    function invertObject(obj, secondary) {
      if (obj == null) return (
        /** @type {?} */
        EMPTY_OBJ
      );
      /** @type {?} */

      var newLookup = {};

      for (var minifiedKey in obj) {
        if (obj.hasOwnProperty(minifiedKey)) {
          /** @type {?} */
          var publicName =
          /** @type {?} */
          obj[minifiedKey];
          /** @type {?} */

          var declaredName = publicName;

          if (Array.isArray(publicName)) {
            declaredName = publicName[1];
            publicName = publicName[0];
          }

          newLookup[publicName] = minifiedKey;

          if (secondary) {
            secondary[publicName] =
            /** @type {?} */
            declaredName;
          }
        }
      }

      return newLookup;
    }
    /**
     * Create a directive definition object.
     *
     * # Example
     * ```ts
     * class MyDirective {
     *   // Generated by Angular Template Compiler
     *   // [Symbol] syntax will not be supported by TypeScript until v2.7
     *   static ɵdir = ɵɵdefineDirective({
     *     ...
     *   });
     * }
     * ```
     *
     * \@codeGenApi
     * @type {?}
     */


    var ɵɵdefineDirective =
    /** @type {?} */

    /** @type {?} */
    ɵɵdefineComponent;
    /**
     * Create a pipe definition object.
     *
     * # Example
     * ```
     * class MyPipe implements PipeTransform {
     *   // Generated by Angular Template Compiler
     *   static ɵpipe = definePipe({
     *     ...
     *   });
     * }
     * ```
     * \@codeGenApi
     * @template T
     * @param {?} pipeDef Pipe definition generated by the compiler
     *
     * @return {?}
     */

    function ɵɵdefinePipe(pipeDef) {
      return (
        /** @type {?} */

        /** @type {?} */
        {
          type: pipeDef.type,
          name: pipeDef.name,
          factory: null,
          pure: pipeDef.pure !== false,
          onDestroy: pipeDef.type.prototype.ngOnDestroy || null
        }
      );
    }
    /**
     * The following getter methods retrieve the definition form the type. Currently the retrieval
     * honors inheritance, but in the future we may change the rule to require that definitions are
     * explicit. This would require some sort of migration strategy.
     * @template T
     * @param {?} type
     * @return {?}
     */


    function getComponentDef(type) {
      return type[NG_COMP_DEF] || null;
    }
    /**
     * @template T
     * @param {?} type
     * @return {?}
     */


    function getDirectiveDef(type) {
      return type[NG_DIR_DEF] || null;
    }
    /**
     * @template T
     * @param {?} type
     * @return {?}
     */


    function getPipeDef(type) {
      return type[NG_PIPE_DEF] || null;
    }
    /**
     * @template T
     * @param {?} type
     * @param {?=} throwNotFound
     * @return {?}
     */


    function getFactoryDef(type, throwNotFound) {
      /** @type {?} */
      var hasFactoryDef = type.hasOwnProperty(NG_FACTORY_DEF);

      if (!hasFactoryDef && throwNotFound === true && ngDevMode) {
        throw new Error("Type ".concat(stringify(type), " does not have '\u0275fac' property."));
      }

      return hasFactoryDef ? type[NG_FACTORY_DEF] : null;
    }
    /**
     * @template T
     * @param {?} type
     * @param {?=} throwNotFound
     * @return {?}
     */


    function getNgModuleDef(type, throwNotFound) {
      /** @type {?} */
      var ngModuleDef = type[NG_MOD_DEF] || null;

      if (!ngModuleDef && throwNotFound === true) {
        throw new Error("Type ".concat(stringify(type), " does not have '\u0275mod' property."));
      }

      return ngModuleDef;
    }
    /**
     * @param {?} type
     * @return {?}
     */


    function getNgLocaleIdDef(type) {
      return (
        /** @type {?} */
        type[NG_LOC_ID_DEF] || null
      );
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/interfaces/view.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */
    // Below are constants for LView indices to help us look up LView members
    // without having to remember the specific indices.
    // Uglify will inline these when minifying so there shouldn't be a cost.

    /** @type {?} */


    var HOST = 0;
    /** @type {?} */

    var TVIEW = 1;
    /** @type {?} */

    var FLAGS = 2;
    /** @type {?} */

    var PARENT = 3;
    /** @type {?} */

    var NEXT = 4;
    /** @type {?} */

    var QUERIES = 5;
    /** @type {?} */

    var T_HOST = 6;
    /** @type {?} */

    var CLEANUP = 7;
    /** @type {?} */

    var CONTEXT = 8;
    /** @type {?} */

    var INJECTOR$1 = 9;
    /** @type {?} */

    var RENDERER_FACTORY = 10;
    /** @type {?} */

    var RENDERER = 11;
    /** @type {?} */

    var SANITIZER = 12;
    /** @type {?} */

    var CHILD_HEAD = 13;
    /** @type {?} */

    var CHILD_TAIL = 14;
    /** @type {?} */

    var DECLARATION_VIEW = 15;
    /** @type {?} */

    var DECLARATION_COMPONENT_VIEW = 16;
    /** @type {?} */

    var DECLARATION_LCONTAINER = 17;
    /** @type {?} */

    var PREORDER_HOOK_FLAGS = 18;
    /**
     * Size of LView's header. Necessary to adjust for it when setting slots.
     * @type {?}
     */

    var HEADER_OFFSET = 19;
    /**
     * @record
     */

    function OpaqueViewState() {}

    if (false) {}
    /**
     * `LView` stores all of the information needed to process the instructions as
     * they are invoked from the template. Each embedded view and component view has its
     * own `LView`. When processing a particular view, we set the `viewData` to that
     * `LView`. When that view is done processing, the `viewData` is set back to
     * whatever the original `viewData` was before (the parent `LView`).
     *
     * Keeping separate state for each view facilities view insertion / deletion, so we
     * don't have to edit the data array based on which views are present.
     * @record
     */


    function LView() {}

    if (false) {}
    /** @enum {number} */


    var LViewFlags = {
      /** The state of the init phase on the first 2 bits */
      InitPhaseStateIncrementer: 1,
      InitPhaseStateMask: 3,

      /**
       * Whether or not the view is in creationMode.
       *
       * This must be stored in the view rather than using `data` as a marker so that
       * we can properly support embedded views. Otherwise, when exiting a child view
       * back into the parent view, `data` will be defined and `creationMode` will be
       * improperly reported as false.
       */
      CreationMode: 4,

      /**
       * Whether or not this LView instance is on its first processing pass.
       *
       * An LView instance is considered to be on its "first pass" until it
       * has completed one creation mode run and one update mode run. At this
       * time, the flag is turned off.
       */
      FirstLViewPass: 8,

      /** Whether this view has default change detection strategy (checks always) or onPush */
      CheckAlways: 16,

      /**
       * Whether or not manual change detection is turned on for onPush components.
       *
       * This is a special mode that only marks components dirty in two cases:
       * 1) There has been a change to an @Input property
       * 2) `markDirty()` has been called manually by the user
       *
       * Note that in this mode, the firing of events does NOT mark components
       * dirty automatically.
       *
       * Manual mode is turned off by default for backwards compatibility, as events
       * automatically mark OnPush components dirty in View Engine.
       *
       * TODO: Add a public API to ChangeDetectionStrategy to turn this mode on
       */
      ManualOnPush: 32,

      /** Whether or not this view is currently dirty (needing check) */
      Dirty: 64,

      /** Whether or not this view is currently attached to change detection tree. */
      Attached: 128,

      /** Whether or not this view is destroyed. */
      Destroyed: 256,

      /** Whether or not this view is the root view */
      IsRoot: 512,

      /**
       * Index of the current init phase on last 22 bits
       */
      IndexWithinInitPhaseIncrementer: 1024,
      IndexWithinInitPhaseShift: 10,
      IndexWithinInitPhaseReset: 1023
    };
    /** @enum {number} */

    var InitPhaseState = {
      OnInitHooksToBeRun: 0,
      AfterContentInitHooksToBeRun: 1,
      AfterViewInitHooksToBeRun: 2,
      InitPhaseCompleted: 3
    };
    /** @enum {number} */

    var PreOrderHookFlags = {
      /**
         The index of the next pre-order hook to be called in the hooks array, on the first 16
         bits
       */
      IndexOfTheNextPreOrderHookMaskMask: 65535,

      /**
       * The number of init hooks that have already been called, on the last 16 bits
       */
      NumberOfInitHooksCalledIncrementer: 65536,
      NumberOfInitHooksCalledShift: 16,
      NumberOfInitHooksCalledMask: 4294901760
    };
    /**
     * Set of instructions used to process host bindings efficiently.
     *
     * See VIEW_DATA.md for more information.
     * @record
     */

    function ExpandoInstructions() {}
    /** @enum {number} */


    var TViewType = {
      /**
       * Root `TView` is the used to bootstrap components into. It is used in conjunction with
       * `LView` which takes an existing DOM node not owned by Angular and wraps it in `TView`/`LView`
       * so that other components can be loaded into it.
       */
      Root: 0,

      /**
       * `TView` associated with a Component. This would be the `TView` directly associated with the
       * component view (as opposed an `Embedded` `TView` which would be a child of `Component` `TView`)
       */
      Component: 1,

      /**
       * `TView` associated with a template. Such as `*ngIf`, `<ng-template>` etc... A `Component`
       * can have zero or more `Embedede` `TView`s.
       */
      Embedded: 2
    };
    /**
     * The static data for an LView (shared between all templates of a
     * given type).
     *
     * Stored on the `ComponentDef.tView`.
     * @record
     */

    function TView() {}

    if (false) {}
    /** @enum {number} */


    var RootContextFlags = {
      Empty: 0,
      DetectChanges: 1,
      FlushPlayers: 2
    };
    /**
     * RootContext contains information which is shared for all components which
     * were bootstrapped with {\@link renderComponent}.
     * @record
     */

    function RootContext() {}

    if (false) {} // Note: This hack is necessary so we don't erroneously get a circular dependency
    // failure based on types.

    /** @type {?} */


    var unusedValueExportToPlacateAjd = 1;
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/interfaces/container.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Special location which allows easy identification of type. If we have an array which was
     * retrieved from the `LView` and that array has `true` at `TYPE` location, we know it is
     * `LContainer`.
     * @type {?}
     */

    var TYPE = 1;
    /**
     * Below are constants for LContainer indices to help us look up LContainer members
     * without having to remember the specific indices.
     * Uglify will inline these when minifying so there shouldn't be a cost.
     * @type {?}
     */

    var ACTIVE_INDEX = 2; // PARENT and NEXT are indices 3 and 4
    // As we already have these constants in LView, we don't need to re-create them.

    /** @type {?} */

    var MOVED_VIEWS = 5; // T_HOST is index 6
    // We already have this constants in LView, we don't need to re-create it.

    /** @type {?} */

    var NATIVE = 7;
    /** @type {?} */

    var VIEW_REFS = 8;
    /**
     * Size of LContainer's header. Represents the index after which all views in the
     * container will be inserted. We need to keep a record of current views so we know
     * which views are already in the DOM (and don't need to be re-added) and so we can
     * remove views from the DOM when they are no longer required.
     * @type {?}
     */

    var CONTAINER_HEADER_OFFSET = 9;
    /** @enum {number} */

    var ActiveIndexFlag = {
      /**
       * Flag which signifies that the `LContainer` does not have any inline embedded views.
       */
      DYNAMIC_EMBEDDED_VIEWS_ONLY: -1,

      /**
       * Flag to signify that this `LContainer` may have transplanted views which need to be change
       * detected. (see: `LView[DECLARATION_COMPONENT_VIEW])`.
       *
       * This flag once set is never unset for the `LContainer`. This means that when unset we can skip
       * a lot of work in `refreshDynamicEmbeddedViews`. But when set we still need to verify
       * that the `MOVED_VIEWS` are transplanted and on-push.
       */
      HAS_TRANSPLANTED_VIEWS: 1,

      /**
       * Number of bits to shift inline embedded views counter to make space for other flags.
       */
      SHIFT: 1,

      /**
       * When incrementing the active index for inline embedded views, the amount to increment to leave
       * space for other flags.
       */
      INCREMENT: 2
    };
    /**
     * The state associated with a container.
     *
     * This is an array so that its structure is closer to LView. This helps
     * when traversing the view tree (which is a mix of containers and component
     * views), so we can jump to viewOrContainer[NEXT] in the same way regardless
     * of type.
     * @record
     */

    function LContainer() {}

    if (false) {} // Note: This hack is necessary so we don't erroneously get a circular dependency
    // failure based on types.

    /** @type {?} */


    var unusedValueExportToPlacateAjd$1 = 1;
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/interfaces/type_checks.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * True if `value` is `LView`.
     * @param {?} value wrapped value of `RNode`, `LView`, `LContainer`
     * @return {?}
     */

    function isLView(value) {
      return Array.isArray(value) && typeof value[TYPE] === 'object';
    }
    /**
     * True if `value` is `LContainer`.
     * @param {?} value wrapped value of `RNode`, `LView`, `LContainer`
     * @return {?}
     */


    function isLContainer(value) {
      return Array.isArray(value) && value[TYPE] === true;
    }
    /**
     * @param {?} tNode
     * @return {?}
     */


    function isContentQueryHost(tNode) {
      return (tNode.flags & 8
      /* hasContentQuery */
      ) !== 0;
    }
    /**
     * @param {?} tNode
     * @return {?}
     */


    function isComponentHost(tNode) {
      return (tNode.flags & 2
      /* isComponentHost */
      ) === 2
      /* isComponentHost */
      ;
    }
    /**
     * @param {?} tNode
     * @return {?}
     */


    function isDirectiveHost(tNode) {
      return (tNode.flags & 1
      /* isDirectiveHost */
      ) === 1
      /* isDirectiveHost */
      ;
    }
    /**
     * @template T
     * @param {?} def
     * @return {?}
     */


    function isComponentDef(def) {
      return (
        /** @type {?} */
        def.template !== null
      );
    }
    /**
     * @param {?} target
     * @return {?}
     */


    function isRootView(target) {
      return (target[FLAGS] & 512
      /* IsRoot */
      ) !== 0;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/assert.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */
    // [Assert functions do not constraint type when they are guarded by a truthy
    // expression.](https://github.com/microsoft/TypeScript/issues/37295)

    /**
     * @param {?} tNode
     * @param {?} lView
     * @return {?}
     */


    function assertTNodeForLView(tNode, lView) {
      tNode.hasOwnProperty('tView_') && assertEqual(
      /** @type {?} */

      /** @type {?} */
      tNode.tView_, lView[TVIEW], 'This TNode does not belong to this LView.');
    }
    /**
     * @param {?} actual
     * @param {?=} msg
     * @return {?}
     */


    function assertComponentType(actual) {
      var msg = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'Type passed in is not ComponentType, it does not have \'ɵcmp\' property.';

      if (!getComponentDef(actual)) {
        throwError(msg);
      }
    }
    /**
     * @param {?} actual
     * @param {?=} msg
     * @return {?}
     */


    function assertNgModuleType(actual) {
      var msg = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'Type passed in is not NgModuleType, it does not have \'ɵmod\' property.';

      if (!getNgModuleDef(actual)) {
        throwError(msg);
      }
    }
    /**
     * @param {?} isParent
     * @return {?}
     */


    function assertPreviousIsParent(isParent) {
      assertEqual(isParent, true, 'previousOrParentTNode should be a parent');
    }
    /**
     * @param {?} tNode
     * @return {?}
     */


    function assertHasParent(tNode) {
      assertDefined(tNode, 'previousOrParentTNode should exist!');
      assertDefined(
      /** @type {?} */
      tNode.parent, 'previousOrParentTNode should have a parent');
    }
    /**
     * @param {?} lView
     * @param {?} index
     * @param {?=} arr
     * @return {?}
     */


    function assertDataNext(lView, index, arr) {
      if (arr == null) arr = lView;
      assertEqual(arr.length, index, "index ".concat(index, " expected to be at the end of arr (length ").concat(arr.length, ")"));
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function assertLContainerOrUndefined(value) {
      value && assertEqual(isLContainer(value), true, 'Expecting LContainer or undefined or null');
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function assertLContainer(value) {
      assertDefined(value, 'LContainer must be defined');
      assertEqual(isLContainer(value), true, 'Expecting LContainer');
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function assertLViewOrUndefined(value) {
      value && assertEqual(isLView(value), true, 'Expecting LView or undefined or null');
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function assertLView(value) {
      assertDefined(value, 'LView must be defined');
      assertEqual(isLView(value), true, 'Expecting LView');
    }
    /**
     * @param {?} tView
     * @param {?=} errMessage
     * @return {?}
     */


    function assertFirstCreatePass(tView, errMessage) {
      assertEqual(tView.firstCreatePass, true, errMessage || 'Should only be called in first create pass.');
    }
    /**
     * @param {?} tView
     * @param {?=} errMessage
     * @return {?}
     */


    function assertFirstUpdatePass(tView, errMessage) {
      assertEqual(tView.firstUpdatePass, true, errMessage || 'Should only be called in first update pass.');
    }
    /**
     * This is a basic sanity check that an object is probably a directive def. DirectiveDef is
     * an interface, so we can't do a direct instanceof check.
     * @template T
     * @param {?} obj
     * @return {?}
     */


    function assertDirectiveDef(obj) {
      if (obj.type === undefined || obj.selectors == undefined || obj.inputs === undefined) {
        throwError("Expected a DirectiveDef/ComponentDef and this object does not seem to have the expected shape.");
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/namespaces.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** @type {?} */


    var SVG_NAMESPACE = 'http://www.w3.org/2000/svg';
    /** @type {?} */

    var MATH_ML_NAMESPACE = 'http://www.w3.org/1998/MathML/';
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/interfaces/context.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * This property will be monkey-patched on elements, components and directives
     * @type {?}
     */

    var MONKEY_PATCH_KEY_NAME = '__ngContext__';
    /**
     * The internal view context which is specific to a given DOM element, directive or
     * component instance. Each value in here (besides the LView and element node details)
     * can be present, null or undefined. If undefined then it implies the value has not been
     * looked up yet, otherwise, if null, then a lookup was executed and nothing was found.
     *
     * Each value will get filled when the respective value is examined within the getContext
     * function. The component, element and each directive instance will share the same instance
     * of the context.
     * @record
     */

    function LContext() {}

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/interfaces/document.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Most of the use of `document` in Angular is from within the DI system so it is possible to simply
     * inject the `DOCUMENT` token and are done.
     *
     * Ivy is special because it does not rely upon the DI and must get hold of the document some other
     * way.
     *
     * The solution is to define `getDocument()` and `setDocument()` top-level functions for ivy.
     * Wherever ivy needs the global document, it calls `getDocument()` instead.
     *
     * When running ivy outside of a browser environment, it is necessary to call `setDocument()` to
     * tell ivy what the global `document` is.
     *
     * Angular does this for us in each of the standard platforms (`Browser`, `Server`, and `WebWorker`)
     * by calling `setDocument()` when providing the `DOCUMENT` token.
     * @type {?}
     */


    var DOCUMENT = undefined;
    /**
     * Tell ivy what the `document` is for this platform.
     *
     * It is only necessary to call this if the current platform is not a browser.
     *
     * @param {?} document The object representing the global `document` in this environment.
     * @return {?}
     */

    function setDocument(document) {
      DOCUMENT = document;
    }
    /**
     * Access the object that represents the `document` for this platform.
     *
     * Ivy calls this whenever it needs to access the `document` object.
     * For example to create the renderer or to do sanitization.
     * @return {?}
     */


    function getDocument() {
      if (DOCUMENT !== undefined) {
        return DOCUMENT;
      } else if (typeof document !== 'undefined') {
        return document;
      } // No "document" can be found. This should only happen if we are running ivy outside Angular and
      // the current platform is not a browser. Since this is not a supported scenario at the moment
      // this should not happen in Angular apps.
      // Once we support running ivy outside of Angular we will need to publish `setDocument()` as a
      // public API. Meanwhile we just return `undefined` and let the application fail.


      return (
        /** @type {?} */
        undefined
      );
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/interfaces/renderer.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @enum {number} */


    var RendererStyleFlags3 = {
      Important: 1,
      DashCase: 2
    };
    RendererStyleFlags3[RendererStyleFlags3.Important] = 'Important';
    RendererStyleFlags3[RendererStyleFlags3.DashCase] = 'DashCase';
    /**
     * Object Oriented style of API needed to create elements and text nodes.
     *
     * This is the native browser API style, e.g. operations are methods on individual objects
     * like HTMLElement. With this style, no additional code is needed as a facade
     * (reducing payload size).
     *
     * @record
     */

    function ObjectOrientedRenderer3() {}

    if (false) {}
    /**
     * Returns whether the `renderer` is a `ProceduralRenderer3`
     * @param {?} renderer
     * @return {?}
     */


    function isProceduralRenderer(renderer) {
      return !!
      /** @type {?} */
      renderer.listen;
    }
    /**
     * Procedural style of API needed to create elements and text nodes.
     *
     * In non-native browser environments (e.g. platforms such as web-workers), this is the
     * facade that enables element manipulation. This also facilitates backwards compatibility
     * with Renderer2.
     * @record
     */


    function ProceduralRenderer3() {}

    if (false) {}
    /**
     * @record
     */


    function RendererFactory3() {}

    if (false) {}

    var ɵ0$2 =
    /**
    * @param {?} hostElement
    * @param {?} rendererType
    * @return {?}
    */
    function ɵ0$2(hostElement, rendererType) {
      return getDocument();
    };
    /** @type {?} */


    var domRendererFactory3 = {
      createRenderer: ɵ0$2
    };
    /**
     * Subset of API needed for appending elements and text nodes.
     * @record
     */

    function RNode() {}

    if (false) {}
    /**
     * Subset of API needed for writing attributes, properties, and setting up
     * listeners on Element.
     * @record
     */


    function RElement() {}

    if (false) {}
    /**
     * @record
     */


    function RCssStyleDeclaration() {}

    if (false) {}
    /**
     * @record
     */


    function RDomTokenList() {}

    if (false) {}
    /**
     * @record
     */


    function RText() {}

    if (false) {}
    /**
     * @record
     */


    function RComment() {}

    if (false) {} // Note: This hack is necessary so we don't erroneously get a circular dependency
    // failure based on types.

    /** @type {?} */


    var unusedValueExportToPlacateAjd$2 = 1;
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/util/view_utils.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * For efficiency reasons we often put several different data types (`RNode`, `LView`, `LContainer`)
     * in same location in `LView`. This is because we don't want to pre-allocate space for it
     * because the storage is sparse. This file contains utilities for dealing with such data types.
     *
     * How do we know what is stored at a given location in `LView`.
     * - `Array.isArray(value) === false` => `RNode` (The normal storage value)
     * - `Array.isArray(value) === true` => then the `value[0]` represents the wrapped value.
     *   - `typeof value[TYPE] === 'object'` => `LView`
     *      - This happens when we have a component at a given location
     *   - `typeof value[TYPE] === true` => `LContainer`
     *      - This happens when we have `LContainer` binding at a given location.
     *
     *
     * NOTE: it is assumed that `Array.isArray` and `typeof` operations are very efficient.
     */

    /**
     * Returns `RNode`.
     * @param {?} value wrapped value of `RNode`, `LView`, `LContainer`
     * @return {?}
     */

    function unwrapRNode(value) {
      while (Array.isArray(value)) {
        value =
        /** @type {?} */
        value[HOST];
      }

      return (
        /** @type {?} */
        value
      );
    }
    /**
     * Returns `LView` or `null` if not found.
     * @param {?} value wrapped value of `RNode`, `LView`, `LContainer`
     * @return {?}
     */


    function unwrapLView(value) {
      while (Array.isArray(value)) {
        // This check is same as `isLView()` but we don't call at as we don't want to call
        // `Array.isArray()` twice and give JITer more work for inlining.
        if (typeof value[TYPE] === 'object') return (
          /** @type {?} */
          value
        );
        value =
        /** @type {?} */
        value[HOST];
      }

      return null;
    }
    /**
     * Returns `LContainer` or `null` if not found.
     * @param {?} value wrapped value of `RNode`, `LView`, `LContainer`
     * @return {?}
     */


    function unwrapLContainer(value) {
      while (Array.isArray(value)) {
        // This check is same as `isLContainer()` but we don't call at as we don't want to call
        // `Array.isArray()` twice and give JITer more work for inlining.
        if (value[TYPE] === true) return (
          /** @type {?} */
          value
        );
        value =
        /** @type {?} */
        value[HOST];
      }

      return null;
    }
    /**
     * Retrieves an element value from the provided `viewData`, by unwrapping
     * from any containers, component views, or style contexts.
     * @param {?} index
     * @param {?} lView
     * @return {?}
     */


    function getNativeByIndex(index, lView) {
      return unwrapRNode(lView[index + HEADER_OFFSET]);
    }
    /**
     * Retrieve an `RNode` for a given `TNode` and `LView`.
     *
     * This function guarantees in dev mode to retrieve a non-null `RNode`.
     *
     * @param {?} tNode
     * @param {?} lView
     * @return {?}
     */


    function getNativeByTNode(tNode, lView) {
      ngDevMode && assertTNodeForLView(tNode, lView);
      ngDevMode && assertDataInRange(lView, tNode.index);
      /** @type {?} */

      var node = unwrapRNode(lView[tNode.index]);
      ngDevMode && !isProceduralRenderer(lView[RENDERER]) && assertDomNode(node);
      return node;
    }
    /**
     * Retrieve an `RNode` or `null` for a given `TNode` and `LView`.
     *
     * Some `TNode`s don't have associated `RNode`s. For example `Projection`
     *
     * @param {?} tNode
     * @param {?} lView
     * @return {?}
     */


    function getNativeByTNodeOrNull(tNode, lView) {
      /** @type {?} */
      var index = tNode.index;

      if (index !== -1) {
        ngDevMode && assertTNodeForLView(tNode, lView);
        /** @type {?} */

        var node = unwrapRNode(lView[index]);
        ngDevMode && node !== null && !isProceduralRenderer(lView[RENDERER]) && assertDomNode(node);
        return node;
      }

      return null;
    }
    /**
     * @param {?} tView
     * @param {?} index
     * @return {?}
     */


    function getTNode(tView, index) {
      ngDevMode && assertGreaterThan(index, -1, 'wrong index for TNode');
      ngDevMode && assertLessThan(index, tView.data.length, 'wrong index for TNode');
      return (
        /** @type {?} */
        tView.data[index + HEADER_OFFSET]
      );
    }
    /**
     * Retrieves a value from any `LView` or `TData`.
     * @template T
     * @param {?} view
     * @param {?} index
     * @return {?}
     */


    function load(view, index) {
      ngDevMode && assertDataInRange(view, index + HEADER_OFFSET);
      return view[index + HEADER_OFFSET];
    }
    /**
     * @param {?} nodeIndex
     * @param {?} hostView
     * @return {?}
     */


    function getComponentLViewByIndex(nodeIndex, hostView) {
      // Could be an LView or an LContainer. If LContainer, unwrap to find LView.
      ngDevMode && assertDataInRange(hostView, nodeIndex);
      /** @type {?} */

      var slotValue = hostView[nodeIndex];
      /** @type {?} */

      var lView = isLView(slotValue) ? slotValue : slotValue[HOST];
      return lView;
    }
    /**
     * Returns the monkey-patch value data present on the target (which could be
     * a component, directive or a DOM node).
     * @param {?} target
     * @return {?}
     */


    function readPatchedData(target) {
      ngDevMode && assertDefined(target, 'Target expected');
      return target[MONKEY_PATCH_KEY_NAME] || null;
    }
    /**
     * @param {?} target
     * @return {?}
     */


    function readPatchedLView(target) {
      /** @type {?} */
      var value = readPatchedData(target);

      if (value) {
        return Array.isArray(value) ? value :
        /** @type {?} */
        value.lView;
      }

      return null;
    }
    /**
     * Checks whether a given view is in creation mode
     * @param {?} view
     * @return {?}
     */


    function isCreationMode(view) {
      return (view[FLAGS] & 4
      /* CreationMode */
      ) === 4
      /* CreationMode */
      ;
    }
    /**
     * Returns a boolean for whether the view is attached to the change detection tree.
     *
     * Note: This determines whether a view should be checked, not whether it's inserted
     * into a container. For that, you'll want `viewAttachedToContainer` below.
     * @param {?} view
     * @return {?}
     */


    function viewAttachedToChangeDetector(view) {
      return (view[FLAGS] & 128
      /* Attached */
      ) === 128
      /* Attached */
      ;
    }
    /**
     * Returns a boolean for whether the view is attached to a container.
     * @param {?} view
     * @return {?}
     */


    function viewAttachedToContainer(view) {
      return isLContainer(view[PARENT]);
    }
    /**
     * Returns a constant from `TConstants` instance.
     * @template T
     * @param {?} consts
     * @param {?} index
     * @return {?}
     */


    function getConstant(consts, index) {
      return consts === null || index == null ? null :
      /** @type {?} */

      /** @type {?} */
      consts[index];
    }
    /**
     * Resets the pre-order hook flags of the view.
     * @param {?} lView the LView on which the flags are reset
     * @return {?}
     */


    function resetPreOrderHookFlags(lView) {
      lView[PREORDER_HOOK_FLAGS] = 0;
    }
    /**
     * @param {?} lContainer
     * @return {?}
     */


    function getLContainerActiveIndex(lContainer) {
      return lContainer[ACTIVE_INDEX] >> 1
      /* SHIFT */
      ;
    }
    /**
     * @param {?} lContainer
     * @param {?} index
     * @return {?}
     */


    function setLContainerActiveIndex(lContainer, index) {
      lContainer[ACTIVE_INDEX] = index << 1
      /* SHIFT */
      ;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/state.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     *
     * @record
     */


    function LFrame() {}

    if (false) {}
    /**
     * All implicit instruction state is stored here.
     *
     * It is useful to have a single object where all of the state is stored as a mental model
     * (rather it being spread across many different variables.)
     *
     * PERF NOTE: Turns out that writing to a true global variable is slower than
     * having an intermediate object with properties.
     * @record
     */


    function InstructionState() {}

    if (false) {}
    /** @type {?} */


    var instructionState = {
      lFrame: createLFrame(null),
      bindingsEnabled: true,
      checkNoChangesMode: false
    };
    /**
     * @return {?}
     */

    function getElementDepthCount() {
      return instructionState.lFrame.elementDepthCount;
    }
    /**
     * @return {?}
     */


    function increaseElementDepthCount() {
      instructionState.lFrame.elementDepthCount++;
    }
    /**
     * @return {?}
     */


    function decreaseElementDepthCount() {
      instructionState.lFrame.elementDepthCount--;
    }
    /**
     * @return {?}
     */


    function getBindingsEnabled() {
      return instructionState.bindingsEnabled;
    }
    /**
     * Enables directive matching on elements.
     *
     *  * Example:
     * ```
     * <my-comp my-directive>
     *   Should match component / directive.
     * </my-comp>
     * <div ngNonBindable>
     *   <!-- ɵɵdisableBindings() -->
     *   <my-comp my-directive>
     *     Should not match component / directive because we are in ngNonBindable.
     *   </my-comp>
     *   <!-- ɵɵenableBindings() -->
     * </div>
     * ```
     *
     * \@codeGenApi
     * @return {?}
     */


    function ɵɵenableBindings() {
      instructionState.bindingsEnabled = true;
    }
    /**
     * Disables directive matching on element.
     *
     *  * Example:
     * ```
     * <my-comp my-directive>
     *   Should match component / directive.
     * </my-comp>
     * <div ngNonBindable>
     *   <!-- ɵɵdisableBindings() -->
     *   <my-comp my-directive>
     *     Should not match component / directive because we are in ngNonBindable.
     *   </my-comp>
     *   <!-- ɵɵenableBindings() -->
     * </div>
     * ```
     *
     * \@codeGenApi
     * @return {?}
     */


    function ɵɵdisableBindings() {
      instructionState.bindingsEnabled = false;
    }
    /**
     * Return the current `LView`.
     * @return {?}
     */


    function getLView() {
      return instructionState.lFrame.lView;
    }
    /**
     * Return the current `TView`.
     * @return {?}
     */


    function getTView() {
      return instructionState.lFrame.tView;
    }
    /**
     * Restores `contextViewData` to the given OpaqueViewState instance.
     *
     * Used in conjunction with the getCurrentView() instruction to save a snapshot
     * of the current view and restore it when listeners are invoked. This allows
     * walking the declaration view tree in listeners to get vars from parent views.
     *
     * \@codeGenApi
     * @param {?} viewToRestore The OpaqueViewState instance to restore.
     *
     * @return {?}
     */


    function ɵɵrestoreView(viewToRestore) {
      instructionState.lFrame.contextLView =
      /** @type {?} */

      /** @type {?} */
      viewToRestore;
    }
    /**
     * @return {?}
     */


    function getPreviousOrParentTNode() {
      return instructionState.lFrame.previousOrParentTNode;
    }
    /**
     * @param {?} tNode
     * @param {?} isParent
     * @return {?}
     */


    function setPreviousOrParentTNode(tNode, isParent) {
      instructionState.lFrame.previousOrParentTNode = tNode;
      instructionState.lFrame.isParent = isParent;
    }
    /**
     * @return {?}
     */


    function getIsParent() {
      return instructionState.lFrame.isParent;
    }
    /**
     * @return {?}
     */


    function setIsNotParent() {
      instructionState.lFrame.isParent = false;
    }
    /**
     * @return {?}
     */


    function setIsParent() {
      instructionState.lFrame.isParent = true;
    }
    /**
     * @return {?}
     */


    function getContextLView() {
      return instructionState.lFrame.contextLView;
    }
    /**
     * @return {?}
     */


    function getCheckNoChangesMode() {
      // TODO(misko): remove this from the LView since it is ngDevMode=true mode only.
      return instructionState.checkNoChangesMode;
    }
    /**
     * @param {?} mode
     * @return {?}
     */


    function setCheckNoChangesMode(mode) {
      instructionState.checkNoChangesMode = mode;
    } // top level variables should not be exported for performance reasons (PERF_NOTES.md)

    /**
     * @return {?}
     */


    function getBindingRoot() {
      /** @type {?} */
      var lFrame = instructionState.lFrame;
      /** @type {?} */

      var index = lFrame.bindingRootIndex;

      if (index === -1) {
        index = lFrame.bindingRootIndex = lFrame.tView.bindingStartIndex;
      }

      return index;
    }
    /**
     * @return {?}
     */


    function getBindingIndex() {
      return instructionState.lFrame.bindingIndex;
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function setBindingIndex(value) {
      return instructionState.lFrame.bindingIndex = value;
    }
    /**
     * @return {?}
     */


    function nextBindingIndex() {
      return instructionState.lFrame.bindingIndex++;
    }
    /**
     * @param {?} count
     * @return {?}
     */


    function incrementBindingIndex(count) {
      /** @type {?} */
      var lFrame = instructionState.lFrame;
      /** @type {?} */

      var index = lFrame.bindingIndex;
      lFrame.bindingIndex = lFrame.bindingIndex + count;
      return index;
    }
    /**
     * Set a new binding root index so that host template functions can execute.
     *
     * Bindings inside the host template are 0 index. But because we don't know ahead of time
     * how many host bindings we have we can't pre-compute them. For this reason they are all
     * 0 index and we just shift the root so that they match next available location in the LView.
     *
     * @param {?} bindingRootIndex Root index for `hostBindings`
     * @param {?} currentDirectiveIndex `TData[currentDirectiveIndex]` will point to the current directive
     *        whose `hostBindings` are being processed.
     * @return {?}
     */


    function setBindingRootForHostBindings(bindingRootIndex, currentDirectiveIndex) {
      /** @type {?} */
      var lFrame = instructionState.lFrame;
      lFrame.bindingIndex = lFrame.bindingRootIndex = bindingRootIndex;
      setCurrentDirectiveIndex(currentDirectiveIndex);
    }
    /**
     * When host binding is executing this points to the directive index.
     * `TView.data[getCurrentDirectiveIndex()]` is `DirectiveDef`
     * `LView[getCurrentDirectiveIndex()]` is directive instance.
     * @return {?}
     */


    function getCurrentDirectiveIndex() {
      return instructionState.lFrame.currentDirectiveIndex;
    }
    /**
     * Sets an index of a directive whose `hostBindings` are being processed.
     *
     * @param {?} currentDirectiveIndex `TData` index where current directive instance can be found.
     * @return {?}
     */


    function setCurrentDirectiveIndex(currentDirectiveIndex) {
      instructionState.lFrame.currentDirectiveIndex = currentDirectiveIndex;
    }
    /**
     * Retrieve the current `DirectiveDef` which is active when `hostBindings` instruction is being
     * executed.
     *
     * @param {?} tData Current `TData` where the `DirectiveDef` will be looked up at.
     * @return {?}
     */


    function getCurrentDirectiveDef(tData) {
      /** @type {?} */
      var currentDirectiveIndex = instructionState.lFrame.currentDirectiveIndex;
      return currentDirectiveIndex === -1 ? null :
      /** @type {?} */
      tData[currentDirectiveIndex];
    }
    /**
     * @return {?}
     */


    function getCurrentQueryIndex() {
      return instructionState.lFrame.currentQueryIndex;
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function setCurrentQueryIndex(value) {
      instructionState.lFrame.currentQueryIndex = value;
    }
    /**
     * This is a light weight version of the `enterView` which is needed by the DI system.
     * @param {?} newView
     * @param {?} tNode
     * @return {?}
     */


    function enterDI(newView, tNode) {
      ngDevMode && assertLViewOrUndefined(newView);
      /** @type {?} */

      var newLFrame = allocLFrame();
      instructionState.lFrame = newLFrame;
      newLFrame.previousOrParentTNode =
      /** @type {?} */
      tNode;
      newLFrame.lView = newView;
    }
    /**
     * Swap the current lView with a new lView.
     *
     * For performance reasons we store the lView in the top level of the module.
     * This way we minimize the number of properties to read. Whenever a new view
     * is entered we have to store the lView for later, and when the view is
     * exited the state has to be restored
     *
     * @param {?} newView New lView to become active
     * @param {?} tNode Element to which the View is a child of
     * @return {?} the previously active lView;
     */


    function enterView(newView, tNode) {
      ngDevMode && assertLViewOrUndefined(newView);
      /** @type {?} */

      var newLFrame = allocLFrame();

      if (ngDevMode) {
        assertEqual(newLFrame.isParent, true, 'Expected clean LFrame');
        assertEqual(newLFrame.lView, null, 'Expected clean LFrame');
        assertEqual(newLFrame.tView, null, 'Expected clean LFrame');
        assertEqual(newLFrame.selectedIndex, 0, 'Expected clean LFrame');
        assertEqual(newLFrame.elementDepthCount, 0, 'Expected clean LFrame');
        assertEqual(newLFrame.currentDirectiveIndex, -1, 'Expected clean LFrame');
        assertEqual(newLFrame.currentNamespace, null, 'Expected clean LFrame');
        assertEqual(newLFrame.currentSanitizer, null, 'Expected clean LFrame');
        assertEqual(newLFrame.bindingRootIndex, -1, 'Expected clean LFrame');
        assertEqual(newLFrame.currentQueryIndex, 0, 'Expected clean LFrame');
      }
      /** @type {?} */


      var tView = newView[TVIEW];
      instructionState.lFrame = newLFrame;
      newLFrame.previousOrParentTNode =
      /** @type {?} */
      tNode;
      newLFrame.lView = newView;
      newLFrame.tView = tView;
      newLFrame.contextLView =
      /** @type {?} */
      newView;
      newLFrame.bindingIndex = tView.bindingStartIndex;
    }
    /**
     * Allocates next free LFrame. This function tries to reuse the `LFrame`s to lower memory pressure.
     * @return {?}
     */


    function allocLFrame() {
      /** @type {?} */
      var currentLFrame = instructionState.lFrame;
      /** @type {?} */

      var childLFrame = currentLFrame === null ? null : currentLFrame.child;
      /** @type {?} */

      var newLFrame = childLFrame === null ? createLFrame(currentLFrame) : childLFrame;
      return newLFrame;
    }
    /**
     * @param {?} parent
     * @return {?}
     */


    function createLFrame(parent) {
      /** @type {?} */
      var lFrame = {
        previousOrParentTNode:
        /** @type {?} */
        null,
        //
        isParent: true,
        //
        lView:
        /** @type {?} */
        null,
        //
        tView:
        /** @type {?} */
        null,
        //
        selectedIndex: 0,
        //
        contextLView:
        /** @type {?} */
        null,
        //
        elementDepthCount: 0,
        //
        currentNamespace: null,
        //
        currentSanitizer: null,
        //
        currentDirectiveIndex: -1,
        //
        bindingRootIndex: -1,
        //
        bindingIndex: -1,
        //
        currentQueryIndex: 0,
        //
        parent:
        /** @type {?} */
        parent,
        //
        child: null
      };
      parent !== null && (parent.child = lFrame); // link the new LFrame for reuse.

      return lFrame;
    }
    /**
     * A lightweight version of leave which is used with DI.
     *
     * This function only resets `previousOrParentTNode` and `LView` as those are the only properties
     * used with DI (`enterDI()`).
     *
     * NOTE: This function is reexported as `leaveDI`. However `leaveDI` has return type of `void` where
     * as `leaveViewLight` has `LFrame`. This is so that `leaveViewLight` can be used in `leaveView`.
     * @return {?}
     */


    function leaveViewLight() {
      /** @type {?} */
      var oldLFrame = instructionState.lFrame;
      instructionState.lFrame = oldLFrame.parent;
      oldLFrame.previousOrParentTNode =
      /** @type {?} */
      null;
      oldLFrame.lView =
      /** @type {?} */
      null;
      return oldLFrame;
    }
    /**
     * This is a lightweight version of the `leaveView` which is needed by the DI system.
     *
     * NOTE: this function is an alias so that we can change the type of the function to have `void`
     * return type.
     * @type {?}
     */


    var leaveDI = leaveViewLight;
    /**
     * Leave the current `LView`
     *
     * This pops the `LFrame` with the associated `LView` from the stack.
     *
     * IMPORTANT: We must zero out the `LFrame` values here otherwise they will be retained. This is
     * because for performance reasons we don't release `LFrame` but rather keep it for next use.
     * @return {?}
     */

    function leaveView() {
      /** @type {?} */
      var oldLFrame = leaveViewLight();
      oldLFrame.isParent = true;
      oldLFrame.tView =
      /** @type {?} */
      null;
      oldLFrame.selectedIndex = 0;
      oldLFrame.contextLView =
      /** @type {?} */
      null;
      oldLFrame.elementDepthCount = 0;
      oldLFrame.currentDirectiveIndex = -1;
      oldLFrame.currentNamespace = null;
      oldLFrame.currentSanitizer = null;
      oldLFrame.bindingRootIndex = -1;
      oldLFrame.bindingIndex = -1;
      oldLFrame.currentQueryIndex = 0;
    }
    /**
     * @template T
     * @param {?} level
     * @return {?}
     */


    function nextContextImpl(level) {
      /** @type {?} */
      var contextLView = instructionState.lFrame.contextLView = walkUpViews(level,
      /** @type {?} */
      instructionState.lFrame.contextLView);
      return (
        /** @type {?} */
        contextLView[CONTEXT]
      );
    }
    /**
     * @param {?} nestingLevel
     * @param {?} currentView
     * @return {?}
     */


    function walkUpViews(nestingLevel, currentView) {
      while (nestingLevel > 0) {
        ngDevMode && assertDefined(currentView[DECLARATION_VIEW], 'Declaration view should be defined if nesting level is greater than 0.');
        currentView =
        /** @type {?} */
        currentView[DECLARATION_VIEW];
        nestingLevel--;
      }

      return currentView;
    }
    /**
     * Gets the currently selected element index.
     *
     * Used with {\@link property} instruction (and more in the future) to identify the index in the
     * current `LView` to act on.
     * @return {?}
     */


    function getSelectedIndex() {
      return instructionState.lFrame.selectedIndex;
    }
    /**
     * Sets the most recent index passed to {\@link select}
     *
     * Used with {\@link property} instruction (and more in the future) to identify the index in the
     * current `LView` to act on.
     *
     * (Note that if an "exit function" was set earlier (via `setElementExitFn()`) then that will be
     * run if and when the provided `index` value is different from the current selected index value.)
     * @param {?} index
     * @return {?}
     */


    function setSelectedIndex(index) {
      instructionState.lFrame.selectedIndex = index;
    }
    /**
     * Gets the `tNode` that represents currently selected element.
     * @return {?}
     */


    function getSelectedTNode() {
      /** @type {?} */
      var lFrame = instructionState.lFrame;
      return getTNode(lFrame.tView, lFrame.selectedIndex);
    }
    /**
     * Sets the namespace used to create elements to `'http://www.w3.org/2000/svg'` in global state.
     *
     * \@codeGenApi
     * @return {?}
     */


    function ɵɵnamespaceSVG() {
      instructionState.lFrame.currentNamespace = SVG_NAMESPACE;
    }
    /**
     * Sets the namespace used to create elements to `'http://www.w3.org/1998/MathML/'` in global state.
     *
     * \@codeGenApi
     * @return {?}
     */


    function ɵɵnamespaceMathML() {
      instructionState.lFrame.currentNamespace = MATH_ML_NAMESPACE;
    }
    /**
     * Sets the namespace used to create elements to `null`, which forces element creation to use
     * `createElement` rather than `createElementNS`.
     *
     * \@codeGenApi
     * @return {?}
     */


    function ɵɵnamespaceHTML() {
      namespaceHTMLInternal();
    }
    /**
     * Sets the namespace used to create elements to `null`, which forces element creation to use
     * `createElement` rather than `createElementNS`.
     * @return {?}
     */


    function namespaceHTMLInternal() {
      instructionState.lFrame.currentNamespace = null;
    }
    /**
     * @return {?}
     */


    function getNamespace() {
      return instructionState.lFrame.currentNamespace;
    }
    /**
     * @param {?} sanitizer
     * @return {?}
     */


    function setCurrentStyleSanitizer(sanitizer) {
      instructionState.lFrame.currentSanitizer = sanitizer;
    }
    /**
     * @return {?}
     */


    function resetCurrentStyleSanitizer() {
      setCurrentStyleSanitizer(null);
    }
    /**
     * @return {?}
     */


    function getCurrentStyleSanitizer() {
      // TODO(misko): This should throw when there is no LView, but it turns out we can get here from
      // `NodeStyleDebug` hence we return `null`. This should be fixed

      /** @type {?} */
      var lFrame = instructionState.lFrame;
      return lFrame === null ? null : lFrame.currentSanitizer;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/hooks.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Adds all directive lifecycle hooks from the given `DirectiveDef` to the given `TView`.
     *
     * Must be run *only* on the first template pass.
     *
     * Sets up the pre-order hooks on the provided `tView`,
     * see {\@link HookData} for details about the data structure.
     *
     * @param {?} directiveIndex The index of the directive in LView
     * @param {?} directiveDef The definition containing the hooks to setup in tView
     * @param {?} tView The current TView
     * @return {?}
     */


    function registerPreOrderHooks(directiveIndex, directiveDef, tView) {
      ngDevMode && assertFirstCreatePass(tView);
      var onChanges = directiveDef.onChanges,
          onInit = directiveDef.onInit,
          doCheck = directiveDef.doCheck;

      if (onChanges) {
        (tView.preOrderHooks || (tView.preOrderHooks = [])).push(directiveIndex, onChanges);
        (tView.preOrderCheckHooks || (tView.preOrderCheckHooks = [])).push(directiveIndex, onChanges);
      }

      if (onInit) {
        (tView.preOrderHooks || (tView.preOrderHooks = [])).push(-directiveIndex, onInit);
      }

      if (doCheck) {
        (tView.preOrderHooks || (tView.preOrderHooks = [])).push(directiveIndex, doCheck);
        (tView.preOrderCheckHooks || (tView.preOrderCheckHooks = [])).push(directiveIndex, doCheck);
      }
    }
    /**
     *
     * Loops through the directives on the provided `tNode` and queues hooks to be
     * run that are not initialization hooks.
     *
     * Should be executed during `elementEnd()` and similar to
     * preserve hook execution order. Content, view, and destroy hooks for projected
     * components and directives must be called *before* their hosts.
     *
     * Sets up the content, view, and destroy hooks on the provided `tView`,
     * see {\@link HookData} for details about the data structure.
     *
     * NOTE: This does not set up `onChanges`, `onInit` or `doCheck`, those are set up
     * separately at `elementStart`.
     *
     * @param {?} tView The current TView
     * @param {?} tNode The TNode whose directives are to be searched for hooks to queue
     * @return {?}
     */


    function registerPostOrderHooks(tView, tNode) {
      ngDevMode && assertFirstCreatePass(tView); // It's necessary to loop through the directives at elementEnd() (rather than processing in
      // directiveCreate) so we can preserve the current hook order. Content, view, and destroy
      // hooks for projected components and directives must be called *before* their hosts.

      for (var i = tNode.directiveStart, end = tNode.directiveEnd; i < end; i++) {
        /** @type {?} */
        var _directiveDef =
        /** @type {?} */
        tView.data[i];

        if (_directiveDef.afterContentInit) {
          (tView.contentHooks || (tView.contentHooks = [])).push(-i, _directiveDef.afterContentInit);
        }

        if (_directiveDef.afterContentChecked) {
          (tView.contentHooks || (tView.contentHooks = [])).push(i, _directiveDef.afterContentChecked);
          (tView.contentCheckHooks || (tView.contentCheckHooks = [])).push(i, _directiveDef.afterContentChecked);
        }

        if (_directiveDef.afterViewInit) {
          (tView.viewHooks || (tView.viewHooks = [])).push(-i, _directiveDef.afterViewInit);
        }

        if (_directiveDef.afterViewChecked) {
          (tView.viewHooks || (tView.viewHooks = [])).push(i, _directiveDef.afterViewChecked);
          (tView.viewCheckHooks || (tView.viewCheckHooks = [])).push(i, _directiveDef.afterViewChecked);
        }

        if (_directiveDef.onDestroy != null) {
          (tView.destroyHooks || (tView.destroyHooks = [])).push(i, _directiveDef.onDestroy);
        }
      }
    }
    /**
     * Executing hooks requires complex logic as we need to deal with 2 constraints.
     *
     * 1. Init hooks (ngOnInit, ngAfterContentInit, ngAfterViewInit) must all be executed once and only
     * once, across many change detection cycles. This must be true even if some hooks throw, or if
     * some recursively trigger a change detection cycle.
     * To solve that, it is required to track the state of the execution of these init hooks.
     * This is done by storing and maintaining flags in the view: the {@link InitPhaseState},
     * and the index within that phase. They can be seen as a cursor in the following structure:
     * [[onInit1, onInit2], [afterContentInit1], [afterViewInit1, afterViewInit2, afterViewInit3]]
     * They are are stored as flags in LView[FLAGS].
     *
     * 2. Pre-order hooks can be executed in batches, because of the select instruction.
     * To be able to pause and resume their execution, we also need some state about the hook's array
     * that is being processed:
     * - the index of the next hook to be executed
     * - the number of init hooks already found in the processed part of the  array
     * They are are stored as flags in LView[PREORDER_HOOK_FLAGS].
     */

    /**
     * Executes pre-order check hooks ( OnChanges, DoChanges) given a view where all the init hooks were
     * executed once. This is a light version of executeInitAndCheckPreOrderHooks where we can skip read
     * / write of the init-hooks related flags.
     * @param {?} lView The LView where hooks are defined
     * @param {?} hooks Hooks to be run
     * @param {?=} nodeIndex 3 cases depending on the value:
     * - undefined: all hooks from the array should be executed (post-order case)
     * - null: execute hooks only from the saved index until the end of the array (pre-order case, when
     * flushing the remaining hooks)
     * - number: execute hooks only from the saved index until that node index exclusive (pre-order
     * case, when executing select(number))
     * @return {?}
     */


    function executeCheckHooks(lView, hooks, nodeIndex) {
      callHooks(lView, hooks, 3
      /* InitPhaseCompleted */
      , nodeIndex);
    }
    /**
     * Executes post-order init and check hooks (one of AfterContentInit, AfterContentChecked,
     * AfterViewInit, AfterViewChecked) given a view where there are pending init hooks to be executed.
     * @param {?} lView The LView where hooks are defined
     * @param {?} hooks Hooks to be run
     * @param {?} initPhase A phase for which hooks should be run
     * @param {?=} nodeIndex 3 cases depending on the value:
     * - undefined: all hooks from the array should be executed (post-order case)
     * - null: execute hooks only from the saved index until the end of the array (pre-order case, when
     * flushing the remaining hooks)
     * - number: execute hooks only from the saved index until that node index exclusive (pre-order
     * case, when executing select(number))
     * @return {?}
     */


    function executeInitAndCheckHooks(lView, hooks, initPhase, nodeIndex) {
      ngDevMode && assertNotEqual(initPhase, 3
      /* InitPhaseCompleted */
      , 'Init pre-order hooks should not be called more than once');

      if ((lView[FLAGS] & 3
      /* InitPhaseStateMask */
      ) === initPhase) {
        callHooks(lView, hooks, initPhase, nodeIndex);
      }
    }
    /**
     * @param {?} lView
     * @param {?} initPhase
     * @return {?}
     */


    function incrementInitPhaseFlags(lView, initPhase) {
      ngDevMode && assertNotEqual(initPhase, 3
      /* InitPhaseCompleted */
      , 'Init hooks phase should not be incremented after all init hooks have been run.');
      /** @type {?} */

      var flags = lView[FLAGS];

      if ((flags & 3
      /* InitPhaseStateMask */
      ) === initPhase) {
        flags &= 1023
        /* IndexWithinInitPhaseReset */
        ;
        flags += 1
        /* InitPhaseStateIncrementer */
        ;
        lView[FLAGS] = flags;
      }
    }
    /**
     * Calls lifecycle hooks with their contexts, skipping init hooks if it's not
     * the first LView pass
     *
     * @param {?} currentView The current view
     * @param {?} arr The array in which the hooks are found
     * @param {?} initPhase
     * @param {?} currentNodeIndex 3 cases depending on the value:
     * - undefined: all hooks from the array should be executed (post-order case)
     * - null: execute hooks only from the saved index until the end of the array (pre-order case, when
     * flushing the remaining hooks)
     * - number: execute hooks only from the saved index until that node index exclusive (pre-order
     * case, when executing select(number))
     * @return {?}
     */


    function callHooks(currentView, arr, initPhase, currentNodeIndex) {
      ngDevMode && assertEqual(getCheckNoChangesMode(), false, 'Hooks should never be run in the check no changes mode.');
      /** @type {?} */

      var startIndex = currentNodeIndex !== undefined ? currentView[PREORDER_HOOK_FLAGS] & 65535
      /* IndexOfTheNextPreOrderHookMaskMask */
      : 0;
      /** @type {?} */

      var nodeIndexLimit = currentNodeIndex != null ? currentNodeIndex : -1;
      /** @type {?} */

      var lastNodeIndexFound = 0;

      for (var i = startIndex; i < arr.length; i++) {
        /** @type {?} */
        var hook =
        /** @type {?} */
        arr[i + 1];

        if (typeof hook === 'number') {
          lastNodeIndexFound =
          /** @type {?} */
          arr[i];

          if (currentNodeIndex != null && lastNodeIndexFound >= currentNodeIndex) {
            break;
          }
        } else {
          /** @type {?} */
          var isInitHook = arr[i] < 0;
          if (isInitHook) currentView[PREORDER_HOOK_FLAGS] += 65536
          /* NumberOfInitHooksCalledIncrementer */
          ;

          if (lastNodeIndexFound < nodeIndexLimit || nodeIndexLimit == -1) {
            callHook(currentView, initPhase, arr, i);
            currentView[PREORDER_HOOK_FLAGS] = (currentView[PREORDER_HOOK_FLAGS] & 4294901760
            /* NumberOfInitHooksCalledMask */
            ) + i + 2;
          }

          i++;
        }
      }
    }
    /**
     * Execute one hook against the current `LView`.
     *
     * @param {?} currentView The current view
     * @param {?} initPhase
     * @param {?} arr The array in which the hooks are found
     * @param {?} i The current index within the hook data array
     * @return {?}
     */


    function callHook(currentView, initPhase, arr, i) {
      /** @type {?} */
      var isInitHook = arr[i] < 0;
      /** @type {?} */

      var hook =
      /** @type {?} */
      arr[i + 1];
      /** @type {?} */

      var directiveIndex = isInitHook ? -arr[i] :
      /** @type {?} */
      arr[i];
      /** @type {?} */

      var directive = currentView[directiveIndex];

      if (isInitHook) {
        /** @type {?} */
        var indexWithintInitPhase = currentView[FLAGS] >> 10
        /* IndexWithinInitPhaseShift */
        ; // The init phase state must be always checked here as it may have been recursively
        // updated

        if (indexWithintInitPhase < currentView[PREORDER_HOOK_FLAGS] >> 16
        /* NumberOfInitHooksCalledShift */
        && (currentView[FLAGS] & 3
        /* InitPhaseStateMask */
        ) === initPhase) {
          currentView[FLAGS] += 1024
          /* IndexWithinInitPhaseIncrementer */
          ;
          hook.call(directive);
        }
      } else {
        hook.call(directive);
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/interfaces/injector.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** @type {?} */


    var TNODE = 8;
    /** @type {?} */

    var PARENT_INJECTOR = 8;
    /** @type {?} */

    var INJECTOR_BLOOM_PARENT_SIZE = 9;
    /**
     * Represents a relative location of parent injector.
     *
     * The interfaces encodes number of parents `LView`s to traverse and index in the `LView`
     * pointing to the parent injector.
     * @record
     */

    function RelativeInjectorLocation() {}

    if (false) {}
    /** @enum {number} */


    var RelativeInjectorLocationFlags = {
      InjectorIndexMask: 32767,
      ViewOffsetShift: 16,
      NO_PARENT: -1
    };
    /** @type {?} */

    var NO_PARENT_INJECTOR =
    /** @type {?} */
    -1;
    /**
     * Each injector is saved in 9 contiguous slots in `LView` and 9 contiguous slots in
     * `TView.data`. This allows us to store information about the current node's tokens (which
     * can be shared in `TView`) as well as the tokens of its ancestor nodes (which cannot be
     * shared, so they live in `LView`).
     *
     * Each of these slots (aside from the last slot) contains a bloom filter. This bloom filter
     * determines whether a directive is available on the associated node or not. This prevents us
     * from searching the directives array at this level unless it's probable the directive is in it.
     *
     * See: https://en.wikipedia.org/wiki/Bloom_filter for more about bloom filters.
     *
     * Because all injectors have been flattened into `LView` and `TViewData`, they cannot typed
     * using interfaces as they were previously. The start index of each `LInjector` and `TInjector`
     * will differ based on where it is flattened into the main array, so it's not possible to know
     * the indices ahead of time and save their types here. The interfaces are still included here
     * for documentation purposes.
     *
     * export interface LInjector extends Array<any> {
     *
     *    // Cumulative bloom for directive IDs 0-31  (IDs are % BLOOM_SIZE)
     *    [0]: number;
     *
     *    // Cumulative bloom for directive IDs 32-63
     *    [1]: number;
     *
     *    // Cumulative bloom for directive IDs 64-95
     *    [2]: number;
     *
     *    // Cumulative bloom for directive IDs 96-127
     *    [3]: number;
     *
     *    // Cumulative bloom for directive IDs 128-159
     *    [4]: number;
     *
     *    // Cumulative bloom for directive IDs 160 - 191
     *    [5]: number;
     *
     *    // Cumulative bloom for directive IDs 192 - 223
     *    [6]: number;
     *
     *    // Cumulative bloom for directive IDs 224 - 255
     *    [7]: number;
     *
     *    // We need to store a reference to the injector's parent so DI can keep looking up
     *    // the injector tree until it finds the dependency it's looking for.
     *    [PARENT_INJECTOR]: number;
     * }
     *
     * export interface TInjector extends Array<any> {
     *
     *    // Shared node bloom for directive IDs 0-31  (IDs are % BLOOM_SIZE)
     *    [0]: number;
     *
     *    // Shared node bloom for directive IDs 32-63
     *    [1]: number;
     *
     *    // Shared node bloom for directive IDs 64-95
     *    [2]: number;
     *
     *    // Shared node bloom for directive IDs 96-127
     *    [3]: number;
     *
     *    // Shared node bloom for directive IDs 128-159
     *    [4]: number;
     *
     *    // Shared node bloom for directive IDs 160 - 191
     *    [5]: number;
     *
     *    // Shared node bloom for directive IDs 192 - 223
     *    [6]: number;
     *
     *    // Shared node bloom for directive IDs 224 - 255
     *    [7]: number;
     *
     *    // Necessary to find directive indices for a particular node.
     *    [TNODE]: TElementNode|TElementContainerNode|TContainerNode;
     *  }
     */

    /**
     * Factory for creating instances of injectors in the NodeInjector.
     *
     * This factory is complicated by the fact that it can resolve `multi` factories as well.
     *
     * NOTE: Some of the fields are optional which means that this class has two hidden classes.
     * - One without `multi` support (most common)
     * - One with `multi` values, (rare).
     *
     * Since VMs can cache up to 4 inline hidden classes this is OK.
     *
     * - Single factory: Only `resolving` and `factory` is defined.
     * - `providers` factory: `componentProviders` is a number and `index = -1`.
     * - `viewProviders` factory: `componentProviders` is a number and `index` points to `providers`.
     */

    var NodeInjectorFactory =
    /**
     * @param {?} factory
     * @param {?} isViewProvider
     * @param {?} injectImplementation
     */
    function NodeInjectorFactory(factory,
    /**
     * Set to `true` if the token is declared in `viewProviders` (or if it is component).
     */
    isViewProvider, injectImplementation) {
      _classCallCheck(this, NodeInjectorFactory);

      this.factory = factory;
      /**
       * Marker set to true during factory invocation to see if we get into recursive loop.
       * Recursive loop causes an error to be displayed.
       */

      this.resolving = false;
      this.canSeeViewProviders = isViewProvider;
      this.injectImpl = injectImplementation;
    };

    if (false) {}
    /**
     * @param {?} obj
     * @return {?}
     */


    function isFactory(obj) {
      return obj instanceof NodeInjectorFactory;
    } // Note: This hack is necessary so we don't erroneously get a circular dependency
    // failure based on types.

    /** @type {?} */


    var unusedValueExportToPlacateAjd$3 = 1;
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/node_assert.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} tNode
     * @param {?} type
     * @return {?}
     */

    function assertNodeType(tNode, type) {
      assertDefined(tNode, 'should be called with a TNode');
      assertEqual(tNode.type, type, "should be a ".concat(typeName(type)));
    }
    /**
     * @param {?} tNode
     * @param {...?} types
     * @return {?}
     */


    function assertNodeOfPossibleTypes(tNode) {
      assertDefined(tNode, 'should be called with a TNode');
      /** @type {?} */

      for (var _len10 = arguments.length, types = new Array(_len10 > 1 ? _len10 - 1 : 0), _key11 = 1; _key11 < _len10; _key11++) {
        types[_key11 - 1] = arguments[_key11];
      }

      var found = types.some(
      /**
      * @param {?} type
      * @return {?}
      */
      function (type) {
        return tNode.type === type;
      });
      assertEqual(found, true, "Should be one of ".concat(types.map(typeName).join(', '), " but got ").concat(typeName(tNode.type)));
    }
    /**
     * @param {?} type
     * @return {?}
     */


    function typeName(type) {
      if (type == 1
      /* Projection */
      ) return 'Projection';
      if (type == 0
      /* Container */
      ) return 'Container';
      if (type == 5
      /* IcuContainer */
      ) return 'IcuContainer';
      if (type == 2
      /* View */
      ) return 'View';
      if (type == 3
      /* Element */
      ) return 'Element';
      if (type == 4
      /* ElementContainer */
      ) return 'ElementContainer';
      return '<unknown>';
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/util/attrs_utils.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Assigns all attribute values to the provided element via the inferred renderer.
     *
     * This function accepts two forms of attribute entries:
     *
     * default: (key, value):
     *  attrs = [key1, value1, key2, value2]
     *
     * namespaced: (NAMESPACE_MARKER, uri, name, value)
     *  attrs = [NAMESPACE_MARKER, uri, name, value, NAMESPACE_MARKER, uri, name, value]
     *
     * The `attrs` array can contain a mix of both the default and namespaced entries.
     * The "default" values are set without a marker, but if the function comes across
     * a marker value then it will attempt to set a namespaced value. If the marker is
     * not of a namespaced value then the function will quit and return the index value
     * where it stopped during the iteration of the attrs array.
     *
     * See [AttributeMarker] to understand what the namespace marker value is.
     *
     * Note that this instruction does not support assigning style and class values to
     * an element. See `elementStart` and `elementHostAttrs` to learn how styling values
     * are applied to an element.
     * @param {?} renderer The renderer to be used
     * @param {?} native The element that the attributes will be assigned to
     * @param {?} attrs The attribute array of values that will be assigned to the element
     * @return {?} the index value that was last accessed in the attributes array
     */


    function setUpAttributes(renderer, _native, attrs) {
      /** @type {?} */
      var isProc = isProceduralRenderer(renderer);
      /** @type {?} */

      var i = 0;

      while (i < attrs.length) {
        /** @type {?} */
        var value = attrs[i];

        if (typeof value === 'number') {
          // only namespaces are supported. Other value types (such as style/class
          // entries) are not supported in this function.
          if (value !== 0
          /* NamespaceURI */
          ) {
              break;
            } // we just landed on the marker value ... therefore
          // we should skip to the next entry


          i++;
          /** @type {?} */

          var namespaceURI =
          /** @type {?} */
          attrs[i++];
          /** @type {?} */

          var attrName =
          /** @type {?} */
          attrs[i++];
          /** @type {?} */

          var attrVal =
          /** @type {?} */
          attrs[i++];
          ngDevMode && ngDevMode.rendererSetAttribute++;
          isProc ?
          /** @type {?} */
          renderer.setAttribute(_native, attrName, attrVal, namespaceURI) : _native.setAttributeNS(namespaceURI, attrName, attrVal);
        } else {
          // attrName is string;

          /** @type {?} */
          var _attrName =
          /** @type {?} */
          value;
          /** @type {?} */

          var _attrVal = attrs[++i]; // Standard attributes

          ngDevMode && ngDevMode.rendererSetAttribute++;

          if (isAnimationProp(_attrName)) {
            if (isProc) {
              /** @type {?} */
              renderer.setProperty(_native, _attrName, _attrVal);
            }
          } else {
            isProc ?
            /** @type {?} */
            renderer.setAttribute(_native, _attrName,
            /** @type {?} */
            _attrVal) : _native.setAttribute(_attrName,
            /** @type {?} */
            _attrVal);
          }

          i++;
        }
      } // another piece of code may iterate over the same attributes array. Therefore
      // it may be helpful to return the exact spot where the attributes array exited
      // whether by running into an unsupported marker or if all the static values were
      // iterated over.


      return i;
    }
    /**
     * Test whether the given value is a marker that indicates that the following
     * attribute values in a `TAttributes` array are only the names of attributes,
     * and not name-value pairs.
     * @param {?} marker The attribute marker to test.
     * @return {?} true if the marker is a "name-only" marker (e.g. `Bindings`, `Template` or `I18n`).
     */


    function isNameOnlyAttributeMarker(marker) {
      return marker === 3
      /* Bindings */
      || marker === 4
      /* Template */
      || marker === 6
      /* I18n */
      ;
    }
    /**
     * @param {?} name
     * @return {?}
     */


    function isAnimationProp(name) {
      // Perf note: accessing charCodeAt to check for the first character of a string is faster as
      // compared to accessing a character at index 0 (ex. name[0]). The main reason for this is that
      // charCodeAt doesn't allocate memory to return a substring.
      return name.charCodeAt(0) === 64
      /* AT_SIGN */
      ;
    }
    /**
     * Merges `src` `TAttributes` into `dst` `TAttributes` removing any duplicates in the process.
     *
     * This merge function keeps the order of attrs same.
     *
     * @param {?} dst Location of where the merged `TAttributes` should end up.
     * @param {?} src `TAttributes` which should be appended to `dst`
     * @return {?}
     */


    function mergeHostAttrs(dst, src) {
      if (src === null || src.length === 0) {// do nothing
      } else if (dst === null || dst.length === 0) {
        // We have source, but dst is empty, just make a copy.
        dst = src.slice();
      } else {
        /** @type {?} */
        var srcMarker = -1
        /* ImplicitAttributes */
        ;

        for (var i = 0; i < src.length; i++) {
          /** @type {?} */
          var item = src[i];

          if (typeof item === 'number') {
            srcMarker = item;
          } else {
            if (srcMarker === 0
            /* NamespaceURI */
            ) {// Case where we need to consume `key1`, `key2`, `value` items.
              } else if (srcMarker === -1
            /* ImplicitAttributes */
            || srcMarker === 2
            /* Styles */
            ) {
                // Case where we have to consume `key1` and `value` only.
                mergeHostAttribute(dst, srcMarker,
                /** @type {?} */
                item, null,
                /** @type {?} */
                src[++i]);
              } else {
              // Case where we have to consume `key1` only.
              mergeHostAttribute(dst, srcMarker,
              /** @type {?} */
              item, null, null);
            }
          }
        }
      }

      return dst;
    }
    /**
     * Append `key`/`value` to existing `TAttributes` taking region marker and duplicates into account.
     *
     * @param {?} dst `TAttributes` to append to.
     * @param {?} marker Region where the `key`/`value` should be added.
     * @param {?} key1 Key to add to `TAttributes`
     * @param {?} key2 Key to add to `TAttributes` (in case of `AttributeMarker.NamespaceURI`)
     * @param {?} value Value to add or to overwrite to `TAttributes` Only used if `marker` is not Class.
     * @return {?}
     */


    function mergeHostAttribute(dst, marker, key1, key2, value) {
      /** @type {?} */
      var i = 0; // Assume that new markers will be inserted at the end.

      /** @type {?} */

      var markerInsertPosition = dst.length; // scan until correct type.

      if (marker === -1
      /* ImplicitAttributes */
      ) {
          markerInsertPosition = -1;
        } else {
        while (i < dst.length) {
          /** @type {?} */
          var dstValue = dst[i++];

          if (typeof dstValue === 'number') {
            if (dstValue === marker) {
              markerInsertPosition = -1;
              break;
            } else if (dstValue > marker) {
              // We need to save this as we want the markers to be inserted in specific order.
              markerInsertPosition = i - 1;
              break;
            }
          }
        }
      } // search until you find place of insertion


      while (i < dst.length) {
        /** @type {?} */
        var item = dst[i];

        if (typeof item === 'number') {
          // since `i` started as the index after the marker, we did not find it if we are at the next
          // marker
          break;
        } else if (item === key1) {
          // We already have same token
          if (key2 === null) {
            if (value !== null) {
              dst[i + 1] = value;
            }

            return;
          } else if (key2 === dst[i + 1]) {
            dst[i + 2] =
            /** @type {?} */
            value;
            return;
          }
        } // Increment counter.


        i++;
        if (key2 !== null) i++;
        if (value !== null) i++;
      } // insert at location.


      if (markerInsertPosition !== -1) {
        dst.splice(markerInsertPosition, 0, marker);
        i = markerInsertPosition + 1;
      }

      dst.splice(i++, 0, key1);

      if (key2 !== null) {
        dst.splice(i++, 0, key2);
      }

      if (value !== null) {
        dst.splice(i++, 0, value);
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/util/injector_utils.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */
    /// Parent Injector Utils ///////////////////////////////////////////////////////////////

    /**
     * @param {?} parentLocation
     * @return {?}
     */


    function hasParentInjector(parentLocation) {
      return parentLocation !== NO_PARENT_INJECTOR;
    }
    /**
     * @param {?} parentLocation
     * @return {?}
     */


    function getParentInjectorIndex(parentLocation) {
      return (
        /** @type {?} */

        /** @type {?} */
        parentLocation & 32767
        /* InjectorIndexMask */

      );
    }
    /**
     * @param {?} parentLocation
     * @return {?}
     */


    function getParentInjectorViewOffset(parentLocation) {
      return (
        /** @type {?} */

        /** @type {?} */
        parentLocation >> 16
        /* ViewOffsetShift */

      );
    }
    /**
     * Unwraps a parent injector location number to find the view offset from the current injector,
     * then walks up the declaration view tree until the view is found that contains the parent
     * injector.
     *
     * @param {?} location The location of the parent injector, which contains the view offset
     * @param {?} startView The LView instance from which to start walking up the view tree
     * @return {?} The LView instance that contains the parent injector
     */


    function getParentInjectorView(location, startView) {
      /** @type {?} */
      var viewOffset = getParentInjectorViewOffset(location);
      /** @type {?} */

      var parentView = startView; // For most cases, the parent injector can be found on the host node (e.g. for component
      // or container), but we must keep the loop here to support the rarer case of deeply nested
      // <ng-template> tags or inline views, where the parent injector might live many views
      // above the child injector.

      while (viewOffset > 0) {
        parentView =
        /** @type {?} */
        parentView[DECLARATION_VIEW];
        viewOffset--;
      }

      return parentView;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/util/misc_utils.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Used for stringify render output in Ivy.
     * Important! This function is very performance-sensitive and we should
     * be extra careful not to introduce megamorphic reads in it.
     * @param {?} value
     * @return {?}
     */


    function renderStringify(value) {
      if (typeof value === 'string') return value;
      if (value == null) return '';
      return '' + value;
    }
    /**
     * Used to stringify a value so that it can be displayed in an error message.
     * Important! This function contains a megamorphic read and should only be
     * used for error messages.
     * @param {?} value
     * @return {?}
     */


    function stringifyForError(value) {
      if (typeof value === 'function') return value.name || value.toString();

      if (typeof value === 'object' && value != null && typeof value.type === 'function') {
        return value.type.name || value.type.toString();
      }

      return renderStringify(value);
    }

    var ɵ0$3 =
    /**
    * @return {?}
    */
    function ɵ0$3() {
      return (typeof requestAnimationFrame !== 'undefined' && requestAnimationFrame || // browser only
      setTimeout // everything else
      ).bind(_global);
    };
    /** @type {?} */


    var defaultScheduler = ɵ0$3();
    /**
     *
     * \@codeGenApi
     * @param {?} element
     * @return {?}
     */

    function ɵɵresolveWindow(element) {
      return {
        name: 'window',
        target: element.ownerDocument.defaultView
      };
    }
    /**
     *
     * \@codeGenApi
     * @param {?} element
     * @return {?}
     */


    function ɵɵresolveDocument(element) {
      return {
        name: 'document',
        target: element.ownerDocument
      };
    }
    /**
     *
     * \@codeGenApi
     * @param {?} element
     * @return {?}
     */


    function ɵɵresolveBody(element) {
      return {
        name: 'body',
        target: element.ownerDocument.body
      };
    }
    /**
     * The special delimiter we use to separate property names, prefixes, and suffixes
     * in property binding metadata. See storeBindingMetadata().
     *
     * We intentionally use the Unicode "REPLACEMENT CHARACTER" (U+FFFD) as a delimiter
     * because it is a very uncommon character that is unlikely to be part of a user's
     * property names or interpolation strings. If it is in fact used in a property
     * binding, DebugElement.properties will not return the correct value for that
     * binding. However, there should be no runtime effect for real applications.
     *
     * This character is typically rendered as a question mark inside of a diamond.
     * See https://en.wikipedia.org/wiki/Specials_(Unicode_block)
     *
     * @type {?}
     */


    var INTERPOLATION_DELIMITER = "\uFFFD";
    /**
     * Unwrap a value which might be behind a closure (for forward declaration reasons).
     * @template T
     * @param {?} value
     * @return {?}
     */

    function maybeUnwrapFn(value) {
      if (value instanceof Function) {
        return value();
      } else {
        return value;
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/di.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Defines if the call to `inject` should include `viewProviders` in its resolution.
     *
     * This is set to true when we try to instantiate a component. This value is reset in
     * `getNodeInjectable` to a value which matches the declaration location of the token about to be
     * instantiated. This is done so that if we are injecting a token which was declared outside of
     * `viewProviders` we don't accidentally pull `viewProviders` in.
     *
     * Example:
     *
     * ```
     * \@Injectable()
     * class MyService {
     *   constructor(public value: String) {}
     * }
     *
     * \@Component({
     *   providers: [
     *     MyService,
     *     {provide: String, value: 'providers' }
     *   ]
     *   viewProviders: [
     *     {provide: String, value: 'viewProviders'}
     *   ]
     * })
     * class MyComponent {
     *   constructor(myService: MyService, value: String) {
     *     // We expect that Component can see into `viewProviders`.
     *     expect(value).toEqual('viewProviders');
     *     // `MyService` was not declared in `viewProviders` hence it can't see it.
     *     expect(myService.value).toEqual('providers');
     *   }
     * }
     *
     * ```
     * @type {?}
     */


    var includeViewProviders = true;
    /**
     * @param {?} v
     * @return {?}
     */

    function setIncludeViewProviders(v) {
      /** @type {?} */
      var oldValue = includeViewProviders;
      includeViewProviders = v;
      return oldValue;
    }
    /**
     * The number of slots in each bloom filter (used by DI). The larger this number, the fewer
     * directives that will share slots, and thus, the fewer false positives when checking for
     * the existence of a directive.
     * @type {?}
     */


    var BLOOM_SIZE = 256;
    /** @type {?} */

    var BLOOM_MASK = BLOOM_SIZE - 1;
    /**
     * Counter used to generate unique IDs for directives.
     * @type {?}
     */

    var nextNgElementId = 0;
    /**
     * Registers this directive as present in its node's injector by flipping the directive's
     * corresponding bit in the injector's bloom filter.
     *
     * @param {?} injectorIndex The index of the node injector where this token should be registered
     * @param {?} tView The TView for the injector's bloom filters
     * @param {?} type The directive token to register
     * @return {?}
     */

    function bloomAdd(injectorIndex, tView, type) {
      ngDevMode && assertEqual(tView.firstCreatePass, true, 'expected firstCreatePass to be true');
      /** @type {?} */

      var id = typeof type !== 'string' ?
      /** @type {?} */
      type[NG_ELEMENT_ID] : type.charCodeAt(0) || 0; // Set a unique ID on the directive type, so if something tries to inject the directive,
      // we can easily retrieve the ID and hash it into the bloom bit that should be checked.

      if (id == null) {
        id =
        /** @type {?} */
        type[NG_ELEMENT_ID] = nextNgElementId++;
      } // We only have BLOOM_SIZE (256) slots in our bloom filter (8 buckets * 32 bits each),
      // so all unique IDs must be modulo-ed into a number from 0 - 255 to fit into the filter.

      /** @type {?} */


      var bloomBit = id & BLOOM_MASK; // Create a mask that targets the specific bit associated with the directive.
      // JS bit operations are 32 bits, so this will be a number between 2^0 and 2^31, corresponding
      // to bit positions 0 - 31 in a 32 bit integer.

      /** @type {?} */

      var mask = 1 << bloomBit; // Use the raw bloomBit number to determine which bloom filter bucket we should check
      // e.g: bf0 = [0 - 31], bf1 = [32 - 63], bf2 = [64 - 95], bf3 = [96 - 127], etc

      /** @type {?} */

      var b7 = bloomBit & 0x80;
      /** @type {?} */

      var b6 = bloomBit & 0x40;
      /** @type {?} */

      var b5 = bloomBit & 0x20;
      /** @type {?} */

      var tData =
      /** @type {?} */
      tView.data;

      if (b7) {
        b6 ? b5 ? tData[injectorIndex + 7] |= mask : tData[injectorIndex + 6] |= mask : b5 ? tData[injectorIndex + 5] |= mask : tData[injectorIndex + 4] |= mask;
      } else {
        b6 ? b5 ? tData[injectorIndex + 3] |= mask : tData[injectorIndex + 2] |= mask : b5 ? tData[injectorIndex + 1] |= mask : tData[injectorIndex] |= mask;
      }
    }
    /**
     * Creates (or gets an existing) injector for a given element or container.
     *
     * @param {?} tNode for which an injector should be retrieved / created.
     * @param {?} hostView View where the node is stored
     * @return {?} Node injector
     */


    function getOrCreateNodeInjectorForNode(tNode, hostView) {
      /** @type {?} */
      var existingInjectorIndex = getInjectorIndex(tNode, hostView);

      if (existingInjectorIndex !== -1) {
        return existingInjectorIndex;
      }
      /** @type {?} */


      var tView = hostView[TVIEW];

      if (tView.firstCreatePass) {
        tNode.injectorIndex = hostView.length;
        insertBloom(tView.data, tNode); // foundation for node bloom

        insertBloom(hostView, null); // foundation for cumulative bloom

        insertBloom(tView.blueprint, null);
      }
      /** @type {?} */


      var parentLoc = getParentInjectorLocation(tNode, hostView);
      /** @type {?} */

      var injectorIndex = tNode.injectorIndex; // If a parent injector can't be found, its location is set to -1.
      // In that case, we don't need to set up a cumulative bloom

      if (hasParentInjector(parentLoc)) {
        /** @type {?} */
        var parentIndex = getParentInjectorIndex(parentLoc);
        /** @type {?} */

        var parentLView = getParentInjectorView(parentLoc, hostView);
        /** @type {?} */

        var parentData =
        /** @type {?} */
        parentLView[TVIEW].data; // Creates a cumulative bloom filter that merges the parent's bloom filter
        // and its own cumulative bloom (which contains tokens for all ancestors)

        for (var i = 0; i < 8; i++) {
          hostView[injectorIndex + i] = parentLView[parentIndex + i] | parentData[parentIndex + i];
        }
      }

      hostView[injectorIndex + PARENT_INJECTOR] = parentLoc;
      return injectorIndex;
    }
    /**
     * @param {?} arr
     * @param {?} footer
     * @return {?}
     */


    function insertBloom(arr, footer) {
      arr.push(0, 0, 0, 0, 0, 0, 0, 0, footer);
    }
    /**
     * @param {?} tNode
     * @param {?} hostView
     * @return {?}
     */


    function getInjectorIndex(tNode, hostView) {
      if (tNode.injectorIndex === -1 || // If the injector index is the same as its parent's injector index, then the index has been
      // copied down from the parent node. No injector has been created yet on this node.
      tNode.parent && tNode.parent.injectorIndex === tNode.injectorIndex || // After the first template pass, the injector index might exist but the parent values
      // might not have been calculated yet for this instance
      hostView[tNode.injectorIndex + PARENT_INJECTOR] == null) {
        return -1;
      } else {
        return tNode.injectorIndex;
      }
    }
    /**
     * Finds the index of the parent injector, with a view offset if applicable. Used to set the
     * parent injector initially.
     *
     * Returns a combination of number of `ViewData` we have to go up and index in that `Viewdata`
     * @param {?} tNode
     * @param {?} view
     * @return {?}
     */


    function getParentInjectorLocation(tNode, view) {
      if (tNode.parent && tNode.parent.injectorIndex !== -1) {
        return (
          /** @type {?} */
          tNode.parent.injectorIndex
        ); // ViewOffset is 0
      } // For most cases, the parent injector index can be found on the host node (e.g. for component
      // or container), so this loop will be skipped, but we must keep the loop here to support
      // the rarer case of deeply nested <ng-template> tags or inline views.

      /** @type {?} */


      var hostTNode = view[T_HOST];
      /** @type {?} */

      var viewOffset = 1;

      while (hostTNode && hostTNode.injectorIndex === -1) {
        view =
        /** @type {?} */
        view[DECLARATION_VIEW];
        hostTNode = view ? view[T_HOST] : null;
        viewOffset++;
      }

      return hostTNode ? hostTNode.injectorIndex | viewOffset << 16
      /* ViewOffsetShift */
      :
      /** @type {?} */
      -1;
    }
    /**
     * Makes a type or an injection token public to the DI system by adding it to an
     * injector's bloom filter.
     *
     * @param {?} injectorIndex
     * @param {?} tView
     * @param {?} token The type or the injection token to be made public
     * @return {?}
     */


    function diPublicInInjector(injectorIndex, tView, token) {
      bloomAdd(injectorIndex, tView, token);
    }
    /**
     * Inject static attribute value into directive constructor.
     *
     * This method is used with `factory` functions which are generated as part of
     * `defineDirective` or `defineComponent`. The method retrieves the static value
     * of an attribute. (Dynamic attributes are not supported since they are not resolved
     *  at the time of injection and can change over time.)
     *
     * # Example
     * Given:
     * ```
     * \@Component(...)
     * class MyComponent {
     *   constructor(\@Attribute('title') title: string) { ... }
     * }
     * ```
     * When instantiated with
     * ```
     * <my-component title="Hello"></my-component>
     * ```
     *
     * Then factory method generated is:
     * ```
     * MyComponent.ɵcmp = defineComponent({
     *   factory: () => new MyComponent(injectAttribute('title'))
     *   ...
     * })
     * ```
     *
     * \@publicApi
     * @param {?} tNode
     * @param {?} attrNameToInject
     * @return {?}
     */


    function injectAttributeImpl(tNode, attrNameToInject) {
      ngDevMode && assertNodeOfPossibleTypes(tNode, 0
      /* Container */
      , 3
      /* Element */
      , 4
      /* ElementContainer */
      );
      ngDevMode && assertDefined(tNode, 'expecting tNode');

      if (attrNameToInject === 'class') {
        return tNode.classes;
      }

      if (attrNameToInject === 'style') {
        return tNode.styles;
      }
      /** @type {?} */


      var attrs = tNode.attrs;

      if (attrs) {
        /** @type {?} */
        var attrsLength = attrs.length;
        /** @type {?} */

        var i = 0;

        while (i < attrsLength) {
          /** @type {?} */
          var value = attrs[i]; // If we hit a `Bindings` or `Template` marker then we are done.

          if (isNameOnlyAttributeMarker(value)) break; // Skip namespaced attributes

          if (value === 0
          /* NamespaceURI */
          ) {
              // we skip the next two values
              // as namespaced attributes looks like
              // [..., AttributeMarker.NamespaceURI, 'http://someuri.com/test', 'test:exist',
              // 'existValue', ...]
              i = i + 2;
            } else if (typeof value === 'number') {
            // Skip to the first value of the marked attribute.
            i++;

            while (i < attrsLength && typeof attrs[i] === 'string') {
              i++;
            }
          } else if (value === attrNameToInject) {
            return (
              /** @type {?} */
              attrs[i + 1]
            );
          } else {
            i = i + 2;
          }
        }
      }

      return null;
    }
    /**
     * Returns the value associated to the given token from the NodeInjectors => ModuleInjector.
     *
     * Look for the injector providing the token by walking up the node injector tree and then
     * the module injector tree.
     *
     * This function patches `token` with `__NG_ELEMENT_ID__` which contains the id for the bloom
     * filter. Negative values are reserved for special objects.
     *   - `-1` is reserved for injecting `Injector` (implemented by `NodeInjector`)
     *
     * @template T
     * @param {?} tNode The Node where the search for the injector should start
     * @param {?} lView The `LView` that contains the `tNode`
     * @param {?} token The token to look for
     * @param {?=} flags Injection flags
     * @param {?=} notFoundValue The value to return when the injection flags is `InjectFlags.Optional`
     * @return {?} the value from the injector, `null` when not found, or `notFoundValue` if provided
     */


    function getOrCreateInjectable(tNode, lView, token) {
      var flags = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : InjectFlags.Default;
      var notFoundValue = arguments.length > 4 ? arguments[4] : undefined;

      if (tNode !== null) {
        /** @type {?} */
        var bloomHash = bloomHashBitOrFactory(token); // If the ID stored here is a function, this is a special object like ElementRef or TemplateRef
        // so just call the factory function to create it.

        if (typeof bloomHash === 'function') {
          enterDI(lView, tNode);

          try {
            /** @type {?} */
            var value = bloomHash();

            if (value == null && !(flags & InjectFlags.Optional)) {
              throw new Error("No provider for ".concat(stringifyForError(token), "!"));
            } else {
              return value;
            }
          } finally {
            leaveDI();
          }
        } else if (typeof bloomHash == 'number') {
          if (bloomHash === -1) {
            // `-1` is a special value used to identify `Injector` types.
            return (
              /** @type {?} */
              new NodeInjector(tNode, lView)
            );
          } // If the token has a bloom hash, then it is a token which could be in NodeInjector.
          // A reference to the previous injector TView that was found while climbing the element
          // injector tree. This is used to know if viewProviders can be accessed on the current
          // injector.

          /** @type {?} */


          var previousTView = null;
          /** @type {?} */

          var injectorIndex = getInjectorIndex(tNode, lView);
          /** @type {?} */

          var parentLocation = NO_PARENT_INJECTOR;
          /** @type {?} */

          var hostTElementNode = flags & InjectFlags.Host ? lView[DECLARATION_COMPONENT_VIEW][T_HOST] : null; // If we should skip this injector, or if there is no injector on this node, start by
          // searching
          // the parent injector.

          if (injectorIndex === -1 || flags & InjectFlags.SkipSelf) {
            parentLocation = injectorIndex === -1 ? getParentInjectorLocation(tNode, lView) : lView[injectorIndex + PARENT_INJECTOR];

            if (!shouldSearchParent(flags, false)) {
              injectorIndex = -1;
            } else {
              previousTView = lView[TVIEW];
              injectorIndex = getParentInjectorIndex(parentLocation);
              lView = getParentInjectorView(parentLocation, lView);
            }
          } // Traverse up the injector tree until we find a potential match or until we know there
          // *isn't* a match.


          while (injectorIndex !== -1) {
            parentLocation = lView[injectorIndex + PARENT_INJECTOR]; // Check the current injector. If it matches, see if it contains token.

            /** @type {?} */

            var tView = lView[TVIEW];

            if (bloomHasToken(bloomHash, injectorIndex, tView.data)) {
              // At this point, we have an injector which *may* contain the token, so we step through
              // the providers and directives associated with the injector's corresponding node to get
              // the instance.

              /** @type {?} */
              var instance = searchTokensOnInjector(injectorIndex, lView, token, previousTView, flags, hostTElementNode);

              if (instance !== NOT_FOUND) {
                return instance;
              }
            }

            if (shouldSearchParent(flags, lView[TVIEW].data[injectorIndex + TNODE] === hostTElementNode) && bloomHasToken(bloomHash, injectorIndex, lView)) {
              // The def wasn't found anywhere on this node, so it was a false positive.
              // Traverse up the tree and continue searching.
              previousTView = tView;
              injectorIndex = getParentInjectorIndex(parentLocation);
              lView = getParentInjectorView(parentLocation, lView);
            } else {
              // If we should not search parent OR If the ancestor bloom filter value does not have the
              // bit corresponding to the directive we can give up on traversing up to find the specific
              // injector.
              injectorIndex = -1;
            }
          }
        }
      }

      if (flags & InjectFlags.Optional && notFoundValue === undefined) {
        // This must be set or the NullInjector will throw for optional deps
        notFoundValue = null;
      }

      if ((flags & (InjectFlags.Self | InjectFlags.Host)) === 0) {
        /** @type {?} */
        var moduleInjector = lView[INJECTOR$1]; // switch to `injectInjectorOnly` implementation for module injector, since module injector
        // should not have access to Component/Directive DI scope (that may happen through
        // `directiveInject` implementation)

        /** @type {?} */

        var previousInjectImplementation = setInjectImplementation(undefined);

        try {
          if (moduleInjector) {
            return moduleInjector.get(token, notFoundValue, flags & InjectFlags.Optional);
          } else {
            return injectRootLimpMode(token, notFoundValue, flags & InjectFlags.Optional);
          }
        } finally {
          setInjectImplementation(previousInjectImplementation);
        }
      }

      if (flags & InjectFlags.Optional) {
        return notFoundValue;
      } else {
        throw new Error("NodeInjector: NOT_FOUND [".concat(stringifyForError(token), "]"));
      }
    }
    /** @type {?} */


    var NOT_FOUND = {};
    /**
     * @template T
     * @param {?} injectorIndex
     * @param {?} lView
     * @param {?} token
     * @param {?} previousTView
     * @param {?} flags
     * @param {?} hostTElementNode
     * @return {?}
     */

    function searchTokensOnInjector(injectorIndex, lView, token, previousTView, flags, hostTElementNode) {
      /** @type {?} */
      var currentTView = lView[TVIEW];
      /** @type {?} */

      var tNode =
      /** @type {?} */
      currentTView.data[injectorIndex + TNODE]; // First, we need to determine if view providers can be accessed by the starting element.
      // There are two possibities

      /** @type {?} */

      var canAccessViewProviders = previousTView == null ? // 1) This is the first invocation `previousTView == null` which means that we are at the
      // `TNode` of where injector is starting to look. In such a case the only time we are allowed
      // to look into the ViewProviders is if:
      // - we are on a component
      // - AND the injector set `includeViewProviders` to true (implying that the token can see
      // ViewProviders because it is the Component or a Service which itself was declared in
      // ViewProviders)
      isComponentHost(tNode) && includeViewProviders : // 2) `previousTView != null` which means that we are now walking across the parent nodes.
      // In such a case we are only allowed to look into the ViewProviders if:
      // - We just crossed from child View to Parent View `previousTView != currentTView`
      // - AND the parent TNode is an Element.
      // This means that we just came from the Component's View and therefore are allowed to see
      // into the ViewProviders.
      previousTView != currentTView && tNode.type === 3
      /* Element */
      ; // This special case happens when there is a @host on the inject and when we are searching
      // on the host element node.

      /** @type {?} */

      var isHostSpecialCase = flags & InjectFlags.Host && hostTElementNode === tNode;
      /** @type {?} */

      var injectableIdx = locateDirectiveOrProvider(tNode, currentTView, token, canAccessViewProviders, isHostSpecialCase);

      if (injectableIdx !== null) {
        return getNodeInjectable(lView, currentTView, injectableIdx,
        /** @type {?} */
        tNode);
      } else {
        return NOT_FOUND;
      }
    }
    /**
     * Searches for the given token among the node's directives and providers.
     *
     * @template T
     * @param {?} tNode TNode on which directives are present.
     * @param {?} tView The tView we are currently processing
     * @param {?} token Provider token or type of a directive to look for.
     * @param {?} canAccessViewProviders Whether view providers should be considered.
     * @param {?} isHostSpecialCase Whether the host special case applies.
     * @return {?} Index of a found directive or provider, or null when none found.
     */


    function locateDirectiveOrProvider(tNode, tView, token, canAccessViewProviders, isHostSpecialCase) {
      /** @type {?} */
      var nodeProviderIndexes = tNode.providerIndexes;
      /** @type {?} */

      var tInjectables = tView.data;
      /** @type {?} */

      var injectablesStart = nodeProviderIndexes & 65535
      /* ProvidersStartIndexMask */
      ;
      /** @type {?} */

      var directivesStart = tNode.directiveStart;
      /** @type {?} */

      var directiveEnd = tNode.directiveEnd;
      /** @type {?} */

      var cptViewProvidersCount = nodeProviderIndexes >> 16
      /* CptViewProvidersCountShift */
      ;
      /** @type {?} */

      var startingIndex = canAccessViewProviders ? injectablesStart : injectablesStart + cptViewProvidersCount; // When the host special case applies, only the viewProviders and the component are visible

      /** @type {?} */

      var endIndex = isHostSpecialCase ? injectablesStart + cptViewProvidersCount : directiveEnd;

      for (var i = startingIndex; i < endIndex; i++) {
        /** @type {?} */
        var providerTokenOrDef =
        /** @type {?} */
        tInjectables[i];

        if (i < directivesStart && token === providerTokenOrDef || i >= directivesStart &&
        /** @type {?} */
        providerTokenOrDef.type === token) {
          return i;
        }
      }

      if (isHostSpecialCase) {
        /** @type {?} */
        var dirDef =
        /** @type {?} */
        tInjectables[directivesStart];

        if (dirDef && isComponentDef(dirDef) && dirDef.type === token) {
          return directivesStart;
        }
      }

      return null;
    }
    /**
     * Retrieve or instantiate the injectable from the `LView` at particular `index`.
     *
     * This function checks to see if the value has already been instantiated and if so returns the
     * cached `injectable`. Otherwise if it detects that the value is still a factory it
     * instantiates the `injectable` and caches the value.
     * @param {?} lView
     * @param {?} tView
     * @param {?} index
     * @param {?} tNode
     * @return {?}
     */


    function getNodeInjectable(lView, tView, index, tNode) {
      /** @type {?} */
      var value = lView[index];
      /** @type {?} */

      var tData = tView.data;

      if (isFactory(value)) {
        /** @type {?} */
        var factory = value;

        if (factory.resolving) {
          throw new Error("Circular dep for ".concat(stringifyForError(tData[index])));
        }
        /** @type {?} */


        var previousIncludeViewProviders = setIncludeViewProviders(factory.canSeeViewProviders);
        factory.resolving = true;
        /** @type {?} */

        var previousInjectImplementation;

        if (factory.injectImpl) {
          previousInjectImplementation = setInjectImplementation(factory.injectImpl);
        }

        enterDI(lView, tNode);

        try {
          value = lView[index] = factory.factory(undefined, tData, lView, tNode); // This code path is hit for both directives and providers.
          // For perf reasons, we want to avoid searching for hooks on providers.
          // It does no harm to try (the hooks just won't exist), but the extra
          // checks are unnecessary and this is a hot path. So we check to see
          // if the index of the dependency is in the directive range for this
          // tNode. If it's not, we know it's a provider and skip hook registration.

          if (tView.firstCreatePass && index >= tNode.directiveStart) {
            ngDevMode && assertDirectiveDef(tData[index]);
            registerPreOrderHooks(index,
            /** @type {?} */
            tData[index], tView);
          }
        } finally {
          if (factory.injectImpl) setInjectImplementation(previousInjectImplementation);
          setIncludeViewProviders(previousIncludeViewProviders);
          factory.resolving = false;
          leaveDI();
        }
      }

      return value;
    }
    /**
     * Returns the bit in an injector's bloom filter that should be used to determine whether or not
     * the directive might be provided by the injector.
     *
     * When a directive is public, it is added to the bloom filter and given a unique ID that can be
     * retrieved on the Type. When the directive isn't public or the token is not a directive `null`
     * is returned as the node injector can not possibly provide that token.
     *
     * @param {?} token the injection token
     * @return {?} the matching bit to check in the bloom filter or `null` if the token is not known.
     *   When the returned value is negative then it represents special values such as `Injector`.
     */


    function bloomHashBitOrFactory(token) {
      ngDevMode && assertDefined(token, 'token must be defined');

      if (typeof token === 'string') {
        return token.charCodeAt(0) || 0;
      }
      /** @type {?} */


      var tokenId =
      /** @type {?} */
      token[NG_ELEMENT_ID]; // Negative token IDs are used for special objects such as `Injector`

      return typeof tokenId === 'number' && tokenId > 0 ? tokenId & BLOOM_MASK : tokenId;
    }
    /**
     * @param {?} bloomHash
     * @param {?} injectorIndex
     * @param {?} injectorView
     * @return {?}
     */


    function bloomHasToken(bloomHash, injectorIndex, injectorView) {
      // Create a mask that targets the specific bit associated with the directive we're looking for.
      // JS bit operations are 32 bits, so this will be a number between 2^0 and 2^31, corresponding
      // to bit positions 0 - 31 in a 32 bit integer.

      /** @type {?} */
      var mask = 1 << bloomHash;
      /** @type {?} */

      var b7 = bloomHash & 0x80;
      /** @type {?} */

      var b6 = bloomHash & 0x40;
      /** @type {?} */

      var b5 = bloomHash & 0x20; // Our bloom filter size is 256 bits, which is eight 32-bit bloom filter buckets:
      // bf0 = [0 - 31], bf1 = [32 - 63], bf2 = [64 - 95], bf3 = [96 - 127], etc.
      // Get the bloom filter value from the appropriate bucket based on the directive's bloomBit.

      /** @type {?} */

      var value;

      if (b7) {
        value = b6 ? b5 ? injectorView[injectorIndex + 7] : injectorView[injectorIndex + 6] : b5 ? injectorView[injectorIndex + 5] : injectorView[injectorIndex + 4];
      } else {
        value = b6 ? b5 ? injectorView[injectorIndex + 3] : injectorView[injectorIndex + 2] : b5 ? injectorView[injectorIndex + 1] : injectorView[injectorIndex];
      } // If the bloom filter value has the bit corresponding to the directive's bloomBit flipped on,
      // this injector is a potential match.


      return !!(value & mask);
    }
    /**
     * Returns true if flags prevent parent injector from being searched for tokens
     * @param {?} flags
     * @param {?} isFirstHostTNode
     * @return {?}
     */


    function shouldSearchParent(flags, isFirstHostTNode) {
      return !(flags & InjectFlags.Self) && !(flags & InjectFlags.Host && isFirstHostTNode);
    }

    var NodeInjector = /*#__PURE__*/function () {
      /**
       * @param {?} _tNode
       * @param {?} _lView
       */
      function NodeInjector(_tNode, _lView) {
        _classCallCheck(this, NodeInjector);

        this._tNode = _tNode;
        this._lView = _lView;
      }
      /**
       * @param {?} token
       * @param {?=} notFoundValue
       * @return {?}
       */


      _createClass2(NodeInjector, [{
        key: "get",
        value: function get(token, notFoundValue) {
          return getOrCreateInjectable(this._tNode, this._lView, token, undefined, notFoundValue);
        }
      }]);

      return NodeInjector;
    }();

    if (false) {}
    /**
     * \@codeGenApi
     * @template T
     * @param {?} type
     * @return {?}
     */


    function ɵɵgetFactoryOf(type) {
      /** @type {?} */
      var typeAny =
      /** @type {?} */
      type;

      if (isForwardRef(type)) {
        return (
          /** @type {?} */

          /**
          * @return {?}
          */
          function () {
            /** @type {?} */
            var factory = ɵɵgetFactoryOf(resolveForwardRef(typeAny));
            return factory ? factory() : null;
          }
        );
      }
      /** @type {?} */


      var factory = getFactoryDef(typeAny);

      if (factory === null) {
        /** @type {?} */
        var injectorDef = getInjectorDef(typeAny);
        factory = injectorDef && injectorDef.factory;
      }

      return factory || null;
    }
    /**
     * \@codeGenApi
     * @template T
     * @param {?} type
     * @return {?}
     */


    function ɵɵgetInheritedFactory(type) {
      return noSideEffects(
      /**
      * @return {?}
      */
      function () {
        /** @type {?} */
        var proto =
        /** @type {?} */
        Object.getPrototypeOf(type.prototype).constructor;
        /** @type {?} */

        var factory =
        /** @type {?} */
        proto[NG_FACTORY_DEF] || ɵɵgetFactoryOf(proto);

        if (factory !== null) {
          return factory;
        } else {
          // There is no factory defined. Either this was improper usage of inheritance
          // (no Angular decorator on the superclass) or there is no constructor at all
          // in the inheritance chain. Since the two cases cannot be distinguished, the
          // latter has to be assumed.
          return (
            /**
            * @param {?} t
            * @return {?}
            */
            function (t) {
              return new t();
            }
          );
        }
      });
    }
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */


    var ERROR_TYPE = 'ngType';
    var ERROR_DEBUG_CONTEXT = 'ngDebugContext';
    var ERROR_ORIGINAL_ERROR = 'ngOriginalError';
    var ERROR_LOGGER = 'ngErrorLogger';

    function wrappedError(message, originalError) {
      var msg = "".concat(message, " caused by: ").concat(originalError instanceof Error ? originalError.message : originalError);
      var error = Error(msg);
      error[ERROR_ORIGINAL_ERROR] = originalError;
      return error;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/errors.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} error
     * @return {?}
     */


    function getType(error) {
      return (
        /** @type {?} */
        error[ERROR_TYPE]
      );
    }
    /**
     * @param {?} error
     * @return {?}
     */


    function getDebugContext(error) {
      return (
        /** @type {?} */
        error[ERROR_DEBUG_CONTEXT]
      );
    }
    /**
     * @param {?} error
     * @return {?}
     */


    function getOriginalError(error) {
      return (
        /** @type {?} */
        error[ERROR_ORIGINAL_ERROR]
      );
    }
    /**
     * @param {?} error
     * @return {?}
     */


    function getErrorLogger(error) {
      return (
        /** @type {?} */
        error[ERROR_LOGGER] || defaultErrorLogger
      );
    }
    /**
     * @param {?} console
     * @param {...?} values
     * @return {?}
     */


    function defaultErrorLogger(console) {
      for (var _len11 = arguments.length, values = new Array(_len11 > 1 ? _len11 - 1 : 0), _key12 = 1; _key12 < _len11; _key12++) {
        values[_key12 - 1] = arguments[_key12];
      }

      /** @type {?} */
      console.error.apply(console, values);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/error_handler.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Provides a hook for centralized exception handling.
     *
     * The default implementation of `ErrorHandler` prints error messages to the `console`. To
     * intercept error handling, write a custom exception handler that replaces this default as
     * appropriate for your app.
     *
     * \@usageNotes
     * ### Example
     *
     * ```
     * class MyErrorHandler implements ErrorHandler {
     *   handleError(error) {
     *     // do something with the exception
     *   }
     * }
     *
     * \@NgModule({
     *   providers: [{provide: ErrorHandler, useClass: MyErrorHandler}]
     * })
     * class MyModule {}
     * ```
     *
     * \@publicApi
     */


    var ErrorHandler = /*#__PURE__*/function () {
      function ErrorHandler() {
        _classCallCheck(this, ErrorHandler);

        /**
         * \@internal
         */
        this._console = console;
      }
      /**
       * @param {?} error
       * @return {?}
       */


      _createClass2(ErrorHandler, [{
        key: "handleError",
        value: function handleError(error) {
          /** @type {?} */
          var originalError = this._findOriginalError(error);
          /** @type {?} */


          var context = this._findContext(error); // Note: Browser consoles show the place from where console.error was called.
          // We can use this to give users additional information about the error.

          /** @type {?} */


          var errorLogger = getErrorLogger(error);
          errorLogger(this._console, "ERROR", error);

          if (originalError) {
            errorLogger(this._console, "ORIGINAL ERROR", originalError);
          }

          if (context) {
            errorLogger(this._console, 'ERROR CONTEXT', context);
          }
        }
        /**
         * \@internal
         * @param {?} error
         * @return {?}
         */

      }, {
        key: "_findContext",
        value: function _findContext(error) {
          if (error) {
            return getDebugContext(error) ? getDebugContext(error) : this._findContext(getOriginalError(error));
          }

          return null;
        }
        /**
         * \@internal
         * @param {?} error
         * @return {?}
         */

      }, {
        key: "_findOriginalError",
        value: function _findOriginalError(error) {
          /** @type {?} */
          var e = getOriginalError(error);

          while (e && getOriginalError(e)) {
            e = getOriginalError(e);
          }

          return e;
        }
      }]);

      return ErrorHandler;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/metadata/schema.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * A schema definition associated with an NgModule.
     *
     * @see `\@NgModule`, `CUSTOM_ELEMENTS_SCHEMA`, `NO_ERRORS_SCHEMA`
     *
     * @param name The name of a defined schema.
     *
     * \@publicApi
     * @record
     */


    function SchemaMetadata() {}

    if (false) {}
    /**
     * Defines a schema that allows an NgModule to contain the following:
     * - Non-Angular elements named with dash case (`-`).
     * - Element properties named with dash case (`-`).
     * Dash case is the naming convention for custom elements.
     *
     * \@publicApi
     * @type {?}
     */


    var CUSTOM_ELEMENTS_SCHEMA = {
      name: 'custom-elements'
    };
    /**
     * Defines a schema that allows any property on any element.
     *
     * \@publicApi
     * @type {?}
     */

    var NO_ERRORS_SCHEMA = {
      name: 'no-errors-schema'
    };
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/sanitization/bypass.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** @enum {string} */

    var BypassType = {
      Url: "URL",
      Html: "HTML",
      ResourceUrl: "ResourceURL",
      Script: "Script",
      Style: "Style"
    };
    /**
     * Marker interface for a value that's safe to use in a particular context.
     *
     * \@publicApi
     * @record
     */

    function SafeValue() {}
    /**
     * Marker interface for a value that's safe to use as HTML.
     *
     * \@publicApi
     * @record
     */


    function SafeHtml() {}
    /**
     * Marker interface for a value that's safe to use as style (CSS).
     *
     * \@publicApi
     * @record
     */


    function SafeStyle() {}
    /**
     * Marker interface for a value that's safe to use as JavaScript.
     *
     * \@publicApi
     * @record
     */


    function SafeScript() {}
    /**
     * Marker interface for a value that's safe to use as a URL linking to a document.
     *
     * \@publicApi
     * @record
     */


    function SafeUrl() {}
    /**
     * Marker interface for a value that's safe to use as a URL to load executable code from.
     *
     * \@publicApi
     * @record
     */


    function SafeResourceUrl() {}
    /**
     * @abstract
     */


    var SafeValueImpl = /*#__PURE__*/function () {
      /**
       * @param {?} changingThisBreaksApplicationSecurity
       */
      function SafeValueImpl(changingThisBreaksApplicationSecurity) {
        _classCallCheck(this, SafeValueImpl);

        this.changingThisBreaksApplicationSecurity = changingThisBreaksApplicationSecurity;
      }
      /**
       * @return {?}
       */


      _createClass2(SafeValueImpl, [{
        key: "toString",
        value: function toString() {
          return "SafeValue must use [property]=binding: ".concat(this.changingThisBreaksApplicationSecurity) + " (see http://g.co/ng/security#xss)";
        }
      }]);

      return SafeValueImpl;
    }();

    if (false) {}

    var SafeHtmlImpl = /*#__PURE__*/function (_SafeValueImpl) {
      _inherits(SafeHtmlImpl, _SafeValueImpl);

      var _super27 = _createSuper(SafeHtmlImpl);

      function SafeHtmlImpl() {
        _classCallCheck(this, SafeHtmlImpl);

        return _super27.apply(this, arguments);
      }

      _createClass2(SafeHtmlImpl, [{
        key: "getTypeName",

        /**
         * @return {?}
         */
        value: function getTypeName() {
          return "HTML"
          /* Html */
          ;
        }
      }]);

      return SafeHtmlImpl;
    }(SafeValueImpl);

    var SafeStyleImpl = /*#__PURE__*/function (_SafeValueImpl2) {
      _inherits(SafeStyleImpl, _SafeValueImpl2);

      var _super28 = _createSuper(SafeStyleImpl);

      function SafeStyleImpl() {
        _classCallCheck(this, SafeStyleImpl);

        return _super28.apply(this, arguments);
      }

      _createClass2(SafeStyleImpl, [{
        key: "getTypeName",

        /**
         * @return {?}
         */
        value: function getTypeName() {
          return "Style"
          /* Style */
          ;
        }
      }]);

      return SafeStyleImpl;
    }(SafeValueImpl);

    var SafeScriptImpl = /*#__PURE__*/function (_SafeValueImpl3) {
      _inherits(SafeScriptImpl, _SafeValueImpl3);

      var _super29 = _createSuper(SafeScriptImpl);

      function SafeScriptImpl() {
        _classCallCheck(this, SafeScriptImpl);

        return _super29.apply(this, arguments);
      }

      _createClass2(SafeScriptImpl, [{
        key: "getTypeName",

        /**
         * @return {?}
         */
        value: function getTypeName() {
          return "Script"
          /* Script */
          ;
        }
      }]);

      return SafeScriptImpl;
    }(SafeValueImpl);

    var SafeUrlImpl = /*#__PURE__*/function (_SafeValueImpl4) {
      _inherits(SafeUrlImpl, _SafeValueImpl4);

      var _super30 = _createSuper(SafeUrlImpl);

      function SafeUrlImpl() {
        _classCallCheck(this, SafeUrlImpl);

        return _super30.apply(this, arguments);
      }

      _createClass2(SafeUrlImpl, [{
        key: "getTypeName",

        /**
         * @return {?}
         */
        value: function getTypeName() {
          return "URL"
          /* Url */
          ;
        }
      }]);

      return SafeUrlImpl;
    }(SafeValueImpl);

    var SafeResourceUrlImpl = /*#__PURE__*/function (_SafeValueImpl5) {
      _inherits(SafeResourceUrlImpl, _SafeValueImpl5);

      var _super31 = _createSuper(SafeResourceUrlImpl);

      function SafeResourceUrlImpl() {
        _classCallCheck(this, SafeResourceUrlImpl);

        return _super31.apply(this, arguments);
      }

      _createClass2(SafeResourceUrlImpl, [{
        key: "getTypeName",

        /**
         * @return {?}
         */
        value: function getTypeName() {
          return "ResourceURL"
          /* ResourceUrl */
          ;
        }
      }]);

      return SafeResourceUrlImpl;
    }(SafeValueImpl);
    /**
     * @template T
     * @param {?} value
     * @return {?}
     */


    function unwrapSafeValue(value) {
      return value instanceof SafeValueImpl ?
      /** @type {?} */

      /** @type {?} */
      value.changingThisBreaksApplicationSecurity :
      /** @type {?} */

      /** @type {?} */
      value;
    }
    /**
     * @param {?} value
     * @param {?} type
     * @return {?}
     */


    function allowSanitizationBypassAndThrow(value, type) {
      /** @type {?} */
      var actualType = getSanitizationBypassType(value);

      if (actualType != null && actualType !== type) {
        // Allow ResourceURLs in URL contexts, they are strictly more trusted.
        if (actualType === "ResourceURL"
        /* ResourceUrl */
        && type === "URL"
        /* Url */
        ) return true;
        throw new Error("Required a safe ".concat(type, ", got a ").concat(actualType, " (see http://g.co/ng/security#xss)"));
      }

      return actualType === type;
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function getSanitizationBypassType(value) {
      return value instanceof SafeValueImpl &&
      /** @type {?} */
      value.getTypeName() || null;
    }
    /**
     * Mark `html` string as trusted.
     *
     * This function wraps the trusted string in `String` and brands it in a way which makes it
     * recognizable to {\@link htmlSanitizer} to be trusted implicitly.
     *
     * @param {?} trustedHtml `html` string which needs to be implicitly trusted.
     * @return {?} a `html` which has been branded to be implicitly trusted.
     */


    function bypassSanitizationTrustHtml(trustedHtml) {
      return new SafeHtmlImpl(trustedHtml);
    }
    /**
     * Mark `style` string as trusted.
     *
     * This function wraps the trusted string in `String` and brands it in a way which makes it
     * recognizable to {\@link styleSanitizer} to be trusted implicitly.
     *
     * @param {?} trustedStyle `style` string which needs to be implicitly trusted.
     * @return {?} a `style` hich has been branded to be implicitly trusted.
     */


    function bypassSanitizationTrustStyle(trustedStyle) {
      return new SafeStyleImpl(trustedStyle);
    }
    /**
     * Mark `script` string as trusted.
     *
     * This function wraps the trusted string in `String` and brands it in a way which makes it
     * recognizable to {\@link scriptSanitizer} to be trusted implicitly.
     *
     * @param {?} trustedScript `script` string which needs to be implicitly trusted.
     * @return {?} a `script` which has been branded to be implicitly trusted.
     */


    function bypassSanitizationTrustScript(trustedScript) {
      return new SafeScriptImpl(trustedScript);
    }
    /**
     * Mark `url` string as trusted.
     *
     * This function wraps the trusted string in `String` and brands it in a way which makes it
     * recognizable to {\@link urlSanitizer} to be trusted implicitly.
     *
     * @param {?} trustedUrl `url` string which needs to be implicitly trusted.
     * @return {?} a `url`  which has been branded to be implicitly trusted.
     */


    function bypassSanitizationTrustUrl(trustedUrl) {
      return new SafeUrlImpl(trustedUrl);
    }
    /**
     * Mark `url` string as trusted.
     *
     * This function wraps the trusted string in `String` and brands it in a way which makes it
     * recognizable to {\@link resourceUrlSanitizer} to be trusted implicitly.
     *
     * @param {?} trustedResourceUrl `url` string which needs to be implicitly trusted.
     * @return {?} a `url` which has been branded to be implicitly trusted.
     */


    function bypassSanitizationTrustResourceUrl(trustedResourceUrl) {
      return new SafeResourceUrlImpl(trustedResourceUrl);
    }
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * This file is used to control if the default rendering pipeline should be `ViewEngine` or `Ivy`.
     *
     * For more information on how to run and debug tests with either Ivy or View Engine (legacy),
     * please see [BAZEL.md](./docs/BAZEL.md).
     */


    var _devMode = true;
    var _runModeLocked = false;
    /**
     * Returns whether Angular is in development mode. After called once,
     * the value is locked and won't change any more.
     *
     * By default, this is true, unless a user calls `enableProdMode` before calling this.
     *
     * @publicApi
     */

    function isDevMode() {
      _runModeLocked = true;
      return _devMode;
    }
    /**
     * Disable Angular's development mode, which turns off assertions and other
     * checks within the framework.
     *
     * One important assertion this disables verifies that a change detection pass
     * does not result in additional changes to any bindings (also known as
     * unidirectional data flow).
     *
     * @publicApi
     */


    function enableProdMode() {
      if (_runModeLocked) {
        throw new Error('Cannot enable prod mode after platform setup.');
      }

      _devMode = false;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/sanitization/inert_body.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * This helper class is used to get hold of an inert tree of DOM elements containing dirty HTML
     * that needs sanitizing.
     * Depending upon browser support we must use one of three strategies for doing this.
     * Support: Safari 10.x -> XHR strategy
     * Support: Firefox -> DomParser strategy
     * Default: InertDocument strategy
     */


    var InertBodyHelper = /*#__PURE__*/function () {
      /**
       * @param {?} defaultDoc
       */
      function InertBodyHelper(defaultDoc) {
        _classCallCheck(this, InertBodyHelper);

        this.defaultDoc = defaultDoc;
        this.inertDocument = this.defaultDoc.implementation.createHTMLDocument('sanitization-inert');
        /** @type {?} */

        var inertBodyElement = this.inertDocument.body;

        if (inertBodyElement == null) {
          // usually there should be only one body element in the document, but IE doesn't have any, so
          // we need to create one.

          /** @type {?} */
          var inertHtml = this.inertDocument.createElement('html');
          this.inertDocument.appendChild(inertHtml);
          inertBodyElement = this.inertDocument.createElement('body');
          inertHtml.appendChild(inertBodyElement);
        }

        inertBodyElement.innerHTML = '<svg><g onload="this.parentNode.remove()"></g></svg>';

        if (inertBodyElement.querySelector && !inertBodyElement.querySelector('svg')) {
          // We just hit the Safari 10.1 bug - which allows JS to run inside the SVG G element
          // so use the XHR strategy.
          this.getInertBodyElement = this.getInertBodyElement_XHR;
          return;
        }

        inertBodyElement.innerHTML = '<svg><p><style><img src="</style><img src=x onerror=alert(1)//">';

        if (inertBodyElement.querySelector && inertBodyElement.querySelector('svg img')) {
          // We just hit the Firefox bug - which prevents the inner img JS from being sanitized
          // so use the DOMParser strategy, if it is available.
          // If the DOMParser is not available then we are not in Firefox (Server/WebWorker?) so we
          // fall through to the default strategy below.
          if (isDOMParserAvailable()) {
            this.getInertBodyElement = this.getInertBodyElement_DOMParser;
            return;
          }
        } // None of the bugs were hit so it is safe for us to use the default InertDocument strategy


        this.getInertBodyElement = this.getInertBodyElement_InertDocument;
      }
      /**
       * Use XHR to create and fill an inert body element (on Safari 10.1)
       * See
       * https://github.com/cure53/DOMPurify/blob/a992d3a75031cb8bb032e5ea8399ba972bdf9a65/src/purify.js#L439-L449
       * @private
       * @param {?} html
       * @return {?}
       */


      _createClass2(InertBodyHelper, [{
        key: "getInertBodyElement_XHR",
        value: function getInertBodyElement_XHR(html) {
          // We add these extra elements to ensure that the rest of the content is parsed as expected
          // e.g. leading whitespace is maintained and tags like `<meta>` do not get hoisted to the
          // `<head>` tag.
          html = '<body><remove></remove>' + html + '</body>';

          try {
            html = encodeURI(html);
          } catch (_a) {
            return null;
          }
          /** @type {?} */


          var xhr = new XMLHttpRequest();
          xhr.responseType = 'document';
          xhr.open('GET', 'data:text/html;charset=utf-8,' + html, false);
          xhr.send(undefined);
          /** @type {?} */

          var body = xhr.response.body;
          body.removeChild(
          /** @type {?} */
          body.firstChild);
          return body;
        }
        /**
         * Use DOMParser to create and fill an inert body element (on Firefox)
         * See https://github.com/cure53/DOMPurify/releases/tag/0.6.7
         *
         * @private
         * @param {?} html
         * @return {?}
         */

      }, {
        key: "getInertBodyElement_DOMParser",
        value: function getInertBodyElement_DOMParser(html) {
          // We add these extra elements to ensure that the rest of the content is parsed as expected
          // e.g. leading whitespace is maintained and tags like `<meta>` do not get hoisted to the
          // `<head>` tag.
          html = '<body><remove></remove>' + html + '</body>';

          try {
            /** @type {?} */
            var body =
            /** @type {?} */
            new
            /** @type {?} */
            window.DOMParser().parseFromString(html, 'text/html').body;
            body.removeChild(
            /** @type {?} */
            body.firstChild);
            return body;
          } catch (_a) {
            return null;
          }
        }
        /**
         * Use an HTML5 `template` element, if supported, or an inert body element created via
         * `createHtmlDocument` to create and fill an inert DOM element.
         * This is the default sane strategy to use if the browser does not require one of the specialised
         * strategies above.
         * @private
         * @param {?} html
         * @return {?}
         */

      }, {
        key: "getInertBodyElement_InertDocument",
        value: function getInertBodyElement_InertDocument(html) {
          // Prefer using <template> element if supported.

          /** @type {?} */
          var templateEl = this.inertDocument.createElement('template');

          if ('content' in templateEl) {
            templateEl.innerHTML = html;
            return templateEl;
          } // Note that previously we used to do something like `this.inertDocument.body.innerHTML = html`
          // and we returned the inert `body` node. This was changed, because IE seems to treat setting
          // `innerHTML` on an inserted element differently, compared to one that hasn't been inserted
          // yet. In particular, IE appears to split some of the text into multiple text nodes rather
          // than keeping them in a single one which ends up messing with Ivy's i18n parsing further
          // down the line. This has been worked around by creating a new inert `body` and using it as
          // the root node in which we insert the HTML.

          /** @type {?} */


          var inertBody = this.inertDocument.createElement('body');
          inertBody.innerHTML = html; // Support: IE 9-11 only
          // strip custom-namespaced attributes on IE<=11

          if (
          /** @type {?} */
          this.defaultDoc.documentMode) {
            this.stripCustomNsAttrs(inertBody);
          }

          return inertBody;
        }
        /**
         * When IE9-11 comes across an unknown namespaced attribute e.g. 'xlink:foo' it adds 'xmlns:ns1'
         * attribute to declare ns1 namespace and prefixes the attribute with 'ns1' (e.g.
         * 'ns1:xlink:foo').
         *
         * This is undesirable since we don't want to allow any of these custom attributes. This method
         * strips them all.
         * @private
         * @param {?} el
         * @return {?}
         */

      }, {
        key: "stripCustomNsAttrs",
        value: function stripCustomNsAttrs(el) {
          /** @type {?} */
          var elAttrs = el.attributes; // loop backwards so that we can support removals.

          for (var i = elAttrs.length - 1; 0 < i; i--) {
            /** @type {?} */
            var attrib = elAttrs.item(i);
            /** @type {?} */

            var attrName =
            /** @type {?} */
            attrib.name;

            if (attrName === 'xmlns:ns1' || attrName.indexOf('ns1:') === 0) {
              el.removeAttribute(attrName);
            }
          }
          /** @type {?} */


          var childNode =
          /** @type {?} */
          el.firstChild;

          while (childNode) {
            if (childNode.nodeType === Node.ELEMENT_NODE) this.stripCustomNsAttrs(
            /** @type {?} */
            childNode);
            childNode = childNode.nextSibling;
          }
        }
      }]);

      return InertBodyHelper;
    }();

    if (false) {}
    /**
     * We need to determine whether the DOMParser exists in the global context.
     * The try-catch is because, on some browsers, trying to access this property
     * on window can actually throw an error.
     *
     * @suppress {uselessCode}
     * @return {?}
     */


    function isDOMParserAvailable() {
      try {
        return !!
        /** @type {?} */
        window.DOMParser;
      } catch (_a) {
        return false;
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/sanitization/url_sanitizer.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * A pattern that recognizes a commonly useful subset of URLs that are safe.
     *
     * This regular expression matches a subset of URLs that will not cause script
     * execution if used in URL context within a HTML document. Specifically, this
     * regular expression matches if (comment from here on and regex copied from
     * Soy's EscapingConventions):
     * (1) Either an allowed protocol (http, https, mailto or ftp).
     * (2) or no protocol.  A protocol must be followed by a colon. The below
     *     allows that by allowing colons only after one of the characters [/?#].
     *     A colon after a hash (#) must be in the fragment.
     *     Otherwise, a colon after a (?) must be in a query.
     *     Otherwise, a colon after a single solidus (/) must be in a path.
     *     Otherwise, a colon after a double solidus (//) must be in the authority
     *     (before port).
     *
     * The pattern disallows &, used in HTML entity declarations before
     * one of the characters in [/?#]. This disallows HTML entities used in the
     * protocol name, which should never happen, e.g. "h&#116;tp" for "http".
     * It also disallows HTML entities in the first path part of a relative path,
     * e.g. "foo&lt;bar/baz".  Our existing escaping functions should not produce
     * that. More importantly, it disallows masking of a colon,
     * e.g. "javascript&#58;...".
     *
     * This regular expression was taken from the Closure sanitization library.
     * @type {?}
     */


    var SAFE_URL_PATTERN = /^(?:(?:https?|mailto|ftp|tel|file):|[^&:/?#]*(?:[/?#]|$))/gi;
    /* A pattern that matches safe srcset values */

    /** @type {?} */

    var SAFE_SRCSET_PATTERN = /^(?:(?:https?|file):|[^&:/?#]*(?:[/?#]|$))/gi;
    /**
     * A pattern that matches safe data URLs. Only matches image, video and audio types.
     * @type {?}
     */

    var DATA_URL_PATTERN = /^data:(?:image\/(?:bmp|gif|jpeg|jpg|png|tiff|webp)|video\/(?:mpeg|mp4|ogg|webm)|audio\/(?:mp3|oga|ogg|opus));base64,[a-z0-9+\/]+=*$/i;
    /**
     * @param {?} url
     * @return {?}
     */

    function _sanitizeUrl(url) {
      url = String(url);
      if (url.match(SAFE_URL_PATTERN) || url.match(DATA_URL_PATTERN)) return url;

      if (isDevMode()) {
        console.warn("WARNING: sanitizing unsafe URL value ".concat(url, " (see http://g.co/ng/security#xss)"));
      }

      return 'unsafe:' + url;
    }
    /**
     * @param {?} srcset
     * @return {?}
     */


    function sanitizeSrcset(srcset) {
      srcset = String(srcset);
      return srcset.split(',').map(
      /**
      * @param {?} srcset
      * @return {?}
      */
      function (srcset) {
        return _sanitizeUrl(srcset.trim());
      }).join(', ');
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/sanitization/html_sanitizer.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} tags
     * @return {?}
     */


    function tagSet(tags) {
      /** @type {?} */
      var res = {};

      var _iterator9 = _createForOfIteratorHelper(tags.split(',')),
          _step9;

      try {
        for (_iterator9.s(); !(_step9 = _iterator9.n()).done;) {
          var t = _step9.value;
          res[t] = true;
        }
      } catch (err) {
        _iterator9.e(err);
      } finally {
        _iterator9.f();
      }

      return res;
    }
    /**
     * @param {...?} sets
     * @return {?}
     */


    function merge() {
      /** @type {?} */
      var res = {};

      for (var _len12 = arguments.length, sets = new Array(_len12), _key13 = 0; _key13 < _len12; _key13++) {
        sets[_key13] = arguments[_key13];
      }

      for (var _i11 = 0, _sets = sets; _i11 < _sets.length; _i11++) {
        var s = _sets[_i11];

        for (var v in s) {
          if (s.hasOwnProperty(v)) res[v] = true;
        }
      }

      return res;
    } // Good source of info about elements and attributes
    // http://dev.w3.org/html5/spec/Overview.html#semantics
    // http://simon.html5.org/html-elements
    // Safe Void Elements - HTML5
    // http://dev.w3.org/html5/spec/Overview.html#void-elements

    /** @type {?} */


    var VOID_ELEMENTS = tagSet('area,br,col,hr,img,wbr'); // Elements that you can, intentionally, leave open (and which close themselves)
    // http://dev.w3.org/html5/spec/Overview.html#optional-tags

    /** @type {?} */

    var OPTIONAL_END_TAG_BLOCK_ELEMENTS = tagSet('colgroup,dd,dt,li,p,tbody,td,tfoot,th,thead,tr');
    /** @type {?} */

    var OPTIONAL_END_TAG_INLINE_ELEMENTS = tagSet('rp,rt');
    /** @type {?} */

    var OPTIONAL_END_TAG_ELEMENTS = merge(OPTIONAL_END_TAG_INLINE_ELEMENTS, OPTIONAL_END_TAG_BLOCK_ELEMENTS); // Safe Block Elements - HTML5

    /** @type {?} */

    var BLOCK_ELEMENTS = merge(OPTIONAL_END_TAG_BLOCK_ELEMENTS, tagSet('address,article,' + 'aside,blockquote,caption,center,del,details,dialog,dir,div,dl,figure,figcaption,footer,h1,h2,h3,h4,h5,' + 'h6,header,hgroup,hr,ins,main,map,menu,nav,ol,pre,section,summary,table,ul')); // Inline Elements - HTML5

    /** @type {?} */

    var INLINE_ELEMENTS = merge(OPTIONAL_END_TAG_INLINE_ELEMENTS, tagSet('a,abbr,acronym,audio,b,' + 'bdi,bdo,big,br,cite,code,del,dfn,em,font,i,img,ins,kbd,label,map,mark,picture,q,ruby,rp,rt,s,' + 'samp,small,source,span,strike,strong,sub,sup,time,track,tt,u,var,video'));
    /** @type {?} */

    var VALID_ELEMENTS = merge(VOID_ELEMENTS, BLOCK_ELEMENTS, INLINE_ELEMENTS, OPTIONAL_END_TAG_ELEMENTS); // Attributes that have href and hence need to be sanitized

    /** @type {?} */

    var URI_ATTRS = tagSet('background,cite,href,itemtype,longdesc,poster,src,xlink:href'); // Attributes that have special href set hence need to be sanitized

    /** @type {?} */

    var SRCSET_ATTRS = tagSet('srcset');
    /** @type {?} */

    var HTML_ATTRS = tagSet('abbr,accesskey,align,alt,autoplay,axis,bgcolor,border,cellpadding,cellspacing,class,clear,color,cols,colspan,' + 'compact,controls,coords,datetime,default,dir,download,face,headers,height,hidden,hreflang,hspace,' + 'ismap,itemscope,itemprop,kind,label,lang,language,loop,media,muted,nohref,nowrap,open,preload,rel,rev,role,rows,rowspan,rules,' + 'scope,scrolling,shape,size,sizes,span,srclang,start,summary,tabindex,target,title,translate,type,usemap,' + 'valign,value,vspace,width'); // Accessibility attributes as per WAI-ARIA 1.1 (W3C Working Draft 14 December 2018)

    /** @type {?} */

    var ARIA_ATTRS = tagSet('aria-activedescendant,aria-atomic,aria-autocomplete,aria-busy,aria-checked,aria-colcount,aria-colindex,' + 'aria-colspan,aria-controls,aria-current,aria-describedby,aria-details,aria-disabled,aria-dropeffect,' + 'aria-errormessage,aria-expanded,aria-flowto,aria-grabbed,aria-haspopup,aria-hidden,aria-invalid,' + 'aria-keyshortcuts,aria-label,aria-labelledby,aria-level,aria-live,aria-modal,aria-multiline,' + 'aria-multiselectable,aria-orientation,aria-owns,aria-placeholder,aria-posinset,aria-pressed,aria-readonly,' + 'aria-relevant,aria-required,aria-roledescription,aria-rowcount,aria-rowindex,aria-rowspan,aria-selected,' + 'aria-setsize,aria-sort,aria-valuemax,aria-valuemin,aria-valuenow,aria-valuetext'); // NB: This currently consciously doesn't support SVG. SVG sanitization has had several security
    // issues in the past, so it seems safer to leave it out if possible. If support for binding SVG via
    // innerHTML is required, SVG attributes should be added here.
    // NB: Sanitization does not allow <form> elements or other active elements (<button> etc). Those
    // can be sanitized, but they increase security surface area without a legitimate use case, so they
    // are left out here.

    /** @type {?} */

    var VALID_ATTRS = merge(URI_ATTRS, SRCSET_ATTRS, HTML_ATTRS, ARIA_ATTRS); // Elements whose content should not be traversed/preserved, if the elements themselves are invalid.
    //
    // Typically, `<invalid>Some content</invalid>` would traverse (and in this case preserve)
    // `Some content`, but strip `invalid-element` opening/closing tags. For some elements, though, we
    // don't want to preserve the content, if the elements themselves are going to be removed.

    /** @type {?} */

    var SKIP_TRAVERSING_CONTENT_IF_INVALID_ELEMENTS = tagSet('script,style,template');
    /**
     * SanitizingHtmlSerializer serializes a DOM fragment, stripping out any unsafe elements and unsafe
     * attributes.
     */

    var SanitizingHtmlSerializer = /*#__PURE__*/function () {
      function SanitizingHtmlSerializer() {
        _classCallCheck(this, SanitizingHtmlSerializer);

        // Explicitly track if something was stripped, to avoid accidentally warning of sanitization just
        // because characters were re-encoded.
        this.sanitizedSomething = false;
        this.buf = [];
      }
      /**
       * @param {?} el
       * @return {?}
       */


      _createClass2(SanitizingHtmlSerializer, [{
        key: "sanitizeChildren",
        value: function sanitizeChildren(el) {
          // This cannot use a TreeWalker, as it has to run on Angular's various DOM adapters.
          // However this code never accesses properties off of `document` before deleting its contents
          // again, so it shouldn't be vulnerable to DOM clobbering.

          /** @type {?} */
          var current =
          /** @type {?} */
          el.firstChild;
          /** @type {?} */

          var traverseContent = true;

          while (current) {
            if (current.nodeType === Node.ELEMENT_NODE) {
              traverseContent = this.startElement(
              /** @type {?} */
              current);
            } else if (current.nodeType === Node.TEXT_NODE) {
              this.chars(
              /** @type {?} */
              current.nodeValue);
            } else {
              // Strip non-element, non-text nodes.
              this.sanitizedSomething = true;
            }

            if (traverseContent && current.firstChild) {
              current =
              /** @type {?} */
              current.firstChild;
              continue;
            }

            while (current) {
              // Leaving the element. Walk up and to the right, closing tags as we go.
              if (current.nodeType === Node.ELEMENT_NODE) {
                this.endElement(
                /** @type {?} */
                current);
              }
              /** @type {?} */


              var next = this.checkClobberedElement(current,
              /** @type {?} */
              current.nextSibling);

              if (next) {
                current = next;
                break;
              }

              current = this.checkClobberedElement(current,
              /** @type {?} */
              current.parentNode);
            }
          }

          return this.buf.join('');
        }
        /**
         * Sanitizes an opening element tag (if valid) and returns whether the element's contents should
         * be traversed. Element content must always be traversed (even if the element itself is not
         * valid/safe), unless the element is one of `SKIP_TRAVERSING_CONTENT_IF_INVALID_ELEMENTS`.
         *
         * @private
         * @param {?} element The element to sanitize.
         * @return {?} True if the element's contents should be traversed.
         */

      }, {
        key: "startElement",
        value: function startElement(element) {
          /** @type {?} */
          var tagName = element.nodeName.toLowerCase();

          if (!VALID_ELEMENTS.hasOwnProperty(tagName)) {
            this.sanitizedSomething = true;
            return !SKIP_TRAVERSING_CONTENT_IF_INVALID_ELEMENTS.hasOwnProperty(tagName);
          }

          this.buf.push('<');
          this.buf.push(tagName);
          /** @type {?} */

          var elAttrs = element.attributes;

          for (var i = 0; i < elAttrs.length; i++) {
            /** @type {?} */
            var elAttr = elAttrs.item(i);
            /** @type {?} */

            var attrName =
            /** @type {?} */
            elAttr.name;
            /** @type {?} */

            var lower = attrName.toLowerCase();

            if (!VALID_ATTRS.hasOwnProperty(lower)) {
              this.sanitizedSomething = true;
              continue;
            }
            /** @type {?} */


            var value =
            /** @type {?} */
            elAttr.value; // TODO(martinprobst): Special case image URIs for data:image/...

            if (URI_ATTRS[lower]) value = _sanitizeUrl(value);
            if (SRCSET_ATTRS[lower]) value = sanitizeSrcset(value);
            this.buf.push(' ', attrName, '="', encodeEntities(value), '"');
          }

          this.buf.push('>');
          return true;
        }
        /**
         * @private
         * @param {?} current
         * @return {?}
         */

      }, {
        key: "endElement",
        value: function endElement(current) {
          /** @type {?} */
          var tagName = current.nodeName.toLowerCase();

          if (VALID_ELEMENTS.hasOwnProperty(tagName) && !VOID_ELEMENTS.hasOwnProperty(tagName)) {
            this.buf.push('</');
            this.buf.push(tagName);
            this.buf.push('>');
          }
        }
        /**
         * @private
         * @param {?} chars
         * @return {?}
         */

      }, {
        key: "chars",
        value: function chars(_chars) {
          this.buf.push(encodeEntities(_chars));
        }
        /**
         * @param {?} node
         * @param {?} nextNode
         * @return {?}
         */

      }, {
        key: "checkClobberedElement",
        value: function checkClobberedElement(node, nextNode) {
          if (nextNode && (node.compareDocumentPosition(nextNode) & Node.DOCUMENT_POSITION_CONTAINED_BY) === Node.DOCUMENT_POSITION_CONTAINED_BY) {
            throw new Error("Failed to sanitize html because the element is clobbered: ".concat(
            /** @type {?} */
            node.outerHTML));
          }

          return nextNode;
        }
      }]);

      return SanitizingHtmlSerializer;
    }();

    if (false) {} // Regular Expressions for parsing tags and attributes

    /** @type {?} */


    var SURROGATE_PAIR_REGEXP = /[\uD800-\uDBFF][\uDC00-\uDFFF]/g; // ! to ~ is the ASCII range.

    /** @type {?} */

    var NON_ALPHANUMERIC_REGEXP = /([^\#-~ |!])/g;
    /**
     * Escapes all potentially dangerous characters, so that the
     * resulting string can be safely inserted into attribute or
     * element text.
     * @param {?} value
     * @return {?}
     */

    function encodeEntities(value) {
      return value.replace(/&/g, '&amp;').replace(SURROGATE_PAIR_REGEXP,
      /**
      * @param {?} match
      * @return {?}
      */
      function (match) {
        /** @type {?} */
        var hi = match.charCodeAt(0);
        /** @type {?} */

        var low = match.charCodeAt(1);
        return '&#' + ((hi - 0xD800) * 0x400 + (low - 0xDC00) + 0x10000) + ';';
      }).replace(NON_ALPHANUMERIC_REGEXP,
      /**
      * @param {?} match
      * @return {?}
      */
      function (match) {
        return '&#' + match.charCodeAt(0) + ';';
      }).replace(/</g, '&lt;').replace(/>/g, '&gt;');
    }
    /** @type {?} */


    var inertBodyHelper;
    /**
     * Sanitizes the given unsafe, untrusted HTML fragment, and returns HTML text that is safe to add to
     * the DOM in a browser environment.
     * @param {?} defaultDoc
     * @param {?} unsafeHtmlInput
     * @return {?}
     */

    function _sanitizeHtml(defaultDoc, unsafeHtmlInput) {
      /** @type {?} */
      var inertBodyElement = null;

      try {
        inertBodyHelper = inertBodyHelper || new InertBodyHelper(defaultDoc); // Make sure unsafeHtml is actually a string (TypeScript types are not enforced at runtime).

        /** @type {?} */

        var unsafeHtml = unsafeHtmlInput ? String(unsafeHtmlInput) : '';
        inertBodyElement = inertBodyHelper.getInertBodyElement(unsafeHtml); // mXSS protection. Repeatedly parse the document to make sure it stabilizes, so that a browser
        // trying to auto-correct incorrect HTML cannot cause formerly inert HTML to become dangerous.

        /** @type {?} */

        var mXSSAttempts = 5;
        /** @type {?} */

        var parsedHtml = unsafeHtml;

        do {
          if (mXSSAttempts === 0) {
            throw new Error('Failed to sanitize html because the input is unstable');
          }

          mXSSAttempts--;
          unsafeHtml = parsedHtml;
          parsedHtml =
          /** @type {?} */
          inertBodyElement.innerHTML;
          inertBodyElement = inertBodyHelper.getInertBodyElement(unsafeHtml);
        } while (unsafeHtml !== parsedHtml);
        /** @type {?} */


        var sanitizer = new SanitizingHtmlSerializer();
        /** @type {?} */

        var safeHtml = sanitizer.sanitizeChildren(
        /** @type {?} */
        getTemplateContent(
        /** @type {?} */
        inertBodyElement) || inertBodyElement);

        if (isDevMode() && sanitizer.sanitizedSomething) {
          console.warn('WARNING: sanitizing HTML stripped some content, see http://g.co/ng/security#xss');
        }

        return safeHtml;
      } finally {
        // In case anything goes wrong, clear out inertElement to reset the entire DOM structure.
        if (inertBodyElement) {
          /** @type {?} */
          var parent = getTemplateContent(inertBodyElement) || inertBodyElement;

          while (parent.firstChild) {
            parent.removeChild(parent.firstChild);
          }
        }
      }
    }
    /**
     * @param {?} el
     * @return {?}
     */


    function getTemplateContent(el) {
      return 'content' in
      /** @type {?} */
      el && isTemplateElement(el) ? el.content : null;
    }
    /**
     * @param {?} el
     * @return {?}
     */


    function isTemplateElement(el) {
      return el.nodeType === Node.ELEMENT_NODE && el.nodeName === 'TEMPLATE';
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/sanitization/security.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** @enum {number} */


    var SecurityContext = {
      NONE: 0,
      HTML: 1,
      STYLE: 2,
      SCRIPT: 3,
      URL: 4,
      RESOURCE_URL: 5
    };
    SecurityContext[SecurityContext.NONE] = 'NONE';
    SecurityContext[SecurityContext.HTML] = 'HTML';
    SecurityContext[SecurityContext.STYLE] = 'STYLE';
    SecurityContext[SecurityContext.SCRIPT] = 'SCRIPT';
    SecurityContext[SecurityContext.URL] = 'URL';
    SecurityContext[SecurityContext.RESOURCE_URL] = 'RESOURCE_URL';
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/sanitization/style_sanitizer.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Regular expression for safe style values.
     *
     * Quotes (" and ') are allowed, but a check must be done elsewhere to ensure they're balanced.
     *
     * ',' allows multiple values to be assigned to the same property (e.g. background-attachment or
     * font-family) and hence could allow multiple values to get injected, but that should pose no risk
     * of XSS.
     *
     * The function expression checks only for XSS safety, not for CSS validity.
     *
     * This regular expression was taken from the Closure sanitization library, and augmented for
     * transformation values.
     * @type {?}
     */

    var VALUES = '[-,."\'%_!# a-zA-Z0-9]+';
    /** @type {?} */

    var TRANSFORMATION_FNS = '(?:matrix|translate|scale|rotate|skew|perspective)(?:X|Y|Z|3d)?';
    /** @type {?} */

    var COLOR_FNS = '(?:rgb|hsl)a?';
    /** @type {?} */

    var GRADIENTS = '(?:repeating-)?(?:linear|radial)-gradient';
    /** @type {?} */

    var CSS3_FNS = '(?:attr|calc|var)';
    /** @type {?} */

    var FN_ARGS = '\\([-0-9.%, #a-zA-Z]+\\)';
    /** @type {?} */

    var SAFE_STYLE_VALUE = new RegExp("^(".concat(VALUES, "|") + "(?:".concat(TRANSFORMATION_FNS, "|").concat(COLOR_FNS, "|").concat(GRADIENTS, "|").concat(CSS3_FNS, ")") + "".concat(FN_ARGS, ")$"), 'g');
    /**
     * Matches a `url(...)` value with an arbitrary argument as long as it does
     * not contain parentheses.
     *
     * The URL value still needs to be sanitized separately.
     *
     * `url(...)` values are a very common use case, e.g. for `background-image`. With carefully crafted
     * CSS style rules, it is possible to construct an information leak with `url` values in CSS, e.g.
     * by observing whether scroll bars are displayed, or character ranges used by a font face
     * definition.
     *
     * Angular only allows binding CSS values (as opposed to entire CSS rules), so it is unlikely that
     * binding a URL value without further cooperation from the page will cause an information leak, and
     * if so, it is just a leak, not a full blown XSS vulnerability.
     *
     * Given the common use case, low likelihood of attack vector, and low impact of an attack, this
     * code is permissive and allows URLs that sanitize otherwise.
     * @type {?}
     */

    var URL_RE = /^url\(([^)]+)\)$/;
    /**
     * Checks that quotes (" and ') are properly balanced inside a string. Assumes
     * that neither escape (\) nor any other character that could result in
     * breaking out of a string parsing context are allowed;
     * see http://www.w3.org/TR/css3-syntax/#string-token-diagram.
     *
     * This code was taken from the Closure sanitization library.
     * @param {?} value
     * @return {?}
     */

    function hasBalancedQuotes(value) {
      /** @type {?} */
      var outsideSingle = true;
      /** @type {?} */

      var outsideDouble = true;

      for (var i = 0; i < value.length; i++) {
        /** @type {?} */
        var c = value.charAt(i);

        if (c === '\'' && outsideDouble) {
          outsideSingle = !outsideSingle;
        } else if (c === '"' && outsideSingle) {
          outsideDouble = !outsideDouble;
        }
      }

      return outsideSingle && outsideDouble;
    }
    /**
     * Sanitizes the given untrusted CSS style property value (i.e. not an entire object, just a single
     * value) and returns a value that is safe to use in a browser environment.
     * @param {?} value
     * @return {?}
     */


    function _sanitizeStyle(value) {
      value = String(value).trim(); // Make sure it's actually a string.

      if (!value) return ''; // Single url(...) values are supported, but only for URLs that sanitize cleanly. See above for
      // reasoning behind this.

      /** @type {?} */

      var urlMatch = value.match(URL_RE);

      if (urlMatch && _sanitizeUrl(urlMatch[1]) === urlMatch[1] || value.match(SAFE_STYLE_VALUE) && hasBalancedQuotes(value)) {
        return value; // Safe style values.
      }

      if (isDevMode()) {
        console.warn("WARNING: sanitizing unsafe style value ".concat(value, " (see http://g.co/ng/security#xss)."));
      }

      return 'unsafe';
    }
    /** @enum {number} */


    var StyleSanitizeMode = {
      /** Just check to see if the property is required to be sanitized or not */
      ValidateProperty: 1,

      /** Skip checking the property; just sanitize the value */
      SanitizeOnly: 2,

      /** Check the property and (if true) then sanitize the value */
      ValidateAndSanitize: 3
    };
    /**
     * Used to intercept and sanitize style values before they are written to the renderer.
     *
     * This function is designed to be called in two modes. When a value is not provided
     * then the function will return a boolean whether a property will be sanitized later.
     * If a value is provided then the sanitized version of that will be returned.
     * @record
     */

    function StyleSanitizeFn() {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/sanitization/sanitization.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * An `html` sanitizer which converts untrusted `html` **string** into trusted string by removing
     * dangerous content.
     *
     * This method parses the `html` and locates potentially dangerous content (such as urls and
     * javascript) and removes it.
     *
     * It is possible to mark a string as trusted by calling {\@link bypassSanitizationTrustHtml}.
     *
     * \@publicApi
     * @param {?} unsafeHtml untrusted `html`, typically from the user.
     * @return {?} `html` string which is safe to display to user, because all of the dangerous javascript
     * and urls have been removed.
     *
     */


    function ɵɵsanitizeHtml(unsafeHtml) {
      /** @type {?} */
      var sanitizer = getSanitizer();

      if (sanitizer) {
        return sanitizer.sanitize(SecurityContext.HTML, unsafeHtml) || '';
      }

      if (allowSanitizationBypassAndThrow(unsafeHtml, "HTML"
      /* Html */
      )) {
        return unwrapSafeValue(unsafeHtml);
      }

      return _sanitizeHtml(getDocument(), renderStringify(unsafeHtml));
    }
    /**
     * A `style` sanitizer which converts untrusted `style` **string** into trusted string by removing
     * dangerous content.
     *
     * This method parses the `style` and locates potentially dangerous content (such as urls and
     * javascript) and removes it.
     *
     * It is possible to mark a string as trusted by calling {\@link bypassSanitizationTrustStyle}.
     *
     * \@publicApi
     * @param {?} unsafeStyle untrusted `style`, typically from the user.
     * @return {?} `style` string which is safe to bind to the `style` properties, because all of the
     * dangerous javascript and urls have been removed.
     *
     */


    function ɵɵsanitizeStyle(unsafeStyle) {
      /** @type {?} */
      var sanitizer = getSanitizer();

      if (sanitizer) {
        return sanitizer.sanitize(SecurityContext.STYLE, unsafeStyle) || '';
      }

      if (allowSanitizationBypassAndThrow(unsafeStyle, "Style"
      /* Style */
      )) {
        return unwrapSafeValue(unsafeStyle);
      }

      return _sanitizeStyle(renderStringify(unsafeStyle));
    }
    /**
     * A `url` sanitizer which converts untrusted `url` **string** into trusted string by removing
     * dangerous
     * content.
     *
     * This method parses the `url` and locates potentially dangerous content (such as javascript) and
     * removes it.
     *
     * It is possible to mark a string as trusted by calling {\@link bypassSanitizationTrustUrl}.
     *
     * \@publicApi
     * @param {?} unsafeUrl untrusted `url`, typically from the user.
     * @return {?} `url` string which is safe to bind to the `src` properties such as `<img src>`, because
     * all of the dangerous javascript has been removed.
     *
     */


    function ɵɵsanitizeUrl(unsafeUrl) {
      /** @type {?} */
      var sanitizer = getSanitizer();

      if (sanitizer) {
        return sanitizer.sanitize(SecurityContext.URL, unsafeUrl) || '';
      }

      if (allowSanitizationBypassAndThrow(unsafeUrl, "URL"
      /* Url */
      )) {
        return unwrapSafeValue(unsafeUrl);
      }

      return _sanitizeUrl(renderStringify(unsafeUrl));
    }
    /**
     * A `url` sanitizer which only lets trusted `url`s through.
     *
     * This passes only `url`s marked trusted by calling {\@link bypassSanitizationTrustResourceUrl}.
     *
     * \@publicApi
     * @param {?} unsafeResourceUrl untrusted `url`, typically from the user.
     * @return {?} `url` string which is safe to bind to the `src` properties such as `<img src>`, because
     * only trusted `url`s have been allowed to pass.
     *
     */


    function ɵɵsanitizeResourceUrl(unsafeResourceUrl) {
      /** @type {?} */
      var sanitizer = getSanitizer();

      if (sanitizer) {
        return sanitizer.sanitize(SecurityContext.RESOURCE_URL, unsafeResourceUrl) || '';
      }

      if (allowSanitizationBypassAndThrow(unsafeResourceUrl, "ResourceURL"
      /* ResourceUrl */
      )) {
        return unwrapSafeValue(unsafeResourceUrl);
      }

      throw new Error('unsafe value used in a resource URL context (see http://g.co/ng/security#xss)');
    }
    /**
     * A `script` sanitizer which only lets trusted javascript through.
     *
     * This passes only `script`s marked trusted by calling {\@link
     * bypassSanitizationTrustScript}.
     *
     * \@publicApi
     * @param {?} unsafeScript untrusted `script`, typically from the user.
     * @return {?} `url` string which is safe to bind to the `<script>` element such as `<img src>`,
     * because only trusted `scripts` have been allowed to pass.
     *
     */


    function ɵɵsanitizeScript(unsafeScript) {
      /** @type {?} */
      var sanitizer = getSanitizer();

      if (sanitizer) {
        return sanitizer.sanitize(SecurityContext.SCRIPT, unsafeScript) || '';
      }

      if (allowSanitizationBypassAndThrow(unsafeScript, "Script"
      /* Script */
      )) {
        return unwrapSafeValue(unsafeScript);
      }

      throw new Error('unsafe value used in a script context');
    }
    /**
     * Detects which sanitizer to use for URL property, based on tag name and prop name.
     *
     * The rules are based on the RESOURCE_URL context config from
     * `packages/compiler/src/schema/dom_security_schema.ts`.
     * If tag and prop names don't match Resource URL schema, use URL sanitizer.
     * @param {?} tag
     * @param {?} prop
     * @return {?}
     */


    function getUrlSanitizer(tag, prop) {
      if (prop === 'src' && (tag === 'embed' || tag === 'frame' || tag === 'iframe' || tag === 'media' || tag === 'script') || prop === 'href' && (tag === 'base' || tag === 'link')) {
        return ɵɵsanitizeResourceUrl;
      }

      return ɵɵsanitizeUrl;
    }
    /**
     * Sanitizes URL, selecting sanitizer function based on tag and property names.
     *
     * This function is used in case we can't define security context at compile time, when only prop
     * name is available. This happens when we generate host bindings for Directives/Components. The
     * host element is unknown at compile time, so we defer calculation of specific sanitizer to
     * runtime.
     *
     * \@publicApi
     * @param {?} unsafeUrl untrusted `url`, typically from the user.
     * @param {?} tag target element tag name.
     * @param {?} prop name of the property that contains the value.
     * @return {?} `url` string which is safe to bind.
     *
     */


    function ɵɵsanitizeUrlOrResourceUrl(unsafeUrl, tag, prop) {
      return getUrlSanitizer(tag, prop)(unsafeUrl);
    }
    /**
     * The default style sanitizer will handle sanitization for style properties by
     * sanitizing any CSS property that can include a `url` value (usually image-based properties)
     *
     * \@publicApi
     * @type {?}
     */


    var ɵɵdefaultStyleSanitizer =
    /** @type {?} */

    /**
    * @param {?} prop
    * @param {?} value
    * @param {?=} mode
    * @return {?}
    */
    function ɵɵdefaultStyleSanitizer(prop, value, mode) {
      if (value === undefined && mode === undefined) {
        // This is a workaround for the fact that `StyleSanitizeFn` should not exist once PR#34480
        // lands. For now the `StyleSanitizeFn` and should act like `(value: any) => string` as a
        // work around.
        return ɵɵsanitizeStyle(prop);
      }

      mode = mode || 3
      /* ValidateAndSanitize */
      ;
      /** @type {?} */

      var doSanitizeValue = true;

      if (mode & 1
      /* ValidateProperty */
      ) {
          doSanitizeValue = stylePropNeedsSanitization(prop);
        }

      if (mode & 2
      /* SanitizeOnly */
      ) {
          return doSanitizeValue ? ɵɵsanitizeStyle(value) : unwrapSafeValue(value);
        } else {
        return doSanitizeValue;
      }
    };
    /**
     * @param {?} prop
     * @return {?}
     */


    function stylePropNeedsSanitization(prop) {
      return prop === 'background-image' || prop === 'backgroundImage' || prop === 'background' || prop === 'border-image' || prop === 'borderImage' || prop === 'border-image-source' || prop === 'borderImageSource' || prop === 'filter' || prop === 'list-style' || prop === 'listStyle' || prop === 'list-style-image' || prop === 'listStyleImage' || prop === 'clip-path' || prop === 'clipPath';
    }
    /**
     * @param {?} name
     * @return {?}
     */


    function validateAgainstEventProperties(name) {
      if (name.toLowerCase().startsWith('on')) {
        /** @type {?} */
        var msg = "Binding to event property '".concat(name, "' is disallowed for security reasons, ") + "please use (".concat(name.slice(2), ")=...") + "\nIf '".concat(name, "' is a directive input, make sure the directive is imported by the") + " current module.";
        throw new Error(msg);
      }
    }
    /**
     * @param {?} name
     * @return {?}
     */


    function validateAgainstEventAttributes(name) {
      if (name.toLowerCase().startsWith('on')) {
        /** @type {?} */
        var msg = "Binding to event attribute '".concat(name, "' is disallowed for security reasons, ") + "please use (".concat(name.slice(2), ")=...");
        throw new Error(msg);
      }
    }
    /**
     * @return {?}
     */


    function getSanitizer() {
      /** @type {?} */
      var lView = getLView();
      return lView && lView[SANITIZER];
    }
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * THIS FILE CONTAINS CODE WHICH SHOULD BE TREE SHAKEN AND NEVER CALLED FROM PRODUCTION CODE!!!
     */

    /**
     * Creates an `Array` construction with a given name. This is useful when
     * looking for memory consumption to see what time of array it is.
     *
     *
     * @param name Name to give to the constructor
     * @returns A subclass of `Array` if possible. This can only be done in
     *          environments which support `class` construct.
     */


    function createNamedArrayType(name) {
      // This should never be called in prod mode, so let's verify that is the case.
      if (ngDevMode) {
        try {
          // We need to do it this way so that TypeScript does not down-level the below code.
          var FunctionConstructor = createNamedArrayType.constructor;
          return new FunctionConstructor('Array', "return class ".concat(name, " extends Array{}"))(Array);
        } catch (e) {
          // If it does not work just give up and fall back to regular Array.
          return Array;
        }
      } else {
        throw new Error('Looks like we are in \'prod mode\', but we are creating a named Array type, which is wrong! Check your code');
      }
    }
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */


    function normalizeDebugBindingName(name) {
      // Attribute names with `$` (eg `x-y$`) are valid per spec, but unsupported by some browsers
      name = camelCaseToDashCase(name.replace(/[$@]/g, '_'));
      return "ng-reflect-".concat(name);
    }

    var CAMEL_CASE_REGEXP = /([A-Z])/g;

    function camelCaseToDashCase(input) {
      return input.replace(CAMEL_CASE_REGEXP, function () {
        for (var _len13 = arguments.length, m = new Array(_len13), _key14 = 0; _key14 < _len13; _key14++) {
          m[_key14] = arguments[_key14];
        }

        return '-' + m[1].toLowerCase();
      });
    }

    function normalizeDebugBindingValue(value) {
      try {
        // Limit the size of the value as otherwise the DOM just gets polluted.
        return value != null ? value.toString().slice(0, 30) : value;
      } catch (e) {
        return '[ERROR] Exception while trying to serialize the value';
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/context_discovery.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Returns the matching `LContext` data for a given DOM node, directive or component instance.
     *
     * This function will examine the provided DOM element, component, or directive instance\'s
     * monkey-patched property to derive the `LContext` data. Once called then the monkey-patched
     * value will be that of the newly created `LContext`.
     *
     * If the monkey-patched value is the `LView` instance then the context value for that
     * target will be created and the monkey-patch reference will be updated. Therefore when this
     * function is called it may mutate the provided element\'s, component\'s or any of the associated
     * directive\'s monkey-patch values.
     *
     * If the monkey-patch value is not detected then the code will walk up the DOM until an element
     * is found which contains a monkey-patch reference. When that occurs then the provided element
     * will be updated with a new context (which is then returned). If the monkey-patch value is not
     * detected for a component/directive instance then it will throw an error (all components and
     * directives should be automatically monkey-patched by ivy).
     *
     * @param {?} target Component, Directive or DOM Node.
     * @return {?}
     */


    function getLContext(target) {
      /** @type {?} */
      var mpValue = readPatchedData(target);

      if (mpValue) {
        // only when it's an array is it considered an LView instance
        // ... otherwise it's an already constructed LContext instance
        if (Array.isArray(mpValue)) {
          /** @type {?} */
          var lView =
          /** @type {?} */
          mpValue;
          /** @type {?} */

          var nodeIndex;
          /** @type {?} */

          var component = undefined;
          /** @type {?} */

          var directives = undefined;

          if (isComponentInstance(target)) {
            nodeIndex = findViaComponent(lView, target);

            if (nodeIndex == -1) {
              throw new Error('The provided component was not found in the application');
            }

            component = target;
          } else if (isDirectiveInstance(target)) {
            nodeIndex = findViaDirective(lView, target);

            if (nodeIndex == -1) {
              throw new Error('The provided directive was not found in the application');
            }

            directives = getDirectivesAtNodeIndex(nodeIndex, lView, false);
          } else {
            nodeIndex = findViaNativeElement(lView,
            /** @type {?} */
            target);

            if (nodeIndex == -1) {
              return null;
            }
          } // the goal is not to fill the entire context full of data because the lookups
          // are expensive. Instead, only the target data (the element, component, container, ICU
          // expression or directive details) are filled into the context. If called multiple times
          // with different target values then the missing target data will be filled in.

          /** @type {?} */


          var _native2 = unwrapRNode(lView[nodeIndex]);
          /** @type {?} */


          var existingCtx = readPatchedData(_native2);
          /** @type {?} */

          var context = existingCtx && !Array.isArray(existingCtx) ? existingCtx : createLContext(lView, nodeIndex, _native2); // only when the component has been discovered then update the monkey-patch

          if (component && context.component === undefined) {
            context.component = component;
            attachPatchData(context.component, context);
          } // only when the directives have been discovered then update the monkey-patch


          if (directives && context.directives === undefined) {
            context.directives = directives;

            for (var i = 0; i < directives.length; i++) {
              attachPatchData(directives[i], context);
            }
          }

          attachPatchData(context["native"], context);
          mpValue = context;
        }
      } else {
        /** @type {?} */
        var rElement =
        /** @type {?} */
        target;
        ngDevMode && assertDomNode(rElement); // if the context is not found then we need to traverse upwards up the DOM
        // to find the nearest element that has already been monkey patched with data

        /** @type {?} */

        var parent =
        /** @type {?} */
        rElement;

        while (parent = parent.parentNode) {
          /** @type {?} */
          var parentContext = readPatchedData(parent);

          if (parentContext) {
            /** @type {?} */
            var _lView2 = void 0;

            if (Array.isArray(parentContext)) {
              _lView2 =
              /** @type {?} */
              parentContext;
            } else {
              _lView2 = parentContext.lView;
            } // the edge of the app was also reached here through another means
            // (maybe because the DOM was changed manually).


            if (!_lView2) {
              return null;
            }
            /** @type {?} */


            var index = findViaNativeElement(_lView2, rElement);

            if (index >= 0) {
              /** @type {?} */
              var _native3 = unwrapRNode(_lView2[index]);
              /** @type {?} */


              var _context = createLContext(_lView2, index, _native3);

              attachPatchData(_native3, _context);
              mpValue = _context;
              break;
            }
          }
        }
      }

      return (
        /** @type {?} */
        mpValue || null
      );
    }
    /**
     * Creates an empty instance of a `LContext` context
     * @param {?} lView
     * @param {?} nodeIndex
     * @param {?} native
     * @return {?}
     */


    function createLContext(lView, nodeIndex, _native4) {
      return {
        lView: lView,
        nodeIndex: nodeIndex,
        "native": _native4,
        component: undefined,
        directives: undefined,
        localRefs: undefined
      };
    }
    /**
     * Takes a component instance and returns the view for that component.
     *
     * @param {?} componentInstance
     * @return {?} The component's view
     */


    function getComponentViewByInstance(componentInstance) {
      /** @type {?} */
      var lView = readPatchedData(componentInstance);
      /** @type {?} */

      var view;

      if (Array.isArray(lView)) {
        /** @type {?} */
        var nodeIndex = findViaComponent(lView, componentInstance);
        view = getComponentLViewByIndex(nodeIndex, lView);
        /** @type {?} */

        var context = createLContext(lView, nodeIndex,
        /** @type {?} */
        view[HOST]);
        context.component = componentInstance;
        attachPatchData(componentInstance, context);
        attachPatchData(context["native"], context);
      } else {
        /** @type {?} */
        var _context2 =
        /** @type {?} */

        /** @type {?} */
        lView;
        view = getComponentLViewByIndex(_context2.nodeIndex, _context2.lView);
      }

      return view;
    }
    /**
     * Assigns the given data to the given target (which could be a component,
     * directive or DOM node instance) using monkey-patching.
     * @param {?} target
     * @param {?} data
     * @return {?}
     */


    function attachPatchData(target, data) {
      target[MONKEY_PATCH_KEY_NAME] = data;
    }
    /**
     * @param {?} instance
     * @return {?}
     */


    function isComponentInstance(instance) {
      return instance && instance.constructor && instance.constructor.ɵcmp;
    }
    /**
     * @param {?} instance
     * @return {?}
     */


    function isDirectiveInstance(instance) {
      return instance && instance.constructor && instance.constructor.ɵdir;
    }
    /**
     * Locates the element within the given LView and returns the matching index
     * @param {?} lView
     * @param {?} target
     * @return {?}
     */


    function findViaNativeElement(lView, target) {
      /** @type {?} */
      var tNode = lView[TVIEW].firstChild;

      while (tNode) {
        /** @type {?} */
        var _native5 =
        /** @type {?} */
        getNativeByTNodeOrNull(tNode, lView);

        if (_native5 === target) {
          return tNode.index;
        }

        tNode = traverseNextElement(tNode);
      }

      return -1;
    }
    /**
     * Locates the next tNode (child, sibling or parent).
     * @param {?} tNode
     * @return {?}
     */


    function traverseNextElement(tNode) {
      if (tNode.child) {
        return tNode.child;
      } else if (tNode.next) {
        return tNode.next;
      } else {
        // Let's take the following template: <div><span>text</span></div><component/>
        // After checking the text node, we need to find the next parent that has a "next" TNode,
        // in this case the parent `div`, so that we can find the component.
        while (tNode.parent && !tNode.parent.next) {
          tNode = tNode.parent;
        }

        return tNode.parent && tNode.parent.next;
      }
    }
    /**
     * Locates the component within the given LView and returns the matching index
     * @param {?} lView
     * @param {?} componentInstance
     * @return {?}
     */


    function findViaComponent(lView, componentInstance) {
      /** @type {?} */
      var componentIndices = lView[TVIEW].components;

      if (componentIndices) {
        for (var i = 0; i < componentIndices.length; i++) {
          /** @type {?} */
          var elementComponentIndex = componentIndices[i];
          /** @type {?} */

          var componentView = getComponentLViewByIndex(elementComponentIndex, lView);

          if (componentView[CONTEXT] === componentInstance) {
            return elementComponentIndex;
          }
        }
      } else {
        /** @type {?} */
        var rootComponentView = getComponentLViewByIndex(HEADER_OFFSET, lView);
        /** @type {?} */

        var rootComponent = rootComponentView[CONTEXT];

        if (rootComponent === componentInstance) {
          // we are dealing with the root element here therefore we know that the
          // element is the very first element after the HEADER data in the lView
          return HEADER_OFFSET;
        }
      }

      return -1;
    }
    /**
     * Locates the directive within the given LView and returns the matching index
     * @param {?} lView
     * @param {?} directiveInstance
     * @return {?}
     */


    function findViaDirective(lView, directiveInstance) {
      // if a directive is monkey patched then it will (by default)
      // have a reference to the LView of the current view. The
      // element bound to the directive being search lives somewhere
      // in the view data. We loop through the nodes and check their
      // list of directives for the instance.

      /** @type {?} */
      var tNode = lView[TVIEW].firstChild;

      while (tNode) {
        /** @type {?} */
        var directiveIndexStart = tNode.directiveStart;
        /** @type {?} */

        var directiveIndexEnd = tNode.directiveEnd;

        for (var i = directiveIndexStart; i < directiveIndexEnd; i++) {
          if (lView[i] === directiveInstance) {
            return tNode.index;
          }
        }

        tNode = traverseNextElement(tNode);
      }

      return -1;
    }
    /**
     * Returns a list of directives extracted from the given view based on the
     * provided list of directive index values.
     *
     * @param {?} nodeIndex The node index
     * @param {?} lView The target view data
     * @param {?} includeComponents Whether or not to include components in returned directives
     * @return {?}
     */


    function getDirectivesAtNodeIndex(nodeIndex, lView, includeComponents) {
      /** @type {?} */
      var tNode =
      /** @type {?} */
      lView[TVIEW].data[nodeIndex];
      /** @type {?} */

      var directiveStartIndex = tNode.directiveStart;
      if (directiveStartIndex == 0) return EMPTY_ARRAY;
      /** @type {?} */

      var directiveEndIndex = tNode.directiveEnd;
      if (!includeComponents && tNode.flags & 2
      /* isComponentHost */
      ) directiveStartIndex++;
      return lView.slice(directiveStartIndex, directiveEndIndex);
    }
    /**
     * @param {?} nodeIndex
     * @param {?} lView
     * @return {?}
     */


    function getComponentAtNodeIndex(nodeIndex, lView) {
      /** @type {?} */
      var tNode =
      /** @type {?} */
      lView[TVIEW].data[nodeIndex];
      /** @type {?} */

      var directiveStartIndex = tNode.directiveStart;
      return tNode.flags & 2
      /* isComponentHost */
      ? lView[directiveStartIndex] : null;
    }
    /**
     * Returns a map of local references (local reference name => element or directive instance) that
     * exist on a given element.
     * @param {?} lView
     * @param {?} nodeIndex
     * @return {?}
     */


    function discoverLocalRefs(lView, nodeIndex) {
      /** @type {?} */
      var tNode =
      /** @type {?} */
      lView[TVIEW].data[nodeIndex];

      if (tNode && tNode.localNames) {
        /** @type {?} */
        var result = {};
        /** @type {?} */

        var localIndex = tNode.index + 1;

        for (var i = 0; i < tNode.localNames.length; i += 2) {
          result[tNode.localNames[i]] = lView[localIndex];
          localIndex++;
        }

        return result;
      }

      return null;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/errors.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Called when directives inject each other (creating a circular dependency)
     * @param {?} token
     * @return {?}
     */


    function throwCyclicDependencyError(token) {
      throw new Error("Cannot instantiate cyclic dependency! ".concat(token));
    }
    /**
     * Called when there are multiple component selectors that match a given node
     * @param {?} tNode
     * @return {?}
     */


    function throwMultipleComponentError(tNode) {
      throw new Error("Multiple components match node with tagname ".concat(tNode.tagName));
    }
    /**
     * @return {?}
     */


    function throwMixedMultiProviderError() {
      throw new Error("Cannot mix multi providers and regular providers");
    }
    /**
     * @param {?=} ngModuleType
     * @param {?=} providers
     * @param {?=} provider
     * @return {?}
     */


    function throwInvalidProviderError(ngModuleType, providers, provider) {
      /** @type {?} */
      var ngModuleDetail = '';

      if (ngModuleType && providers) {
        /** @type {?} */
        var providerDetail = providers.map(
        /**
        * @param {?} v
        * @return {?}
        */
        function (v) {
          return v == provider ? '?' + provider + '?' : '...';
        });
        ngModuleDetail = " - only instances of Provider and Type are allowed, got: [".concat(providerDetail.join(', '), "]");
      }

      throw new Error("Invalid provider for the NgModule '".concat(stringify(ngModuleType), "'") + ngModuleDetail);
    }
    /**
     * Throws an ExpressionChangedAfterChecked error if checkNoChanges mode is on.
     * @param {?} creationMode
     * @param {?} oldValue
     * @param {?} currValue
     * @param {?=} propName
     * @return {?}
     */


    function throwErrorIfNoChangesMode(creationMode, oldValue, currValue, propName) {
      /** @type {?} */
      var field = propName ? " for '".concat(propName, "'") : '';
      /** @type {?} */

      var msg = "ExpressionChangedAfterItHasBeenCheckedError: Expression has changed after it was checked. Previous value".concat(field, ": '").concat(oldValue, "'. Current value: '").concat(currValue, "'.");

      if (creationMode) {
        msg += " It seems like the view has been created after its parent and its children have been dirty checked." + " Has it been created in a change detection hook?";
      } // TODO: include debug context, see `viewDebugError` function in
      // `packages/core/src/view/errors.ts` for reference.


      throw new Error(msg);
    }
    /**
     * @param {?} lView
     * @param {?} rootIndex
     * @param {?} expressionIndex
     * @param {?} meta
     * @param {?} changedValue
     * @return {?}
     */


    function constructDetailsForInterpolation(lView, rootIndex, expressionIndex, meta, changedValue) {
      var _meta$split = meta.split(INTERPOLATION_DELIMITER),
          _meta$split2 = _toArray(_meta$split),
          propName = _meta$split2[0],
          prefix = _meta$split2[1],
          chunks = _meta$split2.slice(2);
      /** @type {?} */


      var oldValue = prefix;
      /** @type {?} */

      var newValue = prefix;

      for (var i = 0; i < chunks.length; i++) {
        /** @type {?} */
        var slotIdx = rootIndex + i;
        oldValue += "".concat(lView[slotIdx]).concat(chunks[i]);
        newValue += "".concat(slotIdx === expressionIndex ? changedValue : lView[slotIdx]).concat(chunks[i]);
      }

      return {
        propName: propName,
        oldValue: oldValue,
        newValue: newValue
      };
    }
    /**
     * Constructs an object that contains details for the ExpressionChangedAfterItHasBeenCheckedError:
     * - property name (for property bindings or interpolations)
     * - old and new values, enriched using information from metadata
     *
     * More information on the metadata storage format can be found in `storePropertyBindingMetadata`
     * function description.
     * @param {?} lView
     * @param {?} bindingIndex
     * @param {?} oldValue
     * @param {?} newValue
     * @return {?}
     */


    function getExpressionChangedErrorDetails(lView, bindingIndex, oldValue, newValue) {
      /** @type {?} */
      var tData = lView[TVIEW].data;
      /** @type {?} */

      var metadata = tData[bindingIndex];

      if (typeof metadata === 'string') {
        // metadata for property interpolation
        if (metadata.indexOf(INTERPOLATION_DELIMITER) > -1) {
          return constructDetailsForInterpolation(lView, bindingIndex, bindingIndex, metadata, newValue);
        } // metadata for property binding


        return {
          propName: metadata,
          oldValue: oldValue,
          newValue: newValue
        };
      } // metadata is not available for this expression, check if this expression is a part of the
      // property interpolation by going from the current binding index left and look for a string that
      // contains INTERPOLATION_DELIMITER, the layout in tView.data for this case will look like this:
      // [..., 'id�Prefix � and � suffix', null, null, null, ...]


      if (metadata === null) {
        /** @type {?} */
        var idx = bindingIndex - 1;

        while (typeof tData[idx] !== 'string' && tData[idx + 1] === null) {
          idx--;
        }
        /** @type {?} */


        var meta = tData[idx];

        if (typeof meta === 'string') {
          /** @type {?} */
          var matches = meta.match(new RegExp(INTERPOLATION_DELIMITER, 'g')); // first interpolation delimiter separates property name from interpolation parts (in case of
          // property interpolations), so we subtract one from total number of found delimiters

          if (matches && matches.length - 1 > bindingIndex - idx) {
            return constructDetailsForInterpolation(lView, idx, bindingIndex, meta, newValue);
          }
        }
      }

      return {
        propName: undefined,
        oldValue: oldValue,
        newValue: newValue
      };
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/interfaces/node.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @enum {number} */


    var TNodeType = {
      /**
       * The TNode contains information about an {@link LContainer} for embedded views.
       */
      Container: 0,

      /**
       * The TNode contains information about an `<ng-content>` projection
       */
      Projection: 1,

      /**
       * The TNode contains information about an {@link LView}
       */
      View: 2,

      /**
       * The TNode contains information about a DOM element aka {@link RNode}.
       */
      Element: 3,

      /**
       * The TNode contains information about an `<ng-container>` element {@link RNode}.
       */
      ElementContainer: 4,

      /**
       * The TNode contains information about an ICU comment used in `i18n`.
       */
      IcuContainer: 5
    };
    /** @enum {number} */

    var TNodeFlags = {
      /** Bit #1 - This bit is set if the node is a host for any directive (including a component) */
      isDirectiveHost: 1,

      /**
       * Bit #2 - This bit is set if the node is a host for a component.
       *
       * Setting this bit implies that the `isDirectiveHost` bit is set as well.
       * */
      isComponentHost: 2,

      /** Bit #3 - This bit is set if the node has been projected */
      isProjected: 4,

      /** Bit #4 - This bit is set if any directive on this node has content queries */
      hasContentQuery: 8,

      /** Bit #5 - This bit is set if the node has any "class" inputs */
      hasClassInput: 16,

      /** Bit #6 - This bit is set if the node has any "style" inputs */
      hasStyleInput: 32,

      /** Bit #7 This bit is set if the node has been detached by i18n */
      isDetached: 64,

      /**
       * Bit #8 - This bit is set if the node has directives with host bindings.
       *
       * This flags allows us to guard host-binding logic and invoke it only on nodes
       * that actually have directives with host bindings.
       */
      hasHostBindings: 128
    };
    /** @enum {number} */

    var TNodeProviderIndexes = {
      /** The index of the first provider on this node is encoded on the least significant bits */
      ProvidersStartIndexMask: 65535,

      /**
         The count of view providers from the component on this node is encoded on the 16 most
         significant bits
       */
      CptViewProvidersCountShift: 16,
      CptViewProvidersCountShifter: 65536
    };
    /** @enum {number} */

    var AttributeMarker = {
      /**
       * An implicit marker which indicates that the value in the array are of `attributeKey`,
       * `attributeValue` format.
       *
       * NOTE: This is implicit as it is the type when no marker is present in array. We indicate that
       * it should not be present at runtime by the negative number.
       */
      ImplicitAttributes: -1,

      /**
       * Marker indicates that the following 3 values in the attributes array are:
       * namespaceUri, attributeName, attributeValue
       * in that order.
       */
      NamespaceURI: 0,

      /**
       * Signals class declaration.
       *
       * Each value following `Classes` designates a class name to include on the element.
       * ## Example:
       *
       * Given:
       * ```
       * <div class="foo bar baz">...<d/vi>
       * ```
       *
       * the generated code is:
       * ```
       * var _c1 = [AttributeMarker.Classes, 'foo', 'bar', 'baz'];
       * ```
       */
      Classes: 1,

      /**
       * Signals style declaration.
       *
       * Each pair of values following `Styles` designates a style name and value to include on the
       * element.
       * ## Example:
       *
       * Given:
       * ```
       * <div style="width:100px; height:200px; color:red">...</div>
       * ```
       *
       * the generated code is:
       * ```
       * var _c1 = [AttributeMarker.Styles, 'width', '100px', 'height'. '200px', 'color', 'red'];
       * ```
       */
      Styles: 2,

      /**
       * Signals that the following attribute names were extracted from input or output bindings.
       *
       * For example, given the following HTML:
       *
       * ```
       * <div moo="car" [foo]="exp" (bar)="doSth()">
       * ```
       *
       * the generated code is:
       *
       * ```
       * var _c1 = ['moo', 'car', AttributeMarker.Bindings, 'foo', 'bar'];
       * ```
       */
      Bindings: 3,

      /**
       * Signals that the following attribute names were hoisted from an inline-template declaration.
       *
       * For example, given the following HTML:
       *
       * ```
       * <div *ngFor="let value of values; trackBy:trackBy" dirA [dirB]="value">
       * ```
       *
       * the generated code for the `template()` instruction would include:
       *
       * ```
       * ['dirA', '', AttributeMarker.Bindings, 'dirB', AttributeMarker.Template, 'ngFor', 'ngForOf',
       * 'ngForTrackBy', 'let-value']
       * ```
       *
       * while the generated code for the `element()` instruction inside the template function would
       * include:
       *
       * ```
       * ['dirA', '', AttributeMarker.Bindings, 'dirB']
       * ```
       */
      Template: 4,

      /**
       * Signals that the following attribute is `ngProjectAs` and its value is a parsed `CssSelector`.
       *
       * For example, given the following HTML:
       *
       * ```
       * <h1 attr="value" ngProjectAs="[title]">
       * ```
       *
       * the generated code for the `element()` instruction would include:
       *
       * ```
       * ['attr', 'value', AttributeMarker.ProjectAs, ['', 'title', '']]
       * ```
       */
      ProjectAs: 5,

      /**
       * Signals that the following attribute will be translated by runtime i18n
       *
       * For example, given the following HTML:
       *
       * ```
       * <div moo="car" foo="value" i18n-foo [bar]="binding" i18n-bar>
       * ```
       *
       * the generated code is:
       *
       * ```
       * var _c1 = ['moo', 'car', AttributeMarker.I18n, 'foo', 'bar'];
       */
      I18n: 6
    };
    /**
     * Binding data (flyweight) for a particular node that is shared between all templates
     * of a specific type.
     *
     * If a property is:
     *    - PropertyAliases: that property's data was generated and this is it
     *    - Null: that property's data was already generated and nothing was found.
     *    - Undefined: that property's data has not yet been generated
     *
     * see: https://en.wikipedia.org/wiki/Flyweight_pattern for more on the Flyweight pattern
     * @record
     */

    function TNode() {}

    if (false) {}
    /**
     * Static data for an element
     * @record
     */


    function TElementNode() {}

    if (false) {}
    /**
     * Static data for a text node
     * @record
     */


    function TTextNode() {}

    if (false) {}
    /**
     * Static data for an LContainer
     * @record
     */


    function TContainerNode() {}

    if (false) {}
    /**
     * Static data for an <ng-container>
     * @record
     */


    function TElementContainerNode() {}

    if (false) {}
    /**
     * Static data for an ICU expression
     * @record
     */


    function TIcuContainerNode() {}

    if (false) {}
    /**
     * Static data for a view
     * @record
     */


    function TViewNode() {}

    if (false) {}
    /**
     * Static data for an LProjectionNode
     * @record
     */


    function TProjectionNode() {}

    if (false) {} // Note: This hack is necessary so we don't erroneously get a circular dependency
    // failure based on types.

    /** @type {?} */


    var unusedValueExportToPlacateAjd$4 = 1;
    /**
     * Returns `true` if the `TNode` has a directive which has `\@Input()` for `class` binding.
     *
     * ```
     * <div my-dir [class]="exp"></div>
     * ```
     * and
     * ```
     * \@Directive({
     * })
     * class MyDirective {
     * \@Input()
     *   class: string;
     * }
     * ```
     *
     * In the above case it is necessary to write the reconciled styling information into the
     * directive's input.
     *
     * @param {?} tNode
     * @return {?}
     */

    function hasClassInput(tNode) {
      return (tNode.flags & 16
      /* hasClassInput */
      ) !== 0;
    }
    /**
     * Returns `true` if the `TNode` has a directive which has `\@Input()` for `style` binding.
     *
     * ```
     * <div my-dir [style]="exp"></div>
     * ```
     * and
     * ```
     * \@Directive({
     * })
     * class MyDirective {
     * \@Input()
     *   class: string;
     * }
     * ```
     *
     * In the above case it is necessary to write the reconciled styling information into the
     * directive's input.
     *
     * @param {?} tNode
     * @return {?}
     */


    function hasStyleInput(tNode) {
      return (tNode.flags & 32
      /* hasStyleInput */
      ) !== 0;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/interfaces/projection.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** @enum {number} */


    var SelectorFlags = {
      /** Indicates this is the beginning of a new negative selector */
      NOT: 1,

      /** Mode for matching attributes */
      ATTRIBUTE: 2,

      /** Mode for matching tag names */
      ELEMENT: 4,

      /** Mode for matching class names */
      CLASS: 8
    }; // Note: This hack is necessary so we don't erroneously get a circular dependency
    // failure based on types.

    /** @type {?} */

    var unusedValueExportToPlacateAjd$5 = 1;
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/styling/class_differ.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Returns an index of `classToSearch` in `className` taking token boundaries into account.
     *
     * `classIndexOf('AB A', 'A', 0)` will be 3 (not 0 since `AB!==A`)
     *
     * @param {?} className A string containing classes (whitespace separated)
     * @param {?} classToSearch A class name to locate
     * @param {?} startingIndex Starting location of search
     * @return {?} an index of the located class (or -1 if not found)
     */

    function classIndexOf(className, classToSearch, startingIndex) {
      ngDevMode && assertNotEqual(classToSearch, '', 'can not look for "" string.');
      /** @type {?} */

      var end = className.length;

      while (true) {
        /** @type {?} */
        var foundIndex = className.indexOf(classToSearch, startingIndex);
        if (foundIndex === -1) return foundIndex;

        if (foundIndex === 0 || className.charCodeAt(foundIndex - 1) <= 32
        /* SPACE */
        ) {
            // Ensure that it has leading whitespace

            /** @type {?} */
            var length = classToSearch.length;

            if (foundIndex + length === end || className.charCodeAt(foundIndex + length) <= 32
            /* SPACE */
            ) {
                // Ensure that it has trailing whitespace
                return foundIndex;
              }
          } // False positive, keep searching from where we left off.


        startingIndex = foundIndex + 1;
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/node_selector_matcher.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var unusedValueToPlacateAjd = unusedValueExportToPlacateAjd$4 + unusedValueExportToPlacateAjd$5;
    /** @type {?} */

    var NG_TEMPLATE_SELECTOR = 'ng-template';
    /**
     * Search the `TAttributes` to see if it contains `cssClassToMatch` (case insensitive)
     *
     * @param {?} attrs `TAttributes` to search through.
     * @param {?} cssClassToMatch class to match (lowercase)
     * @param {?} isProjectionMode Whether or not class matching should look into the attribute `class` in
     *    addition to the `AttributeMarker.Classes`.
     * @return {?}
     */

    function isCssClassMatching(attrs, cssClassToMatch, isProjectionMode) {
      // TODO(misko): The fact that this function needs to know about `isProjectionMode` seems suspect.
      // It is strange to me that sometimes the class information comes in form of `class` attribute
      // and sometimes in form of `AttributeMarker.Classes`. Some investigation is needed to determine
      // if that is the right behavior.
      ngDevMode && assertEqual(cssClassToMatch, cssClassToMatch.toLowerCase(), 'Class name expected to be lowercase.');
      /** @type {?} */

      var i = 0;

      while (i < attrs.length) {
        /** @type {?} */
        var item = attrs[i++];

        if (isProjectionMode && item === 'class') {
          item =
          /** @type {?} */
          attrs[i];

          if (classIndexOf(item.toLowerCase(), cssClassToMatch, 0) !== -1) {
            return true;
          }
        } else if (item === 1
        /* Classes */
        ) {
            // We found the classes section. Start searching for the class.
            while (i < attrs.length && typeof (item = attrs[i++]) == 'string') {
              // while we have strings
              if (item.toLowerCase() === cssClassToMatch) return true;
            }

            return false;
          }
      }

      return false;
    }
    /**
     * Checks whether the `tNode` represents an inline template (e.g. `*ngFor`).
     *
     * @param {?} tNode current TNode
     * @return {?}
     */


    function isInlineTemplate(tNode) {
      return tNode.type === 0
      /* Container */
      && tNode.tagName !== NG_TEMPLATE_SELECTOR;
    }
    /**
     * Function that checks whether a given tNode matches tag-based selector and has a valid type.
     *
     * Matching can be performed in 2 modes: projection mode (when we project nodes) and regular
     * directive matching mode:
     * - in the "directive matching" mode we do _not_ take TContainer's tagName into account if it is
     * different from NG_TEMPLATE_SELECTOR (value different from NG_TEMPLATE_SELECTOR indicates that a
     * tag name was extracted from * syntax so we would match the same directive twice);
     * - in the "projection" mode, we use a tag name potentially extracted from the * syntax processing
     * (applicable to TNodeType.Container only).
     * @param {?} tNode
     * @param {?} currentSelector
     * @param {?} isProjectionMode
     * @return {?}
     */


    function hasTagAndTypeMatch(tNode, currentSelector, isProjectionMode) {
      /** @type {?} */
      var tagNameToCompare = tNode.type === 0
      /* Container */
      && !isProjectionMode ? NG_TEMPLATE_SELECTOR : tNode.tagName;
      return currentSelector === tagNameToCompare;
    }
    /**
     * A utility function to match an Ivy node static data against a simple CSS selector
     *
     * @param {?} tNode
     * @param {?} selector The selector to try matching against the node.
     * @param {?} isProjectionMode if `true` we are matching for content projection, otherwise we are doing
     * directive matching.
     * @return {?} true if node matches the selector.
     */


    function isNodeMatchingSelector(tNode, selector, isProjectionMode) {
      ngDevMode && assertDefined(selector[0], 'Selector should have a tag name');
      /** @type {?} */

      var mode = 4
      /* ELEMENT */
      ;
      /** @type {?} */

      var nodeAttrs = tNode.attrs || []; // Find the index of first attribute that has no value, only a name.

      /** @type {?} */

      var nameOnlyMarkerIdx = getNameOnlyMarkerIndex(nodeAttrs); // When processing ":not" selectors, we skip to the next ":not" if the
      // current one doesn't match

      /** @type {?} */

      var skipToNextSelector = false;

      for (var i = 0; i < selector.length; i++) {
        /** @type {?} */
        var current = selector[i];

        if (typeof current === 'number') {
          // If we finish processing a :not selector and it hasn't failed, return false
          if (!skipToNextSelector && !isPositive(mode) && !isPositive(current)) {
            return false;
          } // If we are skipping to the next :not() and this mode flag is positive,
          // it's a part of the current :not() selector, and we should keep skipping


          if (skipToNextSelector && isPositive(current)) continue;
          skipToNextSelector = false;
          mode =
          /** @type {?} */
          current | mode & 1
          /* NOT */
          ;
          continue;
        }

        if (skipToNextSelector) continue;

        if (mode & 4
        /* ELEMENT */
        ) {
            mode = 2
            /* ATTRIBUTE */
            | mode & 1
            /* NOT */
            ;

            if (current !== '' && !hasTagAndTypeMatch(tNode, current, isProjectionMode) || current === '' && selector.length === 1) {
              if (isPositive(mode)) return false;
              skipToNextSelector = true;
            }
          } else {
          /** @type {?} */
          var selectorAttrValue = mode & 8
          /* CLASS */
          ? current : selector[++i]; // special case for matching against classes when a tNode has been instantiated with
          // class and style values as separate attribute values (e.g. ['title', CLASS, 'foo'])

          if (mode & 8
          /* CLASS */
          && tNode.attrs !== null) {
            if (!isCssClassMatching(tNode.attrs,
            /** @type {?} */
            selectorAttrValue, isProjectionMode)) {
              if (isPositive(mode)) return false;
              skipToNextSelector = true;
            }

            continue;
          }
          /** @type {?} */


          var attrName = mode & 8
          /* CLASS */
          ? 'class' : current;
          /** @type {?} */

          var attrIndexInNode = findAttrIndexInNode(attrName, nodeAttrs, isInlineTemplate(tNode), isProjectionMode);

          if (attrIndexInNode === -1) {
            if (isPositive(mode)) return false;
            skipToNextSelector = true;
            continue;
          }

          if (selectorAttrValue !== '') {
            /** @type {?} */
            var nodeAttrValue = void 0;

            if (attrIndexInNode > nameOnlyMarkerIdx) {
              nodeAttrValue = '';
            } else {
              ngDevMode && assertNotEqual(nodeAttrs[attrIndexInNode], 0
              /* NamespaceURI */
              , 'We do not match directives on namespaced attributes'); // we lowercase the attribute value to be able to match
              // selectors without case-sensitivity
              // (selectors are already in lowercase when generated)

              nodeAttrValue =
              /** @type {?} */
              nodeAttrs[attrIndexInNode + 1].toLowerCase();
            }
            /** @type {?} */


            var compareAgainstClassName = mode & 8
            /* CLASS */
            ? nodeAttrValue : null;

            if (compareAgainstClassName && classIndexOf(compareAgainstClassName,
            /** @type {?} */
            selectorAttrValue, 0) !== -1 || mode & 2
            /* ATTRIBUTE */
            && selectorAttrValue !== nodeAttrValue) {
              if (isPositive(mode)) return false;
              skipToNextSelector = true;
            }
          }
        }
      }

      return isPositive(mode) || skipToNextSelector;
    }
    /**
     * @param {?} mode
     * @return {?}
     */


    function isPositive(mode) {
      return (mode & 1
      /* NOT */
      ) === 0;
    }
    /**
     * Examines the attribute's definition array for a node to find the index of the
     * attribute that matches the given `name`.
     *
     * NOTE: This will not match namespaced attributes.
     *
     * Attribute matching depends upon `isInlineTemplate` and `isProjectionMode`.
     * The following table summarizes which types of attributes we attempt to match:
     *
     * ===========================================================================================================
     * Modes                   | Normal Attributes | Bindings Attributes | Template Attributes | I18n
     * Attributes
     * ===========================================================================================================
     * Inline + Projection     | YES               | YES                 | NO                  | YES
     * -----------------------------------------------------------------------------------------------------------
     * Inline + Directive      | NO                | NO                  | YES                 | NO
     * -----------------------------------------------------------------------------------------------------------
     * Non-inline + Projection | YES               | YES                 | NO                  | YES
     * -----------------------------------------------------------------------------------------------------------
     * Non-inline + Directive  | YES               | YES                 | NO                  | YES
     * ===========================================================================================================
     *
     * @param {?} name the name of the attribute to find
     * @param {?} attrs the attribute array to examine
     * @param {?} isInlineTemplate true if the node being matched is an inline template (e.g. `*ngFor`)
     * rather than a manually expanded template node (e.g `<ng-template>`).
     * @param {?} isProjectionMode true if we are matching against content projection otherwise we are
     * matching against directives.
     * @return {?}
     */


    function findAttrIndexInNode(name, attrs, isInlineTemplate, isProjectionMode) {
      if (attrs === null) return -1;
      /** @type {?} */

      var i = 0;

      if (isProjectionMode || !isInlineTemplate) {
        /** @type {?} */
        var bindingsMode = false;

        while (i < attrs.length) {
          /** @type {?} */
          var maybeAttrName = attrs[i];

          if (maybeAttrName === name) {
            return i;
          } else if (maybeAttrName === 3
          /* Bindings */
          || maybeAttrName === 6
          /* I18n */
          ) {
              bindingsMode = true;
            } else if (maybeAttrName === 1
          /* Classes */
          || maybeAttrName === 2
          /* Styles */
          ) {
              /** @type {?} */
              var value = attrs[++i]; // We should skip classes here because we have a separate mechanism for
              // matching classes in projection mode.

              while (typeof value === 'string') {
                value = attrs[++i];
              }

              continue;
            } else if (maybeAttrName === 4
          /* Template */
          ) {
              // We do not care about Template attributes in this scenario.
              break;
            } else if (maybeAttrName === 0
          /* NamespaceURI */
          ) {
              // Skip the whole namespaced attribute and value. This is by design.
              i += 4;
              continue;
            } // In binding mode there are only names, rather than name-value pairs.


          i += bindingsMode ? 1 : 2;
        } // We did not match the attribute


        return -1;
      } else {
        return matchTemplateAttribute(attrs, name);
      }
    }
    /**
     * @param {?} tNode
     * @param {?} selector
     * @param {?=} isProjectionMode
     * @return {?}
     */


    function isNodeMatchingSelectorList(tNode, selector) {
      var isProjectionMode = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;

      for (var i = 0; i < selector.length; i++) {
        if (isNodeMatchingSelector(tNode, selector[i], isProjectionMode)) {
          return true;
        }
      }

      return false;
    }
    /**
     * @param {?} tNode
     * @return {?}
     */


    function getProjectAsAttrValue(tNode) {
      /** @type {?} */
      var nodeAttrs = tNode.attrs;

      if (nodeAttrs != null) {
        /** @type {?} */
        var ngProjectAsAttrIdx = nodeAttrs.indexOf(5
        /* ProjectAs */
        ); // only check for ngProjectAs in attribute names, don't accidentally match attribute's value
        // (attribute names are stored at even indexes)

        if ((ngProjectAsAttrIdx & 1) === 0) {
          return (
            /** @type {?} */
            nodeAttrs[ngProjectAsAttrIdx + 1]
          );
        }
      }

      return null;
    }
    /**
     * @param {?} nodeAttrs
     * @return {?}
     */


    function getNameOnlyMarkerIndex(nodeAttrs) {
      for (var i = 0; i < nodeAttrs.length; i++) {
        /** @type {?} */
        var nodeAttr = nodeAttrs[i];

        if (isNameOnlyAttributeMarker(nodeAttr)) {
          return i;
        }
      }

      return nodeAttrs.length;
    }
    /**
     * @param {?} attrs
     * @param {?} name
     * @return {?}
     */


    function matchTemplateAttribute(attrs, name) {
      /** @type {?} */
      var i = attrs.indexOf(4
      /* Template */
      );

      if (i > -1) {
        i++;

        while (i < attrs.length) {
          /** @type {?} */
          var attr = attrs[i]; // Return in case we checked all template attrs and are switching to the next section in the
          // attrs array (that starts with a number that represents an attribute marker).

          if (typeof attr === 'number') return -1;
          if (attr === name) return i;
          i++;
        }
      }

      return -1;
    }
    /**
     * Checks whether a selector is inside a CssSelectorList
     * @param {?} selector Selector to be checked.
     * @param {?} list List in which to look for the selector.
     * @return {?}
     */


    function isSelectorInSelectorList(selector, list) {
      selectorListLoop: for (var i = 0; i < list.length; i++) {
        /** @type {?} */
        var currentSelectorInList = list[i];

        if (selector.length !== currentSelectorInList.length) {
          continue;
        }

        for (var j = 0; j < selector.length; j++) {
          if (selector[j] !== currentSelectorInList[j]) {
            continue selectorListLoop;
          }
        }

        return true;
      }

      return false;
    }
    /**
     * @param {?} isNegativeMode
     * @param {?} chunk
     * @return {?}
     */


    function maybeWrapInNotSelector(isNegativeMode, chunk) {
      return isNegativeMode ? ':not(' + chunk.trim() + ')' : chunk;
    }
    /**
     * @param {?} selector
     * @return {?}
     */


    function stringifyCSSSelector(selector) {
      /** @type {?} */
      var result =
      /** @type {?} */
      selector[0];
      /** @type {?} */

      var i = 1;
      /** @type {?} */

      var mode = 2
      /* ATTRIBUTE */
      ;
      /** @type {?} */

      var currentChunk = '';
      /** @type {?} */

      var isNegativeMode = false;

      while (i < selector.length) {
        /** @type {?} */
        var valueOrMarker = selector[i];

        if (typeof valueOrMarker === 'string') {
          if (mode & 2
          /* ATTRIBUTE */
          ) {
              /** @type {?} */
              var attrValue =
              /** @type {?} */
              selector[++i];
              currentChunk += '[' + valueOrMarker + (attrValue.length > 0 ? '="' + attrValue + '"' : '') + ']';
            } else if (mode & 8
          /* CLASS */
          ) {
              currentChunk += '.' + valueOrMarker;
            } else if (mode & 4
          /* ELEMENT */
          ) {
              currentChunk += ' ' + valueOrMarker;
            }
        } else {
          //
          // Append current chunk to the final result in case we come across SelectorFlag, which
          // indicates that the previous section of a selector is over. We need to accumulate content
          // between flags to make sure we wrap the chunk later in :not() selector if needed, e.g.
          // ```
          //  ['', Flags.CLASS, '.classA', Flags.CLASS | Flags.NOT, '.classB', '.classC']
          // ```
          // should be transformed to `.classA :not(.classB .classC)`.
          //
          // Note: for negative selector part, we accumulate content between flags until we find the
          // next negative flag. This is needed to support a case where `:not()` rule contains more than
          // one chunk, e.g. the following selector:
          // ```
          //  ['', Flags.ELEMENT | Flags.NOT, 'p', Flags.CLASS, 'foo', Flags.CLASS | Flags.NOT, 'bar']
          // ```
          // should be stringified to `:not(p.foo) :not(.bar)`
          //
          if (currentChunk !== '' && !isPositive(valueOrMarker)) {
            result += maybeWrapInNotSelector(isNegativeMode, currentChunk);
            currentChunk = '';
          }

          mode = valueOrMarker; // According to CssSelector spec, once we come across `SelectorFlags.NOT` flag, the negative
          // mode is maintained for remaining chunks of a selector.

          isNegativeMode = isNegativeMode || !isPositive(mode);
        }

        i++;
      }

      if (currentChunk !== '') {
        result += maybeWrapInNotSelector(isNegativeMode, currentChunk);
      }

      return result;
    }
    /**
     * Generates string representation of CSS selector in parsed form.
     *
     * ComponentDef and DirectiveDef are generated with the selector in parsed form to avoid doing
     * additional parsing at runtime (for example, for directive matching). However in some cases (for
     * example, while bootstrapping a component), a string version of the selector is required to query
     * for the host element on the page. This function takes the parsed form of a selector and returns
     * its string representation.
     *
     * @param {?} selectorList selector in parsed form
     * @return {?} string representation of a given selector
     */


    function stringifyCSSSelectorList(selectorList) {
      return selectorList.map(stringifyCSSSelector).join(',');
    }
    /**
     * Extracts attributes and classes information from a given CSS selector.
     *
     * This function is used while creating a component dynamically. In this case, the host element
     * (that is created dynamically) should contain attributes and classes specified in component's CSS
     * selector.
     *
     * @param {?} selector CSS selector in parsed form (in a form of array)
     * @return {?} object with `attrs` and `classes` fields that contain extracted information
     */


    function extractAttrsAndClassesFromSelector(selector) {
      /** @type {?} */
      var attrs = [];
      /** @type {?} */

      var classes = [];
      /** @type {?} */

      var i = 1;
      /** @type {?} */

      var mode = 2
      /* ATTRIBUTE */
      ;

      while (i < selector.length) {
        /** @type {?} */
        var valueOrMarker = selector[i];

        if (typeof valueOrMarker === 'string') {
          if (mode === 2
          /* ATTRIBUTE */
          ) {
              if (valueOrMarker !== '') {
                attrs.push(valueOrMarker,
                /** @type {?} */
                selector[++i]);
              }
            } else if (mode === 8
          /* CLASS */
          ) {
              classes.push(valueOrMarker);
            }
        } else {
          // According to CssSelector spec, once we come across `SelectorFlags.NOT` flag, the negative
          // mode is maintained for remaining chunks of a selector. Since attributes and classes are
          // extracted only for "positive" part of the selector, we can stop here.
          if (!isPositive(mode)) break;
          mode = valueOrMarker;
        }

        i++;
      }

      return {
        attrs: attrs,
        classes: classes
      };
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/tokens.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */
    // WARNING: interface has both a type and a value, skipping emit

    /**
     * A special value which designates that a value has not changed.
     * @type {?}
     */


    var NO_CHANGE = typeof ngDevMode === 'undefined' || ngDevMode ? {
      __brand__: 'NO_CHANGE'
    } :
    /** @type {?} */
    {};
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/util/view_traversal_utils.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Gets the parent LView of the passed LView, if the PARENT is an LContainer, will get the parent of
     * that LContainer, which is an LView
     * @param {?} lView the lView whose parent to get
     * @return {?}
     */

    function getLViewParent(lView) {
      ngDevMode && assertLView(lView);
      /** @type {?} */

      var parent = lView[PARENT];
      return isLContainer(parent) ?
      /** @type {?} */
      parent[PARENT] : parent;
    }
    /**
     * Retrieve the root view from any component or `LView` by walking the parent `LView` until
     * reaching the root `LView`.
     *
     * @param {?} componentOrLView any component or `LView`
     * @return {?}
     */


    function getRootView(componentOrLView) {
      ngDevMode && assertDefined(componentOrLView, 'component');
      /** @type {?} */

      var lView = isLView(componentOrLView) ? componentOrLView :
      /** @type {?} */
      readPatchedLView(componentOrLView);

      while (lView && !(lView[FLAGS] & 512
      /* IsRoot */
      )) {
        lView =
        /** @type {?} */
        getLViewParent(lView);
      }

      ngDevMode && assertLView(lView);
      return lView;
    }
    /**
     * Returns the `RootContext` instance that is associated with
     * the application where the target is situated. It does this by walking the parent views until it
     * gets to the root view, then getting the context off of that.
     *
     * @param {?} viewOrComponent the `LView` or component to get the root context for.
     * @return {?}
     */


    function getRootContext(viewOrComponent) {
      /** @type {?} */
      var rootView = getRootView(viewOrComponent);
      ngDevMode && assertDefined(rootView[CONTEXT], 'RootView has no context. Perhaps it is disconnected?');
      return (
        /** @type {?} */
        rootView[CONTEXT]
      );
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/advance.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Advances to an element for later binding instructions.
     *
     * Used in conjunction with instructions like {\@link property} to act on elements with specified
     * indices, for example those created with {\@link element} or {\@link elementStart}.
     *
     * ```ts
     * (rf: RenderFlags, ctx: any) => {
     *   if (rf & 1) {
     *     text(0, 'Hello');
     *     text(1, 'Goodbye')
     *     element(2, 'div');
     *   }
     *   if (rf & 2) {
     *     advance(2); // Advance twice to the <div>.
     *     property('title', 'test');
     *   }
     *  }
     * ```
     * \@codeGenApi
     * @param {?} delta Number of elements to advance forwards by.
     *
     * @return {?}
     */


    function ɵɵadvance(delta) {
      ngDevMode && assertGreaterThan(delta, 0, 'Can only advance forward');
      selectIndexInternal(getTView(), getLView(), getSelectedIndex() + delta, getCheckNoChangesMode());
    }
    /**
     * Selects an element for later binding instructions.
     * @deprecated No longer being generated, but still used in unit tests.
     * \@codeGenApi
     * @param {?} index
     * @return {?}
     */


    function ɵɵselect(index) {
      // TODO(misko): Remove this function as it is no longer being used.
      selectIndexInternal(getTView(), getLView(), index, getCheckNoChangesMode());
    }
    /**
     * @param {?} tView
     * @param {?} lView
     * @param {?} index
     * @param {?} checkNoChangesMode
     * @return {?}
     */


    function selectIndexInternal(tView, lView, index, checkNoChangesMode) {
      ngDevMode && assertGreaterThan(index, -1, 'Invalid index');
      ngDevMode && assertDataInRange(lView, index + HEADER_OFFSET); // Flush the initial hooks for elements in the view that have been added up to this point.
      // PERF WARNING: do NOT extract this to a separate function without running benchmarks

      if (!checkNoChangesMode) {
        /** @type {?} */
        var hooksInitPhaseCompleted = (lView[FLAGS] & 3
        /* InitPhaseStateMask */
        ) === 3
        /* InitPhaseCompleted */
        ;

        if (hooksInitPhaseCompleted) {
          /** @type {?} */
          var preOrderCheckHooks = tView.preOrderCheckHooks;

          if (preOrderCheckHooks !== null) {
            executeCheckHooks(lView, preOrderCheckHooks, index);
          }
        } else {
          /** @type {?} */
          var preOrderHooks = tView.preOrderHooks;

          if (preOrderHooks !== null) {
            executeInitAndCheckHooks(lView, preOrderHooks, 0
            /* OnInitHooksToBeRun */
            , index);
          }
        }
      } // We must set the selected index *after* running the hooks, because hooks may have side-effects
      // that cause other template functions to run, thus updating the selected index, which is global
      // state. If we run `setSelectedIndex` *before* we run the hooks, in some cases the selected index
      // will be altered by the time we leave the `ɵɵadvance` instruction.


      setSelectedIndex(index);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/interfaces/i18n.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** @enum {number} */


    var I18nMutateOpCode = {
      /**
       * Stores shift amount for bits 17-3 that contain reference index.
       */
      SHIFT_REF: 3,

      /**
       * Stores shift amount for bits 31-17 that contain parent index.
       */
      SHIFT_PARENT: 17,

      /**
       * Mask for OpCode
       */
      MASK_OPCODE: 7,

      /**
       * OpCode to select a node. (next OpCode will contain the operation.)
       */
      Select: 0,

      /**
       * OpCode to append the current node to `PARENT`.
       */
      AppendChild: 1,

      /**
       * OpCode to remove the `REF` node from `PARENT`.
       */
      Remove: 3,

      /**
       * OpCode to set the attribute of a node.
       */
      Attr: 4,

      /**
       * OpCode to simulate elementEnd()
       */
      ElementEnd: 5,

      /**
       * OpCode to read the remove OpCodes for the nested ICU
       */
      RemoveNestedIcu: 6
    };
    /**
     * Marks that the next string is for element.
     *
     * See `I18nMutateOpCodes` documentation.
     * @type {?}
     */

    var ELEMENT_MARKER = {
      marker: 'element'
    }; // WARNING: interface has both a type and a value, skipping emit

    /**
     * Marks that the next string is for comment.
     *
     * See `I18nMutateOpCodes` documentation.
     * @type {?}
     */

    var COMMENT_MARKER = {
      marker: 'comment'
    }; // WARNING: interface has both a type and a value, skipping emit

    /**
     * Array storing OpCode for dynamically creating `i18n` blocks.
     *
     * Example:
     * ```ts
     * <I18nCreateOpCode>[
     *   // For adding text nodes
     *   // ---------------------
     *   // Equivalent to:
     *   //   const node = lView[index++] = document.createTextNode('abc');
     *   //   lView[1].insertBefore(node, lView[2]);
     *   'abc', 1 << SHIFT_PARENT | 2 << SHIFT_REF | InsertBefore,
     *
     *   // Equivalent to:
     *   //   const node = lView[index++] = document.createTextNode('xyz');
     *   //   lView[1].appendChild(node);
     *   'xyz', 1 << SHIFT_PARENT | AppendChild,
     *
     *   // For adding element nodes
     *   // ---------------------
     *   // Equivalent to:
     *   //   const node = lView[index++] = document.createElement('div');
     *   //   lView[1].insertBefore(node, lView[2]);
     *   ELEMENT_MARKER, 'div', 1 << SHIFT_PARENT | 2 << SHIFT_REF | InsertBefore,
     *
     *   // Equivalent to:
     *   //   const node = lView[index++] = document.createElement('div');
     *   //   lView[1].appendChild(node);
     *   ELEMENT_MARKER, 'div', 1 << SHIFT_PARENT | AppendChild,
     *
     *   // For adding comment nodes
     *   // ---------------------
     *   // Equivalent to:
     *   //   const node = lView[index++] = document.createComment('');
     *   //   lView[1].insertBefore(node, lView[2]);
     *   COMMENT_MARKER, '', 1 << SHIFT_PARENT | 2 << SHIFT_REF | InsertBefore,
     *
     *   // Equivalent to:
     *   //   const node = lView[index++] = document.createComment('');
     *   //   lView[1].appendChild(node);
     *   COMMENT_MARKER, '', 1 << SHIFT_PARENT | AppendChild,
     *
     *   // For moving existing nodes to a different location
     *   // --------------------------------------------------
     *   // Equivalent to:
     *   //   const node = lView[1];
     *   //   lView[2].insertBefore(node, lView[3]);
     *   1 << SHIFT_REF | Select, 2 << SHIFT_PARENT | 3 << SHIFT_REF | InsertBefore,
     *
     *   // Equivalent to:
     *   //   const node = lView[1];
     *   //   lView[2].appendChild(node);
     *   1 << SHIFT_REF | Select, 2 << SHIFT_PARENT | AppendChild,
     *
     *   // For removing existing nodes
     *   // --------------------------------------------------
     *   //   const node = lView[1];
     *   //   removeChild(tView.data(1), node, lView);
     *   1 << SHIFT_REF | Remove,
     *
     *   // For writing attributes
     *   // --------------------------------------------------
     *   //   const node = lView[1];
     *   //   node.setAttribute('attr', 'value');
     *   1 << SHIFT_REF | Select, 'attr', 'value'
     *            // NOTE: Select followed by two string (vs select followed by OpCode)
     * ];
     * ```
     * NOTE:
     *   - `index` is initial location where the extra nodes should be stored in the EXPANDO section of
     * `LVIewData`.
     *
     * See: `applyI18nCreateOpCodes`;
     * @record
     */

    function I18nMutateOpCodes() {}
    /** @enum {number} */


    var I18nUpdateOpCode = {
      /**
       * Stores shift amount for bits 17-2 that contain reference index.
       */
      SHIFT_REF: 2,

      /**
       * Mask for OpCode
       */
      MASK_OPCODE: 3,

      /**
       * OpCode to update a text node.
       */
      Text: 0,

      /**
       * OpCode to update a attribute of a node.
       */
      Attr: 1,

      /**
       * OpCode to switch the current ICU case.
       */
      IcuSwitch: 2,

      /**
       * OpCode to update the current ICU case.
       */
      IcuUpdate: 3
    };
    /**
     * Stores DOM operations which need to be applied to update DOM render tree due to changes in
     * expressions.
     *
     * The basic idea is that `i18nExp` OpCodes capture expression changes and update a change
     * mask bit. (Bit 1 for expression 1, bit 2 for expression 2 etc..., bit 32 for expression 32 and
     * higher.) The OpCodes then compare its own change mask against the expression change mask to
     * determine if the OpCodes should execute.
     *
     * These OpCodes can be used by both the i18n block as well as ICU sub-block.
     *
     * ## Example
     *
     * Assume
     * ```ts
     *   if (rf & RenderFlags.Update) {
     *    i18nExp(ctx.exp1); // If changed set mask bit 1
     *    i18nExp(ctx.exp2); // If changed set mask bit 2
     *    i18nExp(ctx.exp3); // If changed set mask bit 3
     *    i18nExp(ctx.exp4); // If changed set mask bit 4
     *    i18nApply(0);            // Apply all changes by executing the OpCodes.
     *  }
     * ```
     * We can assume that each call to `i18nExp` sets an internal `changeMask` bit depending on the
     * index of `i18nExp`.
     *
     * ### OpCodes
     * ```ts
     * <I18nUpdateOpCodes>[
     *   // The following OpCodes represent: `<div i18n-title="pre{{exp1}}in{{exp2}}post">`
     *   // If `changeMask & 0b11`
     *   //        has changed then execute update OpCodes.
     *   //        has NOT changed then skip `7` values and start processing next OpCodes.
     *   0b11, 7,
     *   // Concatenate `newValue = 'pre'+lView[bindIndex-4]+'in'+lView[bindIndex-3]+'post';`.
     *   'pre', -4, 'in', -3, 'post',
     *   // Update attribute: `elementAttribute(1, 'title', sanitizerFn(newValue));`
     *   1 << SHIFT_REF | Attr, 'title', sanitizerFn,
     *
     *   // The following OpCodes represent: `<div i18n>Hello {{exp3}}!">`
     *   // If `changeMask & 0b100`
     *   //        has changed then execute update OpCodes.
     *   //        has NOT changed then skip `4` values and start processing next OpCodes.
     *   0b100, 4,
     *   // Concatenate `newValue = 'Hello ' + lView[bindIndex -2] + '!';`.
     *   'Hello ', -2, '!',
     *   // Update text: `lView[1].textContent = newValue;`
     *   1 << SHIFT_REF | Text,
     *
     *   // The following OpCodes represent: `<div i18n>{exp4, plural, ... }">`
     *   // If `changeMask & 0b1000`
     *   //        has changed then execute update OpCodes.
     *   //        has NOT changed then skip `4` values and start processing next OpCodes.
     *   0b1000, 4,
     *   // Concatenate `newValue = lView[bindIndex -1];`.
     *   -1,
     *   // Switch ICU: `icuSwitchCase(lView[1], 0, newValue);`
     *   0 << SHIFT_ICU | 1 << SHIFT_REF | IcuSwitch,
     *
     *   // Note `changeMask & -1` is always true, so the IcuUpdate will always execute.
     *   -1, 1,
     *   // Update ICU: `icuUpdateCase(lView[1], 0);`
     *   0 << SHIFT_ICU | 1 << SHIFT_REF | IcuUpdate,
     *
     * ];
     * ```
     *
     * @record
     */

    function I18nUpdateOpCodes() {}
    /**
     * Store information for the i18n translation block.
     * @record
     */


    function TI18n() {}

    if (false) {}
    /** @enum {number} */


    var IcuType = {
      select: 0,
      plural: 1
    };
    /**
     * @record
     */

    function TIcu() {}

    if (false) {} // Note: This hack is necessary so we don't erroneously get a circular dependency
    // failure based on types.

    /** @type {?} */


    var unusedValueExportToPlacateAjd$6 = 1;
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/interfaces/styling.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Store the static values for the styling binding.
     *
     * The `TStylingStatic` is just `KeyValueArray` where key `""` (stored at location 0) contains the
     * `TStylingKey` (stored at location 1). In other words this wraps the `TStylingKey` such that the
     * `""` contains the wrapped value.
     *
     * When instructions are resolving styling they may need to look forward or backwards in the linked
     * list to resolve the value. For this reason we have to make sure that he linked list also contains
     * the static values. However the list only has space for one item per styling instruction. For this
     * reason we store the static values here as part of the `TStylingKey`. This means that the
     * resolution function when looking for a value needs to first look at the binding value, and than
     * at `TStylingKey` (if it exists).
     *
     * Imagine we have:
     *
     * ```
     * <div class="TEMPLATE" my-dir>
     *
     * \@Directive({
     *   host: {
     *     class: 'DIR',
     *     '[class.dynamic]': 'exp' // ɵɵclassProp('dynamic', ctx.exp);
     *   }
     * })
     * ```
     *
     * In the above case the linked list will contain one item:
     *
     * ```
     *   // assume binding location: 10 for `ɵɵclassProp('dynamic', ctx.exp);`
     *   tData[10] = <TStylingStatic>[
     *     '': 'dynamic', // This is the wrapped value of `TStylingKey`
     *     'DIR': true,   // This is the default static value of directive binding.
     *   ];
     *   tData[10 + 1] = 0; // We don't have prev/next.
     *
     *   lView[10] = undefined;     // assume `ctx.exp` is `undefined`
     *   lView[10 + 1] = undefined; // Just normalized `lView[10]`
     * ```
     *
     * So when the function is resolving styling value, it first needs to look into the linked list
     * (there is none) and than into the static `TStylingStatic` too see if there is a default value for
     * `dynamic` (there is not). Therefore it is safe to remove it.
     *
     * If setting `true` case:
     * ```
     *   lView[10] = true;     // assume `ctx.exp` is `true`
     *   lView[10 + 1] = true; // Just normalized `lView[10]`
     * ```
     * So when the function is resolving styling value, it first needs to look into the linked list
     * (there is none) and than into `TNode.residualClass` (TNode.residualStyle) which contains
     * ```
     *   tNode.residualClass = [
     *     'TEMPLATE': true,
     *   ];
     * ```
     *
     * This means that it is safe to add class.
     * @record
     */

    function TStylingStatic() {}
    /**
     * This is a branded number which contains previous and next index.
     *
     * When we come across styling instructions we need to store the `TStylingKey` in the correct
     * order so that we can re-concatenate the styling value in the desired priority.
     *
     * The insertion can happen either at the:
     * - end of template as in the case of coming across additional styling instruction in the template
     * - in front of the template in the case of coming across additional instruction in the
     *   `hostBindings`.
     *
     * We use `TStylingRange` to store the previous and next index into the `TData` where the template
     * bindings can be found.
     *
     * - bit 0 is used to mark that the previous index has a duplicate for current value.
     * - bit 1 is used to mark that the next index has a duplicate for the current value.
     * - bits 2-16 are used to encode the next/tail of the template.
     * - bits 17-32 are used to encode the previous/head of template.
     *
     * NODE: *duplicate* false implies that it is statically known that this binding will not collide
     * with other bindings and therefore there is no need to check other bindings. For example the
     * bindings in `<div [style.color]="exp" [style.width]="exp">` will never collide and will have
     * their bits set accordingly. Previous duplicate means that we may need to check previous if the
     * current binding is `null`. Next duplicate means that we may need to check next bindings if the
     * current binding is not `null`.
     *
     * NOTE: `0` has special significance and represents `null` as in no additional pointer.
     * @record
     */


    function TStylingRange() {}

    if (false) {}
    /** @enum {number} */


    var StylingRange = {
      /// Number of bits to shift for the previous pointer
      PREV_SHIFT: 17,
      /// Previous pointer mask.
      PREV_MASK: 4294836224,
      /// Number of bits to shift for the next pointer
      NEXT_SHIFT: 2,
      /// Next pointer mask.
      NEXT_MASK: 131068,
      // Mask to remove nagative bit. (interpret number as positive)
      UNSIGNED_MASK: 32767,

      /**
       * This bit is set if the previous bindings contains a binding which could possibly cause a
       * duplicate. For example: `<div [style]="map" [style.width]="width">`, the `width` binding will
       * have previous duplicate set. The implication is that if `width` binding becomes `null`, it is
       * necessary to defer the value to `map.width`. (Because `width` overwrites `map.width`.)
       */
      PREV_DUPLICATE: 2,

      /**
       * This bit is set to if the next binding contains a binding which could possibly cause a
       * duplicate. For example: `<div [style]="map" [style.width]="width">`, the `map` binding will
       * have next duplicate set. The implication is that if `map.width` binding becomes not `null`, it
       * is necessary to defer the value to `width`. (Because `width` overwrites `map.width`.)
       */
      NEXT_DUPLICATE: 1
    };
    /**
     * @param {?} prev
     * @param {?} next
     * @return {?}
     */

    function toTStylingRange(prev, next) {
      ngDevMode && assertNumberInRange(prev, 0, 32767
      /* UNSIGNED_MASK */
      );
      ngDevMode && assertNumberInRange(next, 0, 32767
      /* UNSIGNED_MASK */
      );
      return (
        /** @type {?} */
        prev << 17
        /* PREV_SHIFT */
        | next << 2
        /* NEXT_SHIFT */

      );
    }
    /**
     * @param {?} tStylingRange
     * @return {?}
     */


    function getTStylingRangePrev(tStylingRange) {
      ngDevMode && assertNumber(tStylingRange, 'expected number');
      return (
        /** @type {?} */

        /** @type {?} */
        tStylingRange >> 17
        /* PREV_SHIFT */
        & 32767
        /* UNSIGNED_MASK */

      );
    }
    /**
     * @param {?} tStylingRange
     * @return {?}
     */


    function getTStylingRangePrevDuplicate(tStylingRange) {
      ngDevMode && assertNumber(tStylingRange, 'expected number');
      return (
      /** @type {?} */

      /** @type {?} */
      tStylingRange & 2
      /* PREV_DUPLICATE */
      ) == 2
      /* PREV_DUPLICATE */
      ;
    }
    /**
     * @param {?} tStylingRange
     * @param {?} previous
     * @return {?}
     */


    function setTStylingRangePrev(tStylingRange, previous) {
      ngDevMode && assertNumber(tStylingRange, 'expected number');
      ngDevMode && assertNumberInRange(previous, 0, 32767
      /* UNSIGNED_MASK */
      );
      return (
        /** @type {?} */

        /** @type {?} */

        /** @type {?} */
        tStylingRange & ~4294836224
        /* PREV_MASK */
        | previous << 17
        /* PREV_SHIFT */

      );
    }
    /**
     * @param {?} tStylingRange
     * @return {?}
     */


    function setTStylingRangePrevDuplicate(tStylingRange) {
      ngDevMode && assertNumber(tStylingRange, 'expected number');
      return (
        /** @type {?} */

        /** @type {?} */

        /** @type {?} */
        tStylingRange | 2
        /* PREV_DUPLICATE */

      );
    }
    /**
     * @param {?} tStylingRange
     * @return {?}
     */


    function getTStylingRangeNext(tStylingRange) {
      ngDevMode && assertNumber(tStylingRange, 'expected number');
      return (
      /** @type {?} */

      /** @type {?} */
      tStylingRange & 131068
      /* NEXT_MASK */
      ) >> 2
      /* NEXT_SHIFT */
      ;
    }
    /**
     * @param {?} tStylingRange
     * @param {?} next
     * @return {?}
     */


    function setTStylingRangeNext(tStylingRange, next) {
      ngDevMode && assertNumber(tStylingRange, 'expected number');
      ngDevMode && assertNumberInRange(next, 0, 32767
      /* UNSIGNED_MASK */
      );
      return (
        /** @type {?} */

        /** @type {?} */

        /** @type {?} */
        tStylingRange & ~131068
        /* NEXT_MASK */
        | //
        next << 2
        /* NEXT_SHIFT */

      );
    }
    /**
     * @param {?} tStylingRange
     * @return {?}
     */


    function getTStylingRangeNextDuplicate(tStylingRange) {
      ngDevMode && assertNumber(tStylingRange, 'expected number');
      return (
      /** @type {?} */

      /** @type {?} */
      tStylingRange & 1
      /* NEXT_DUPLICATE */
      ) === 1
      /* NEXT_DUPLICATE */
      ;
    }
    /**
     * @param {?} tStylingRange
     * @return {?}
     */


    function setTStylingRangeNextDuplicate(tStylingRange) {
      ngDevMode && assertNumber(tStylingRange, 'expected number');
      return (
        /** @type {?} */

        /** @type {?} */

        /** @type {?} */
        tStylingRange | 1
        /* NEXT_DUPLICATE */

      );
    }
    /**
     * @param {?} tStylingRange
     * @return {?}
     */


    function getTStylingRangeTail(tStylingRange) {
      ngDevMode && assertNumber(tStylingRange, 'expected number');
      /** @type {?} */

      var next = getTStylingRangeNext(tStylingRange);
      return next === 0 ? getTStylingRangePrev(tStylingRange) : next;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/util/debug_utils.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     * @param {?} obj
     * @param {?} debug
     * @return {?}
     */


    function attachDebugObject(obj, debug) {
      Object.defineProperty(obj, 'debug', {
        value: debug,
        enumerable: false
      });
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/lview_debug.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var NG_DEV_MODE = (typeof ngDevMode === 'undefined' || !!ngDevMode) && initNgDevMode();
    /*
     * This file contains conditionally attached classes which provide human readable (debug) level
     * information for `LView`, `LContainer` and other internal data structures. These data structures
     * are stored internally as array which makes it very difficult during debugging to reason about the
     * current state of the system.
     *
     * Patching the array with extra property does change the array's hidden class' but it does not
     * change the cost of access, therefore this patching should not have significant if any impact in
     * `ngDevMode` mode. (see: https://jsperf.com/array-vs-monkey-patch-array)
     *
     * So instead of seeing:
     * ```
     * Array(30) [Object, 659, null, …]
     * ```
     *
     * You get to see:
     * ```
     * LViewDebug {
     *   views: [...],
     *   flags: {attached: true, ...}
     *   nodes: [
     *     {html: '<div id="123">', ..., nodes: [
     *       {html: '<span>', ..., nodes: null}
     *     ]}
     *   ]
     * }
     * ```
     */

    /** @type {?} */

    var LVIEW_COMPONENT_CACHE;
    /** @type {?} */

    var LVIEW_EMBEDDED_CACHE;
    /** @type {?} */

    var LVIEW_ROOT;
    /**
     * @record
     */

    function TViewDebug() {}

    if (false) {}
    /**
     * This function clones a blueprint and creates LView.
     *
     * Simple slice will keep the same type, and we need it to be LView
     * @param {?} tView
     * @return {?}
     */


    function cloneToLViewFromTViewBlueprint(tView) {
      /** @type {?} */
      var debugTView =
      /** @type {?} */
      tView;
      /** @type {?} */

      var lView = getLViewToClone(debugTView.type, tView.template && tView.template.name);
      return (
        /** @type {?} */
        lView.concat(tView.blueprint)
      );
    }
    /**
     * @param {?} type
     * @param {?} name
     * @return {?}
     */


    function getLViewToClone(type, name) {
      switch (type) {
        case 0
        /* Root */
        :
          if (LVIEW_ROOT === undefined) LVIEW_ROOT = new (createNamedArrayType('LRootView'))();
          return LVIEW_ROOT;

        case 1
        /* Component */
        :
          if (LVIEW_COMPONENT_CACHE === undefined) LVIEW_COMPONENT_CACHE = new Map();
          /** @type {?} */

          var componentArray = LVIEW_COMPONENT_CACHE.get(name);

          if (componentArray === undefined) {
            componentArray = new (createNamedArrayType('LComponentView' + nameSuffix(name)))();
            LVIEW_COMPONENT_CACHE.set(name, componentArray);
          }

          return componentArray;

        case 2
        /* Embedded */
        :
          if (LVIEW_EMBEDDED_CACHE === undefined) LVIEW_EMBEDDED_CACHE = new Map();
          /** @type {?} */

          var embeddedArray = LVIEW_EMBEDDED_CACHE.get(name);

          if (embeddedArray === undefined) {
            embeddedArray = new (createNamedArrayType('LEmbeddedView' + nameSuffix(name)))();
            LVIEW_EMBEDDED_CACHE.set(name, embeddedArray);
          }

          return embeddedArray;
      }

      throw new Error('unreachable code');
    }
    /**
     * @param {?} text
     * @return {?}
     */


    function nameSuffix(text) {
      if (text == null) return '';
      /** @type {?} */

      var index = text.lastIndexOf('_Template');
      return '_' + (index === -1 ? text : text.substr(0, index));
    }
    /**
     * This class is a debug version of Object literal so that we can have constructor name show up
     * in
     * debug tools in ngDevMode.
     * @type {?}
     */


    var TViewConstructor = /*#__PURE__*/function () {
      /**
       * @param {?} type
       * @param {?} id
       * @param {?} blueprint
       * @param {?} template
       * @param {?} queries
       * @param {?} viewQuery
       * @param {?} node
       * @param {?} data
       * @param {?} bindingStartIndex
       * @param {?} expandoStartIndex
       * @param {?} expandoInstructions
       * @param {?} firstCreatePass
       * @param {?} firstUpdatePass
       * @param {?} staticViewQueries
       * @param {?} staticContentQueries
       * @param {?} preOrderHooks
       * @param {?} preOrderCheckHooks
       * @param {?} contentHooks
       * @param {?} contentCheckHooks
       * @param {?} viewHooks
       * @param {?} viewCheckHooks
       * @param {?} destroyHooks
       * @param {?} cleanup
       * @param {?} contentQueries
       * @param {?} components
       * @param {?} directiveRegistry
       * @param {?} pipeRegistry
       * @param {?} firstChild
       * @param {?} schemas
       * @param {?} consts
       * @param {?} incompleteFirstPass
       */
      function TView(type, //
      id, //
      blueprint, //
      template, //
      queries, //
      viewQuery, //
      node, //
      data, //
      bindingStartIndex, //
      expandoStartIndex, //
      expandoInstructions, //
      firstCreatePass, //
      firstUpdatePass, //
      staticViewQueries, //
      staticContentQueries, //
      preOrderHooks, //
      preOrderCheckHooks, //
      contentHooks, //
      contentCheckHooks, //
      viewHooks, //
      viewCheckHooks, //
      destroyHooks, //
      cleanup, //
      contentQueries, //
      components, //
      directiveRegistry, //
      pipeRegistry, //
      firstChild, //
      schemas, //
      consts, //
      incompleteFirstPass //
      ) {
        _classCallCheck(this, TView);

        this.type = type;
        this.id = id;
        this.blueprint = blueprint;
        this.template = template;
        this.queries = queries;
        this.viewQuery = viewQuery;
        this.node = node;
        this.data = data;
        this.bindingStartIndex = bindingStartIndex;
        this.expandoStartIndex = expandoStartIndex;
        this.expandoInstructions = expandoInstructions;
        this.firstCreatePass = firstCreatePass;
        this.firstUpdatePass = firstUpdatePass;
        this.staticViewQueries = staticViewQueries;
        this.staticContentQueries = staticContentQueries;
        this.preOrderHooks = preOrderHooks;
        this.preOrderCheckHooks = preOrderCheckHooks;
        this.contentHooks = contentHooks;
        this.contentCheckHooks = contentCheckHooks;
        this.viewHooks = viewHooks;
        this.viewCheckHooks = viewCheckHooks;
        this.destroyHooks = destroyHooks;
        this.cleanup = cleanup;
        this.contentQueries = contentQueries;
        this.components = components;
        this.directiveRegistry = directiveRegistry;
        this.pipeRegistry = pipeRegistry;
        this.firstChild = firstChild;
        this.schemas = schemas;
        this.consts = consts;
        this.incompleteFirstPass = incompleteFirstPass;
      }
      /**
       * @return {?}
       */


      _createClass2(TView, [{
        key: "template_",
        get: function get() {
          /** @type {?} */
          var buf = [];
          processTNodeChildren(this.firstChild, buf);
          return buf.join('');
        }
      }]);

      return TView;
    }();

    var TNode$1 = /*#__PURE__*/function () {
      /**
       * @param {?} tView_
       * @param {?} type
       * @param {?} index
       * @param {?} injectorIndex
       * @param {?} directiveStart
       * @param {?} directiveEnd
       * @param {?} directiveStylingLast
       * @param {?} propertyBindings
       * @param {?} flags
       * @param {?} providerIndexes
       * @param {?} tagName
       * @param {?} attrs
       * @param {?} mergedAttrs
       * @param {?} localNames
       * @param {?} initialInputs
       * @param {?} inputs
       * @param {?} outputs
       * @param {?} tViews
       * @param {?} next
       * @param {?} projectionNext
       * @param {?} child
       * @param {?} parent
       * @param {?} projection
       * @param {?} styles
       * @param {?} residualStyles
       * @param {?} classes
       * @param {?} residualClasses
       * @param {?} classBindings
       * @param {?} styleBindings
       */
      function TNode$1(tView_, //
      type, //
      index, //
      injectorIndex, //
      directiveStart, //
      directiveEnd, //
      directiveStylingLast, //
      propertyBindings, //
      flags, //
      providerIndexes, //
      tagName, //
      attrs, //
      mergedAttrs, //
      localNames, //
      initialInputs, //
      inputs, //
      outputs, //
      tViews, //
      next, //
      projectionNext, //
      child, //
      parent, //
      projection, //
      styles, //
      residualStyles, //
      classes, //
      residualClasses, //
      classBindings, //
      styleBindings) {
        _classCallCheck(this, TNode$1);

        this.tView_ = tView_;
        this.type = type;
        this.index = index;
        this.injectorIndex = injectorIndex;
        this.directiveStart = directiveStart;
        this.directiveEnd = directiveEnd;
        this.directiveStylingLast = directiveStylingLast;
        this.propertyBindings = propertyBindings;
        this.flags = flags;
        this.providerIndexes = providerIndexes;
        this.tagName = tagName;
        this.attrs = attrs;
        this.mergedAttrs = mergedAttrs;
        this.localNames = localNames;
        this.initialInputs = initialInputs;
        this.inputs = inputs;
        this.outputs = outputs;
        this.tViews = tViews;
        this.next = next;
        this.projectionNext = projectionNext;
        this.child = child;
        this.parent = parent;
        this.projection = projection;
        this.styles = styles;
        this.residualStyles = residualStyles;
        this.classes = classes;
        this.residualClasses = residualClasses;
        this.classBindings = classBindings;
        this.styleBindings = styleBindings;
      }
      /**
       * @return {?}
       */


      _createClass2(TNode$1, [{
        key: "type_",
        get: function get() {
          switch (this.type) {
            case 0
            /* Container */
            :
              return 'TNodeType.Container';

            case 3
            /* Element */
            :
              return 'TNodeType.Element';

            case 4
            /* ElementContainer */
            :
              return 'TNodeType.ElementContainer';

            case 5
            /* IcuContainer */
            :
              return 'TNodeType.IcuContainer';

            case 1
            /* Projection */
            :
              return 'TNodeType.Projection';

            case 2
            /* View */
            :
              return 'TNodeType.View';

            default:
              return 'TNodeType.???';
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "flags_",
        get: function get() {
          /** @type {?} */
          var flags = [];
          if (this.flags & 16
          /* hasClassInput */
          ) flags.push('TNodeFlags.hasClassInput');
          if (this.flags & 8
          /* hasContentQuery */
          ) flags.push('TNodeFlags.hasContentQuery');
          if (this.flags & 32
          /* hasStyleInput */
          ) flags.push('TNodeFlags.hasStyleInput');
          if (this.flags & 128
          /* hasHostBindings */
          ) flags.push('TNodeFlags.hasHostBindings');
          if (this.flags & 2
          /* isComponentHost */
          ) flags.push('TNodeFlags.isComponentHost');
          if (this.flags & 1
          /* isDirectiveHost */
          ) flags.push('TNodeFlags.isDirectiveHost');
          if (this.flags & 64
          /* isDetached */
          ) flags.push('TNodeFlags.isDetached');
          if (this.flags & 4
          /* isProjected */
          ) flags.push('TNodeFlags.isProjected');
          return flags.join('|');
        }
        /**
         * @return {?}
         */

      }, {
        key: "template_",
        get: function get() {
          /** @type {?} */
          var buf = [];
          buf.push('<', this.tagName || this.type_);

          if (this.attrs) {
            for (var i = 0; i < this.attrs.length;) {
              /** @type {?} */
              var attrName = this.attrs[i++];

              if (typeof attrName == 'number') {
                break;
              }
              /** @type {?} */


              var attrValue = this.attrs[i++];
              buf.push(' ',
              /** @type {?} */
              attrName, '="',
              /** @type {?} */
              attrValue, '"');
            }
          }

          buf.push('>');
          processTNodeChildren(this.child, buf);
          buf.push('</', this.tagName || this.type_, '>');
          return buf.join('');
        }
        /**
         * @return {?}
         */

      }, {
        key: "styleBindings_",
        get: function get() {
          return toDebugStyleBinding(this, false);
        }
        /**
         * @return {?}
         */

      }, {
        key: "classBindings_",
        get: function get() {
          return toDebugStyleBinding(this, true);
        }
      }]);

      return TNode$1;
    }();

    if (false) {}
    /** @type {?} */


    var TNodeDebug = TNode$1;
    /**
     * @record
     */

    function DebugStyleBindings() {}
    /**
     * @record
     */


    function DebugStyleBinding() {}

    if (false) {}
    /**
     * @param {?} tNode
     * @param {?} isClassBased
     * @return {?}
     */


    function toDebugStyleBinding(tNode, isClassBased) {
      /** @type {?} */
      var tData = tNode.tView_.data;
      /** @type {?} */

      var bindings =
      /** @type {?} */
      [];
      /** @type {?} */

      var range = isClassBased ? tNode.classBindings : tNode.styleBindings;
      /** @type {?} */

      var prev = getTStylingRangePrev(range);
      /** @type {?} */

      var next = getTStylingRangeNext(range);
      /** @type {?} */

      var isTemplate = next !== 0;
      /** @type {?} */

      var cursor = isTemplate ? next : prev;

      while (cursor !== 0) {
        /** @type {?} */
        var itemKey =
        /** @type {?} */
        tData[cursor];
        /** @type {?} */

        var itemRange =
        /** @type {?} */
        tData[cursor + 1];
        bindings.unshift({
          key: itemKey,
          index: cursor,
          isTemplate: isTemplate,
          prevDuplicate: getTStylingRangePrevDuplicate(itemRange),
          nextDuplicate: getTStylingRangeNextDuplicate(itemRange),
          nextIndex: getTStylingRangeNext(itemRange),
          prevIndex: getTStylingRangePrev(itemRange)
        });
        if (cursor === prev) isTemplate = false;
        cursor = getTStylingRangePrev(itemRange);
      }

      bindings.push((isClassBased ? tNode.residualClasses : tNode.residualStyles) || null);
      return bindings;
    }
    /**
     * @param {?} tNode
     * @param {?} buf
     * @return {?}
     */


    function processTNodeChildren(tNode, buf) {
      while (tNode) {
        buf.push(
        /** @type {?} */

        /** @type {?} */
        tNode.template_);
        tNode = tNode.next;
      }
    }
    /** @type {?} */


    var TViewData = NG_DEV_MODE && createNamedArrayType('TViewData') ||
    /** @type {?} */

    /** @type {?} */
    null;
    /** @type {?} */

    var TVIEWDATA_EMPTY; // can't initialize here or it will not be tree shaken, because
    // `LView` constructor could have side-effects.

    /**
     * This function clones a blueprint and creates TData.
     *
     * Simple slice will keep the same type, and we need it to be TData
     * @param {?} list
     * @return {?}
     */

    function cloneToTViewData(list) {
      if (TVIEWDATA_EMPTY === undefined) TVIEWDATA_EMPTY = new TViewData();
      return (
        /** @type {?} */
        TVIEWDATA_EMPTY.concat(list)
      );
    }
    /** @type {?} */


    var LViewBlueprint = NG_DEV_MODE && createNamedArrayType('LViewBlueprint') ||
    /** @type {?} */

    /** @type {?} */
    null;
    /** @type {?} */

    var MatchesArray = NG_DEV_MODE && createNamedArrayType('MatchesArray') ||
    /** @type {?} */

    /** @type {?} */
    null;
    /** @type {?} */

    var TViewComponents = NG_DEV_MODE && createNamedArrayType('TViewComponents') ||
    /** @type {?} */

    /** @type {?} */
    null;
    /** @type {?} */

    var TNodeLocalNames = NG_DEV_MODE && createNamedArrayType('TNodeLocalNames') ||
    /** @type {?} */

    /** @type {?} */
    null;
    /** @type {?} */

    var TNodeInitialInputs = NG_DEV_MODE && createNamedArrayType('TNodeInitialInputs') ||
    /** @type {?} */

    /** @type {?} */
    null;
    /** @type {?} */

    var TNodeInitialData = NG_DEV_MODE && createNamedArrayType('TNodeInitialData') ||
    /** @type {?} */

    /** @type {?} */
    null;
    /** @type {?} */

    var LCleanup = NG_DEV_MODE && createNamedArrayType('LCleanup') ||
    /** @type {?} */

    /** @type {?} */
    null;
    /** @type {?} */

    var TCleanup = NG_DEV_MODE && createNamedArrayType('TCleanup') ||
    /** @type {?} */

    /** @type {?} */
    null;
    /**
     * @param {?} lView
     * @return {?}
     */

    function attachLViewDebug(lView) {
      attachDebugObject(lView, new LViewDebug(lView));
    }
    /**
     * @param {?} lContainer
     * @return {?}
     */


    function attachLContainerDebug(lContainer) {
      attachDebugObject(lContainer, new LContainerDebug(lContainer));
    }
    /**
     * @param {?} obj
     * @return {?}
     */


    function toDebug(obj) {
      if (obj) {
        /** @type {?} */
        var debug =
        /** @type {?} */
        obj.debug;
        assertDefined(debug, 'Object does not have a debug representation.');
        return debug;
      } else {
        return obj;
      }
    }
    /**
     * Use this method to unwrap a native element in `LView` and convert it into HTML for easier
     * reading.
     *
     * @param {?} value possibly wrapped native DOM node.
     * @param {?=} includeChildren If `true` then the serialized HTML form will include child elements
     * (same
     * as `outerHTML`). If `false` then the serialized HTML form will only contain the element
     * itself
     * (will not serialize child elements).
     * @return {?}
     */


    function toHtml(value) {
      var includeChildren = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;

      /** @type {?} */
      var node =
      /** @type {?} */
      unwrapRNode(value);

      if (node) {
        /** @type {?} */
        var isTextNode = node.nodeType === Node.TEXT_NODE;
        /** @type {?} */

        var outerHTML = (isTextNode ? node.textContent : node.outerHTML) || '';

        if (includeChildren || isTextNode) {
          return outerHTML;
        } else {
          /** @type {?} */
          var innerHTML = '>' + node.innerHTML + '<';
          return outerHTML.split(innerHTML)[0] + '>';
        }
      } else {
        return null;
      }
    }

    var LViewDebug = /*#__PURE__*/function () {
      /**
       * @param {?} _raw_lView
       */
      function LViewDebug(_raw_lView) {
        _classCallCheck(this, LViewDebug);

        this._raw_lView = _raw_lView;
      }
      /**
       * Flags associated with the `LView` unpacked into a more readable state.
       * @return {?}
       */


      _createClass2(LViewDebug, [{
        key: "flags",
        get: function get() {
          /** @type {?} */
          var flags = this._raw_lView[FLAGS];
          return {
            __raw__flags__: flags,
            initPhaseState: flags & 3
            /* InitPhaseStateMask */
            ,
            creationMode: !!(flags & 4
            /* CreationMode */
            ),
            firstViewPass: !!(flags & 8
            /* FirstLViewPass */
            ),
            checkAlways: !!(flags & 16
            /* CheckAlways */
            ),
            dirty: !!(flags & 64
            /* Dirty */
            ),
            attached: !!(flags & 128
            /* Attached */
            ),
            destroyed: !!(flags & 256
            /* Destroyed */
            ),
            isRoot: !!(flags & 512
            /* IsRoot */
            ),
            indexWithinInitPhase: flags >> 10
            /* IndexWithinInitPhaseShift */

          };
        }
        /**
         * @return {?}
         */

      }, {
        key: "parent",
        get: function get() {
          return toDebug(this._raw_lView[PARENT]);
        }
        /**
         * @return {?}
         */

      }, {
        key: "host",
        get: function get() {
          return toHtml(this._raw_lView[HOST], true);
        }
        /**
         * @return {?}
         */

      }, {
        key: "html",
        get: function get() {
          return (this.nodes || []).map(
          /**
          * @param {?} node
          * @return {?}
          */
          function (node) {
            return toHtml(node["native"], true);
          }).join('');
        }
        /**
         * @return {?}
         */

      }, {
        key: "context",
        get: function get() {
          return this._raw_lView[CONTEXT];
        }
        /**
         * The tree of nodes associated with the current `LView`. The nodes have been normalized into
         * a
         * tree structure with relevant details pulled out for readability.
         * @return {?}
         */

      }, {
        key: "nodes",
        get: function get() {
          /** @type {?} */
          var lView = this._raw_lView;
          /** @type {?} */

          var tNode = lView[TVIEW].firstChild;
          return toDebugNodes(tNode, lView);
        }
        /**
         * @return {?}
         */

      }, {
        key: "tView",
        get: function get() {
          return this._raw_lView[TVIEW];
        }
        /**
         * @return {?}
         */

      }, {
        key: "cleanup",
        get: function get() {
          return this._raw_lView[CLEANUP];
        }
        /**
         * @return {?}
         */

      }, {
        key: "injector",
        get: function get() {
          return this._raw_lView[INJECTOR$1];
        }
        /**
         * @return {?}
         */

      }, {
        key: "rendererFactory",
        get: function get() {
          return this._raw_lView[RENDERER_FACTORY];
        }
        /**
         * @return {?}
         */

      }, {
        key: "renderer",
        get: function get() {
          return this._raw_lView[RENDERER];
        }
        /**
         * @return {?}
         */

      }, {
        key: "sanitizer",
        get: function get() {
          return this._raw_lView[SANITIZER];
        }
        /**
         * @return {?}
         */

      }, {
        key: "childHead",
        get: function get() {
          return toDebug(this._raw_lView[CHILD_HEAD]);
        }
        /**
         * @return {?}
         */

      }, {
        key: "next",
        get: function get() {
          return toDebug(this._raw_lView[NEXT]);
        }
        /**
         * @return {?}
         */

      }, {
        key: "childTail",
        get: function get() {
          return toDebug(this._raw_lView[CHILD_TAIL]);
        }
        /**
         * @return {?}
         */

      }, {
        key: "declarationView",
        get: function get() {
          return toDebug(this._raw_lView[DECLARATION_VIEW]);
        }
        /**
         * @return {?}
         */

      }, {
        key: "queries",
        get: function get() {
          return this._raw_lView[QUERIES];
        }
        /**
         * @return {?}
         */

      }, {
        key: "tHost",
        get: function get() {
          return this._raw_lView[T_HOST];
        }
        /**
         * Normalized view of child views (and containers) attached at this location.
         * @return {?}
         */

      }, {
        key: "childViews",
        get: function get() {
          /** @type {?} */
          var childViews = [];
          /** @type {?} */

          var child = this.childHead;

          while (child) {
            childViews.push(child);
            child = child.next;
          }

          return childViews;
        }
      }]);

      return LViewDebug;
    }();

    if (false) {}
    /**
     * @record
     */


    function DebugNode() {}

    if (false) {}
    /**
     * Turns a flat list of nodes into a tree by walking the associated `TNode` tree.
     *
     * @param {?} tNode
     * @param {?} lView
     * @return {?}
     */


    function toDebugNodes(tNode, lView) {
      if (tNode) {
        /** @type {?} */
        var debugNodes = [];
        /** @type {?} */

        var tNodeCursor = tNode;

        while (tNodeCursor) {
          debugNodes.push(buildDebugNode(tNodeCursor, lView, tNodeCursor.index));
          tNodeCursor = tNodeCursor.next;
        }

        return debugNodes;
      } else {
        return null;
      }
    }
    /**
     * @param {?} tNode
     * @param {?} lView
     * @param {?} nodeIndex
     * @return {?}
     */


    function buildDebugNode(tNode, lView, nodeIndex) {
      /** @type {?} */
      var rawValue = lView[nodeIndex];
      /** @type {?} */

      var _native6 = unwrapRNode(rawValue);
      /** @type {?} */


      var componentLViewDebug = toDebug(readLViewValue(rawValue));
      return {
        html: toHtml(_native6),
        "native":
        /** @type {?} */
        _native6,
        nodes: toDebugNodes(tNode.child, lView),
        component: componentLViewDebug
      };
    }

    var LContainerDebug = /*#__PURE__*/function () {
      /**
       * @param {?} _raw_lContainer
       */
      function LContainerDebug(_raw_lContainer) {
        _classCallCheck(this, LContainerDebug);

        this._raw_lContainer = _raw_lContainer;
      }
      /**
       * @return {?}
       */


      _createClass2(LContainerDebug, [{
        key: "activeIndex",
        get: function get() {
          return getLContainerActiveIndex(this._raw_lContainer);
        }
        /**
         * @return {?}
         */

      }, {
        key: "hasTransplantedViews",
        get: function get() {
          return (this._raw_lContainer[ACTIVE_INDEX] & 1
          /* HAS_TRANSPLANTED_VIEWS */
          ) === 1
          /* HAS_TRANSPLANTED_VIEWS */
          ;
        }
        /**
         * @return {?}
         */

      }, {
        key: "views",
        get: function get() {
          return this._raw_lContainer.slice(CONTAINER_HEADER_OFFSET).map(
          /** @type {?} */
          toDebug);
        }
        /**
         * @return {?}
         */

      }, {
        key: "parent",
        get: function get() {
          return toDebug(this._raw_lContainer[PARENT]);
        }
        /**
         * @return {?}
         */

      }, {
        key: "movedViews",
        get: function get() {
          return this._raw_lContainer[MOVED_VIEWS];
        }
        /**
         * @return {?}
         */

      }, {
        key: "host",
        get: function get() {
          return this._raw_lContainer[HOST];
        }
        /**
         * @return {?}
         */

      }, {
        key: "native",
        get: function get() {
          return this._raw_lContainer[NATIVE];
        }
        /**
         * @return {?}
         */

      }, {
        key: "next",
        get: function get() {
          return toDebug(this._raw_lContainer[NEXT]);
        }
      }]);

      return LContainerDebug;
    }();

    if (false) {}
    /**
     * Return an `LView` value if found.
     *
     * @param {?} value `LView` if any
     * @return {?}
     */


    function readLViewValue(value) {
      while (Array.isArray(value)) {
        // This check is not quite right, as it does not take into account `StylingContext`
        // This is why it is in debug, not in util.ts
        if (value.length >= HEADER_OFFSET - 1) return (
          /** @type {?} */
          value
        );
        value = value[HOST];
      }

      return null;
    }

    var I18NDebugItem = /*#__PURE__*/function () {
      /**
       * @param {?} __raw_opCode
       * @param {?} _lView
       * @param {?} nodeIndex
       * @param {?} type
       */
      function I18NDebugItem(__raw_opCode, _lView, nodeIndex, type) {
        _classCallCheck(this, I18NDebugItem);

        this.__raw_opCode = __raw_opCode;
        this._lView = _lView;
        this.nodeIndex = nodeIndex;
        this.type = type;
      }
      /**
       * @return {?}
       */


      _createClass2(I18NDebugItem, [{
        key: "tNode",
        get: function get() {
          return getTNode(this._lView[TVIEW], this.nodeIndex);
        }
      }]);

      return I18NDebugItem;
    }();

    if (false) {}
    /**
     * Turns a list of "Create" & "Update" OpCodes into a human-readable list of operations for
     * debugging purposes.
     * @param {?} mutateOpCodes mutation opCodes to read
     * @param {?} updateOpCodes update opCodes to read
     * @param {?} icus list of ICU expressions
     * @param {?} lView The view the opCodes are acting on
     * @return {?}
     */


    function attachI18nOpCodesDebug(mutateOpCodes, updateOpCodes, icus, lView) {
      attachDebugObject(mutateOpCodes, new I18nMutateOpCodesDebug(mutateOpCodes, lView));
      attachDebugObject(updateOpCodes, new I18nUpdateOpCodesDebug(updateOpCodes, icus, lView));

      if (icus) {
        icus.forEach(
        /**
        * @param {?} icu
        * @return {?}
        */
        function (icu) {
          icu.create.forEach(
          /**
          * @param {?} icuCase
          * @return {?}
          */
          function (icuCase) {
            attachDebugObject(icuCase, new I18nMutateOpCodesDebug(icuCase, lView));
          });
          icu.update.forEach(
          /**
          * @param {?} icuCase
          * @return {?}
          */
          function (icuCase) {
            attachDebugObject(icuCase, new I18nUpdateOpCodesDebug(icuCase, icus, lView));
          });
        });
      }
    }

    var I18nMutateOpCodesDebug = /*#__PURE__*/function () {
      /**
       * @param {?} __raw_opCodes
       * @param {?} __lView
       */
      function I18nMutateOpCodesDebug(__raw_opCodes, __lView) {
        _classCallCheck(this, I18nMutateOpCodesDebug);

        this.__raw_opCodes = __raw_opCodes;
        this.__lView = __lView;
      }
      /**
       * A list of operation information about how the OpCodes will act on the view.
       * @return {?}
       */


      _createClass2(I18nMutateOpCodesDebug, [{
        key: "operations",
        get: function get() {
          var __lView = this.__lView,
              __raw_opCodes = this.__raw_opCodes;
          /** @type {?} */

          var results = [];

          for (var i = 0; i < __raw_opCodes.length; i++) {
            /** @type {?} */
            var opCode = __raw_opCodes[i];
            /** @type {?} */

            var result = void 0;

            if (typeof opCode === 'string') {
              result = {
                __raw_opCode: opCode,
                type: 'Create Text Node',
                nodeIndex: __raw_opCodes[++i],
                text: opCode
              };
            }

            if (typeof opCode === 'number') {
              switch (opCode & 7
              /* MASK_OPCODE */
              ) {
                case 1
                /* AppendChild */
                :
                  /** @type {?} */
                  var destinationNodeIndex = opCode >>> 17
                  /* SHIFT_PARENT */
                  ;
                  result = new I18NDebugItem(opCode, __lView, destinationNodeIndex, 'AppendChild');
                  break;

                case 0
                /* Select */
                :
                  /** @type {?} */
                  var nodeIndex = opCode >>> 3
                  /* SHIFT_REF */
                  ;
                  result = new I18NDebugItem(opCode, __lView, nodeIndex, 'Select');
                  break;

                case 5
                /* ElementEnd */
                :
                  /** @type {?} */
                  var elementIndex = opCode >>> 3
                  /* SHIFT_REF */
                  ;
                  result = new I18NDebugItem(opCode, __lView, elementIndex, 'ElementEnd');
                  break;

                case 4
                /* Attr */
                :
                  elementIndex = opCode >>> 3
                  /* SHIFT_REF */
                  ;
                  result = new I18NDebugItem(opCode, __lView, elementIndex, 'Attr');
                  result['attrName'] = __raw_opCodes[++i];
                  result['attrValue'] = __raw_opCodes[++i];
                  break;
              }
            }

            if (!result) {
              switch (opCode) {
                case COMMENT_MARKER:
                  result = {
                    __raw_opCode: opCode,
                    type: 'COMMENT_MARKER',
                    commentValue: __raw_opCodes[++i],
                    nodeIndex: __raw_opCodes[++i]
                  };
                  break;

                case ELEMENT_MARKER:
                  result = {
                    __raw_opCode: opCode,
                    type: 'ELEMENT_MARKER'
                  };
                  break;
              }
            }

            if (!result) {
              result = {
                __raw_opCode: opCode,
                type: 'Unknown Op Code',
                code: opCode
              };
            }

            results.push(result);
          }

          return results;
        }
      }]);

      return I18nMutateOpCodesDebug;
    }();

    if (false) {}

    var I18nUpdateOpCodesDebug = /*#__PURE__*/function () {
      /**
       * @param {?} __raw_opCodes
       * @param {?} icus
       * @param {?} __lView
       */
      function I18nUpdateOpCodesDebug(__raw_opCodes, icus, __lView) {
        _classCallCheck(this, I18nUpdateOpCodesDebug);

        this.__raw_opCodes = __raw_opCodes;
        this.icus = icus;
        this.__lView = __lView;
      }
      /**
       * A list of operation information about how the OpCodes will act on the view.
       * @return {?}
       */


      _createClass2(I18nUpdateOpCodesDebug, [{
        key: "operations",
        get: function get() {
          var __lView = this.__lView,
              __raw_opCodes = this.__raw_opCodes,
              icus = this.icus;
          /** @type {?} */

          var results = [];

          for (var i = 0; i < __raw_opCodes.length; i++) {
            // bit code to check if we should apply the next update

            /** @type {?} */
            var checkBit =
            /** @type {?} */
            __raw_opCodes[i]; // Number of opCodes to skip until next set of update codes

            /** @type {?} */

            var skipCodes =
            /** @type {?} */
            __raw_opCodes[++i];
            /** @type {?} */

            var value = '';

            for (var j = i + 1; j <= i + skipCodes; j++) {
              /** @type {?} */
              var opCode = __raw_opCodes[j];

              if (typeof opCode === 'string') {
                value += opCode;
              } else if (typeof opCode == 'number') {
                if (opCode < 0) {
                  // It's a binding index whose value is negative
                  // We cannot know the value of the binding so we only show the index
                  value += "\uFFFD".concat(-opCode - 1, "\uFFFD");
                } else {
                  /** @type {?} */
                  var nodeIndex = opCode >>> 2
                  /* SHIFT_REF */
                  ;
                  /** @type {?} */

                  var tIcuIndex = void 0;
                  /** @type {?} */

                  var tIcu = void 0;

                  switch (opCode & 3
                  /* MASK_OPCODE */
                  ) {
                    case 1
                    /* Attr */
                    :
                      /** @type {?} */
                      var attrName =
                      /** @type {?} */
                      __raw_opCodes[++j];
                      /** @type {?} */

                      var sanitizeFn = __raw_opCodes[++j];
                      results.push({
                        __raw_opCode: opCode,
                        checkBit: checkBit,
                        type: 'Attr',
                        attrValue: value,
                        attrName: attrName,
                        sanitizeFn: sanitizeFn
                      });
                      break;

                    case 0
                    /* Text */
                    :
                      results.push({
                        __raw_opCode: opCode,
                        checkBit: checkBit,
                        type: 'Text',
                        nodeIndex: nodeIndex,
                        text: value
                      });
                      break;

                    case 2
                    /* IcuSwitch */
                    :
                      tIcuIndex =
                      /** @type {?} */
                      __raw_opCodes[++j];
                      tIcu =
                      /** @type {?} */
                      icus[tIcuIndex];
                      /** @type {?} */

                      var result = new I18NDebugItem(opCode, __lView, nodeIndex, 'IcuSwitch');
                      result['tIcuIndex'] = tIcuIndex;
                      result['checkBit'] = checkBit;
                      result['mainBinding'] = value;
                      result['tIcu'] = tIcu;
                      results.push(result);
                      break;

                    case 3
                    /* IcuUpdate */
                    :
                      tIcuIndex =
                      /** @type {?} */
                      __raw_opCodes[++j];
                      tIcu =
                      /** @type {?} */
                      icus[tIcuIndex];
                      result = new I18NDebugItem(opCode, __lView, nodeIndex, 'IcuUpdate');
                      result['tIcuIndex'] = tIcuIndex;
                      result['checkBit'] = checkBit;
                      result['tIcu'] = tIcu;
                      results.push(result);
                      break;
                  }
                }
              }
            }

            i += skipCodes;
          }

          return results;
        }
      }]);

      return I18nUpdateOpCodesDebug;
    }();

    if (false) {}
    /**
     * @record
     */


    function I18nOpCodesDebug() {}

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/shared.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var ɵ0$4 =
    /**
    * @return {?}
    */
    function ɵ0$4() {
      return Promise.resolve(null);
    };
    /**
     * A permanent marker promise which signifies that the current CD tree is
     * clean.
     * @type {?}
     */


    var _CLEAN_PROMISE = ɵ0$4();
    /**
     * Process the `TView.expandoInstructions`. (Execute the `hostBindings`.)
     *
     * @param {?} tView `TView` containing the `expandoInstructions`
     * @param {?} lView `LView` associated with the `TView`
     * @return {?}
     */


    function setHostBindingsByExecutingExpandoInstructions(tView, lView) {
      ngDevMode && assertSame(tView, lView[TVIEW], '`LView` is not associated with the `TView`!');

      try {
        /** @type {?} */
        var expandoInstructions = tView.expandoInstructions;

        if (expandoInstructions !== null) {
          /** @type {?} */
          var bindingRootIndex = tView.expandoStartIndex;
          /** @type {?} */

          var currentDirectiveIndex = -1;
          /** @type {?} */

          var currentElementIndex = -1; // TODO(misko): PERF It is possible to get here with `TView.expandoInstructions` containing no
          // functions to execute. This is wasteful as there is no work to be done, but we still need
          // to iterate over the instructions.
          // In example of this is in this test: `host_binding_spec.ts`
          // `fit('should not cause problems if detectChanges is called when a property updates', ...`
          // In the above test we get here with expando [0, 0, 1] which requires a lot of processing but
          // there is no function to execute.

          for (var i = 0; i < expandoInstructions.length; i++) {
            /** @type {?} */
            var instruction = expandoInstructions[i];

            if (typeof instruction === 'number') {
              if (instruction <= 0) {
                // Negative numbers mean that we are starting new EXPANDO block and need to update
                // the current element and directive index.
                // Important: In JS `-x` and `0-x` is not the same! If `x===0` then `-x` will produce
                // `-0` which requires non standard math arithmetic and it can prevent VM optimizations.
                // `0-0` will always produce `0` and will not cause a potential deoptimization in VM.
                // TODO(misko): PERF This should be refactored to use `~instruction` as that does not
                // suffer from `-0` and it is faster/more compact.
                currentElementIndex = 0 - instruction;
                setSelectedIndex(currentElementIndex); // Injector block and providers are taken into account.

                /** @type {?} */

                var providerCount =
                /** @type {?} */
                expandoInstructions[++i];
                bindingRootIndex += INJECTOR_BLOOM_PARENT_SIZE + providerCount;
                currentDirectiveIndex = bindingRootIndex;
              } else {
                // This is either the injector size (so the binding root can skip over directives
                // and get to the first set of host bindings on this node) or the host var count
                // (to get to the next set of host bindings on this node).
                bindingRootIndex += instruction;
              }
            } else {
              // If it's not a number, it's a host binding function that needs to be executed.
              if (instruction !== null) {
                setBindingRootForHostBindings(bindingRootIndex, currentDirectiveIndex);
                /** @type {?} */

                var hostCtx = lView[currentDirectiveIndex];
                instruction(2
                /* Update */
                , hostCtx);
              } // TODO(misko): PERF Relying on incrementing the `currentDirectiveIndex` here is
              // sub-optimal. The implications are that if we have a lot of directives but none of them
              // have host bindings we nevertheless need to iterate over the expando instructions to
              // update the counter. It would be much better if we could encode the
              // `currentDirectiveIndex` into the `expandoInstruction` array so that we only need to
              // iterate over those directives which actually have `hostBindings`.


              currentDirectiveIndex++;
            }
          }
        }
      } finally {
        setSelectedIndex(-1);
      }
    }
    /**
     * Refreshes all content queries declared by directives in a given view
     * @param {?} tView
     * @param {?} lView
     * @return {?}
     */


    function refreshContentQueries(tView, lView) {
      /** @type {?} */
      var contentQueries = tView.contentQueries;

      if (contentQueries !== null) {
        for (var i = 0; i < contentQueries.length; i += 2) {
          /** @type {?} */
          var queryStartIdx = contentQueries[i];
          /** @type {?} */

          var directiveDefIdx = contentQueries[i + 1];

          if (directiveDefIdx !== -1) {
            /** @type {?} */
            var _directiveDef2 =
            /** @type {?} */
            tView.data[directiveDefIdx];
            ngDevMode && assertDefined(_directiveDef2.contentQueries, 'contentQueries function should be defined');
            setCurrentQueryIndex(queryStartIdx);

            /** @type {?} */
            _directiveDef2.contentQueries(2
            /* Update */
            , lView[directiveDefIdx], directiveDefIdx);
          }
        }
      }
    }
    /**
     * Refreshes child components in the current view (update mode).
     * @param {?} hostLView
     * @param {?} components
     * @return {?}
     */


    function refreshChildComponents(hostLView, components) {
      for (var i = 0; i < components.length; i++) {
        refreshComponent(hostLView, components[i]);
      }
    }
    /**
     * Renders child components in the current view (creation mode).
     * @param {?} hostLView
     * @param {?} components
     * @return {?}
     */


    function renderChildComponents(hostLView, components) {
      for (var i = 0; i < components.length; i++) {
        renderComponent(hostLView, components[i]);
      }
    }
    /**
     * Creates a native element from a tag name, using a renderer.
     * @param {?} name the tag name
     * @param {?} renderer A renderer to use
     * @param {?} namespace
     * @return {?} the element created
     */


    function elementCreate(name, renderer, namespace) {
      if (isProceduralRenderer(renderer)) {
        return renderer.createElement(name, namespace);
      } else {
        return namespace === null ? renderer.createElement(name) : renderer.createElementNS(namespace, name);
      }
    }
    /**
     * @template T
     * @param {?} parentLView
     * @param {?} tView
     * @param {?} context
     * @param {?} flags
     * @param {?} host
     * @param {?} tHostNode
     * @param {?=} rendererFactory
     * @param {?=} renderer
     * @param {?=} sanitizer
     * @param {?=} injector
     * @return {?}
     */


    function createLView(parentLView, tView, context, flags, host, tHostNode, rendererFactory, renderer, sanitizer, injector) {
      /** @type {?} */
      var lView = ngDevMode ? cloneToLViewFromTViewBlueprint(tView) :
      /** @type {?} */
      tView.blueprint.slice();
      lView[HOST] = host;
      lView[FLAGS] = flags | 4
      /* CreationMode */
      | 128
      /* Attached */
      | 8
      /* FirstLViewPass */
      ;
      resetPreOrderHookFlags(lView);
      lView[PARENT] = lView[DECLARATION_VIEW] = parentLView;
      lView[CONTEXT] = context;
      lView[RENDERER_FACTORY] =
      /** @type {?} */
      rendererFactory || parentLView && parentLView[RENDERER_FACTORY];
      ngDevMode && assertDefined(lView[RENDERER_FACTORY], 'RendererFactory is required');
      lView[RENDERER] =
      /** @type {?} */
      renderer || parentLView && parentLView[RENDERER];
      ngDevMode && assertDefined(lView[RENDERER], 'Renderer is required');
      lView[SANITIZER] = sanitizer || parentLView && parentLView[SANITIZER] ||
      /** @type {?} */
      null;
      lView[
      /** @type {?} */
      INJECTOR$1] = injector || parentLView && parentLView[INJECTOR$1] || null;
      lView[T_HOST] = tHostNode;
      ngDevMode && assertEqual(tView.type == 2
      /* Embedded */
      ? parentLView !== null : true, true, 'Embedded views must have parentLView');
      lView[DECLARATION_COMPONENT_VIEW] = tView.type == 2
      /* Embedded */
      ?
      /** @type {?} */
      parentLView[DECLARATION_COMPONENT_VIEW] : lView;
      ngDevMode && attachLViewDebug(lView);
      return lView;
    }
    /**
     * @param {?} tView
     * @param {?} tHostNode
     * @param {?} index
     * @param {?} type
     * @param {?} name
     * @param {?} attrs
     * @return {?}
     */


    function getOrCreateTNode(tView, tHostNode, index, type, name, attrs) {
      // Keep this function short, so that the VM will inline it.

      /** @type {?} */
      var adjustedIndex = index + HEADER_OFFSET;
      /** @type {?} */

      var tNode =
      /** @type {?} */
      tView.data[adjustedIndex] || createTNodeAtIndex(tView, tHostNode, adjustedIndex, type, name, attrs);
      setPreviousOrParentTNode(tNode, true);
      return (
        /** @type {?} */
        tNode
      );
    }
    /**
     * @param {?} tView
     * @param {?} tHostNode
     * @param {?} adjustedIndex
     * @param {?} type
     * @param {?} name
     * @param {?} attrs
     * @return {?}
     */


    function createTNodeAtIndex(tView, tHostNode, adjustedIndex, type, name, attrs) {
      /** @type {?} */
      var previousOrParentTNode = getPreviousOrParentTNode();
      /** @type {?} */

      var isParent = getIsParent();
      /** @type {?} */

      var parent = isParent ? previousOrParentTNode : previousOrParentTNode && previousOrParentTNode.parent; // Parents cannot cross component boundaries because components will be used in multiple places,
      // so it's only set if the view is the same.

      /** @type {?} */

      var parentInSameView = parent && parent !== tHostNode;
      /** @type {?} */

      var tParentNode = parentInSameView ?
      /** @type {?} */
      parent : null;
      /** @type {?} */

      var tNode = tView.data[adjustedIndex] = createTNode(tView, tParentNode, type, adjustedIndex, name, attrs); // Assign a pointer to the first child node of a given view. The first node is not always the one
      // at index 0, in case of i18n, index 0 can be the instruction `i18nStart` and the first node has
      // the index 1 or more, so we can't just check node index.

      if (tView.firstChild === null) {
        tView.firstChild = tNode;
      }

      if (previousOrParentTNode) {
        if (isParent && previousOrParentTNode.child == null && (tNode.parent !== null || previousOrParentTNode.type === 2
        /* View */
        )) {
          // We are in the same view, which means we are adding content node to the parent view.
          previousOrParentTNode.child = tNode;
        } else if (!isParent) {
          previousOrParentTNode.next = tNode;
        }
      }

      return tNode;
    }
    /**
     * @param {?} tView
     * @param {?} tParentNode
     * @param {?} index
     * @param {?} lView
     * @return {?}
     */


    function assignTViewNodeToLView(tView, tParentNode, index, lView) {
      // View nodes are not stored in data because they can be added / removed at runtime (which
      // would cause indices to change). Their TNodes are instead stored in tView.node.

      /** @type {?} */
      var tNode = tView.node;

      if (tNode == null) {
        ngDevMode && tParentNode && assertNodeOfPossibleTypes(tParentNode, 3
        /* Element */
        , 0
        /* Container */
        );
        tView.node = tNode =
        /** @type {?} */
        createTNode(tView,
        /** @type {?} */
        tParentNode, //
        2
        /* View */
        , index, null, null);
      }

      return lView[T_HOST] =
      /** @type {?} */
      tNode;
    }
    /**
     * When elements are created dynamically after a view blueprint is created (e.g. through
     * i18nApply() or ComponentFactory.create), we need to adjust the blueprint for future
     * template passes.
     *
     * @param {?} tView `TView` associated with `LView`
     * @param {?} lView
     * @param {?} numSlotsToAlloc The number of slots to alloc in the LView, should be >0
     * @return {?}
     */


    function allocExpando(tView, lView, numSlotsToAlloc) {
      ngDevMode && assertGreaterThan(numSlotsToAlloc, 0, 'The number of slots to alloc should be greater than 0');

      if (numSlotsToAlloc > 0) {
        if (tView.firstCreatePass) {
          for (var i = 0; i < numSlotsToAlloc; i++) {
            tView.blueprint.push(null);
            tView.data.push(null);
            lView.push(null);
          } // We should only increment the expando start index if there aren't already directives
          // and injectors saved in the "expando" section


          if (!tView.expandoInstructions) {
            tView.expandoStartIndex += numSlotsToAlloc;
          } else {
            // Since we're adding the dynamic nodes into the expando section, we need to let the host
            // bindings know that they should skip x slots
            tView.expandoInstructions.push(numSlotsToAlloc);
          }
        }
      }
    } //////////////////////////
    //// Render
    //////////////////////////

    /**
     * Processes a view in the creation mode. This includes a number of steps in a specific order:
     * - creating view query functions (if any);
     * - executing a template function in the creation mode;
     * - updating static queries (if any);
     * - creating child components defined in a given view.
     * @template T
     * @param {?} tView
     * @param {?} lView
     * @param {?} context
     * @return {?}
     */


    function renderView(tView, lView, context) {
      ngDevMode && assertEqual(isCreationMode(lView), true, 'Should be run in creation mode');
      enterView(lView, lView[T_HOST]);

      try {
        /** @type {?} */
        var viewQuery = tView.viewQuery;

        if (viewQuery !== null) {
          executeViewQueryFn(1
          /* Create */
          , viewQuery, context);
        } // Execute a template associated with this view, if it exists. A template function might not be
        // defined for the root component views.

        /** @type {?} */


        var templateFn = tView.template;

        if (templateFn !== null) {
          executeTemplate(tView, lView, templateFn, 1
          /* Create */
          , context);
        } // This needs to be set before children are processed to support recursive components.
        // This must be set to false immediately after the first creation run because in an
        // ngFor loop, all the views will be created together before update mode runs and turns
        // off firstCreatePass. If we don't set it here, instances will perform directive
        // matching, etc again and again.


        if (tView.firstCreatePass) {
          tView.firstCreatePass = false;
        } // We resolve content queries specifically marked as `static` in creation mode. Dynamic
        // content queries are resolved during change detection (i.e. update mode), after embedded
        // views are refreshed (see block above).


        if (tView.staticContentQueries) {
          refreshContentQueries(tView, lView);
        } // We must materialize query results before child components are processed
        // in case a child component has projected a container. The LContainer needs
        // to exist so the embedded views are properly attached by the container.


        if (tView.staticViewQueries) {
          executeViewQueryFn(2
          /* Update */
          ,
          /** @type {?} */
          tView.viewQuery, context);
        } // Render child component views.

        /** @type {?} */


        var components = tView.components;

        if (components !== null) {
          renderChildComponents(lView, components);
        }
      } catch (error) {
        // If we didn't manage to get past the first template pass due to
        // an error, mark the view as corrupted so we can try to recover.
        if (tView.firstCreatePass) {
          tView.incompleteFirstPass = true;
        }

        throw error;
      } finally {
        lView[FLAGS] &= ~4
        /* CreationMode */
        ;
        leaveView();
      }
    }
    /**
     * Processes a view in update mode. This includes a number of steps in a specific order:
     * - executing a template function in update mode;
     * - executing hooks;
     * - refreshing queries;
     * - setting host bindings;
     * - refreshing child (embedded and component) views.
     * @template T
     * @param {?} tView
     * @param {?} lView
     * @param {?} templateFn
     * @param {?} context
     * @return {?}
     */


    function refreshView(tView, lView, templateFn, context) {
      ngDevMode && assertEqual(isCreationMode(lView), false, 'Should be run in update mode');
      /** @type {?} */

      var flags = lView[FLAGS];
      if ((flags & 256
      /* Destroyed */
      ) === 256
      /* Destroyed */
      ) return;
      enterView(lView, lView[T_HOST]);
      /** @type {?} */

      var checkNoChangesMode = getCheckNoChangesMode();

      try {
        resetPreOrderHookFlags(lView);
        setBindingIndex(tView.bindingStartIndex);

        if (templateFn !== null) {
          executeTemplate(tView, lView, templateFn, 2
          /* Update */
          , context);
        }
        /** @type {?} */


        var hooksInitPhaseCompleted = (flags & 3
        /* InitPhaseStateMask */
        ) === 3
        /* InitPhaseCompleted */
        ; // execute pre-order hooks (OnInit, OnChanges, DoCheck)
        // PERF WARNING: do NOT extract this to a separate function without running benchmarks

        if (!checkNoChangesMode) {
          if (hooksInitPhaseCompleted) {
            /** @type {?} */
            var preOrderCheckHooks = tView.preOrderCheckHooks;

            if (preOrderCheckHooks !== null) {
              executeCheckHooks(lView, preOrderCheckHooks, null);
            }
          } else {
            /** @type {?} */
            var preOrderHooks = tView.preOrderHooks;

            if (preOrderHooks !== null) {
              executeInitAndCheckHooks(lView, preOrderHooks, 0
              /* OnInitHooksToBeRun */
              , null);
            }

            incrementInitPhaseFlags(lView, 0
            /* OnInitHooksToBeRun */
            );
          }
        }

        refreshDynamicEmbeddedViews(lView); // Content query results must be refreshed before content hooks are called.

        if (tView.contentQueries !== null) {
          refreshContentQueries(tView, lView);
        } // execute content hooks (AfterContentInit, AfterContentChecked)
        // PERF WARNING: do NOT extract this to a separate function without running benchmarks


        if (!checkNoChangesMode) {
          if (hooksInitPhaseCompleted) {
            /** @type {?} */
            var contentCheckHooks = tView.contentCheckHooks;

            if (contentCheckHooks !== null) {
              executeCheckHooks(lView, contentCheckHooks);
            }
          } else {
            /** @type {?} */
            var contentHooks = tView.contentHooks;

            if (contentHooks !== null) {
              executeInitAndCheckHooks(lView, contentHooks, 1
              /* AfterContentInitHooksToBeRun */
              );
            }

            incrementInitPhaseFlags(lView, 1
            /* AfterContentInitHooksToBeRun */
            );
          }
        }

        setHostBindingsByExecutingExpandoInstructions(tView, lView); // Refresh child component views.

        /** @type {?} */

        var components = tView.components;

        if (components !== null) {
          refreshChildComponents(lView, components);
        } // View queries must execute after refreshing child components because a template in this view
        // could be inserted in a child component. If the view query executes before child component
        // refresh, the template might not yet be inserted.

        /** @type {?} */


        var viewQuery = tView.viewQuery;

        if (viewQuery !== null) {
          executeViewQueryFn(2
          /* Update */
          , viewQuery, context);
        } // execute view hooks (AfterViewInit, AfterViewChecked)
        // PERF WARNING: do NOT extract this to a separate function without running benchmarks


        if (!checkNoChangesMode) {
          if (hooksInitPhaseCompleted) {
            /** @type {?} */
            var viewCheckHooks = tView.viewCheckHooks;

            if (viewCheckHooks !== null) {
              executeCheckHooks(lView, viewCheckHooks);
            }
          } else {
            /** @type {?} */
            var viewHooks = tView.viewHooks;

            if (viewHooks !== null) {
              executeInitAndCheckHooks(lView, viewHooks, 2
              /* AfterViewInitHooksToBeRun */
              );
            }

            incrementInitPhaseFlags(lView, 2
            /* AfterViewInitHooksToBeRun */
            );
          }
        }

        if (tView.firstUpdatePass === true) {
          // We need to make sure that we only flip the flag on successful `refreshView` only
          // Don't do this in `finally` block.
          // If we did this in `finally` block then an exception could block the execution of styling
          // instructions which in turn would be unable to insert themselves into the styling linked
          // list. The result of this would be that if the exception would not be throw on subsequent CD
          // the styling would be unable to process it data and reflect to the DOM.
          tView.firstUpdatePass = false;
        } // Do not reset the dirty state when running in check no changes mode. We don't want components
        // to behave differently depending on whether check no changes is enabled or not. For example:
        // Marking an OnPush component as dirty from within the `ngAfterViewInit` hook in order to
        // refresh a `NgClass` binding should work. If we would reset the dirty state in the check
        // no changes cycle, the component would be not be dirty for the next update pass. This would
        // be different in production mode where the component dirty state is not reset.


        if (!checkNoChangesMode) {
          lView[FLAGS] &= ~(64
          /* Dirty */
          | 8
          /* FirstLViewPass */
          );
        }
      } finally {
        leaveView();
      }
    }
    /**
     * @template T
     * @param {?} tView
     * @param {?} lView
     * @param {?} templateFn
     * @param {?} context
     * @return {?}
     */


    function renderComponentOrTemplate(tView, lView, templateFn, context) {
      /** @type {?} */
      var rendererFactory = lView[RENDERER_FACTORY];
      /** @type {?} */

      var normalExecutionPath = !getCheckNoChangesMode();
      /** @type {?} */

      var creationModeIsActive = isCreationMode(lView);

      try {
        if (normalExecutionPath && !creationModeIsActive && rendererFactory.begin) {
          rendererFactory.begin();
        }

        if (creationModeIsActive) {
          renderView(tView, lView, context);
        }

        refreshView(tView, lView, templateFn, context);
      } finally {
        if (normalExecutionPath && !creationModeIsActive && rendererFactory.end) {
          rendererFactory.end();
        }
      }
    }
    /**
     * @template T
     * @param {?} tView
     * @param {?} lView
     * @param {?} templateFn
     * @param {?} rf
     * @param {?} context
     * @return {?}
     */


    function executeTemplate(tView, lView, templateFn, rf, context) {
      /** @type {?} */
      var prevSelectedIndex = getSelectedIndex();

      try {
        setSelectedIndex(-1);

        if (rf & 2
        /* Update */
        && lView.length > HEADER_OFFSET) {
          // When we're updating, inherently select 0 so we don't
          // have to generate that instruction for most update blocks.
          selectIndexInternal(tView, lView, 0, getCheckNoChangesMode());
        }

        templateFn(rf, context);
      } finally {
        setSelectedIndex(prevSelectedIndex);
      }
    } //////////////////////////
    //// Element
    //////////////////////////

    /**
     * @param {?} tView
     * @param {?} tNode
     * @param {?} lView
     * @return {?}
     */


    function executeContentQueries(tView, tNode, lView) {
      if (isContentQueryHost(tNode)) {
        /** @type {?} */
        var start = tNode.directiveStart;
        /** @type {?} */

        var end = tNode.directiveEnd;

        for (var directiveIndex = start; directiveIndex < end; directiveIndex++) {
          /** @type {?} */
          var def =
          /** @type {?} */
          tView.data[directiveIndex];

          if (def.contentQueries) {
            def.contentQueries(1
            /* Create */
            , lView[directiveIndex], directiveIndex);
          }
        }
      }
    }
    /**
     * Creates directive instances.
     * @param {?} tView
     * @param {?} lView
     * @param {?} tNode
     * @return {?}
     */


    function createDirectivesInstances(tView, lView, tNode) {
      if (!getBindingsEnabled()) return;
      instantiateAllDirectives(tView, lView, tNode, getNativeByTNode(tNode, lView));

      if ((tNode.flags & 128
      /* hasHostBindings */
      ) === 128
      /* hasHostBindings */
      ) {
          invokeDirectivesHostBindings(tView, lView, tNode);
        }
    }
    /**
     * Takes a list of local names and indices and pushes the resolved local variable values
     * to LView in the same order as they are loaded in the template with load().
     * @param {?} viewData
     * @param {?} tNode
     * @param {?=} localRefExtractor
     * @return {?}
     */


    function saveResolvedLocalsInData(viewData, tNode) {
      var localRefExtractor = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : getNativeByTNode;

      /** @type {?} */
      var localNames = tNode.localNames;

      if (localNames !== null) {
        /** @type {?} */
        var localIndex = tNode.index + 1;

        for (var i = 0; i < localNames.length; i += 2) {
          /** @type {?} */
          var index =
          /** @type {?} */
          localNames[i + 1];
          /** @type {?} */

          var value = index === -1 ? localRefExtractor(
          /** @type {?} */
          tNode, viewData) : viewData[index];
          viewData[localIndex++] = value;
        }
      }
    }
    /**
     * Gets TView from a template function or creates a new TView
     * if it doesn't already exist.
     *
     * @param {?} def ComponentDef
     * @return {?} TView
     */


    function getOrCreateTComponentView(def) {
      /** @type {?} */
      var tView = def.tView; // Create a TView if there isn't one, or recreate it if the first create pass didn't
      // complete successfuly since we can't know for sure whether it's in a usable shape.

      if (tView === null || tView.incompleteFirstPass) {
        return def.tView = createTView(1
        /* Component */
        , -1, def.template, def.decls, def.vars, def.directiveDefs, def.pipeDefs, def.viewQuery, def.schemas, def.consts);
      }

      return tView;
    }
    /**
     * Creates a TView instance
     *
     * @param {?} type
     * @param {?} viewIndex The viewBlockId for inline views, or -1 if it's a component/dynamic
     * @param {?} templateFn Template function
     * @param {?} decls The number of nodes, local refs, and pipes in this template
     * @param {?} vars
     * @param {?} directives Registry of directives for this view
     * @param {?} pipes Registry of pipes for this view
     * @param {?} viewQuery View queries for this view
     * @param {?} schemas Schemas for this view
     * @param {?} consts Constants for this view
     * @return {?}
     */


    function createTView(type, viewIndex, templateFn, decls, vars, directives, pipes, viewQuery, schemas, consts) {
      ngDevMode && ngDevMode.tView++;
      /** @type {?} */

      var bindingStartIndex = HEADER_OFFSET + decls; // This length does not yet contain host bindings from child directives because at this point,
      // we don't know which directives are active on this template. As soon as a directive is matched
      // that has a host binding, we will update the blueprint with that def's hostVars count.

      /** @type {?} */

      var initialViewLength = bindingStartIndex + vars;
      /** @type {?} */

      var blueprint = createViewBlueprint(bindingStartIndex, initialViewLength);
      return blueprint[
      /** @type {?} */
      TVIEW] = ngDevMode ? new TViewConstructor(type, viewIndex, // id: number,
      blueprint, // blueprint: LView,
      templateFn, // template: ComponentTemplate<{}>|null,
      null, // queries: TQueries|null
      viewQuery,
      /** @type {?} */
      null, // node: TViewNode|TElementNode|null,
      cloneToTViewData(blueprint).fill(null, bindingStartIndex), // data: TData,
      bindingStartIndex, // bindingStartIndex: number,
      initialViewLength, // expandoStartIndex: number,
      null, // expandoInstructions: ExpandoInstructions|null,
      true, // firstCreatePass: boolean,
      true, // firstUpdatePass: boolean,
      false, // staticViewQueries: boolean,
      false, // staticContentQueries: boolean,
      null, // preOrderHooks: HookData|null,
      null, // preOrderCheckHooks: HookData|null,
      null, // contentHooks: HookData|null,
      null, // contentCheckHooks: HookData|null,
      null, // viewHooks: HookData|null,
      null, // viewCheckHooks: HookData|null,
      null, // destroyHooks: DestroyHookData|null,
      null, // cleanup: any[]|null,
      null, // contentQueries: number[]|null,
      null, // components: number[]|null,
      typeof directives === 'function' ? directives() : directives, // directiveRegistry: DirectiveDefList|null,
      typeof pipes === 'function' ? pipes() : pipes, // pipeRegistry: PipeDefList|null,
      null, // firstChild: TNode|null,
      schemas, // schemas: SchemaMetadata[]|null,
      consts, // consts: TConstants|null
      false // incompleteFirstPass: boolean
      ) : {
        type: type,
        id: viewIndex,
        blueprint: blueprint,
        template: templateFn,
        queries: null,
        viewQuery: viewQuery,
        node:
        /** @type {?} */
        null,
        data: blueprint.slice().fill(null, bindingStartIndex),
        bindingStartIndex: bindingStartIndex,
        expandoStartIndex: initialViewLength,
        expandoInstructions: null,
        firstCreatePass: true,
        firstUpdatePass: true,
        staticViewQueries: false,
        staticContentQueries: false,
        preOrderHooks: null,
        preOrderCheckHooks: null,
        contentHooks: null,
        contentCheckHooks: null,
        viewHooks: null,
        viewCheckHooks: null,
        destroyHooks: null,
        cleanup: null,
        contentQueries: null,
        components: null,
        directiveRegistry: typeof directives === 'function' ? directives() : directives,
        pipeRegistry: typeof pipes === 'function' ? pipes() : pipes,
        firstChild: null,
        schemas: schemas,
        consts: consts,
        incompleteFirstPass: false
      };
    }
    /**
     * @param {?} bindingStartIndex
     * @param {?} initialViewLength
     * @return {?}
     */


    function createViewBlueprint(bindingStartIndex, initialViewLength) {
      /** @type {?} */
      var blueprint = ngDevMode ? new LViewBlueprint() : [];

      for (var i = 0; i < initialViewLength; i++) {
        blueprint.push(i < bindingStartIndex ? null : NO_CHANGE);
      }

      return (
        /** @type {?} */
        blueprint
      );
    }
    /**
     * @param {?} text
     * @param {?} token
     * @return {?}
     */


    function createError(text, token) {
      return new Error("Renderer: ".concat(text, " [").concat(stringifyForError(token), "]"));
    }
    /**
     * @param {?} rElement
     * @param {?} elementOrSelector
     * @return {?}
     */


    function assertHostNodeExists(rElement, elementOrSelector) {
      if (!rElement) {
        if (typeof elementOrSelector === 'string') {
          throw createError('Host node with selector not found:', elementOrSelector);
        } else {
          throw createError('Host node is required:', elementOrSelector);
        }
      }
    }
    /**
     * Locates the host native element, used for bootstrapping existing nodes into rendering pipeline.
     *
     * @param {?} renderer
     * @param {?} elementOrSelector Render element or CSS selector to locate the element.
     * @param {?} encapsulation View Encapsulation defined for component that requests host element.
     * @return {?}
     */


    function locateHostElement(renderer, elementOrSelector, encapsulation) {
      if (isProceduralRenderer(renderer)) {
        // When using native Shadow DOM, do not clear host element to allow native slot projection

        /** @type {?} */
        var preserveContent = encapsulation === ViewEncapsulation$1.ShadowDom;
        return renderer.selectRootElement(elementOrSelector, preserveContent);
      }
      /** @type {?} */


      var rElement = typeof elementOrSelector === 'string' ?
      /** @type {?} */
      renderer.querySelector(elementOrSelector) : elementOrSelector;
      ngDevMode && assertHostNodeExists(rElement, elementOrSelector); // Always clear host element's content when Renderer3 is in use. For procedural renderer case we
      // make it depend on whether ShadowDom encapsulation is used (in which case the content should be
      // preserved to allow native slot projection). ShadowDom encapsulation requires procedural
      // renderer, and procedural renderer case is handled above.

      rElement.textContent = '';
      return rElement;
    }
    /**
     * Saves context for this cleanup function in LView.cleanupInstances.
     *
     * On the first template pass, saves in TView:
     * - Cleanup function
     * - Index of context we just saved in LView.cleanupInstances
     * @param {?} tView
     * @param {?} lView
     * @param {?} context
     * @param {?} cleanupFn
     * @return {?}
     */


    function storeCleanupWithContext(tView, lView, context, cleanupFn) {
      /** @type {?} */
      var lCleanup = getLCleanup(lView);
      lCleanup.push(context);

      if (tView.firstCreatePass) {
        getTViewCleanup(tView).push(cleanupFn, lCleanup.length - 1);
      }
    }
    /**
     * Saves the cleanup function itself in LView.cleanupInstances.
     *
     * This is necessary for functions that are wrapped with their contexts, like in renderer2
     * listeners.
     *
     * On the first template pass, the index of the cleanup function is saved in TView.
     * @param {?} tView
     * @param {?} lView
     * @param {?} cleanupFn
     * @return {?}
     */


    function storeCleanupFn(tView, lView, cleanupFn) {
      getLCleanup(lView).push(cleanupFn);

      if (tView.firstCreatePass) {
        getTViewCleanup(tView).push(
        /** @type {?} */
        lView[CLEANUP].length - 1, null);
      }
    }
    /**
     * Constructs a TNode object from the arguments.
     *
     * @param {?} tView `TView` to which this `TNode` belongs (used only in `ngDevMode`)
     * @param {?} tParent
     * @param {?} type The type of the node
     * @param {?} adjustedIndex The index of the TNode in TView.data, adjusted for HEADER_OFFSET
     * @param {?} tagName The tag name of the node
     * @param {?} attrs The attributes defined on this node
     * @return {?} the TNode object
     */


    function createTNode(tView, tParent, type, adjustedIndex, tagName, attrs) {
      ngDevMode && ngDevMode.tNode++;
      /** @type {?} */

      var injectorIndex = tParent ? tParent.injectorIndex : -1;
      return ngDevMode ? new TNodeDebug(tView, // tView_: TView
      type, // type: TNodeType
      adjustedIndex, // index: number
      injectorIndex, // injectorIndex: number
      -1, // directiveStart: number
      -1, // directiveEnd: number
      -1, // directiveStylingLast: number
      null, // propertyBindings: number[]|null
      0, // flags: TNodeFlags
      0, // providerIndexes: TNodeProviderIndexes
      tagName, // tagName: string|null
      attrs, // attrs: (string|AttributeMarker|(string|SelectorFlags)[])[]|null
      null, // mergedAttrs
      null, // localNames: (string|number)[]|null
      undefined, // initialInputs: (string[]|null)[]|null|undefined
      null, // inputs: PropertyAliases|null
      null, // outputs: PropertyAliases|null
      null, // tViews: ITView|ITView[]|null
      null, // next: ITNode|null
      null, // projectionNext: ITNode|null
      null, // child: ITNode|null
      tParent, // parent: TElementNode|TContainerNode|null
      null, // projection: number|(ITNode|RNode[])[]|null
      null, // styles: string|null
      undefined, // residualStyles: string|null
      null, // classes: string|null
      undefined,
      /** @type {?} */
      0,
      /** @type {?} */
      0) : {
        type: type,
        index: adjustedIndex,
        injectorIndex: injectorIndex,
        directiveStart: -1,
        directiveEnd: -1,
        directiveStylingLast: -1,
        propertyBindings: null,
        flags: 0,
        providerIndexes: 0,
        tagName: tagName,
        attrs: attrs,
        mergedAttrs: null,
        localNames: null,
        initialInputs: undefined,
        inputs: null,
        outputs: null,
        tViews: null,
        next: null,
        projectionNext: null,
        child: null,
        parent: tParent,
        projection: null,
        styles: null,
        residualStyles: undefined,
        classes: null,
        residualClasses: undefined,
        classBindings:
        /** @type {?} */
        0,
        styleBindings:
        /** @type {?} */
        0
      };
    }
    /**
     * @param {?} inputAliasMap
     * @param {?} directiveDefIdx
     * @param {?} propStore
     * @return {?}
     */


    function generatePropertyAliases(inputAliasMap, directiveDefIdx, propStore) {
      for (var publicName in inputAliasMap) {
        if (inputAliasMap.hasOwnProperty(publicName)) {
          propStore = propStore === null ? {} : propStore;
          /** @type {?} */

          var internalName = inputAliasMap[publicName];

          if (propStore.hasOwnProperty(publicName)) {
            propStore[publicName].push(directiveDefIdx, internalName);
          } else {
            propStore[publicName] = [directiveDefIdx, internalName];
          }
        }
      }

      return propStore;
    }
    /**
     * Initializes data structures required to work with directive outputs and outputs.
     * Initialization is done for all directives matched on a given TNode.
     * @param {?} tView
     * @param {?} tNode
     * @return {?}
     */


    function initializeInputAndOutputAliases(tView, tNode) {
      ngDevMode && assertFirstCreatePass(tView);
      /** @type {?} */

      var start = tNode.directiveStart;
      /** @type {?} */

      var end = tNode.directiveEnd;
      /** @type {?} */

      var defs = tView.data;
      /** @type {?} */

      var tNodeAttrs = tNode.attrs;
      /** @type {?} */

      var inputsFromAttrs = ngDevMode ? new TNodeInitialInputs() : [];
      /** @type {?} */

      var inputsStore = null;
      /** @type {?} */

      var outputsStore = null;

      for (var i = start; i < end; i++) {
        /** @type {?} */
        var _directiveDef3 =
        /** @type {?} */
        defs[i];
        /** @type {?} */

        var directiveInputs = _directiveDef3.inputs; // Do not use unbound attributes as inputs to structural directives, since structural
        // directive inputs can only be set using microsyntax (e.g. `<div *dir="exp">`).
        // TODO(FW-1930): microsyntax expressions may also contain unbound/static attributes, which
        // should be set for inline templates.

        /** @type {?} */

        var initialInputs = tNodeAttrs !== null && !isInlineTemplate(tNode) ? generateInitialInputs(directiveInputs, tNodeAttrs) : null;
        inputsFromAttrs.push(initialInputs);
        inputsStore = generatePropertyAliases(directiveInputs, i, inputsStore);
        outputsStore = generatePropertyAliases(_directiveDef3.outputs, i, outputsStore);
      }

      if (inputsStore !== null) {
        if (inputsStore.hasOwnProperty('class')) {
          tNode.flags |= 16
          /* hasClassInput */
          ;
        }

        if (inputsStore.hasOwnProperty('style')) {
          tNode.flags |= 32
          /* hasStyleInput */
          ;
        }
      }

      tNode.initialInputs = inputsFromAttrs;
      tNode.inputs = inputsStore;
      tNode.outputs = outputsStore;
    }
    /**
     * Mapping between attributes names that don't correspond to their element property names.
     *
     * Performance note: this function is written as a series of if checks (instead of, say, a property
     * object lookup) for performance reasons - the series of `if` checks seems to be the fastest way of
     * mapping property names. Do NOT change without benchmarking.
     *
     * Note: this mapping has to be kept in sync with the equally named mapping in the template
     * type-checking machinery of ngtsc.
     * @param {?} name
     * @return {?}
     */


    function mapPropName(name) {
      if (name === 'class') return 'className';
      if (name === 'for') return 'htmlFor';
      if (name === 'formaction') return 'formAction';
      if (name === 'innerHtml') return 'innerHTML';
      if (name === 'readonly') return 'readOnly';
      if (name === 'tabindex') return 'tabIndex';
      return name;
    }
    /**
     * @template T
     * @param {?} tView
     * @param {?} tNode
     * @param {?} lView
     * @param {?} propName
     * @param {?} value
     * @param {?} renderer
     * @param {?} sanitizer
     * @param {?} nativeOnly
     * @return {?}
     */


    function elementPropertyInternal(tView, tNode, lView, propName, value, renderer, sanitizer, nativeOnly) {
      ngDevMode && assertNotSame(value,
      /** @type {?} */
      NO_CHANGE, 'Incoming value should never be NO_CHANGE.');
      /** @type {?} */

      var element =
      /** @type {?} */
      getNativeByTNode(tNode, lView);
      /** @type {?} */

      var inputData = tNode.inputs;
      /** @type {?} */

      var dataValue;

      if (!nativeOnly && inputData != null && (dataValue = inputData[propName])) {
        setInputsForProperty(tView, lView, dataValue, propName, value);
        if (isComponentHost(tNode)) markDirtyIfOnPush(lView, tNode.index);

        if (ngDevMode) {
          setNgReflectProperties(lView, element, tNode.type, dataValue, value);
        }
      } else if (tNode.type === 3
      /* Element */
      ) {
          propName = mapPropName(propName);

          if (ngDevMode) {
            validateAgainstEventProperties(propName);

            if (!validateProperty(tView, lView, element, propName, tNode)) {
              // Return here since we only log warnings for unknown properties.
              warnAboutUnknownProperty(propName, tNode);
              return;
            }

            ngDevMode.rendererSetProperty++;
          } // It is assumed that the sanitizer is only added when the compiler determines that the
          // property is risky, so sanitization can be done without further checks.


          value = sanitizer != null ?
          /** @type {?} */
          sanitizer(value, tNode.tagName || '', propName) : value;

          if (isProceduralRenderer(renderer)) {
            renderer.setProperty(
            /** @type {?} */
            element, propName, value);
          } else if (!isAnimationProp(propName)) {
            /** @type {?} */
            element.setProperty ?
            /** @type {?} */
            element.setProperty(propName, value) :
            /** @type {?} */
            element[propName] = value;
          }
        } else if (tNode.type === 0
      /* Container */
      ) {
          // If the node is a container and the property didn't
          // match any of the inputs or schemas we should throw.
          if (ngDevMode && !matchingSchemas(tView, lView, tNode.tagName)) {
            warnAboutUnknownProperty(propName, tNode);
          }
        }
    }
    /**
     * If node is an OnPush component, marks its LView dirty.
     * @param {?} lView
     * @param {?} viewIndex
     * @return {?}
     */


    function markDirtyIfOnPush(lView, viewIndex) {
      ngDevMode && assertLView(lView);
      /** @type {?} */

      var childComponentLView = getComponentLViewByIndex(viewIndex, lView);

      if (!(childComponentLView[FLAGS] & 16
      /* CheckAlways */
      )) {
        childComponentLView[FLAGS] |= 64
        /* Dirty */
        ;
      }
    }
    /**
     * @param {?} lView
     * @param {?} element
     * @param {?} type
     * @param {?} attrName
     * @param {?} value
     * @return {?}
     */


    function setNgReflectProperty(lView, element, type, attrName, value) {
      /** @type {?} */
      var renderer = lView[RENDERER];
      attrName = normalizeDebugBindingName(attrName);
      /** @type {?} */

      var debugValue = normalizeDebugBindingValue(value);

      if (type === 3
      /* Element */
      ) {
          if (value == null) {
            isProceduralRenderer(renderer) ? renderer.removeAttribute(
            /** @type {?} */
            element, attrName) :
            /** @type {?} */
            element.removeAttribute(attrName);
          } else {
            isProceduralRenderer(renderer) ? renderer.setAttribute(
            /** @type {?} */
            element, attrName, debugValue) :
            /** @type {?} */
            element.setAttribute(attrName, debugValue);
          }
        } else {
        /** @type {?} */
        var textContent = "bindings=".concat(JSON.stringify(_defineProperty({}, attrName, debugValue), null, 2));

        if (isProceduralRenderer(renderer)) {
          renderer.setValue(
          /** @type {?} */
          element, textContent);
        } else {
          /** @type {?} */
          element.textContent = textContent;
        }
      }
    }
    /**
     * @param {?} lView
     * @param {?} element
     * @param {?} type
     * @param {?} dataValue
     * @param {?} value
     * @return {?}
     */


    function setNgReflectProperties(lView, element, type, dataValue, value) {
      if (type === 3
      /* Element */
      || type === 0
      /* Container */
      ) {
          /**
           * dataValue is an array containing runtime input or output names for the directives:
           * i+0: directive instance index
           * i+1: privateName
           *
           * e.g. [0, 'change', 'change-minified']
           * we want to set the reflected property with the privateName: dataValue[i+1]
           */
          for (var i = 0; i < dataValue.length; i += 2) {
            setNgReflectProperty(lView, element, type,
            /** @type {?} */
            dataValue[i + 1], value);
          }
        }
    }
    /**
     * @param {?} tView
     * @param {?} lView
     * @param {?} element
     * @param {?} propName
     * @param {?} tNode
     * @return {?}
     */


    function validateProperty(tView, lView, element, propName, tNode) {
      // If `schemas` is set to `null`, that's an indication that this Component was compiled in AOT
      // mode where this check happens at compile time. In JIT mode, `schemas` is always present and
      // defined as an array (as an empty array in case `schemas` field is not defined) and we should
      // execute the check below.
      if (tView.schemas === null) return true; // The property is considered valid if the element matches the schema, it exists on the element
      // or it is synthetic, and we are in a browser context (web worker nodes should be skipped).

      if (matchingSchemas(tView, lView, tNode.tagName) || propName in element || isAnimationProp(propName)) {
        return true;
      } // Note: `typeof Node` returns 'function' in most browsers, but on IE it is 'object' so we
      // need to account for both here, while being careful for `typeof null` also returning 'object'.


      return typeof Node === 'undefined' || Node === null || !(element instanceof Node);
    }
    /**
     * @param {?} tView
     * @param {?} lView
     * @param {?} tagName
     * @return {?}
     */


    function matchingSchemas(tView, lView, tagName) {
      /** @type {?} */
      var schemas = tView.schemas;

      if (schemas !== null) {
        for (var i = 0; i < schemas.length; i++) {
          /** @type {?} */
          var schema = schemas[i];

          if (schema === NO_ERRORS_SCHEMA || schema === CUSTOM_ELEMENTS_SCHEMA && tagName && tagName.indexOf('-') > -1) {
            return true;
          }
        }
      }

      return false;
    }
    /**
     * Logs a warning that a property is not supported on an element.
     * @param {?} propName Name of the invalid property.
     * @param {?} tNode Node on which we encountered the property.
     * @return {?}
     */


    function warnAboutUnknownProperty(propName, tNode) {
      console.warn("Can't bind to '".concat(propName, "' since it isn't a known property of '").concat(tNode.tagName, "'."));
    }
    /**
     * Instantiate a root component.
     * @template T
     * @param {?} tView
     * @param {?} lView
     * @param {?} def
     * @return {?}
     */


    function instantiateRootComponent(tView, lView, def) {
      /** @type {?} */
      var rootTNode = getPreviousOrParentTNode();

      if (tView.firstCreatePass) {
        if (def.providersResolver) def.providersResolver(def);
        generateExpandoInstructionBlock(tView, rootTNode, 1);
        baseResolveDirective(tView, lView, def);
      }
      /** @type {?} */


      var directive = getNodeInjectable(lView, tView, lView.length - 1,
      /** @type {?} */
      rootTNode);
      attachPatchData(directive, lView);
      /** @type {?} */

      var _native7 = getNativeByTNode(rootTNode, lView);

      if (_native7) {
        attachPatchData(_native7, lView);
      }

      return directive;
    }
    /**
     * Resolve the matched directives on a node.
     * @param {?} tView
     * @param {?} lView
     * @param {?} tNode
     * @param {?} localRefs
     * @return {?}
     */


    function resolveDirectives(tView, lView, tNode, localRefs) {
      // Please make sure to have explicit type for `exportsMap`. Inferred type triggers bug in
      // tsickle.
      ngDevMode && assertFirstCreatePass(tView);
      /** @type {?} */

      var hasDirectives = false;

      if (getBindingsEnabled()) {
        /** @type {?} */
        var directiveDefs = findDirectiveDefMatches(tView, lView, tNode);
        /** @type {?} */

        var exportsMap = localRefs === null ? null : {
          '': -1
        };

        if (directiveDefs !== null) {
          /** @type {?} */
          var totalDirectiveHostVars = 0;
          hasDirectives = true;
          initTNodeFlags(tNode, tView.data.length, directiveDefs.length); // When the same token is provided by several directives on the same node, some rules apply in
          // the viewEngine:
          // - viewProviders have priority over providers
          // - the last directive in NgModule.declarations has priority over the previous one
          // So to match these rules, the order in which providers are added in the arrays is very
          // important.

          for (var i = 0; i < directiveDefs.length; i++) {
            /** @type {?} */
            var def = directiveDefs[i];
            if (def.providersResolver) def.providersResolver(def);
          }

          generateExpandoInstructionBlock(tView, tNode, directiveDefs.length);
          /** @type {?} */

          var preOrderHooksFound = false;
          /** @type {?} */

          var preOrderCheckHooksFound = false;

          for (var _i12 = 0; _i12 < directiveDefs.length; _i12++) {
            /** @type {?} */
            var _def2 = directiveDefs[_i12]; // Merge the attrs in the order of matches. This assumes that the first directive is the
            // component itself, so that the component has the least priority.

            tNode.mergedAttrs = mergeHostAttrs(tNode.mergedAttrs, _def2.hostAttrs);
            baseResolveDirective(tView, lView, _def2);
            saveNameToExportMap(
            /** @type {?} */
            tView.data.length - 1, _def2, exportsMap);
            if (_def2.contentQueries !== null) tNode.flags |= 8
            /* hasContentQuery */
            ;
            if (_def2.hostBindings !== null || _def2.hostAttrs !== null || _def2.hostVars !== 0) tNode.flags |= 128
            /* hasHostBindings */
            ; // Only push a node index into the preOrderHooks array if this is the first
            // pre-order hook found on this node.

            if (!preOrderHooksFound && (_def2.onChanges || _def2.onInit || _def2.doCheck)) {
              // We will push the actual hook function into this array later during dir instantiation.
              // We cannot do it now because we must ensure hooks are registered in the same
              // order that directives are created (i.e. injection order).
              (tView.preOrderHooks || (tView.preOrderHooks = [])).push(tNode.index - HEADER_OFFSET);
              preOrderHooksFound = true;
            }

            if (!preOrderCheckHooksFound && (_def2.onChanges || _def2.doCheck)) {
              (tView.preOrderCheckHooks || (tView.preOrderCheckHooks = [])).push(tNode.index - HEADER_OFFSET);
              preOrderCheckHooksFound = true;
            }

            addHostBindingsToExpandoInstructions(tView, _def2);
            totalDirectiveHostVars += _def2.hostVars;
          }

          initializeInputAndOutputAliases(tView, tNode);
          growHostVarsSpace(tView, lView, totalDirectiveHostVars);
        }

        if (exportsMap) cacheMatchingLocalNames(tNode, localRefs, exportsMap);
      } // Merge the template attrs last so that they have the highest priority.


      tNode.mergedAttrs = mergeHostAttrs(tNode.mergedAttrs, tNode.attrs);
      return hasDirectives;
    }
    /**
     * Add `hostBindings` to the `TView.expandoInstructions`.
     *
     * @param {?} tView `TView` to which the `hostBindings` should be added.
     * @param {?} def `ComponentDef`/`DirectiveDef`, which contains the `hostVars`/`hostBindings` to add.
     * @return {?}
     */


    function addHostBindingsToExpandoInstructions(tView, def) {
      ngDevMode && assertFirstCreatePass(tView);
      /** @type {?} */

      var expando =
      /** @type {?} */
      tView.expandoInstructions; // TODO(misko): PERF we are adding `hostBindings` even if there is nothing to add! This is
      // suboptimal for performance. `def.hostBindings` may be null,
      // but we still need to push null to the array as a placeholder
      // to ensure the directive counter is incremented (so host
      // binding functions always line up with the corrective directive).
      // This is suboptimal for performance. See `currentDirectiveIndex`
      //  comment in `setHostBindingsByExecutingExpandoInstructions` for more
      // details.  expando.push(def.hostBindings);

      expando.push(def.hostBindings);
      /** @type {?} */

      var hostVars = def.hostVars;

      if (hostVars !== 0) {
        expando.push(def.hostVars);
      }
    }
    /**
     * Grow the `LView`, blueprint and `TView.data` to accommodate the `hostBindings`.
     *
     * To support locality we don't know ahead of time how many `hostVars` of the containing directives
     * we need to allocate. For this reason we allow growing these data structures as we discover more
     * directives to accommodate them.
     *
     * @param {?} tView `TView` which needs to be grown.
     * @param {?} lView `LView` which needs to be grown.
     * @param {?} count Size by which we need to grow the data structures.
     * @return {?}
     */


    function growHostVarsSpace(tView, lView, count) {
      ngDevMode && assertFirstCreatePass(tView);
      ngDevMode && assertSame(tView, lView[TVIEW], '`LView` must be associated with `TView`!');

      for (var i = 0; i < count; i++) {
        lView.push(NO_CHANGE);
        tView.blueprint.push(NO_CHANGE);
        tView.data.push(null);
      }
    }
    /**
     * Instantiate all the directives that were previously resolved on the current node.
     * @param {?} tView
     * @param {?} lView
     * @param {?} tNode
     * @param {?} native
     * @return {?}
     */


    function instantiateAllDirectives(tView, lView, tNode, _native8) {
      /** @type {?} */
      var start = tNode.directiveStart;
      /** @type {?} */

      var end = tNode.directiveEnd;

      if (!tView.firstCreatePass) {
        getOrCreateNodeInjectorForNode(tNode, lView);
      }

      attachPatchData(_native8, lView);
      /** @type {?} */

      var initialInputs = tNode.initialInputs;

      for (var i = start; i < end; i++) {
        /** @type {?} */
        var def =
        /** @type {?} */
        tView.data[i];
        /** @type {?} */

        var isComponent = isComponentDef(def);

        if (isComponent) {
          ngDevMode && assertNodeOfPossibleTypes(tNode, 3
          /* Element */
          );
          addComponentLogic(lView,
          /** @type {?} */
          tNode,
          /** @type {?} */
          def);
        }
        /** @type {?} */


        var directive = getNodeInjectable(lView, tView, i, tNode);
        attachPatchData(directive, lView);

        if (initialInputs !== null) {
          setInputsFromAttrs(lView, i - start, directive, def, tNode,
          /** @type {?} */
          initialInputs);
        }

        if (isComponent) {
          /** @type {?} */
          var componentView = getComponentLViewByIndex(tNode.index, lView);
          componentView[CONTEXT] = directive;
        }
      }
    }
    /**
     * @param {?} tView
     * @param {?} lView
     * @param {?} tNode
     * @return {?}
     */


    function invokeDirectivesHostBindings(tView, lView, tNode) {
      /** @type {?} */
      var start = tNode.directiveStart;
      /** @type {?} */

      var end = tNode.directiveEnd;
      /** @type {?} */

      var expando =
      /** @type {?} */
      tView.expandoInstructions;
      /** @type {?} */

      var firstCreatePass = tView.firstCreatePass;
      /** @type {?} */

      var elementIndex = tNode.index - HEADER_OFFSET;
      /** @type {?} */

      var currentDirectiveIndex = getCurrentDirectiveIndex();

      try {
        setSelectedIndex(elementIndex);

        for (var dirIndex = start; dirIndex < end; dirIndex++) {
          /** @type {?} */
          var def =
          /** @type {?} */
          tView.data[dirIndex];
          /** @type {?} */

          var directive = lView[dirIndex];
          setCurrentDirectiveIndex(dirIndex);

          if (def.hostBindings !== null || def.hostVars !== 0 || def.hostAttrs !== null) {
            invokeHostBindingsInCreationMode(def, directive);
          } else if (firstCreatePass) {
            expando.push(null);
          }
        }
      } finally {
        setSelectedIndex(-1);
        setCurrentDirectiveIndex(currentDirectiveIndex);
      }
    }
    /**
     * Invoke the host bindings in creation mode.
     *
     * @param {?} def `DirectiveDef` which may contain the `hostBindings` function.
     * @param {?} directive Instance of directive.
     * @return {?}
     */


    function invokeHostBindingsInCreationMode(def, directive) {
      if (def.hostBindings !== null) {
        /** @type {?} */
        def.hostBindings(1
        /* Create */
        , directive);
      }
    }
    /**
     * Generates a new block in TView.expandoInstructions for this node.
     *
     * Each expando block starts with the element index (turned negative so we can distinguish
     * it from the hostVar count) and the directive count. See more in VIEW_DATA.md.
     * @param {?} tView
     * @param {?} tNode
     * @param {?} directiveCount
     * @return {?}
     */


    function generateExpandoInstructionBlock(tView, tNode, directiveCount) {
      ngDevMode && assertEqual(tView.firstCreatePass, true, 'Expando block should only be generated on first create pass.'); // Important: In JS `-x` and `0-x` is not the same! If `x===0` then `-x` will produce `-0` which
      // requires non standard math arithmetic and it can prevent VM optimizations.
      // `0-0` will always produce `0` and will not cause a potential deoptimization in VM.

      /** @type {?} */

      var elementIndex = HEADER_OFFSET - tNode.index;
      /** @type {?} */

      var providerStartIndex = tNode.providerIndexes & 65535
      /* ProvidersStartIndexMask */
      ;
      /** @type {?} */

      var providerCount = tView.data.length - providerStartIndex;
      (tView.expandoInstructions || (tView.expandoInstructions = [])).push(elementIndex, providerCount, directiveCount);
    }
    /**
     * Matches the current node against all available selectors.
     * If a component is matched (at most one), it is returned in first position in the array.
     * @param {?} tView
     * @param {?} viewData
     * @param {?} tNode
     * @return {?}
     */


    function findDirectiveDefMatches(tView, viewData, tNode) {
      ngDevMode && assertFirstCreatePass(tView);
      ngDevMode && assertNodeOfPossibleTypes(tNode, 3
      /* Element */
      , 4
      /* ElementContainer */
      , 0
      /* Container */
      );
      /** @type {?} */

      var registry = tView.directiveRegistry;
      /** @type {?} */

      var matches = null;

      if (registry) {
        for (var i = 0; i < registry.length; i++) {
          /** @type {?} */
          var def =
          /** @type {?} */
          registry[i];

          if (isNodeMatchingSelectorList(tNode,
          /** @type {?} */
          def.selectors,
          /* isProjectionMode */
          false)) {
            matches || (matches = ngDevMode ? new MatchesArray() : []);
            diPublicInInjector(getOrCreateNodeInjectorForNode(tNode, viewData), tView, def.type);

            if (isComponentDef(def)) {
              if (tNode.flags & 2
              /* isComponentHost */
              ) throwMultipleComponentError(tNode);
              markAsComponentHost(tView, tNode); // The component is always stored first with directives after.

              matches.unshift(def);
            } else {
              matches.push(def);
            }
          }
        }
      }

      return matches;
    }
    /**
     * Marks a given TNode as a component's host. This consists of:
     * - setting appropriate TNode flags;
     * - storing index of component's host element so it will be queued for view refresh during CD.
     * @param {?} tView
     * @param {?} hostTNode
     * @return {?}
     */


    function markAsComponentHost(tView, hostTNode) {
      ngDevMode && assertFirstCreatePass(tView);
      hostTNode.flags |= 2
      /* isComponentHost */
      ;
      (tView.components || (tView.components = ngDevMode ? new TViewComponents() : [])).push(hostTNode.index);
    }
    /**
     * Caches local names and their matching directive indices for query and template lookups.
     * @param {?} tNode
     * @param {?} localRefs
     * @param {?} exportsMap
     * @return {?}
     */


    function cacheMatchingLocalNames(tNode, localRefs, exportsMap) {
      if (localRefs) {
        /** @type {?} */
        var localNames = tNode.localNames = ngDevMode ? new TNodeLocalNames() : []; // Local names must be stored in tNode in the same order that localRefs are defined
        // in the template to ensure the data is loaded in the same slots as their refs
        // in the template (for template queries).

        for (var i = 0; i < localRefs.length; i += 2) {
          /** @type {?} */
          var index = exportsMap[localRefs[i + 1]];
          if (index == null) throw new Error("Export of name '".concat(localRefs[i + 1], "' not found!"));
          localNames.push(localRefs[i], index);
        }
      }
    }
    /**
     * Builds up an export map as directives are created, so local refs can be quickly mapped
     * to their directive instances.
     * @param {?} index
     * @param {?} def
     * @param {?} exportsMap
     * @return {?}
     */


    function saveNameToExportMap(index, def, exportsMap) {
      if (exportsMap) {
        if (def.exportAs) {
          for (var i = 0; i < def.exportAs.length; i++) {
            exportsMap[def.exportAs[i]] = index;
          }
        }

        if (isComponentDef(def)) exportsMap[''] = index;
      }
    }
    /**
     * Initializes the flags on the current node, setting all indices to the initial index,
     * the directive count to 0, and adding the isComponent flag.
     * @param {?} tNode
     * @param {?} index the initial index
     * @param {?} numberOfDirectives
     * @return {?}
     */


    function initTNodeFlags(tNode, index, numberOfDirectives) {
      ngDevMode && assertNotEqual(numberOfDirectives, tNode.directiveEnd - tNode.directiveStart, 'Reached the max number of directives');
      tNode.flags |= 1
      /* isDirectiveHost */
      ; // When the first directive is created on a node, save the index

      tNode.directiveStart = index;
      tNode.directiveEnd = index + numberOfDirectives;
      tNode.providerIndexes = index;
    }
    /**
     * @template T
     * @param {?} tView
     * @param {?} viewData
     * @param {?} def
     * @return {?}
     */


    function baseResolveDirective(tView, viewData, def) {
      tView.data.push(def);
      /** @type {?} */

      var directiveFactory = def.factory || (
      /** @type {?} */
      def.factory = getFactoryDef(def.type, true));
      /** @type {?} */

      var nodeInjectorFactory = new NodeInjectorFactory(directiveFactory, isComponentDef(def), null);
      tView.blueprint.push(nodeInjectorFactory);
      viewData.push(nodeInjectorFactory);
    }
    /**
     * @template T
     * @param {?} lView
     * @param {?} hostTNode
     * @param {?} def
     * @return {?}
     */


    function addComponentLogic(lView, hostTNode, def) {
      /** @type {?} */
      var _native9 =
      /** @type {?} */
      getNativeByTNode(hostTNode, lView);
      /** @type {?} */


      var tView = getOrCreateTComponentView(def); // Only component views should be added to the view tree directly. Embedded views are
      // accessed through their containers because they may be removed / re-added later.

      /** @type {?} */

      var rendererFactory = lView[RENDERER_FACTORY];
      /** @type {?} */

      var componentView = addToViewTree(lView, createLView(lView, tView, null, def.onPush ? 64
      /* Dirty */
      : 16
      /* CheckAlways */
      , _native9,
      /** @type {?} */
      hostTNode, rendererFactory, rendererFactory.createRenderer(_native9, def))); // Component view will always be created before any injected LContainers,
      // so this is a regular element, wrap it with the component view

      lView[hostTNode.index] = componentView;
    }
    /**
     * @param {?} tNode
     * @param {?} lView
     * @param {?} name
     * @param {?} value
     * @param {?} sanitizer
     * @param {?} namespace
     * @return {?}
     */


    function elementAttributeInternal(tNode, lView, name, value, sanitizer, namespace) {
      ngDevMode && assertNotSame(value,
      /** @type {?} */
      NO_CHANGE, 'Incoming value should never be NO_CHANGE.');
      ngDevMode && validateAgainstEventAttributes(name);
      /** @type {?} */

      var element =
      /** @type {?} */
      getNativeByTNode(tNode, lView);
      /** @type {?} */

      var renderer = lView[RENDERER];

      if (value == null) {
        ngDevMode && ngDevMode.rendererRemoveAttribute++;
        isProceduralRenderer(renderer) ? renderer.removeAttribute(element, name, namespace) : element.removeAttribute(name);
      } else {
        ngDevMode && ngDevMode.rendererSetAttribute++;
        /** @type {?} */

        var strValue = sanitizer == null ? renderStringify(value) : sanitizer(value, tNode.tagName || '', name);

        if (isProceduralRenderer(renderer)) {
          renderer.setAttribute(element, name, strValue, namespace);
        } else {
          namespace ? element.setAttributeNS(namespace, name, strValue) : element.setAttribute(name, strValue);
        }
      }
    }
    /**
     * Sets initial input properties on directive instances from attribute data
     *
     * @template T
     * @param {?} lView Current LView that is being processed.
     * @param {?} directiveIndex Index of the directive in directives array
     * @param {?} instance Instance of the directive on which to set the initial inputs
     * @param {?} def The directive def that contains the list of inputs
     * @param {?} tNode The static data for this node
     * @param {?} initialInputData
     * @return {?}
     */


    function setInputsFromAttrs(lView, directiveIndex, instance, def, tNode, initialInputData) {
      /** @type {?} */
      var initialInputs =
      /** @type {?} */
      initialInputData[directiveIndex];

      if (initialInputs !== null) {
        /** @type {?} */
        var setInput = def.setInput;

        for (var i = 0; i < initialInputs.length;) {
          /** @type {?} */
          var publicName = initialInputs[i++];
          /** @type {?} */

          var privateName = initialInputs[i++];
          /** @type {?} */

          var value = initialInputs[i++];

          if (setInput !== null) {
            /** @type {?} */
            def.setInput(instance, value, publicName, privateName);
          } else {
            /** @type {?} */
            instance[privateName] = value;
          }

          if (ngDevMode) {
            /** @type {?} */
            var nativeElement =
            /** @type {?} */
            getNativeByTNode(tNode, lView);
            setNgReflectProperty(lView, nativeElement, tNode.type, privateName, value);
          }
        }
      }
    }
    /**
     * Generates initialInputData for a node and stores it in the template's static storage
     * so subsequent template invocations don't have to recalculate it.
     *
     * initialInputData is an array containing values that need to be set as input properties
     * for directives on this node, but only once on creation. We need this array to support
     * the case where you set an \@Input property of a directive using attribute-like syntax.
     * e.g. if you have a `name` \@Input, you can set it once like this:
     *
     * <my-component name="Bess"></my-component>
     *
     * @param {?} inputs The list of inputs from the directive def
     * @param {?} attrs The static attrs on this node
     * @return {?}
     */


    function generateInitialInputs(inputs, attrs) {
      /** @type {?} */
      var inputsToStore = null;
      /** @type {?} */

      var i = 0;

      while (i < attrs.length) {
        /** @type {?} */
        var attrName = attrs[i];

        if (attrName === 0
        /* NamespaceURI */
        ) {
            // We do not allow inputs on namespaced attributes.
            i += 4;
            continue;
          } else if (attrName === 5
        /* ProjectAs */
        ) {
            // Skip over the `ngProjectAs` value.
            i += 2;
            continue;
          } // If we hit any other attribute markers, we're done anyway. None of those are valid inputs.


        if (typeof attrName === 'number') break;

        if (inputs.hasOwnProperty(
        /** @type {?} */
        attrName)) {
          if (inputsToStore === null) inputsToStore = [];
          inputsToStore.push(
          /** @type {?} */
          attrName, inputs[
          /** @type {?} */
          attrName],
          /** @type {?} */
          attrs[i + 1]);
        }

        i += 2;
      }

      return inputsToStore;
    } //////////////////////////
    //// ViewContainer & View
    //////////////////////////
    // Not sure why I need to do `any` here but TS complains later.

    /** @type {?} */


    var LContainerArray = (typeof ngDevMode === 'undefined' || ngDevMode) && initNgDevMode() && createNamedArrayType('LContainer');
    /**
     * Creates a LContainer, either from a container instruction, or for a ViewContainerRef.
     *
     * @param {?} hostNative The host element for the LContainer
     * @param {?} currentView The parent view of the LContainer
     * @param {?} native The native comment element
     * @param {?} tNode
     * @return {?} LContainer
     */

    function createLContainer(hostNative, currentView, _native10, tNode) {
      ngDevMode && assertLView(currentView);
      ngDevMode && !isProceduralRenderer(currentView[RENDERER]) && assertDomNode(_native10); // https://jsperf.com/array-literal-vs-new-array-really

      /** @type {?} */

      var lContainer = new (ngDevMode ? LContainerArray : Array)(hostNative, // host native
      true, // Boolean `true` in this position signifies that this is an `LContainer`
      -1
      /* DYNAMIC_EMBEDDED_VIEWS_ONLY */
      << 1
      /* SHIFT */
      , // active index
      currentView, // parent
      null, // next
      null, // queries
      tNode, // t_host
      _native10, // native,
      null);
      ngDevMode && attachLContainerDebug(lContainer);
      return lContainer;
    }
    /**
     * Goes over dynamic embedded views (ones created through ViewContainerRef APIs) and refreshes
     * them by executing an associated template function.
     * @param {?} lView
     * @return {?}
     */


    function refreshDynamicEmbeddedViews(lView) {
      /** @type {?} */
      var viewOrContainer = lView[CHILD_HEAD];

      while (viewOrContainer !== null) {
        // Note: viewOrContainer can be an LView or an LContainer instance, but here we are only
        // interested in LContainer

        /** @type {?} */
        var activeIndexFlag = void 0;

        if (isLContainer(viewOrContainer) && (activeIndexFlag = viewOrContainer[ACTIVE_INDEX]) >> 1
        /* SHIFT */
        === -1
        /* DYNAMIC_EMBEDDED_VIEWS_ONLY */
        ) {
            for (var i = CONTAINER_HEADER_OFFSET; i < viewOrContainer.length; i++) {
              /** @type {?} */
              var embeddedLView =
              /** @type {?} */
              viewOrContainer[i];
              /** @type {?} */

              var embeddedTView = embeddedLView[TVIEW];
              ngDevMode && assertDefined(embeddedTView, 'TView must be allocated');

              if (viewAttachedToChangeDetector(embeddedLView)) {
                refreshView(embeddedTView, embeddedLView, embeddedTView.template,
                /** @type {?} */
                embeddedLView[CONTEXT]);
              }
            }

            if ((activeIndexFlag & 1
            /* HAS_TRANSPLANTED_VIEWS */
            ) !== 0) {
              // We should only CD moved views if the component where they were inserted does not match
              // the component where they were declared and insertion is on-push. Moved views also
              // contains intra component moves, or check-always which need to be skipped.
              refreshTransplantedViews(viewOrContainer,
              /** @type {?} */
              lView[DECLARATION_COMPONENT_VIEW]);
            }
          }

        viewOrContainer = viewOrContainer[NEXT];
      }
    }
    /**
     * Refresh transplanted LViews.
     *
     * See: `ActiveIndexFlag.HAS_TRANSPLANTED_VIEWS` and `LView[DECLARATION_COMPONENT_VIEW]` for
     * explanation of transplanted views.
     *
     * @param {?} lContainer The `LContainer` which has transplanted views.
     * @param {?} declaredComponentLView The `lContainer` parent component `LView`.
     * @return {?}
     */


    function refreshTransplantedViews(lContainer, declaredComponentLView) {
      /** @type {?} */
      var movedViews =
      /** @type {?} */
      lContainer[MOVED_VIEWS];
      ngDevMode && assertDefined(movedViews, 'Transplanted View flags set but missing MOVED_VIEWS');

      for (var i = 0; i < movedViews.length; i++) {
        /** @type {?} */
        var movedLView =
        /** @type {?} */
        movedViews[i];
        /** @type {?} */

        var insertionLContainer =
        /** @type {?} */
        movedLView[PARENT];
        ngDevMode && assertLContainer(insertionLContainer);
        /** @type {?} */

        var insertedComponentLView =
        /** @type {?} */
        insertionLContainer[PARENT][DECLARATION_COMPONENT_VIEW];
        ngDevMode && assertDefined(insertedComponentLView, 'Missing LView'); // Check if we have a transplanted view by compering declaration and insertion location.

        if (insertedComponentLView !== declaredComponentLView) {
          // Yes the `LView` is transplanted.
          // Here we would like to know if the component is `OnPush`. We don't have
          // explicit `OnPush` flag instead we set `CheckAlways` to false (which is `OnPush`)
          // Not to be confused with `ManualOnPush` which is used with wether a DOM event
          // should automatically mark a view as dirty.

          /** @type {?} */
          var insertionComponentIsOnPush = (insertedComponentLView[FLAGS] & 16
          /* CheckAlways */
          ) === 0;

          if (insertionComponentIsOnPush) {
            // Here we know that the template has been transplanted across components and is
            // on-push (not just moved within a component). If the insertion is marked dirty, then
            // there is no need to CD here as we will do it again later when we get to insertion
            // point.

            /** @type {?} */
            var movedTView = movedLView[TVIEW];
            ngDevMode && assertDefined(movedTView, 'TView must be allocated');
            refreshView(movedTView, movedLView, movedTView.template,
            /** @type {?} */
            movedLView[CONTEXT]);
          }
        }
      }
    } /////////////

    /**
     * Refreshes components by entering the component view and processing its bindings, queries, etc.
     *
     * @param {?} hostLView
     * @param {?} componentHostIdx  Element index in LView[] (adjusted for HEADER_OFFSET)
     * @return {?}
     */


    function refreshComponent(hostLView, componentHostIdx) {
      ngDevMode && assertEqual(isCreationMode(hostLView), false, 'Should be run in update mode');
      /** @type {?} */

      var componentView = getComponentLViewByIndex(componentHostIdx, hostLView); // Only attached components that are CheckAlways or OnPush and dirty should be refreshed

      if (viewAttachedToChangeDetector(componentView) && componentView[FLAGS] & (16
      /* CheckAlways */
      | 64
      /* Dirty */
      )) {
        /** @type {?} */
        var componentTView = componentView[TVIEW];
        refreshView(componentTView, componentView, componentTView.template, componentView[CONTEXT]);
      }
    }
    /**
     * @param {?} hostLView
     * @param {?} componentHostIdx
     * @return {?}
     */


    function renderComponent(hostLView, componentHostIdx) {
      ngDevMode && assertEqual(isCreationMode(hostLView), true, 'Should be run in creation mode');
      /** @type {?} */

      var componentView = getComponentLViewByIndex(componentHostIdx, hostLView);
      /** @type {?} */

      var componentTView = componentView[TVIEW];
      syncViewWithBlueprint(componentTView, componentView);
      renderView(componentTView, componentView, componentView[CONTEXT]);
    }
    /**
     * Syncs an LView instance with its blueprint if they have gotten out of sync.
     *
     * Typically, blueprints and their view instances should always be in sync, so the loop here
     * will be skipped. However, consider this case of two components side-by-side:
     *
     * App template:
     * ```
     * <comp></comp>
     * <comp></comp>
     * ```
     *
     * The following will happen:
     * 1. App template begins processing.
     * 2. First <comp> is matched as a component and its LView is created.
     * 3. Second <comp> is matched as a component and its LView is created.
     * 4. App template completes processing, so it's time to check child templates.
     * 5. First <comp> template is checked. It has a directive, so its def is pushed to blueprint.
     * 6. Second <comp> template is checked. Its blueprint has been updated by the first
     * <comp> template, but its LView was created before this update, so it is out of sync.
     *
     * Note that embedded views inside ngFor loops will never be out of sync because these views
     * are processed as soon as they are created.
     *
     * @param {?} tView The `TView` that contains the blueprint for syncing
     * @param {?} lView The view to sync
     * @return {?}
     */


    function syncViewWithBlueprint(tView, lView) {
      for (var i = lView.length; i < tView.blueprint.length; i++) {
        lView.push(tView.blueprint[i]);
      }
    }
    /**
     * Adds LView or LContainer to the end of the current view tree.
     *
     * This structure will be used to traverse through nested views to remove listeners
     * and call onDestroy callbacks.
     *
     * @template T
     * @param {?} lView The view where LView or LContainer should be added
     * @param {?} lViewOrLContainer The LView or LContainer to add to the view tree
     * @return {?} The state passed in
     */


    function addToViewTree(lView, lViewOrLContainer) {
      // TODO(benlesh/misko): This implementation is incorrect, because it always adds the LContainer
      // to the end of the queue, which means if the developer retrieves the LContainers from RNodes out
      // of order, the change detection will run out of order, as the act of retrieving the the
      // LContainer from the RNode is what adds it to the queue.
      if (lView[CHILD_HEAD]) {
        /** @type {?} */
        lView[CHILD_TAIL][NEXT] = lViewOrLContainer;
      } else {
        lView[CHILD_HEAD] = lViewOrLContainer;
      }

      lView[CHILD_TAIL] = lViewOrLContainer;
      return lViewOrLContainer;
    } ///////////////////////////////
    //// Change detection
    ///////////////////////////////

    /**
     * Marks current view and all ancestors dirty.
     *
     * Returns the root view because it is found as a byproduct of marking the view tree
     * dirty, and can be used by methods that consume markViewDirty() to easily schedule
     * change detection. Otherwise, such methods would need to traverse up the view tree
     * an additional time to get the root view and schedule a tick on it.
     *
     * @param {?} lView The starting LView to mark dirty
     * @return {?} the root LView
     */


    function markViewDirty(lView) {
      while (lView) {
        lView[FLAGS] |= 64
        /* Dirty */
        ;
        /** @type {?} */

        var parent = getLViewParent(lView); // Stop traversing up as soon as you find a root view that wasn't attached to any container

        if (isRootView(lView) && !parent) {
          return lView;
        } // continue otherwise


        lView =
        /** @type {?} */
        parent;
      }

      return null;
    }
    /**
     * Used to schedule change detection on the whole application.
     *
     * Unlike `tick`, `scheduleTick` coalesces multiple calls into one change detection run.
     * It is usually called indirectly by calling `markDirty` when the view needs to be
     * re-rendered.
     *
     * Typically `scheduleTick` uses `requestAnimationFrame` to coalesce multiple
     * `scheduleTick` requests. The scheduling function can be overridden in
     * `renderComponent`'s `scheduler` option.
     * @param {?} rootContext
     * @param {?} flags
     * @return {?}
     */


    function scheduleTick(rootContext, flags) {
      /** @type {?} */
      var nothingScheduled = rootContext.flags === 0
      /* Empty */
      ;
      rootContext.flags |= flags;

      if (nothingScheduled && rootContext.clean == _CLEAN_PROMISE) {
        /** @type {?} */
        var res;
        rootContext.clean = new Promise(
        /**
        * @param {?} r
        * @return {?}
        */
        function (r) {
          return res = r;
        });
        rootContext.scheduler(
        /**
        * @return {?}
        */
        function () {
          if (rootContext.flags & 1
          /* DetectChanges */
          ) {
              rootContext.flags &= ~1
              /* DetectChanges */
              ;
              tickRootContext(rootContext);
            }

          if (rootContext.flags & 2
          /* FlushPlayers */
          ) {
              rootContext.flags &= ~2
              /* FlushPlayers */
              ;
              /** @type {?} */

              var playerHandler = rootContext.playerHandler;

              if (playerHandler) {
                playerHandler.flushPlayers();
              }
            }

          rootContext.clean = _CLEAN_PROMISE;

          /** @type {?} */
          res(null);
        });
      }
    }
    /**
     * @param {?} rootContext
     * @return {?}
     */


    function tickRootContext(rootContext) {
      for (var i = 0; i < rootContext.components.length; i++) {
        /** @type {?} */
        var rootComponent = rootContext.components[i];
        /** @type {?} */

        var lView =
        /** @type {?} */
        readPatchedLView(rootComponent);
        /** @type {?} */

        var tView = lView[TVIEW];
        renderComponentOrTemplate(tView, lView, tView.template, rootComponent);
      }
    }
    /**
     * @template T
     * @param {?} tView
     * @param {?} lView
     * @param {?} context
     * @return {?}
     */


    function detectChangesInternal(tView, lView, context) {
      /** @type {?} */
      var rendererFactory = lView[RENDERER_FACTORY];
      if (rendererFactory.begin) rendererFactory.begin();

      try {
        refreshView(tView, lView, tView.template, context);
      } catch (error) {
        handleError(lView, error);
        throw error;
      } finally {
        if (rendererFactory.end) rendererFactory.end();
      }
    }
    /**
     * Synchronously perform change detection on a root view and its components.
     *
     * @param {?} lView The view which the change detection should be performed on.
     * @return {?}
     */


    function detectChangesInRootView(lView) {
      tickRootContext(
      /** @type {?} */
      lView[CONTEXT]);
    }
    /**
     * @template T
     * @param {?} tView
     * @param {?} view
     * @param {?} context
     * @return {?}
     */


    function checkNoChangesInternal(tView, view, context) {
      setCheckNoChangesMode(true);

      try {
        detectChangesInternal(tView, view, context);
      } finally {
        setCheckNoChangesMode(false);
      }
    }
    /**
     * Checks the change detector on a root view and its components, and throws if any changes are
     * detected.
     *
     * This is used in development mode to verify that running change detection doesn't
     * introduce other changes.
     *
     * @param {?} lView The view which the change detection should be checked on.
     * @return {?}
     */


    function checkNoChangesInRootView(lView) {
      setCheckNoChangesMode(true);

      try {
        detectChangesInRootView(lView);
      } finally {
        setCheckNoChangesMode(false);
      }
    }
    /**
     * @template T
     * @param {?} flags
     * @param {?} viewQueryFn
     * @param {?} component
     * @return {?}
     */


    function executeViewQueryFn(flags, viewQueryFn, component) {
      ngDevMode && assertDefined(viewQueryFn, 'View queries function to execute must be defined.');
      setCurrentQueryIndex(0);
      viewQueryFn(flags, component);
    } ///////////////////////////////
    //// Bindings & interpolations
    ///////////////////////////////

    /**
     * Stores meta-data for a property binding to be used by TestBed's `DebugElement.properties`.
     *
     * In order to support TestBed's `DebugElement.properties` we need to save, for each binding:
     * - a bound property name;
     * - a static parts of interpolated strings;
     *
     * A given property metadata is saved at the binding's index in the `TView.data` (in other words, a
     * property binding metadata will be stored in `TView.data` at the same index as a bound value in
     * `LView`). Metadata are represented as `INTERPOLATION_DELIMITER`-delimited string with the
     * following format:
     * - `propertyName` for bound properties;
     * - `propertyName�prefix�interpolation_static_part1�..interpolation_static_partN�suffix` for
     * interpolated properties.
     *
     * @param {?} tData `TData` where meta-data will be saved;
     * @param {?} tNode `TNode` that is a target of the binding;
     * @param {?} propertyName bound property name;
     * @param {?} bindingIndex binding index in `LView`
     * @param {...?} interpolationParts static interpolation parts (for property interpolations)
     * @return {?}
     */


    function storePropertyBindingMetadata(tData, tNode, propertyName, bindingIndex) {
      // Binding meta-data are stored only the first time a given property instruction is processed.
      // Since we don't have a concept of the "first update pass" we need to check for presence of the
      // binding meta-data to decide if one should be stored (or if was stored already).
      if (tData[bindingIndex] === null) {
        if (tNode.inputs == null || !tNode.inputs[propertyName]) {
          /** @type {?} */
          var propBindingIdxs = tNode.propertyBindings || (tNode.propertyBindings = []);
          propBindingIdxs.push(bindingIndex);
          /** @type {?} */

          var bindingMetadata = propertyName;

          for (var _len14 = arguments.length, interpolationParts = new Array(_len14 > 4 ? _len14 - 4 : 0), _key15 = 4; _key15 < _len14; _key15++) {
            interpolationParts[_key15 - 4] = arguments[_key15];
          }

          if (interpolationParts.length > 0) {
            bindingMetadata += INTERPOLATION_DELIMITER + interpolationParts.join(INTERPOLATION_DELIMITER);
          }

          tData[bindingIndex] = bindingMetadata;
        }
      }
    }
    /** @type {?} */


    var CLEAN_PROMISE = _CLEAN_PROMISE;
    /**
     * @param {?} view
     * @return {?}
     */

    function getLCleanup(view) {
      // top level variables should not be exported for performance reasons (PERF_NOTES.md)
      return view[CLEANUP] || (view[CLEANUP] = ngDevMode ? new LCleanup() : []);
    }
    /**
     * @param {?} tView
     * @return {?}
     */


    function getTViewCleanup(tView) {
      return tView.cleanup || (tView.cleanup = ngDevMode ? new TCleanup() : []);
    }
    /**
     * There are cases where the sub component's renderer needs to be included
     * instead of the current renderer (see the componentSyntheticHost* instructions).
     * @param {?} currentDef
     * @param {?} tNode
     * @param {?} lView
     * @return {?}
     */


    function loadComponentRenderer(currentDef, tNode, lView) {
      // TODO(FW-2043): the `currentDef` is null when host bindings are invoked while creating root
      // component (see packages/core/src/render3/component.ts). This is not consistent with the process
      // of creating inner components, when current directive index is available in the state. In order
      // to avoid relying on current def being `null` (thus special-casing root component creation), the
      // process of creating root component should be unified with the process of creating inner
      // components.
      if (currentDef === null || isComponentDef(currentDef)) {
        lView =
        /** @type {?} */
        unwrapLView(lView[tNode.index]);
      }

      return lView[RENDERER];
    }
    /**
     * Handles an error thrown in an LView.
     * @param {?} lView
     * @param {?} error
     * @return {?}
     */


    function handleError(lView, error) {
      /** @type {?} */
      var injector = lView[INJECTOR$1];
      /** @type {?} */

      var errorHandler = injector ? injector.get(ErrorHandler, null) : null;
      errorHandler && errorHandler.handleError(error);
    }
    /**
     * Set the inputs of directives at the current node to corresponding value.
     *
     * @param {?} tView The current TView
     * @param {?} lView the `LView` which contains the directives.
     * @param {?} inputs mapping between the public "input" name and privately-known,
     *        possibly minified, property names to write to.
     * @param {?} publicName
     * @param {?} value Value to set.
     * @return {?}
     */


    function setInputsForProperty(tView, lView, inputs, publicName, value) {
      for (var i = 0; i < inputs.length;) {
        /** @type {?} */
        var index =
        /** @type {?} */
        inputs[i++];
        /** @type {?} */

        var privateName =
        /** @type {?} */
        inputs[i++];
        /** @type {?} */

        var instance = lView[index];
        ngDevMode && assertDataInRange(lView, index);
        /** @type {?} */

        var def =
        /** @type {?} */
        tView.data[index];

        if (def.setInput !== null) {
          /** @type {?} */
          def.setInput(instance, value, publicName, privateName);
        } else {
          instance[privateName] = value;
        }
      }
    }
    /**
     * Updates a text binding at a given index in a given LView.
     * @param {?} lView
     * @param {?} index
     * @param {?} value
     * @return {?}
     */


    function textBindingInternal(lView, index, value) {
      ngDevMode && assertNotSame(value,
      /** @type {?} */
      NO_CHANGE, 'value should not be NO_CHANGE');
      ngDevMode && assertDataInRange(lView, index + HEADER_OFFSET);
      /** @type {?} */

      var element =
      /** @type {?} */

      /** @type {?} */
      getNativeByIndex(index, lView);
      ngDevMode && assertDefined(element, 'native element should exist');
      ngDevMode && ngDevMode.rendererSetText++;
      /** @type {?} */

      var renderer = lView[RENDERER];
      isProceduralRenderer(renderer) ? renderer.setValue(element, value) : element.textContent = value;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/node_manipulation.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var unusedValueToPlacateAjd$1 = unusedValueExportToPlacateAjd$1 + unusedValueExportToPlacateAjd$4 + unusedValueExportToPlacateAjd$5 + unusedValueExportToPlacateAjd$2 + unusedValueExportToPlacateAjd;
    /**
     * @param {?} tNode
     * @param {?} embeddedView
     * @return {?}
     */

    function getLContainer(tNode, embeddedView) {
      ngDevMode && assertLView(embeddedView);
      /** @type {?} */

      var container =
      /** @type {?} */
      embeddedView[PARENT];

      if (tNode.index === -1) {
        // This is a dynamically created view inside a dynamic container.
        // The parent isn't an LContainer if the embedded view hasn't been attached yet.
        return isLContainer(container) ? container : null;
      } else {
        ngDevMode && assertLContainer(container); // This is a inline view node (e.g. embeddedViewStart)

        return container;
      }
    }
    /**
     * Retrieves render parent for a given view.
     * Might be null if a view is not yet attached to any container.
     * @param {?} tViewNode
     * @param {?} view
     * @return {?}
     */


    function getContainerRenderParent(tViewNode, view) {
      /** @type {?} */
      var container = getLContainer(tViewNode, view);
      return container ? nativeParentNode(view[RENDERER], container[NATIVE]) : null;
    }
    /** @enum {number} */


    var WalkTNodeTreeAction = {
      /** node create in the native environment. Run on initial creation. */
      Create: 0,

      /**
       * node insert in the native environment.
       * Run when existing node has been detached and needs to be re-attached.
       */
      Insert: 1,

      /** node detach from the native environment */
      Detach: 2,

      /** node destruction using the renderer's API */
      Destroy: 3
    };
    /**
     * NOTE: for performance reasons, the possible actions are inlined within the function instead of
     * being passed as an argument.
     * @param {?} action
     * @param {?} renderer
     * @param {?} parent
     * @param {?} lNodeToHandle
     * @param {?=} beforeNode
     * @return {?}
     */

    function applyToElementOrContainer(action, renderer, parent, lNodeToHandle, beforeNode) {
      // If this slot was allocated for a text node dynamically created by i18n, the text node itself
      // won't be created until i18nApply() in the update block, so this node should be skipped.
      // For more info, see "ICU expressions should work inside an ngTemplateOutlet inside an ngFor"
      // in `i18n_spec.ts`.
      if (lNodeToHandle != null) {
        /** @type {?} */
        var lContainer;
        /** @type {?} */

        var isComponent = false; // We are expecting an RNode, but in the case of a component or LContainer the `RNode` is
        // wrapped in an array which needs to be unwrapped. We need to know if it is a component and if
        // it has LContainer so that we can process all of those cases appropriately.

        if (isLContainer(lNodeToHandle)) {
          lContainer = lNodeToHandle;
        } else if (isLView(lNodeToHandle)) {
          isComponent = true;
          ngDevMode && assertDefined(lNodeToHandle[HOST], 'HOST must be defined for a component LView');
          lNodeToHandle =
          /** @type {?} */
          lNodeToHandle[HOST];
        }
        /** @type {?} */


        var rNode = unwrapRNode(lNodeToHandle);
        ngDevMode && !isProceduralRenderer(renderer) && assertDomNode(rNode);

        if (action === 0
        /* Create */
        && parent !== null) {
          if (beforeNode == null) {
            nativeAppendChild(renderer, parent, rNode);
          } else {
            nativeInsertBefore(renderer, parent, rNode, beforeNode || null);
          }
        } else if (action === 1
        /* Insert */
        && parent !== null) {
          nativeInsertBefore(renderer, parent, rNode, beforeNode || null);
        } else if (action === 2
        /* Detach */
        ) {
            nativeRemoveNode(renderer, rNode, isComponent);
          } else if (action === 3
        /* Destroy */
        ) {
            ngDevMode && ngDevMode.rendererDestroyNode++;

            /** @type {?} */

            /** @type {?} */
            renderer.destroyNode(rNode);
          }

        if (lContainer != null) {
          applyContainer(renderer, action, lContainer, parent, beforeNode);
        }
      }
    }
    /**
     * @param {?} value
     * @param {?} renderer
     * @return {?}
     */


    function createTextNode(value, renderer) {
      ngDevMode && ngDevMode.rendererCreateTextNode++;
      ngDevMode && ngDevMode.rendererSetText++;
      return isProceduralRenderer(renderer) ? renderer.createText(value) : renderer.createTextNode(value);
    }
    /**
     * @param {?} tView
     * @param {?} lView
     * @param {?} insertMode
     * @param {?} beforeNode
     * @return {?}
     */


    function addRemoveViewFromContainer(tView, lView, insertMode, beforeNode) {
      /** @type {?} */
      var renderParent = getContainerRenderParent(
      /** @type {?} */
      tView.node, lView);
      ngDevMode && assertNodeType(
      /** @type {?} */
      tView.node, 2
      /* View */
      );

      if (renderParent) {
        /** @type {?} */
        var renderer = lView[RENDERER];
        /** @type {?} */

        var action = insertMode ? 1
        /* Insert */
        : 2
        /* Detach */
        ;
        applyView(tView, lView, renderer, action, renderParent, beforeNode);
      }
    }
    /**
     * Detach a `LView` from the DOM by detaching its nodes.
     *
     * @param {?} tView The `TView' of the `LView` to be detached
     * @param {?} lView the `LView` to be detached.
     * @return {?}
     */


    function renderDetachView(tView, lView) {
      applyView(tView, lView, lView[RENDERER], 2
      /* Detach */
      , null, null);
    }
    /**
     * Traverses down and up the tree of views and containers to remove listeners and
     * call onDestroy callbacks.
     *
     * Notes:
     *  - Because it's used for onDestroy calls, it needs to be bottom-up.
     *  - Must process containers instead of their views to avoid splicing
     *  when views are destroyed and re-added.
     *  - Using a while loop because it's faster than recursion
     *  - Destroy only called on movement to sibling or movement to parent (laterally or up)
     *
     * @param {?} rootView The view to destroy
     * @return {?}
     */


    function destroyViewTree(rootView) {
      // If the view has no children, we can clean it up and return early.

      /** @type {?} */
      var lViewOrLContainer = rootView[CHILD_HEAD];

      if (!lViewOrLContainer) {
        return cleanUpView(rootView[TVIEW], rootView);
      }

      while (lViewOrLContainer) {
        /** @type {?} */
        var next = null;

        if (isLView(lViewOrLContainer)) {
          // If LView, traverse down to child.
          next = lViewOrLContainer[CHILD_HEAD];
        } else {
          ngDevMode && assertLContainer(lViewOrLContainer); // If container, traverse down to its first LView.

          /** @type {?} */

          var firstView = lViewOrLContainer[CONTAINER_HEADER_OFFSET];
          if (firstView) next = firstView;
        }

        if (!next) {
          // Only clean up view when moving to the side or up, as destroy hooks
          // should be called in order from the bottom up.
          while (lViewOrLContainer && !
          /** @type {?} */
          lViewOrLContainer[NEXT] && lViewOrLContainer !== rootView) {
            isLView(lViewOrLContainer) && cleanUpView(lViewOrLContainer[TVIEW], lViewOrLContainer);
            lViewOrLContainer = getParentState(lViewOrLContainer, rootView);
          }

          if (lViewOrLContainer === null) lViewOrLContainer = rootView;
          isLView(lViewOrLContainer) && cleanUpView(lViewOrLContainer[TVIEW], lViewOrLContainer);
          next = lViewOrLContainer &&
          /** @type {?} */
          lViewOrLContainer[NEXT];
        }

        lViewOrLContainer = next;
      }
    }
    /**
     * Inserts a view into a container.
     *
     * This adds the view to the container's array of active views in the correct
     * position. It also adds the view's elements to the DOM if the container isn't a
     * root node of another view (in that case, the view's elements will be added when
     * the container's parent view is added later).
     *
     * @param {?} tView The `TView' of the `LView` to insert
     * @param {?} lView The view to insert
     * @param {?} lContainer The container into which the view should be inserted
     * @param {?} index Which index in the container to insert the child view into
     * @return {?}
     */


    function insertView(tView, lView, lContainer, index) {
      ngDevMode && assertLView(lView);
      ngDevMode && assertLContainer(lContainer);
      /** @type {?} */

      var indexInContainer = CONTAINER_HEADER_OFFSET + index;
      /** @type {?} */

      var containerLength = lContainer.length;

      if (index > 0) {
        // This is a new view, we need to add it to the children.
        lContainer[indexInContainer - 1][NEXT] = lView;
      }

      if (index < containerLength - CONTAINER_HEADER_OFFSET) {
        lView[NEXT] = lContainer[indexInContainer];
        addToArray(lContainer, CONTAINER_HEADER_OFFSET + index, lView);
      } else {
        lContainer.push(lView);
        lView[NEXT] = null;
      }

      lView[PARENT] = lContainer; // track views where declaration and insertion points are different

      /** @type {?} */

      var declarationLContainer = lView[DECLARATION_LCONTAINER];

      if (declarationLContainer !== null && lContainer !== declarationLContainer) {
        trackMovedView(declarationLContainer, lView);
      } // notify query that a new view has been added

      /** @type {?} */


      var lQueries = lView[QUERIES];

      if (lQueries !== null) {
        lQueries.insertView(tView);
      } // Sets the attached flag


      lView[FLAGS] |= 128
      /* Attached */
      ;
    }
    /**
     * Track views created from the declaration container (TemplateRef) and inserted into a
     * different LContainer.
     * @param {?} declarationContainer
     * @param {?} lView
     * @return {?}
     */


    function trackMovedView(declarationContainer, lView) {
      ngDevMode && assertDefined(lView, 'LView required');
      ngDevMode && assertLContainer(declarationContainer);
      /** @type {?} */

      var movedViews = declarationContainer[MOVED_VIEWS];
      /** @type {?} */

      var insertedLContainer =
      /** @type {?} */
      lView[PARENT];
      ngDevMode && assertLContainer(insertedLContainer);
      /** @type {?} */

      var insertedComponentLView =
      /** @type {?} */
      insertedLContainer[PARENT][DECLARATION_COMPONENT_VIEW];
      ngDevMode && assertDefined(insertedComponentLView, 'Missing insertedComponentLView');
      /** @type {?} */

      var insertedComponentIsOnPush = (insertedComponentLView[FLAGS] & 16
      /* CheckAlways */
      ) !== 16
      /* CheckAlways */
      ;

      if (insertedComponentIsOnPush) {
        /** @type {?} */
        var declaredComponentLView = lView[DECLARATION_COMPONENT_VIEW];
        ngDevMode && assertDefined(declaredComponentLView, 'Missing declaredComponentLView');

        if (declaredComponentLView !== insertedComponentLView) {
          // At this point the declaration-component is not same as insertion-component and we are in
          // on-push mode, this means that this is a transplanted view. Mark the declared lView as
          // having
          // transplanted views so that those views can participate in CD.
          declarationContainer[ACTIVE_INDEX] |= 1
          /* HAS_TRANSPLANTED_VIEWS */
          ;
        }
      }

      if (movedViews === null) {
        declarationContainer[MOVED_VIEWS] = [lView];
      } else {
        movedViews.push(lView);
      }
    }
    /**
     * @param {?} declarationContainer
     * @param {?} lView
     * @return {?}
     */


    function detachMovedView(declarationContainer, lView) {
      ngDevMode && assertLContainer(declarationContainer);
      ngDevMode && assertDefined(declarationContainer[MOVED_VIEWS], 'A projected view should belong to a non-empty projected views collection');
      /** @type {?} */

      var movedViews =
      /** @type {?} */
      declarationContainer[MOVED_VIEWS];
      /** @type {?} */

      var declaredViewIndex = movedViews.indexOf(lView);
      movedViews.splice(declaredViewIndex, 1);
    }
    /**
     * Detaches a view from a container.
     *
     * This method removes the view from the container's array of active views. It also
     * removes the view's elements from the DOM.
     *
     * @param {?} lContainer The container from which to detach a view
     * @param {?} removeIndex The index of the view to detach
     * @return {?} Detached LView instance.
     */


    function detachView(lContainer, removeIndex) {
      if (lContainer.length <= CONTAINER_HEADER_OFFSET) return;
      /** @type {?} */

      var indexInContainer = CONTAINER_HEADER_OFFSET + removeIndex;
      /** @type {?} */

      var viewToDetach = lContainer[indexInContainer];

      if (viewToDetach) {
        /** @type {?} */
        var declarationLContainer = viewToDetach[DECLARATION_LCONTAINER];

        if (declarationLContainer !== null && declarationLContainer !== lContainer) {
          detachMovedView(declarationLContainer, viewToDetach);
        }

        if (removeIndex > 0) {
          lContainer[indexInContainer - 1][NEXT] =
          /** @type {?} */
          viewToDetach[NEXT];
        }
        /** @type {?} */


        var removedLView = removeFromArray(lContainer, CONTAINER_HEADER_OFFSET + removeIndex);
        addRemoveViewFromContainer(viewToDetach[TVIEW], viewToDetach, false, null); // notify query that a view has been removed

        /** @type {?} */

        var lQueries = removedLView[QUERIES];

        if (lQueries !== null) {
          lQueries.detachView(removedLView[TVIEW]);
        }

        viewToDetach[PARENT] = null;
        viewToDetach[NEXT] = null; // Unsets the attached flag

        viewToDetach[FLAGS] &= ~128
        /* Attached */
        ;
      }

      return viewToDetach;
    }
    /**
     * Removes a view from a container, i.e. detaches it and then destroys the underlying LView.
     *
     * @param {?} lContainer The container from which to remove a view
     * @param {?} removeIndex The index of the view to remove
     * @return {?}
     */


    function removeView(lContainer, removeIndex) {
      /** @type {?} */
      var detachedView = detachView(lContainer, removeIndex);
      detachedView && destroyLView(detachedView[TVIEW], detachedView);
    }
    /**
     * A standalone function which destroys an LView,
     * conducting clean up (e.g. removing listeners, calling onDestroys).
     *
     * @param {?} tView The `TView' of the `LView` to be destroyed
     * @param {?} lView The view to be destroyed.
     * @return {?}
     */


    function destroyLView(tView, lView) {
      if (!(lView[FLAGS] & 256
      /* Destroyed */
      )) {
        /** @type {?} */
        var renderer = lView[RENDERER];

        if (isProceduralRenderer(renderer) && renderer.destroyNode) {
          applyView(tView, lView, renderer, 3
          /* Destroy */
          , null, null);
        }

        destroyViewTree(lView);
      }
    }
    /**
     * Determines which LViewOrLContainer to jump to when traversing back up the
     * tree in destroyViewTree.
     *
     * Normally, the view's parent LView should be checked, but in the case of
     * embedded views, the container (which is the view node's parent, but not the
     * LView's parent) needs to be checked for a possible next property.
     *
     * @param {?} lViewOrLContainer The LViewOrLContainer for which we need a parent state
     * @param {?} rootView The rootView, so we don't propagate too far up the view tree
     * @return {?} The correct parent LViewOrLContainer
     */


    function getParentState(lViewOrLContainer, rootView) {
      /** @type {?} */
      var tNode;

      if (isLView(lViewOrLContainer) && (tNode = lViewOrLContainer[T_HOST]) && tNode.type === 2
      /* View */
      ) {
          // if it's an embedded view, the state needs to go up to the container, in case the
          // container has a next
          return getLContainer(
          /** @type {?} */
          tNode, lViewOrLContainer);
        } else {
        // otherwise, use parent view for containers or component views
        return lViewOrLContainer[PARENT] === rootView ? null : lViewOrLContainer[PARENT];
      }
    }
    /**
     * Calls onDestroys hooks for all directives and pipes in a given view and then removes all
     * listeners. Listeners are removed as the last step so events delivered in the onDestroys hooks
     * can be propagated to \@Output listeners.
     *
     * @param {?} tView `TView` for the `LView` to clean up.
     * @param {?} lView The LView to clean up
     * @return {?}
     */


    function cleanUpView(tView, lView) {
      if (!(lView[FLAGS] & 256
      /* Destroyed */
      )) {
        // Usually the Attached flag is removed when the view is detached from its parent, however
        // if it's a root view, the flag won't be unset hence why we're also removing on destroy.
        lView[FLAGS] &= ~128
        /* Attached */
        ; // Mark the LView as destroyed *before* executing the onDestroy hooks. An onDestroy hook
        // runs arbitrary user code, which could include its own `viewRef.destroy()` (or similar). If
        // We don't flag the view as destroyed before the hooks, this could lead to an infinite loop.
        // This also aligns with the ViewEngine behavior. It also means that the onDestroy hook is
        // really more of an "afterDestroy" hook if you think about it.

        lView[FLAGS] |= 256
        /* Destroyed */
        ;
        executeOnDestroys(tView, lView);
        removeListeners(tView, lView);
        /** @type {?} */

        var hostTNode = lView[T_HOST]; // For component views only, the local renderer is destroyed as clean up time.

        if (hostTNode && hostTNode.type === 3
        /* Element */
        && isProceduralRenderer(lView[RENDERER])) {
          ngDevMode && ngDevMode.rendererDestroy++;

          /** @type {?} */
          lView[RENDERER].destroy();
        }
        /** @type {?} */


        var declarationContainer = lView[DECLARATION_LCONTAINER]; // we are dealing with an embedded view that is still inserted into a container

        if (declarationContainer !== null && isLContainer(lView[PARENT])) {
          // and this is a projected view
          if (declarationContainer !== lView[PARENT]) {
            detachMovedView(declarationContainer, lView);
          } // For embedded views still attached to a container: remove query result from this view.

          /** @type {?} */


          var lQueries = lView[QUERIES];

          if (lQueries !== null) {
            lQueries.detachView(tView);
          }
        }
      }
    }
    /**
     * Removes listeners and unsubscribes from output subscriptions
     * @param {?} tView
     * @param {?} lView
     * @return {?}
     */


    function removeListeners(tView, lView) {
      /** @type {?} */
      var tCleanup = tView.cleanup;

      if (tCleanup !== null) {
        /** @type {?} */
        var lCleanup =
        /** @type {?} */
        lView[CLEANUP];

        for (var i = 0; i < tCleanup.length - 1; i += 2) {
          if (typeof tCleanup[i] === 'string') {
            // This is a native DOM listener

            /** @type {?} */
            var idxOrTargetGetter = tCleanup[i + 1];
            /** @type {?} */

            var target = typeof idxOrTargetGetter === 'function' ? idxOrTargetGetter(lView) : unwrapRNode(lView[idxOrTargetGetter]);
            /** @type {?} */

            var listener = lCleanup[tCleanup[i + 2]];
            /** @type {?} */

            var useCaptureOrSubIdx = tCleanup[i + 3];

            if (typeof useCaptureOrSubIdx === 'boolean') {
              // native DOM listener registered with Renderer3
              target.removeEventListener(tCleanup[i], listener, useCaptureOrSubIdx);
            } else {
              if (useCaptureOrSubIdx >= 0) {
                // unregister
                lCleanup[useCaptureOrSubIdx]();
              } else {
                // Subscription
                lCleanup[-useCaptureOrSubIdx].unsubscribe();
              }
            }

            i += 2;
          } else {
            // This is a cleanup function that is grouped with the index of its context

            /** @type {?} */
            var context = lCleanup[tCleanup[i + 1]];
            tCleanup[i].call(context);
          }
        }

        lView[CLEANUP] = null;
      }
    }
    /**
     * Calls onDestroy hooks for this view
     * @param {?} tView
     * @param {?} lView
     * @return {?}
     */


    function executeOnDestroys(tView, lView) {
      /** @type {?} */
      var destroyHooks;

      if (tView != null && (destroyHooks = tView.destroyHooks) != null) {
        for (var i = 0; i < destroyHooks.length; i += 2) {
          /** @type {?} */
          var context = lView[
          /** @type {?} */
          destroyHooks[i]]; // Only call the destroy hook if the context has been requested.

          if (!(context instanceof NodeInjectorFactory)) {
            /** @type {?} */
            var toCall =
            /** @type {?} */
            destroyHooks[i + 1];

            if (Array.isArray(toCall)) {
              for (var j = 0; j < toCall.length; j += 2) {
                /** @type {?} */
                toCall[j + 1].call(context[
                /** @type {?} */
                toCall[j]]);
              }
            } else {
              toCall.call(context);
            }
          }
        }
      }
    }
    /**
     * Returns a native element if a node can be inserted into the given parent.
     *
     * There are two reasons why we may not be able to insert a element immediately.
     * - Projection: When creating a child content element of a component, we have to skip the
     *   insertion because the content of a component will be projected.
     *   `<component><content>delayed due to projection</content></component>`
     * - Parent container is disconnected: This can happen when we are inserting a view into
     *   parent container, which itself is disconnected. For example the parent container is part
     *   of a View which has not be inserted or is made for projection but has not been inserted
     *   into destination.
     * @param {?} tView
     * @param {?} tNode
     * @param {?} currentView
     * @return {?}
     */


    function getRenderParent(tView, tNode, currentView) {
      // Skip over element and ICU containers as those are represented by a comment node and
      // can't be used as a render parent.

      /** @type {?} */
      var parentTNode = tNode.parent;

      while (parentTNode != null && (parentTNode.type === 4
      /* ElementContainer */
      || parentTNode.type === 5
      /* IcuContainer */
      )) {
        tNode = parentTNode;
        parentTNode = tNode.parent;
      } // If the parent tNode is null, then we are inserting across views: either into an embedded view
      // or a component view.


      if (parentTNode == null) {
        /** @type {?} */
        var hostTNode =
        /** @type {?} */
        currentView[T_HOST];

        if (hostTNode.type === 2
        /* View */
        ) {
            // We are inserting a root element of an embedded view We might delay insertion of children
            // for a given view if it is disconnected. This might happen for 2 main reasons:
            // - view is not inserted into any container(view was created but not inserted yet)
            // - view is inserted into a container but the container itself is not inserted into the DOM
            // (container might be part of projection or child of a view that is not inserted yet).
            // In other words we can insert children of a given view if this view was inserted into a
            // container and the container itself has its render parent determined.
            return getContainerRenderParent(
            /** @type {?} */
            hostTNode, currentView);
          } else {
          // We are inserting a root element of the component view into the component host element and
          // it should always be eager.
          ngDevMode && assertNodeOfPossibleTypes(hostTNode, 3
          /* Element */
          );
          return currentView[HOST];
        }
      } else {
        /** @type {?} */
        var isIcuCase = tNode && tNode.type === 5
        /* IcuContainer */
        ; // If the parent of this node is an ICU container, then it is represented by comment node and we
        // need to use it as an anchor. If it is projected then it's direct parent node is the renderer.

        if (isIcuCase && tNode.flags & 4
        /* isProjected */
        ) {
            return (
              /** @type {?} */
              getNativeByTNode(tNode, currentView).parentNode
            );
          }

        ngDevMode && assertNodeType(parentTNode, 3
        /* Element */
        );

        if (parentTNode.flags & 2
        /* isComponentHost */
        ) {
            /** @type {?} */
            var tData = tView.data;
            /** @type {?} */

            var _tNode2 =
            /** @type {?} */
            tData[parentTNode.index];
            /** @type {?} */

            var encapsulation =
            /** @type {?} */
            tData[_tNode2.directiveStart].encapsulation; // We've got a parent which is an element in the current view. We just need to verify if the
            // parent element is not a component. Component's content nodes are not inserted immediately
            // because they will be projected, and so doing insert at this point would be wasteful.
            // Since the projection would then move it to its final destination. Note that we can't
            // make this assumption when using the Shadow DOM, because the native projection placeholders
            // (<content> or <slot>) have to be in place as elements are being inserted.

            if (encapsulation !== ViewEncapsulation$1.ShadowDom && encapsulation !== ViewEncapsulation$1.Native) {
              return null;
            }
          }

        return (
          /** @type {?} */
          getNativeByTNode(parentTNode, currentView)
        );
      }
    }
    /**
     * Inserts a native node before another native node for a given parent using {\@link Renderer3}.
     * This is a utility function that can be used when native nodes were determined - it abstracts an
     * actual renderer being used.
     * @param {?} renderer
     * @param {?} parent
     * @param {?} child
     * @param {?} beforeNode
     * @return {?}
     */


    function nativeInsertBefore(renderer, parent, child, beforeNode) {
      ngDevMode && ngDevMode.rendererInsertBefore++;

      if (isProceduralRenderer(renderer)) {
        renderer.insertBefore(parent, child, beforeNode);
      } else {
        parent.insertBefore(child, beforeNode, true);
      }
    }
    /**
     * @param {?} renderer
     * @param {?} parent
     * @param {?} child
     * @return {?}
     */


    function nativeAppendChild(renderer, parent, child) {
      ngDevMode && ngDevMode.rendererAppendChild++;
      ngDevMode && assertDefined(parent, 'parent node must be defined');

      if (isProceduralRenderer(renderer)) {
        renderer.appendChild(parent, child);
      } else {
        parent.appendChild(child);
      }
    }
    /**
     * @param {?} renderer
     * @param {?} parent
     * @param {?} child
     * @param {?} beforeNode
     * @return {?}
     */


    function nativeAppendOrInsertBefore(renderer, parent, child, beforeNode) {
      if (beforeNode !== null) {
        nativeInsertBefore(renderer, parent, child, beforeNode);
      } else {
        nativeAppendChild(renderer, parent, child);
      }
    }
    /**
     * Removes a node from the DOM given its native parent.
     * @param {?} renderer
     * @param {?} parent
     * @param {?} child
     * @param {?=} isHostElement
     * @return {?}
     */


    function nativeRemoveChild(renderer, parent, child, isHostElement) {
      if (isProceduralRenderer(renderer)) {
        renderer.removeChild(parent, child, isHostElement);
      } else {
        parent.removeChild(child);
      }
    }
    /**
     * Returns a native parent of a given native node.
     * @param {?} renderer
     * @param {?} node
     * @return {?}
     */


    function nativeParentNode(renderer, node) {
      return (
        /** @type {?} */
        isProceduralRenderer(renderer) ? renderer.parentNode(node) : node.parentNode
      );
    }
    /**
     * Returns a native sibling of a given native node.
     * @param {?} renderer
     * @param {?} node
     * @return {?}
     */


    function nativeNextSibling(renderer, node) {
      return isProceduralRenderer(renderer) ? renderer.nextSibling(node) : node.nextSibling;
    }
    /**
     * Finds a native "anchor" node for cases where we can't append a native child directly
     * (`appendChild`) and need to use a reference (anchor) node for the `insertBefore` operation.
     * @param {?} parentTNode
     * @param {?} lView
     * @return {?}
     */


    function getNativeAnchorNode(parentTNode, lView) {
      if (parentTNode.type === 2
      /* View */
      ) {
          /** @type {?} */
          var lContainer = getLContainer(
          /** @type {?} */
          parentTNode, lView);
          if (lContainer === null) return null;
          /** @type {?} */

          var index = lContainer.indexOf(lView, CONTAINER_HEADER_OFFSET) - CONTAINER_HEADER_OFFSET;
          return getBeforeNodeForView(index, lContainer);
        } else if (parentTNode.type === 4
      /* ElementContainer */
      || parentTNode.type === 5
      /* IcuContainer */
      ) {
          return getNativeByTNode(parentTNode, lView);
        }

      return null;
    }
    /**
     * Appends the `child` native node (or a collection of nodes) to the `parent`.
     *
     * The element insertion might be delayed {\@link canInsertNativeNode}.
     *
     * @param {?} tView The `TView' to be appended
     * @param {?} lView The current LView
     * @param {?} childEl The native child (or children) that should be appended
     * @param {?} childTNode The TNode of the child element
     * @return {?} Whether or not the child was appended
     */


    function appendChild(tView, lView, childEl, childTNode) {
      /** @type {?} */
      var renderParent = getRenderParent(tView, childTNode, lView);

      if (renderParent != null) {
        /** @type {?} */
        var renderer = lView[RENDERER];
        /** @type {?} */

        var parentTNode = childTNode.parent ||
        /** @type {?} */
        lView[T_HOST];
        /** @type {?} */

        var anchorNode = getNativeAnchorNode(parentTNode, lView);

        if (Array.isArray(childEl)) {
          for (var i = 0; i < childEl.length; i++) {
            nativeAppendOrInsertBefore(renderer, renderParent, childEl[i], anchorNode);
          }
        } else {
          nativeAppendOrInsertBefore(renderer, renderParent, childEl, anchorNode);
        }
      }
    }
    /**
     * Returns the first native node for a given LView, starting from the provided TNode.
     *
     * Native nodes are returned in the order in which those appear in the native tree (DOM).
     * @param {?} lView
     * @param {?} tNode
     * @return {?}
     */


    function getFirstNativeNode(lView, tNode) {
      if (tNode !== null) {
        ngDevMode && assertNodeOfPossibleTypes(tNode, 3
        /* Element */
        , 0
        /* Container */
        , 4
        /* ElementContainer */
        , 5
        /* IcuContainer */
        , 1
        /* Projection */
        );
        /** @type {?} */

        var tNodeType = tNode.type;

        if (tNodeType === 3
        /* Element */
        ) {
            return getNativeByTNode(tNode, lView);
          } else if (tNodeType === 0
        /* Container */
        ) {
            return getBeforeNodeForView(-1, lView[tNode.index]);
          } else if (tNodeType === 4
        /* ElementContainer */
        || tNodeType === 5
        /* IcuContainer */
        ) {
            /** @type {?} */
            var elIcuContainerChild = tNode.child;

            if (elIcuContainerChild !== null) {
              return getFirstNativeNode(lView, elIcuContainerChild);
            } else {
              /** @type {?} */
              var rNodeOrLContainer = lView[tNode.index];

              if (isLContainer(rNodeOrLContainer)) {
                return getBeforeNodeForView(-1, rNodeOrLContainer);
              } else {
                return unwrapRNode(rNodeOrLContainer);
              }
            }
          } else {
          /** @type {?} */
          var componentView = lView[DECLARATION_COMPONENT_VIEW];
          /** @type {?} */

          var componentHost =
          /** @type {?} */
          componentView[T_HOST];
          /** @type {?} */

          var parentView = getLViewParent(componentView);
          /** @type {?} */

          var firstProjectedTNode =
          /** @type {?} */
          componentHost.projection[
          /** @type {?} */
          tNode.projection];

          if (firstProjectedTNode != null) {
            return getFirstNativeNode(
            /** @type {?} */
            parentView, firstProjectedTNode);
          } else {
            return getFirstNativeNode(lView, tNode.next);
          }
        }
      }

      return null;
    }
    /**
     * @param {?} viewIndexInContainer
     * @param {?} lContainer
     * @return {?}
     */


    function getBeforeNodeForView(viewIndexInContainer, lContainer) {
      /** @type {?} */
      var nextViewIndex = CONTAINER_HEADER_OFFSET + viewIndexInContainer + 1;

      if (nextViewIndex < lContainer.length) {
        /** @type {?} */
        var lView =
        /** @type {?} */
        lContainer[nextViewIndex];
        /** @type {?} */

        var firstTNodeOfView = lView[TVIEW].firstChild;

        if (firstTNodeOfView !== null) {
          return getFirstNativeNode(lView, firstTNodeOfView);
        }
      }

      return lContainer[NATIVE];
    }
    /**
     * Removes a native node itself using a given renderer. To remove the node we are looking up its
     * parent from the native tree as not all platforms / browsers support the equivalent of
     * node.remove().
     *
     * @param {?} renderer A renderer to be used
     * @param {?} rNode The native node that should be removed
     * @param {?=} isHostElement A flag indicating if a node to be removed is a host of a component.
     * @return {?}
     */


    function nativeRemoveNode(renderer, rNode, isHostElement) {
      /** @type {?} */
      var nativeParent = nativeParentNode(renderer, rNode);

      if (nativeParent) {
        nativeRemoveChild(renderer, nativeParent, rNode, isHostElement);
      }
    }
    /**
     * Performs the operation of `action` on the node. Typically this involves inserting or removing
     * nodes on the LView or projection boundary.
     * @param {?} renderer
     * @param {?} action
     * @param {?} tNode
     * @param {?} lView
     * @param {?} renderParent
     * @param {?} beforeNode
     * @param {?} isProjection
     * @return {?}
     */


    function applyNodes(renderer, action, tNode, lView, renderParent, beforeNode, isProjection) {
      while (tNode != null) {
        ngDevMode && assertTNodeForLView(tNode, lView);
        ngDevMode && assertNodeOfPossibleTypes(tNode, 0
        /* Container */
        , 3
        /* Element */
        , 4
        /* ElementContainer */
        , 1
        /* Projection */
        , 1
        /* Projection */
        , 5
        /* IcuContainer */
        );
        /** @type {?} */

        var rawSlotValue = lView[tNode.index];
        /** @type {?} */

        var tNodeType = tNode.type;

        if (isProjection) {
          if (action === 0
          /* Create */
          ) {
              rawSlotValue && attachPatchData(unwrapRNode(rawSlotValue), lView);
              tNode.flags |= 4
              /* isProjected */
              ;
            }
        }

        if ((tNode.flags & 64
        /* isDetached */
        ) !== 64
        /* isDetached */
        ) {
            if (tNodeType === 4
            /* ElementContainer */
            || tNodeType === 5
            /* IcuContainer */
            ) {
                applyNodes(renderer, action, tNode.child, lView, renderParent, beforeNode, false);
                applyToElementOrContainer(action, renderer, renderParent, rawSlotValue, beforeNode);
              } else if (tNodeType === 1
            /* Projection */
            ) {
                applyProjectionRecursive(renderer, action, lView,
                /** @type {?} */
                tNode, renderParent, beforeNode);
              } else {
              ngDevMode && assertNodeOfPossibleTypes(tNode, 3
              /* Element */
              , 0
              /* Container */
              );
              applyToElementOrContainer(action, renderer, renderParent, rawSlotValue, beforeNode);
            }
          }

        tNode = isProjection ? tNode.projectionNext : tNode.next;
      }
    }
    /**
     * `applyView` performs operation on the view as specified in `action` (insert, detach, destroy)
     *
     * Inserting a view without projection or containers at top level is simple. Just iterate over the
     * root nodes of the View, and for each node perform the `action`.
     *
     * Things get more complicated with containers and projections. That is because coming across:
     * - Container: implies that we have to insert/remove/destroy the views of that container as well
     *              which in turn can have their own Containers at the View roots.
     * - Projection: implies that we have to insert/remove/destroy the nodes of the projection. The
     *               complication is that the nodes we are projecting can themselves have Containers
     *               or other Projections.
     *
     * As you can see this is a very recursive problem. Yes recursion is not most efficient but the
     * code is complicated enough that trying to implemented with recursion becomes unmaintainable.
     *
     * @param {?} tView The `TView' which needs to be inserted, detached, destroyed
     * @param {?} lView The LView which needs to be inserted, detached, destroyed.
     * @param {?} renderer Renderer to use
     * @param {?} action action to perform (insert, detach, destroy)
     * @param {?} renderParent parent DOM element for insertion/removal.
     * @param {?} beforeNode Before which node the insertions should happen.
     * @return {?}
     */


    function applyView(tView, lView, renderer, action, renderParent, beforeNode) {
      ngDevMode && assertNodeType(
      /** @type {?} */
      tView.node, 2
      /* View */
      );
      /** @type {?} */

      var viewRootTNode =
      /** @type {?} */
      tView.node.child;
      applyNodes(renderer, action, viewRootTNode, lView, renderParent, beforeNode, false);
    }
    /**
     * `applyProjection` performs operation on the projection.
     *
     * Inserting a projection requires us to locate the projected nodes from the parent component. The
     * complication is that those nodes themselves could be re-projected from their parent component.
     *
     * @param {?} tView The `TView` of `LView` which needs to be inserted, detached, destroyed
     * @param {?} lView The `LView` which needs to be inserted, detached, destroyed.
     * @param {?} tProjectionNode node to project
     * @return {?}
     */


    function applyProjection(tView, lView, tProjectionNode) {
      /** @type {?} */
      var renderer = lView[RENDERER];
      /** @type {?} */

      var renderParent = getRenderParent(tView, tProjectionNode, lView);
      /** @type {?} */

      var parentTNode = tProjectionNode.parent ||
      /** @type {?} */
      lView[T_HOST];
      /** @type {?} */

      var beforeNode = getNativeAnchorNode(parentTNode, lView);
      applyProjectionRecursive(renderer, 0
      /* Create */
      , lView, tProjectionNode, renderParent, beforeNode);
    }
    /**
     * `applyProjectionRecursive` performs operation on the projection specified by `action` (insert,
     * detach, destroy)
     *
     * Inserting a projection requires us to locate the projected nodes from the parent component. The
     * complication is that those nodes themselves could be re-projected from their parent component.
     *
     * @param {?} renderer Render to use
     * @param {?} action action to perform (insert, detach, destroy)
     * @param {?} lView The LView which needs to be inserted, detached, destroyed.
     * @param {?} tProjectionNode node to project
     * @param {?} renderParent parent DOM element for insertion/removal.
     * @param {?} beforeNode Before which node the insertions should happen.
     * @return {?}
     */


    function applyProjectionRecursive(renderer, action, lView, tProjectionNode, renderParent, beforeNode) {
      /** @type {?} */
      var componentLView = lView[DECLARATION_COMPONENT_VIEW];
      /** @type {?} */

      var componentNode =
      /** @type {?} */
      componentLView[T_HOST];
      ngDevMode && assertEqual(typeof tProjectionNode.projection, 'number', 'expecting projection index');
      /** @type {?} */

      var nodeToProjectOrRNodes =
      /** @type {?} */

      /** @type {?} */
      componentNode.projection[tProjectionNode.projection];

      if (Array.isArray(nodeToProjectOrRNodes)) {
        // This should not exist, it is a bit of a hack. When we bootstrap a top level node and we
        // need to support passing projectable nodes, so we cheat and put them in the TNode
        // of the Host TView. (Yes we put instance info at the T Level). We can get away with it
        // because we know that that TView is not shared and therefore it will not be a problem.
        // This should be refactored and cleaned up.
        for (var i = 0; i < nodeToProjectOrRNodes.length; i++) {
          /** @type {?} */
          var rNode = nodeToProjectOrRNodes[i];
          applyToElementOrContainer(action, renderer, renderParent, rNode, beforeNode);
        }
      } else {
        /** @type {?} */
        var nodeToProject = nodeToProjectOrRNodes;
        /** @type {?} */

        var projectedComponentLView =
        /** @type {?} */
        componentLView[PARENT];
        applyNodes(renderer, action, nodeToProject, projectedComponentLView, renderParent, beforeNode, true);
      }
    }
    /**
     * `applyContainer` performs an operation on the container and its views as specified by
     * `action` (insert, detach, destroy)
     *
     * Inserting a Container is complicated by the fact that the container may have Views which
     * themselves have containers or projections.
     *
     * @param {?} renderer Renderer to use
     * @param {?} action action to perform (insert, detach, destroy)
     * @param {?} lContainer The LContainer which needs to be inserted, detached, destroyed.
     * @param {?} renderParent parent DOM element for insertion/removal.
     * @param {?} beforeNode Before which node the insertions should happen.
     * @return {?}
     */


    function applyContainer(renderer, action, lContainer, renderParent, beforeNode) {
      ngDevMode && assertLContainer(lContainer);
      /** @type {?} */

      var anchor = lContainer[NATIVE]; // LContainer has its own before node.

      /** @type {?} */

      var _native11 = unwrapRNode(lContainer); // An LContainer can be created dynamically on any node by injecting ViewContainerRef.
      // Asking for a ViewContainerRef on an element will result in a creation of a separate anchor node
      // (comment in the DOM) that will be different from the LContainer's host node. In this particular
      // case we need to execute action on 2 nodes:
      // - container's host node (this is done in the executeActionOnElementOrContainer)
      // - container's host node (this is done here)


      if (anchor !== _native11) {
        // This is very strange to me (Misko). I would expect that the native is same as anchor. I don't
        // see a reason why they should be different, but they are.
        //
        // If they are we need to process the second anchor as well.
        applyToElementOrContainer(action, renderer, renderParent, anchor, beforeNode);
      }

      for (var i = CONTAINER_HEADER_OFFSET; i < lContainer.length; i++) {
        /** @type {?} */
        var lView =
        /** @type {?} */
        lContainer[i];
        applyView(lView[TVIEW], lView, renderer, action, renderParent, anchor);
      }
    }
    /**
     * Writes class/style to element.
     *
     * @param {?} renderer Renderer to use.
     * @param {?} isClassBased `true` if it should be written to `class` (`false` to write to `style`)
     * @param {?} rNode The Node to write to.
     * @param {?} prop Property to write to. This would be the class/style name.
     * @param {?} value Value to write. If `null`/`undefined`/`false` this is considered a remove (set/add
     *        otherwise).
     * @return {?}
     */


    function applyStyling(renderer, isClassBased, rNode, prop, value) {
      /** @type {?} */
      var isProcedural = isProceduralRenderer(renderer);

      if (isClassBased) {
        // We actually want JS true/false here because any truthy value should add the class
        if (!value) {
          ngDevMode && ngDevMode.rendererRemoveClass++;

          if (isProcedural) {
            /** @type {?} */
            renderer.removeClass(rNode, prop);
          } else {
            /** @type {?} */
            rNode.classList.remove(prop);
          }
        } else {
          ngDevMode && ngDevMode.rendererAddClass++;

          if (isProcedural) {
            /** @type {?} */
            renderer.addClass(rNode, prop);
          } else {
            ngDevMode && assertDefined(
            /** @type {?} */
            rNode.classList, 'HTMLElement expected');

            /** @type {?} */
            rNode.classList.add(prop);
          }
        }
      } else {
        // TODO(misko): Can't import RendererStyleFlags2.DashCase as it causes imports to be resolved in
        // different order which causes failures. Using direct constant as workaround for now.

        /** @type {?} */
        var flags = prop.indexOf('-') == -1 ? undefined : 2
        /* RendererStyleFlags2.DashCase */
        ;

        if (value == null
        /** || value === undefined */
        ) {
            ngDevMode && ngDevMode.rendererRemoveStyle++;

            if (isProcedural) {
              /** @type {?} */
              renderer.removeStyle(rNode, prop, flags);
            } else {
              /** @type {?} */
              rNode.style.removeProperty(prop);
            }
          } else {
          ngDevMode && ngDevMode.rendererSetStyle++;

          if (isProcedural) {
            /** @type {?} */
            renderer.setStyle(rNode, prop, value, flags);
          } else {
            ngDevMode && assertDefined(
            /** @type {?} */
            rNode.style, 'HTMLElement expected');

            /** @type {?} */
            rNode.style.setProperty(prop, value);
          }
        }
      }
    }
    /**
     * Write `cssText` to `RElement`.
     *
     * This function does direct write without any reconciliation. Used for writing initial values, so
     * that static styling values do not pull in the style parser.
     *
     * @param {?} renderer Renderer to use
     * @param {?} element The element which needs to be updated.
     * @param {?} newValue The new class list to write.
     * @return {?}
     */


    function writeDirectStyle(renderer, element, newValue) {
      ngDevMode && assertString(newValue, '\'newValue\' should be a string');

      if (isProceduralRenderer(renderer)) {
        renderer.setAttribute(element, 'style', newValue);
      } else {
        /** @type {?} */
        element.style.cssText = newValue;
      }

      ngDevMode && ngDevMode.rendererSetStyle++;
    }
    /**
     * Write `className` to `RElement`.
     *
     * This function does direct write without any reconciliation. Used for writing initial values, so
     * that static styling values do not pull in the style parser.
     *
     * @param {?} renderer Renderer to use
     * @param {?} element The element which needs to be updated.
     * @param {?} newValue The new class list to write.
     * @return {?}
     */


    function writeDirectClass(renderer, element, newValue) {
      ngDevMode && assertString(newValue, '\'newValue\' should be a string');

      if (isProceduralRenderer(renderer)) {
        if (newValue === '') {
          // There are tests in `google3` which expect `element.getAttribute('class')` to be `null`.
          renderer.removeAttribute(element, 'class');
        } else {
          renderer.setAttribute(element, 'class', newValue);
        }
      } else {
        element.className = newValue;
      }

      ngDevMode && ngDevMode.rendererSetClassName++;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/node_util.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * If `startTNode.parent` exists and has an injector, returns TNode for that injector.
     * Otherwise, unwraps a parent injector location number to find the view offset from the current
     * injector, then walks up the declaration view tree until the TNode of the parent injector is
     * found.
     *
     * @param {?} location The location of the parent injector, which contains the view offset
     * @param {?} startView The LView instance from which to start walking up the view tree
     * @param {?} startTNode The TNode instance of the starting element
     * @return {?} The TNode of the parent injector
     */


    function getParentInjectorTNode(location, startView, startTNode) {
      // If there is an injector on the parent TNode, retrieve the TNode for that injector.
      if (startTNode.parent && startTNode.parent.injectorIndex !== -1) {
        // view offset is 0

        /** @type {?} */
        var injectorIndex = startTNode.parent.injectorIndex;
        /** @type {?} */

        var tNode = startTNode.parent; // If tNode.injectorIndex === tNode.parent.injectorIndex, then the index belongs to a parent
        // injector.

        while (tNode.parent != null && injectorIndex == tNode.parent.injectorIndex) {
          tNode = tNode.parent;
        }

        return tNode;
      }
      /** @type {?} */


      var viewOffset = getParentInjectorViewOffset(location); // view offset is 1

      /** @type {?} */

      var parentView = startView;
      /** @type {?} */

      var parentTNode =
      /** @type {?} */
      startView[T_HOST]; // view offset is superior to 1

      while (viewOffset > 1) {
        parentView =
        /** @type {?} */
        parentView[DECLARATION_VIEW];
        parentTNode =
        /** @type {?} */
        parentView[T_HOST];
        viewOffset--;
      }

      return parentTNode;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/view_ref.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @record
     */


    function viewEngine_ChangeDetectorRef_interface() {}
    /**
     * @template T
     */


    var ViewRef = /*#__PURE__*/function () {
      /**
       * @param {?} _lView
       * @param {?=} _cdRefInjectingView
       */
      function ViewRef(_lView, _cdRefInjectingView) {
        _classCallCheck(this, ViewRef);

        this._lView = _lView;
        this._cdRefInjectingView = _cdRefInjectingView;
        this._appRef = null;
        this._viewContainerRef = null;
        /**
         * \@internal
         */

        this._tViewNode = null;
      }
      /**
       * @return {?}
       */


      _createClass2(ViewRef, [{
        key: "destroy",

        /**
         * @return {?}
         */
        value: function destroy() {
          if (this._appRef) {
            this._appRef.detachView(this);
          } else if (this._viewContainerRef) {
            /** @type {?} */
            var index = this._viewContainerRef.indexOf(this);

            if (index > -1) {
              this._viewContainerRef.detach(index);
            }

            this._viewContainerRef = null;
          }

          destroyLView(this._lView[TVIEW], this._lView);
        }
        /**
         * @param {?} callback
         * @return {?}
         */

      }, {
        key: "onDestroy",
        value: function onDestroy(callback) {
          storeCleanupFn(this._lView[TVIEW], this._lView, callback);
        }
        /**
         * Marks a view and all of its ancestors dirty.
         *
         * It also triggers change detection by calling `scheduleTick` internally, which coalesces
         * multiple `markForCheck` calls to into one change detection run.
         *
         * This can be used to ensure an {\@link ChangeDetectionStrategy#OnPush OnPush} component is
         * checked when it needs to be re-rendered but the two normal triggers haven't marked it
         * dirty (i.e. inputs haven't changed and events haven't fired in the view).
         *
         * <!-- TODO: Add a link to a chapter on OnPush components -->
         *
         * \@usageNotes
         * ### Example
         *
         * ```typescript
         * \@Component({
         *   selector: 'my-app',
         *   template: `Number of ticks: {{numberOfTicks}}`
         *   changeDetection: ChangeDetectionStrategy.OnPush,
         * })
         * class AppComponent {
         *   numberOfTicks = 0;
         *
         *   constructor(private ref: ChangeDetectorRef) {
         *     setInterval(() => {
         *       this.numberOfTicks++;
         *       // the following is required, otherwise the view will not be updated
         *       this.ref.markForCheck();
         *     }, 1000);
         *   }
         * }
         * ```
         * @return {?}
         */

      }, {
        key: "markForCheck",
        value: function markForCheck() {
          markViewDirty(this._cdRefInjectingView || this._lView);
        }
        /**
         * Detaches the view from the change detection tree.
         *
         * Detached views will not be checked during change detection runs until they are
         * re-attached, even if they are dirty. `detach` can be used in combination with
         * {\@link ChangeDetectorRef#detectChanges detectChanges} to implement local change
         * detection checks.
         *
         * <!-- TODO: Add a link to a chapter on detach/reattach/local digest -->
         * <!-- TODO: Add a live demo once ref.detectChanges is merged into master -->
         *
         * \@usageNotes
         * ### Example
         *
         * The following example defines a component with a large list of readonly data.
         * Imagine the data changes constantly, many times per second. For performance reasons,
         * we want to check and update the list every five seconds. We can do that by detaching
         * the component's change detector and doing a local check every five seconds.
         *
         * ```typescript
         * class DataProvider {
         *   // in a real application the returned data will be different every time
         *   get data() {
         *     return [1,2,3,4,5];
         *   }
         * }
         *
         * \@Component({
         *   selector: 'giant-list',
         *   template: `
         *     <li *ngFor="let d of dataProvider.data">Data {{d}}</li>
         *   `,
         * })
         * class GiantList {
         *   constructor(private ref: ChangeDetectorRef, private dataProvider: DataProvider) {
         *     ref.detach();
         *     setInterval(() => {
         *       this.ref.detectChanges();
         *     }, 5000);
         *   }
         * }
         *  /
         *   selector: 'app',
         *   providers: [DataProvider],
         *   template: `
         *     <giant-list><giant-list>
         *   `,
         * })
         * class App {
         * }
         * ```
         * @return {?}
         */

      }, {
        key: "detach",
        value: function detach() {
          this._lView[FLAGS] &= ~128
          /* Attached */
          ;
        }
        /**
         * Re-attaches a view to the change detection tree.
         *
         * This can be used to re-attach views that were previously detached from the tree
         * using {\@link ChangeDetectorRef#detach detach}. Views are attached to the tree by default.
         *
         * <!-- TODO: Add a link to a chapter on detach/reattach/local digest -->
         *
         * \@usageNotes
         * ### Example
         *
         * The following example creates a component displaying `live` data. The component will detach
         * its change detector from the main change detector tree when the component's live property
         * is set to false.
         *
         * ```typescript
         * class DataProvider {
         *   data = 1;
         *
         *   constructor() {
         *     setInterval(() => {
         *       this.data = this.data * 2;
         *     }, 500);
         *   }
         * }
         *
         * \@Component({
         *   selector: 'live-data',
         *   inputs: ['live'],
         *   template: 'Data: {{dataProvider.data}}'
         * })
         * class LiveData {
         *   constructor(private ref: ChangeDetectorRef, private dataProvider: DataProvider) {}
         *
         *   set live(value) {
         *     if (value) {
         *       this.ref.reattach();
         *     } else {
         *       this.ref.detach();
         *     }
         *   }
         * }
         *  /
         *   selector: 'my-app',
         *   providers: [DataProvider],
         *   template: `
         *     Live Update: <input type="checkbox" [(ngModel)]="live">
         *     <live-data [live]="live"><live-data>
         *   `,
         * })
         * class AppComponent {
         *   live = true;
         * }
         * ```
         * @return {?}
         */

      }, {
        key: "reattach",
        value: function reattach() {
          this._lView[FLAGS] |= 128
          /* Attached */
          ;
        }
        /**
         * Checks the view and its children.
         *
         * This can also be used in combination with {\@link ChangeDetectorRef#detach detach} to implement
         * local change detection checks.
         *
         * <!-- TODO: Add a link to a chapter on detach/reattach/local digest -->
         * <!-- TODO: Add a live demo once ref.detectChanges is merged into master -->
         *
         * \@usageNotes
         * ### Example
         *
         * The following example defines a component with a large list of readonly data.
         * Imagine, the data changes constantly, many times per second. For performance reasons,
         * we want to check and update the list every five seconds.
         *
         * We can do that by detaching the component's change detector and doing a local change detection
         * check every five seconds.
         *
         * See {\@link ChangeDetectorRef#detach detach} for more information.
         * @return {?}
         */

      }, {
        key: "detectChanges",
        value: function detectChanges() {
          detectChangesInternal(this._lView[TVIEW], this._lView, this.context);
        }
        /**
         * Checks the change detector and its children, and throws if any changes are detected.
         *
         * This is used in development mode to verify that running change detection doesn't
         * introduce other changes.
         * @return {?}
         */

      }, {
        key: "checkNoChanges",
        value: function checkNoChanges() {
          checkNoChangesInternal(this._lView[TVIEW], this._lView, this.context);
        }
        /**
         * @param {?} vcRef
         * @return {?}
         */

      }, {
        key: "attachToViewContainerRef",
        value: function attachToViewContainerRef(vcRef) {
          if (this._appRef) {
            throw new Error('This view is already attached directly to the ApplicationRef!');
          }

          this._viewContainerRef = vcRef;
        }
        /**
         * @return {?}
         */

      }, {
        key: "detachFromAppRef",
        value: function detachFromAppRef() {
          this._appRef = null;
          renderDetachView(this._lView[TVIEW], this._lView);
        }
        /**
         * @param {?} appRef
         * @return {?}
         */

      }, {
        key: "attachToAppRef",
        value: function attachToAppRef(appRef) {
          if (this._viewContainerRef) {
            throw new Error('This view is already attached to a ViewContainer!');
          }

          this._appRef = appRef;
        }
      }, {
        key: "rootNodes",
        get: function get() {
          /** @type {?} */
          var lView = this._lView;

          if (lView[HOST] == null) {
            /** @type {?} */
            var hostTView =
            /** @type {?} */
            lView[T_HOST];
            return collectNativeNodes(lView[TVIEW], lView, hostTView.child, []);
          }

          return [];
        }
        /**
         * @return {?}
         */

      }, {
        key: "context",
        get: function get() {
          return (
            /** @type {?} */
            this._lView[CONTEXT]
          );
        }
        /**
         * @return {?}
         */

      }, {
        key: "destroyed",
        get: function get() {
          return (this._lView[FLAGS] & 256
          /* Destroyed */
          ) === 256
          /* Destroyed */
          ;
        }
      }]);

      return ViewRef;
    }();

    if (false) {}
    /**
     * \@internal
     * @template T
     */


    var RootViewRef = /*#__PURE__*/function (_ViewRef) {
      _inherits(RootViewRef, _ViewRef);

      var _super32 = _createSuper(RootViewRef);

      /**
       * @param {?} _view
       */
      function RootViewRef(_view) {
        var _this150;

        _classCallCheck(this, RootViewRef);

        _this150 = _super32.call(this, _view);
        _this150._view = _view;
        return _this150;
      }
      /**
       * @return {?}
       */


      _createClass2(RootViewRef, [{
        key: "detectChanges",
        value: function detectChanges() {
          detectChangesInRootView(this._view);
        }
        /**
         * @return {?}
         */

      }, {
        key: "checkNoChanges",
        value: function checkNoChanges() {
          checkNoChangesInRootView(this._view);
        }
        /**
         * @return {?}
         */

      }, {
        key: "context",
        get: function get() {
          return (
            /** @type {?} */
            null
          );
        }
      }]);

      return RootViewRef;
    }(ViewRef);

    if (false) {}
    /**
     * @param {?} tView
     * @param {?} lView
     * @param {?} tNode
     * @param {?} result
     * @param {?=} isProjection
     * @return {?}
     */


    function collectNativeNodes(tView, lView, tNode, result) {
      var isProjection = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : false;

      while (tNode !== null) {
        ngDevMode && assertNodeOfPossibleTypes(tNode, 3
        /* Element */
        , 0
        /* Container */
        , 1
        /* Projection */
        , 4
        /* ElementContainer */
        , 5
        /* IcuContainer */
        );
        /** @type {?} */

        var lNode = lView[tNode.index];

        if (lNode !== null) {
          result.push(unwrapRNode(lNode));
        } // A given lNode can represent either a native node or a LContainer (when it is a host of a
        // ViewContainerRef). When we find a LContainer we need to descend into it to collect root nodes
        // from the views in this container.


        if (isLContainer(lNode)) {
          for (var i = CONTAINER_HEADER_OFFSET; i < lNode.length; i++) {
            /** @type {?} */
            var lViewInAContainer = lNode[i];
            /** @type {?} */

            var lViewFirstChildTNode = lViewInAContainer[TVIEW].firstChild;

            if (lViewFirstChildTNode !== null) {
              collectNativeNodes(lViewInAContainer[TVIEW], lViewInAContainer, lViewFirstChildTNode, result);
            }
          }
        }
        /** @type {?} */


        var tNodeType = tNode.type;

        if (tNodeType === 4
        /* ElementContainer */
        || tNodeType === 5
        /* IcuContainer */
        ) {
            collectNativeNodes(tView, lView, tNode.child, result);
          } else if (tNodeType === 1
        /* Projection */
        ) {
            /** @type {?} */
            var componentView = lView[DECLARATION_COMPONENT_VIEW];
            /** @type {?} */

            var componentHost =
            /** @type {?} */
            componentView[T_HOST];
            /** @type {?} */

            var parentView = getLViewParent(componentView);
            /** @type {?} */

            var firstProjectedNode =
            /** @type {?} */
            componentHost.projection[
            /** @type {?} */
            tNode.projection];

            if (firstProjectedNode !== null && parentView !== null) {
              collectNativeNodes(parentView[TVIEW], parentView, firstProjectedNode, result, true);
            }
          }

        tNode = isProjection ? tNode.projectionNext : tNode.next;
      }

      return result;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/view_engine_compatibility.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Creates an ElementRef from the most recent node.
     *
     * @param {?} ElementRefToken
     * @return {?} The ElementRef instance to use
     */


    function injectElementRef(ElementRefToken) {
      return createElementRef(ElementRefToken, getPreviousOrParentTNode(), getLView());
    }
    /** @type {?} */


    var R3ElementRef;
    /**
     * Creates an ElementRef given a node.
     *
     * @param {?} ElementRefToken The ElementRef type
     * @param {?} tNode The node for which you'd like an ElementRef
     * @param {?} view The view to which the node belongs
     * @return {?} The ElementRef instance to use
     */

    function createElementRef(ElementRefToken, tNode, view) {
      if (!R3ElementRef) {
        R3ElementRef = /*#__PURE__*/function (_ElementRefToken) {
          _inherits(ElementRef, _ElementRefToken);

          var _super33 = _createSuper(ElementRef);

          function ElementRef() {
            _classCallCheck(this, ElementRef);

            return _super33.apply(this, arguments);
          }

          return ElementRef;
        }(ElementRefToken);
      }

      return new R3ElementRef(
      /** @type {?} */
      getNativeByTNode(tNode, view));
    }
    /** @type {?} */


    var R3TemplateRef;
    /**
     * Creates a TemplateRef given a node.
     *
     * @template T
     * @param {?} TemplateRefToken
     * @param {?} ElementRefToken
     * @return {?} The TemplateRef instance to use
     */

    function injectTemplateRef(TemplateRefToken, ElementRefToken) {
      return createTemplateRef(TemplateRefToken, ElementRefToken, getPreviousOrParentTNode(), getLView());
    }
    /**
     * Creates a TemplateRef and stores it on the injector.
     *
     * @template T
     * @param {?} TemplateRefToken The TemplateRef type
     * @param {?} ElementRefToken The ElementRef type
     * @param {?} hostTNode The node on which a TemplateRef is requested
     * @param {?} hostView The view to which the node belongs
     * @return {?} The TemplateRef instance or null if we can't create a TemplateRef on a given node type
     */


    function createTemplateRef(TemplateRefToken, ElementRefToken, hostTNode, hostView) {
      if (!R3TemplateRef) {
        R3TemplateRef = /*#__PURE__*/function (_TemplateRefToken) {
          _inherits(TemplateRef, _TemplateRefToken);

          var _super34 = _createSuper(TemplateRef);

          /**
           * @param {?} _declarationView
           * @param {?} _declarationTContainer
           * @param {?} elementRef
           */
          function TemplateRef(_declarationView, _declarationTContainer, elementRef) {
            var _this151;

            _classCallCheck(this, TemplateRef);

            _this151 = _super34.call(this);
            _this151._declarationView = _declarationView;
            _this151._declarationTContainer = _declarationTContainer;
            _this151.elementRef = elementRef;
            return _this151;
          }
          /**
           * @param {?} context
           * @return {?}
           */


          _createClass2(TemplateRef, [{
            key: "createEmbeddedView",
            value: function createEmbeddedView(context) {
              /** @type {?} */
              var embeddedTView =
              /** @type {?} */
              this._declarationTContainer.tViews;
              /** @type {?} */

              var embeddedLView = createLView(this._declarationView, embeddedTView, context, 16
              /* CheckAlways */
              , null, embeddedTView.node);
              /** @type {?} */

              var declarationLContainer = this._declarationView[this._declarationTContainer.index];
              ngDevMode && assertLContainer(declarationLContainer);
              embeddedLView[DECLARATION_LCONTAINER] = declarationLContainer;
              /** @type {?} */

              var declarationViewLQueries = this._declarationView[QUERIES];

              if (declarationViewLQueries !== null) {
                embeddedLView[QUERIES] = declarationViewLQueries.createEmbeddedView(embeddedTView);
              }

              renderView(embeddedTView, embeddedLView, context);
              /** @type {?} */

              var viewRef = new ViewRef(embeddedLView);
              viewRef._tViewNode =
              /** @type {?} */
              embeddedLView[T_HOST];
              return viewRef;
            }
          }]);

          return TemplateRef;
        }(TemplateRefToken);
      }

      if (hostTNode.type === 0
      /* Container */
      ) {
          ngDevMode && assertDefined(hostTNode.tViews, 'TView must be allocated');
          return new R3TemplateRef(hostView,
          /** @type {?} */
          hostTNode, createElementRef(ElementRefToken, hostTNode, hostView));
        } else {
        return null;
      }
    }
    /** @type {?} */


    var R3ViewContainerRef;
    /**
     * Creates a ViewContainerRef and stores it on the injector. Or, if the ViewContainerRef
     * already exists, retrieves the existing ViewContainerRef.
     *
     * @param {?} ViewContainerRefToken
     * @param {?} ElementRefToken
     * @return {?} The ViewContainerRef instance to use
     */

    function injectViewContainerRef(ViewContainerRefToken, ElementRefToken) {
      /** @type {?} */
      var previousTNode =
      /** @type {?} */
      getPreviousOrParentTNode();
      return createContainerRef(ViewContainerRefToken, ElementRefToken, previousTNode, getLView());
    }
    /**
     * Creates a ViewContainerRef and stores it on the injector.
     *
     * @param {?} ViewContainerRefToken The ViewContainerRef type
     * @param {?} ElementRefToken The ElementRef type
     * @param {?} hostTNode The node that is requesting a ViewContainerRef
     * @param {?} hostView The view to which the node belongs
     * @return {?} The ViewContainerRef instance to use
     */


    function createContainerRef(ViewContainerRefToken, ElementRefToken, hostTNode, hostView) {
      if (!R3ViewContainerRef) {
        R3ViewContainerRef = /*#__PURE__*/function (_ViewContainerRefToke) {
          _inherits(ViewContainerRef, _ViewContainerRefToke);

          var _super35 = _createSuper(ViewContainerRef);

          /**
           * @param {?} _lContainer
           * @param {?} _hostTNode
           * @param {?} _hostView
           */
          function ViewContainerRef(_lContainer, _hostTNode, _hostView) {
            var _this152;

            _classCallCheck(this, ViewContainerRef);

            _this152 = _super35.call(this);
            _this152._lContainer = _lContainer;
            _this152._hostTNode = _hostTNode;
            _this152._hostView = _hostView;
            return _this152;
          }
          /**
           * @return {?}
           */


          _createClass2(ViewContainerRef, [{
            key: "clear",

            /**
             * @return {?}
             */
            value: function clear() {
              while (this.length > 0) {
                this.remove(this.length - 1);
              }
            }
            /**
             * @param {?} index
             * @return {?}
             */

          }, {
            key: "get",
            value: function get(index) {
              return this._lContainer[VIEW_REFS] !== null &&
              /** @type {?} */
              this._lContainer[VIEW_REFS][index] || null;
            }
            /**
             * @return {?}
             */

          }, {
            key: "createEmbeddedView",

            /**
             * @template C
             * @param {?} templateRef
             * @param {?=} context
             * @param {?=} index
             * @return {?}
             */
            value: function createEmbeddedView(templateRef, context, index) {
              /** @type {?} */
              var viewRef = templateRef.createEmbeddedView(context ||
              /** @type {?} */
              {});
              this.insert(viewRef, index);
              return viewRef;
            }
            /**
             * @template C
             * @param {?} componentFactory
             * @param {?=} index
             * @param {?=} injector
             * @param {?=} projectableNodes
             * @param {?=} ngModuleRef
             * @return {?}
             */

          }, {
            key: "createComponent",
            value: function createComponent(componentFactory, index, injector, projectableNodes, ngModuleRef) {
              /** @type {?} */
              var contextInjector = injector || this.parentInjector;

              if (!ngModuleRef &&
              /** @type {?} */
              componentFactory.ngModule == null && contextInjector) {
                // DO NOT REFACTOR. The code here used to have a `value || undefined` expression
                // which seems to cause internal google apps to fail. This is documented in the
                // following internal bug issue: go/b/142967802

                /** @type {?} */
                var result = contextInjector.get(NgModuleRef, null);

                if (result) {
                  ngModuleRef = result;
                }
              }
              /** @type {?} */


              var componentRef = componentFactory.create(contextInjector, projectableNodes, undefined, ngModuleRef);
              this.insert(componentRef.hostView, index);
              return componentRef;
            }
            /**
             * @param {?} viewRef
             * @param {?=} index
             * @return {?}
             */

          }, {
            key: "insert",
            value: function insert(viewRef, index) {
              /** @type {?} */
              var lView =
              /** @type {?} */

              /** @type {?} */
              viewRef._lView;
              /** @type {?} */

              var tView = lView[TVIEW];

              if (viewRef.destroyed) {
                throw new Error('Cannot insert a destroyed View in a ViewContainer!');
              }

              this.allocateContainerIfNeeded();

              if (viewAttachedToContainer(lView)) {
                // If view is already attached, detach it first so we clean up references appropriately.

                /** @type {?} */
                var prevIdx = this.indexOf(viewRef); // A view might be attached either to this or a different container. The `prevIdx` for
                // those cases will be:
                // equal to -1 for views attached to this ViewContainerRef
                // >= 0 for views attached to a different ViewContainerRef

                if (prevIdx !== -1) {
                  this.detach(prevIdx);
                } else {
                  /** @type {?} */
                  var prevLContainer =
                  /** @type {?} */
                  lView[PARENT];
                  ngDevMode && assertEqual(isLContainer(prevLContainer), true, 'An attached view should have its PARENT point to a container.'); // We need to re-create a R3ViewContainerRef instance since those are not stored on
                  // LView (nor anywhere else).

                  /** @type {?} */

                  var prevVCRef = new R3ViewContainerRef(prevLContainer,
                  /** @type {?} */
                  prevLContainer[T_HOST], prevLContainer[PARENT]);
                  prevVCRef.detach(prevVCRef.indexOf(viewRef));
                }
              }
              /** @type {?} */


              var adjustedIdx = this._adjustIndex(index);

              insertView(tView, lView, this._lContainer, adjustedIdx);
              /** @type {?} */

              var beforeNode = getBeforeNodeForView(adjustedIdx, this._lContainer);
              addRemoveViewFromContainer(tView, lView, true, beforeNode);

              /** @type {?} */
              viewRef.attachToViewContainerRef(this);
              addToArray(
              /** @type {?} */
              this._lContainer[VIEW_REFS], adjustedIdx, viewRef);
              return viewRef;
            }
            /**
             * @param {?} viewRef
             * @param {?} newIndex
             * @return {?}
             */

          }, {
            key: "move",
            value: function move(viewRef, newIndex) {
              if (viewRef.destroyed) {
                throw new Error('Cannot move a destroyed View in a ViewContainer!');
              }

              return this.insert(viewRef, newIndex);
            }
            /**
             * @param {?} viewRef
             * @return {?}
             */

          }, {
            key: "indexOf",
            value: function indexOf(viewRef) {
              /** @type {?} */
              var viewRefsArr = this._lContainer[VIEW_REFS];
              return viewRefsArr !== null ? viewRefsArr.indexOf(viewRef) : -1;
            }
            /**
             * @param {?=} index
             * @return {?}
             */

          }, {
            key: "remove",
            value: function remove(index) {
              this.allocateContainerIfNeeded();
              /** @type {?} */

              var adjustedIdx = this._adjustIndex(index, -1);

              removeView(this._lContainer, adjustedIdx);
              removeFromArray(
              /** @type {?} */
              this._lContainer[VIEW_REFS], adjustedIdx);
            }
            /**
             * @param {?=} index
             * @return {?}
             */

          }, {
            key: "detach",
            value: function detach(index) {
              this.allocateContainerIfNeeded();
              /** @type {?} */

              var adjustedIdx = this._adjustIndex(index, -1);
              /** @type {?} */


              var view = detachView(this._lContainer, adjustedIdx);
              /** @type {?} */

              var wasDetached = view && removeFromArray(
              /** @type {?} */
              this._lContainer[VIEW_REFS], adjustedIdx) != null;
              return wasDetached ? new ViewRef(
              /** @type {?} */
              view) : null;
            }
            /**
             * @private
             * @param {?=} index
             * @param {?=} shift
             * @return {?}
             */

          }, {
            key: "_adjustIndex",
            value: function _adjustIndex(index) {
              var shift = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;

              if (index == null) {
                return this.length + shift;
              }

              if (ngDevMode) {
                assertGreaterThan(index, -1, "ViewRef index must be positive, got ".concat(index)); // +1 because it's legal to insert at the end.

                assertLessThan(index, this.length + 1 + shift, 'index');
              }

              return index;
            }
            /**
             * @private
             * @return {?}
             */

          }, {
            key: "allocateContainerIfNeeded",
            value: function allocateContainerIfNeeded() {
              if (this._lContainer[VIEW_REFS] === null) {
                this._lContainer[VIEW_REFS] = [];
              }
            }
          }, {
            key: "element",
            get: function get() {
              return createElementRef(ElementRefToken, this._hostTNode, this._hostView);
            }
            /**
             * @return {?}
             */

          }, {
            key: "injector",
            get: function get() {
              return new NodeInjector(this._hostTNode, this._hostView);
            }
            /**
             * @deprecated No replacement
             * @return {?}
             */

          }, {
            key: "parentInjector",
            get: function get() {
              /** @type {?} */
              var parentLocation = getParentInjectorLocation(this._hostTNode, this._hostView);
              /** @type {?} */

              var parentView = getParentInjectorView(parentLocation, this._hostView);
              /** @type {?} */

              var parentTNode = getParentInjectorTNode(parentLocation, this._hostView, this._hostTNode);
              return !hasParentInjector(parentLocation) || parentTNode == null ? new NodeInjector(null, this._hostView) : new NodeInjector(parentTNode, parentView);
            }
          }, {
            key: "length",
            get: function get() {
              return this._lContainer.length - CONTAINER_HEADER_OFFSET;
            }
          }]);

          return ViewContainerRef;
        }(ViewContainerRefToken);
      }

      ngDevMode && assertNodeOfPossibleTypes(hostTNode, 0
      /* Container */
      , 3
      /* Element */
      , 4
      /* ElementContainer */
      );
      /** @type {?} */

      var lContainer;
      /** @type {?} */

      var slotValue = hostView[hostTNode.index];

      if (isLContainer(slotValue)) {
        // If the host is a container, we don't need to create a new LContainer
        lContainer = slotValue;
        setLContainerActiveIndex(lContainer, -1
        /* DYNAMIC_EMBEDDED_VIEWS_ONLY */
        );
      } else {
        /** @type {?} */
        var commentNode; // If the host is an element container, the native host element is guaranteed to be a
        // comment and we can reuse that comment as anchor element for the new LContainer.
        // The comment node in question is already part of the DOM structure so we don't need to append
        // it again.

        if (hostTNode.type === 4
        /* ElementContainer */
        ) {
            commentNode =
            /** @type {?} */
            unwrapRNode(slotValue);
          } else {
          ngDevMode && ngDevMode.rendererCreateComment++;
          commentNode = hostView[RENDERER].createComment(ngDevMode ? 'container' : ''); // A `ViewContainerRef` can be injected by the root (topmost / bootstrapped) component. In
          // this case we can't use TView / TNode data structures to insert container's marker node
          // (both a parent of a comment node and the comment node itself are not part of any view). In
          // this specific case we use low-level DOM manipulation to insert container's marker (comment)
          // node.

          if (isRootView(hostView)) {
            /** @type {?} */
            var renderer = hostView[RENDERER];
            /** @type {?} */

            var hostNative =
            /** @type {?} */
            getNativeByTNode(hostTNode, hostView);
            /** @type {?} */

            var parentOfHostNative = nativeParentNode(renderer, hostNative);
            nativeInsertBefore(renderer,
            /** @type {?} */
            parentOfHostNative, commentNode, nativeNextSibling(renderer, hostNative));
          } else {
            appendChild(hostView[TVIEW], hostView, commentNode, hostTNode);
          }
        }

        hostView[hostTNode.index] = lContainer = createLContainer(slotValue, hostView, commentNode, hostTNode);
        addToViewTree(hostView, lContainer);
      }

      return new R3ViewContainerRef(lContainer, hostTNode, hostView);
    }
    /**
     * Returns a ChangeDetectorRef (a.k.a. a ViewRef)
     * @param {?=} isPipe
     * @return {?}
     */


    function injectChangeDetectorRef() {
      var isPipe = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
      return createViewRef(getPreviousOrParentTNode(), getLView(), isPipe);
    }
    /**
     * Creates a ViewRef and stores it on the injector as ChangeDetectorRef (public alias).
     *
     * @param {?} tNode The node that is requesting a ChangeDetectorRef
     * @param {?} lView The view to which the node belongs
     * @param {?} isPipe Whether the view is being injected into a pipe.
     * @return {?} The ChangeDetectorRef to use
     */


    function createViewRef(tNode, lView, isPipe) {
      // `isComponentView` will be true for Component and Directives (but not for Pipes).
      // See https://github.com/angular/angular/pull/33072 for proper fix

      /** @type {?} */
      var isComponentView = !isPipe && isComponentHost(tNode);

      if (isComponentView) {
        // The LView represents the location where the component is declared.
        // Instead we want the LView for the component View and so we need to look it up.

        /** @type {?} */
        var componentView = getComponentLViewByIndex(tNode.index, lView);
        return new ViewRef(componentView, componentView);
      } else if (tNode.type === 3
      /* Element */
      || tNode.type === 0
      /* Container */
      || tNode.type === 4
      /* ElementContainer */
      || tNode.type === 5
      /* IcuContainer */
      ) {
          // The LView represents the location where the injection is requested from.
          // We need to locate the containing LView (in case where the `lView` is an embedded view)

          /** @type {?} */
          var hostComponentView = lView[DECLARATION_COMPONENT_VIEW];
          return new ViewRef(hostComponentView, lView);
        }

      return (
        /** @type {?} */
        null
      );
    }
    /**
     * Returns a Renderer2 (or throws when application was bootstrapped with Renderer3)
     * @param {?} view
     * @return {?}
     */


    function getOrCreateRenderer2(view) {
      /** @type {?} */
      var renderer = view[RENDERER];

      if (isProceduralRenderer(renderer)) {
        return (
          /** @type {?} */
          renderer
        );
      } else {
        throw new Error('Cannot inject Renderer2 when the application uses Renderer3!');
      }
    }
    /**
     * Injects a Renderer2 for the current component.
     * @return {?}
     */


    function injectRenderer2() {
      // We need the Renderer to be based on the component that it's being injected into, however since
      // DI happens before we've entered its view, `getLView` will return the parent view instead.

      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var tNode = getPreviousOrParentTNode();
      /** @type {?} */

      var nodeAtIndex = getComponentLViewByIndex(tNode.index, lView);
      return getOrCreateRenderer2(isLView(nodeAtIndex) ? nodeAtIndex : lView);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/change_detection/change_detector_ref.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Base class for Angular Views, provides change detection functionality.
     * A change-detection tree collects all views that are to be checked for changes.
     * Use the methods to add and remove views from the tree, initiate change-detection,
     * and explicitly mark views as _dirty_, meaning that they have changed and need to be rerendered.
     *
     * \@usageNotes
     *
     * The following examples demonstrate how to modify default change-detection behavior
     * to perform explicit detection when needed.
     *
     * ### Use `markForCheck()` with `CheckOnce` strategy
     *
     * The following example sets the `OnPush` change-detection strategy for a component
     * (`CheckOnce`, rather than the default `CheckAlways`), then forces a second check
     * after an interval. See [live demo](http://plnkr.co/edit/GC512b?p=preview).
     *
     * <code-example path="core/ts/change_detect/change-detection.ts"
     * region="mark-for-check"></code-example>
     *
     * ### Detach change detector to limit how often check occurs
     *
     * The following example defines a component with a large list of read-only data
     * that is expected to change constantly, many times per second.
     * To improve performance, we want to check and update the list
     * less often than the changes actually occur. To do that, we detach
     * the component's change detector and perform an explicit local check every five seconds.
     *
     * <code-example path="core/ts/change_detect/change-detection.ts" region="detach"></code-example>
     *
     *
     * ### Reattaching a detached component
     *
     * The following example creates a component displaying live data.
     * The component detaches its change detector from the main change detector tree
     * when the `live` property is set to false, and reattaches it when the property
     * becomes true.
     *
     * <code-example path="core/ts/change_detect/change-detection.ts" region="reattach"></code-example>
     *
     * \@publicApi
     * @abstract
     */


    var ChangeDetectorRef = function ChangeDetectorRef() {
      _classCallCheck(this, ChangeDetectorRef);
    };
    /**
     * \@internal
     * @nocollapse
     */


    ChangeDetectorRef.__NG_ELEMENT_ID__ =
    /**
    * @return {?}
    */
    function () {
      return SWITCH_CHANGE_DETECTOR_REF_FACTORY();
    };

    if (false) {}
    /** @type {?} */


    var SWITCH_CHANGE_DETECTOR_REF_FACTORY__POST_R3__ = injectChangeDetectorRef;
    /** @type {?} */

    var SWITCH_CHANGE_DETECTOR_REF_FACTORY__PRE_R3__ =
    /**
    * @param {...?} args
    * @return {?}
    */
    function SWITCH_CHANGE_DETECTOR_REF_FACTORY__PRE_R3__() {};

    var ɵ0$5 = SWITCH_CHANGE_DETECTOR_REF_FACTORY__POST_R3__;
    /** @type {?} */

    var SWITCH_CHANGE_DETECTOR_REF_FACTORY = SWITCH_CHANGE_DETECTOR_REF_FACTORY__POST_R3__;
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * @description
     *
     * Represents a type that a Component or other object is instances of.
     *
     * An example of a `Type` is `MyCustomComponent` class, which in JavaScript is be represented by
     * the `MyCustomComponent` constructor function.
     *
     * @publicApi
     */

    var Type = Function;

    function isType(v) {
      return typeof v === 'function';
    }
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Attention: These regex has to hold even if the code is minified!
     */


    var DELEGATE_CTOR = /^function\s+\S+\(\)\s*{[\s\S]+\.apply\(this,\s*arguments\)/;
    var INHERITED_CLASS = /^class\s+[A-Za-z\d$_]*\s*extends\s+[^{]+{/;
    var INHERITED_CLASS_WITH_CTOR = /^class\s+[A-Za-z\d$_]*\s*extends\s+[^{]+{[\s\S]*constructor\s*\(/;
    var INHERITED_CLASS_WITH_DELEGATE_CTOR = /^class\s+[A-Za-z\d$_]*\s*extends\s+[^{]+{[\s\S]*constructor\s*\(\)\s*{\s+super\(\.\.\.arguments\)/;
    /**
     * Determine whether a stringified type is a class which delegates its constructor
     * to its parent.
     *
     * This is not trivial since compiled code can actually contain a constructor function
     * even if the original source code did not. For instance, when the child class contains
     * an initialized instance property.
     */

    function isDelegateCtor(typeStr) {
      return DELEGATE_CTOR.test(typeStr) || INHERITED_CLASS_WITH_DELEGATE_CTOR.test(typeStr) || INHERITED_CLASS.test(typeStr) && !INHERITED_CLASS_WITH_CTOR.test(typeStr);
    }

    var ReflectionCapabilities = /*#__PURE__*/function () {
      function ReflectionCapabilities(reflect) {
        _classCallCheck(this, ReflectionCapabilities);

        this._reflect = reflect || _global['Reflect'];
      }

      _createClass2(ReflectionCapabilities, [{
        key: "isReflectionEnabled",
        value: function isReflectionEnabled() {
          return true;
        }
      }, {
        key: "factory",
        value: function factory(t) {
          return function () {
            for (var _len15 = arguments.length, args = new Array(_len15), _key16 = 0; _key16 < _len15; _key16++) {
              args[_key16] = arguments[_key16];
            }

            return _construct(t, args);
          };
        }
        /** @internal */

      }, {
        key: "_zipTypesAndAnnotations",
        value: function _zipTypesAndAnnotations(paramTypes, paramAnnotations) {
          var result;

          if (typeof paramTypes === 'undefined') {
            result = newArray(paramAnnotations.length);
          } else {
            result = newArray(paramTypes.length);
          }

          for (var i = 0; i < result.length; i++) {
            // TS outputs Object for parameters without types, while Traceur omits
            // the annotations. For now we preserve the Traceur behavior to aid
            // migration, but this can be revisited.
            if (typeof paramTypes === 'undefined') {
              result[i] = [];
            } else if (paramTypes[i] && paramTypes[i] != Object) {
              result[i] = [paramTypes[i]];
            } else {
              result[i] = [];
            }

            if (paramAnnotations && paramAnnotations[i] != null) {
              result[i] = result[i].concat(paramAnnotations[i]);
            }
          }

          return result;
        }
      }, {
        key: "_ownParameters",
        value: function _ownParameters(type, parentCtor) {
          var typeStr = type.toString(); // If we have no decorators, we only have function.length as metadata.
          // In that case, to detect whether a child class declared an own constructor or not,
          // we need to look inside of that constructor to check whether it is
          // just calling the parent.
          // This also helps to work around for https://github.com/Microsoft/TypeScript/issues/12439
          // that sets 'design:paramtypes' to []
          // if a class inherits from another class but has no ctor declared itself.

          if (isDelegateCtor(typeStr)) {
            return null;
          } // Prefer the direct API.


          if (type.parameters && type.parameters !== parentCtor.parameters) {
            return type.parameters;
          } // API of tsickle for lowering decorators to properties on the class.


          var tsickleCtorParams = type.ctorParameters;

          if (tsickleCtorParams && tsickleCtorParams !== parentCtor.ctorParameters) {
            // Newer tsickle uses a function closure
            // Retain the non-function case for compatibility with older tsickle
            var ctorParameters = typeof tsickleCtorParams === 'function' ? tsickleCtorParams() : tsickleCtorParams;

            var _paramTypes = ctorParameters.map(function (ctorParam) {
              return ctorParam && ctorParam.type;
            });

            var _paramAnnotations = ctorParameters.map(function (ctorParam) {
              return ctorParam && convertTsickleDecoratorIntoMetadata(ctorParam.decorators);
            });

            return this._zipTypesAndAnnotations(_paramTypes, _paramAnnotations);
          } // API for metadata created by invoking the decorators.


          var paramAnnotations = type.hasOwnProperty(PARAMETERS) && type[PARAMETERS];

          var paramTypes = this._reflect && this._reflect.getOwnMetadata && this._reflect.getOwnMetadata('design:paramtypes', type);

          if (paramTypes || paramAnnotations) {
            return this._zipTypesAndAnnotations(paramTypes, paramAnnotations);
          } // If a class has no decorators, at least create metadata
          // based on function.length.
          // Note: We know that this is a real constructor as we checked
          // the content of the constructor above.


          return newArray(type.length);
        }
      }, {
        key: "parameters",
        value: function parameters(type) {
          // Note: only report metadata if we have at least one class decorator
          // to stay in sync with the static reflector.
          if (!isType(type)) {
            return [];
          }

          var parentCtor = getParentCtor(type);

          var parameters = this._ownParameters(type, parentCtor);

          if (!parameters && parentCtor !== Object) {
            parameters = this.parameters(parentCtor);
          }

          return parameters || [];
        }
      }, {
        key: "_ownAnnotations",
        value: function _ownAnnotations(typeOrFunc, parentCtor) {
          // Prefer the direct API.
          if (typeOrFunc.annotations && typeOrFunc.annotations !== parentCtor.annotations) {
            var annotations = typeOrFunc.annotations;

            if (typeof annotations === 'function' && annotations.annotations) {
              annotations = annotations.annotations;
            }

            return annotations;
          } // API of tsickle for lowering decorators to properties on the class.


          if (typeOrFunc.decorators && typeOrFunc.decorators !== parentCtor.decorators) {
            return convertTsickleDecoratorIntoMetadata(typeOrFunc.decorators);
          } // API for metadata created by invoking the decorators.


          if (typeOrFunc.hasOwnProperty(ANNOTATIONS)) {
            return typeOrFunc[ANNOTATIONS];
          }

          return null;
        }
      }, {
        key: "annotations",
        value: function annotations(typeOrFunc) {
          if (!isType(typeOrFunc)) {
            return [];
          }

          var parentCtor = getParentCtor(typeOrFunc);
          var ownAnnotations = this._ownAnnotations(typeOrFunc, parentCtor) || [];
          var parentAnnotations = parentCtor !== Object ? this.annotations(parentCtor) : [];
          return parentAnnotations.concat(ownAnnotations);
        }
      }, {
        key: "_ownPropMetadata",
        value: function _ownPropMetadata(typeOrFunc, parentCtor) {
          // Prefer the direct API.
          if (typeOrFunc.propMetadata && typeOrFunc.propMetadata !== parentCtor.propMetadata) {
            var propMetadata = typeOrFunc.propMetadata;

            if (typeof propMetadata === 'function' && propMetadata.propMetadata) {
              propMetadata = propMetadata.propMetadata;
            }

            return propMetadata;
          } // API of tsickle for lowering decorators to properties on the class.


          if (typeOrFunc.propDecorators && typeOrFunc.propDecorators !== parentCtor.propDecorators) {
            var propDecorators = typeOrFunc.propDecorators;
            var _propMetadata = {};
            Object.keys(propDecorators).forEach(function (prop) {
              _propMetadata[prop] = convertTsickleDecoratorIntoMetadata(propDecorators[prop]);
            });
            return _propMetadata;
          } // API for metadata created by invoking the decorators.


          if (typeOrFunc.hasOwnProperty(PROP_METADATA)) {
            return typeOrFunc[PROP_METADATA];
          }

          return null;
        }
      }, {
        key: "propMetadata",
        value: function propMetadata(typeOrFunc) {
          if (!isType(typeOrFunc)) {
            return {};
          }

          var parentCtor = getParentCtor(typeOrFunc);
          var propMetadata = {};

          if (parentCtor !== Object) {
            var parentPropMetadata = this.propMetadata(parentCtor);
            Object.keys(parentPropMetadata).forEach(function (propName) {
              propMetadata[propName] = parentPropMetadata[propName];
            });
          }

          var ownPropMetadata = this._ownPropMetadata(typeOrFunc, parentCtor);

          if (ownPropMetadata) {
            Object.keys(ownPropMetadata).forEach(function (propName) {
              var decorators = [];

              if (propMetadata.hasOwnProperty(propName)) {
                decorators.push.apply(decorators, _toConsumableArray(propMetadata[propName]));
              }

              decorators.push.apply(decorators, _toConsumableArray(ownPropMetadata[propName]));
              propMetadata[propName] = decorators;
            });
          }

          return propMetadata;
        }
      }, {
        key: "ownPropMetadata",
        value: function ownPropMetadata(typeOrFunc) {
          if (!isType(typeOrFunc)) {
            return {};
          }

          return this._ownPropMetadata(typeOrFunc, getParentCtor(typeOrFunc)) || {};
        }
      }, {
        key: "hasLifecycleHook",
        value: function hasLifecycleHook(type, lcProperty) {
          return type instanceof Type && lcProperty in type.prototype;
        }
      }, {
        key: "guards",
        value: function guards(type) {
          return {};
        }
      }, {
        key: "getter",
        value: function getter(name) {
          return new Function('o', 'return o.' + name + ';');
        }
      }, {
        key: "setter",
        value: function setter(name) {
          return new Function('o', 'v', 'return o.' + name + ' = v;');
        }
      }, {
        key: "method",
        value: function method(name) {
          var functionBody = "if (!o.".concat(name, ") throw new Error('\"").concat(name, "\" is undefined');\n        return o.").concat(name, ".apply(o, args);");
          return new Function('o', 'args', functionBody);
        } // There is not a concept of import uri in Js, but this is useful in developing Dart applications.

      }, {
        key: "importUri",
        value: function importUri(type) {
          // StaticSymbol
          if (typeof type === 'object' && type['filePath']) {
            return type['filePath'];
          } // Runtime type


          return "./".concat(stringify(type));
        }
      }, {
        key: "resourceUri",
        value: function resourceUri(type) {
          return "./".concat(stringify(type));
        }
      }, {
        key: "resolveIdentifier",
        value: function resolveIdentifier(name, moduleUrl, members, runtime) {
          return runtime;
        }
      }, {
        key: "resolveEnum",
        value: function resolveEnum(enumIdentifier, name) {
          return enumIdentifier[name];
        }
      }]);

      return ReflectionCapabilities;
    }();

    function convertTsickleDecoratorIntoMetadata(decoratorInvocations) {
      if (!decoratorInvocations) {
        return [];
      }

      return decoratorInvocations.map(function (decoratorInvocation) {
        var decoratorType = decoratorInvocation.type;
        var annotationCls = decoratorType.annotationCls;
        var annotationArgs = decoratorInvocation.args ? decoratorInvocation.args : [];
        return _construct(annotationCls, _toConsumableArray(annotationArgs));
      });
    }

    function getParentCtor(ctor) {
      var parentProto = ctor.prototype ? Object.getPrototypeOf(ctor.prototype) : null;
      var parentCtor = parentProto ? parentProto.constructor : null; // Note: We always use `Object` as the null value
      // to simplify checking later on.

      return parentCtor || Object;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/di/jit/util.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var _reflect = null;
    /**
     * @return {?}
     */

    function getReflect() {
      return _reflect = _reflect || new ReflectionCapabilities();
    }
    /**
     * @param {?} type
     * @return {?}
     */


    function reflectDependencies(type) {
      return convertDependencies(getReflect().parameters(type));
    }
    /**
     * @param {?} deps
     * @return {?}
     */


    function convertDependencies(deps) {
      /** @type {?} */
      var compiler = getCompilerFacade();
      return deps.map(
      /**
      * @param {?} dep
      * @return {?}
      */
      function (dep) {
        return reflectDependency(compiler, dep);
      });
    }
    /**
     * @param {?} compiler
     * @param {?} dep
     * @return {?}
     */


    function reflectDependency(compiler, dep) {
      /** @type {?} */
      var meta = {
        token: null,
        host: false,
        optional: false,
        resolved: compiler.R3ResolvedDependencyType.Token,
        self: false,
        skipSelf: false
      };
      /**
       * @param {?} token
       * @return {?}
       */

      function setTokenAndResolvedType(token) {
        meta.resolved = compiler.R3ResolvedDependencyType.Token;
        meta.token = token;
      }

      if (Array.isArray(dep) && dep.length > 0) {
        for (var j = 0; j < dep.length; j++) {
          /** @type {?} */
          var param = dep[j];

          if (param === undefined) {
            // param may be undefined if type of dep is not set by ngtsc
            continue;
          }
          /** @type {?} */


          var proto = Object.getPrototypeOf(param);

          if (param instanceof Optional || proto.ngMetadataName === 'Optional') {
            meta.optional = true;
          } else if (param instanceof SkipSelf || proto.ngMetadataName === 'SkipSelf') {
            meta.skipSelf = true;
          } else if (param instanceof Self || proto.ngMetadataName === 'Self') {
            meta.self = true;
          } else if (param instanceof Host || proto.ngMetadataName === 'Host') {
            meta.host = true;
          } else if (param instanceof Inject) {
            meta.token = param.token;
          } else if (param instanceof Attribute) {
            if (param.attributeName === undefined) {
              throw new Error("Attribute name must be defined.");
            }

            meta.token = param.attributeName;
            meta.resolved = compiler.R3ResolvedDependencyType.Attribute;
          } else if (param === ChangeDetectorRef) {
            meta.token = param;
            meta.resolved = compiler.R3ResolvedDependencyType.ChangeDetectorRef;
          } else {
            setTokenAndResolvedType(param);
          }
        }
      } else if (dep === undefined || Array.isArray(dep) && dep.length === 0) {
        meta.token = undefined;
        meta.resolved = R3ResolvedDependencyType.Invalid;
      } else {
        setTokenAndResolvedType(dep);
      }

      return meta;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/di/jit/injectable.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Compile an Angular injectable according to its `Injectable` metadata, and patch the resulting
     * injectable def (`ɵprov`) onto the injectable type.
     * @param {?} type
     * @param {?=} srcMeta
     * @return {?}
     */


    function compileInjectable(type, srcMeta) {
      /** @type {?} */
      var ngInjectableDef = null;
      /** @type {?} */

      var ngFactoryDef = null; // if NG_PROV_DEF is already defined on this class then don't overwrite it

      if (!type.hasOwnProperty(NG_PROV_DEF)) {
        Object.defineProperty(type, NG_PROV_DEF, {
          get:
          /**
          * @return {?}
          */
          function get() {
            if (ngInjectableDef === null) {
              ngInjectableDef = getCompilerFacade().compileInjectable(angularCoreDiEnv, "ng:///".concat(type.name, "/\u0275prov.js"), getInjectableMetadata(type, srcMeta));
            }

            return ngInjectableDef;
          }
        }); // On IE10 properties defined via `defineProperty` won't be inherited by child classes,
        // which will break inheriting the injectable definition from a grandparent through an
        // undecorated parent class. We work around it by defining a method which should be used
        // as a fallback. This should only be a problem in JIT mode, because in AOT TypeScript
        // seems to have a workaround for static properties. When inheriting from an undecorated
        // parent is no longer supported in v10, this can safely be removed.

        if (!type.hasOwnProperty(NG_PROV_DEF_FALLBACK)) {
          /** @type {?} */
          type[NG_PROV_DEF_FALLBACK] =
          /**
          * @return {?}
          */
          function () {
            return (
              /** @type {?} */
              type[NG_PROV_DEF]
            );
          };
        }
      } // if NG_FACTORY_DEF is already defined on this class then don't overwrite it


      if (!type.hasOwnProperty(NG_FACTORY_DEF)) {
        Object.defineProperty(type, NG_FACTORY_DEF, {
          get:
          /**
          * @return {?}
          */
          function get() {
            if (ngFactoryDef === null) {
              /** @type {?} */
              var metadata = getInjectableMetadata(type, srcMeta);
              /** @type {?} */

              var compiler = getCompilerFacade();
              ngFactoryDef = compiler.compileFactory(angularCoreDiEnv, "ng:///".concat(type.name, "/\u0275fac.js"), {
                name: metadata.name,
                type: metadata.type,
                typeArgumentCount: metadata.typeArgumentCount,
                deps: reflectDependencies(type),
                injectFn: 'inject',
                target: compiler.R3FactoryTarget.Injectable
              });
            }

            return ngFactoryDef;
          },
          // Leave this configurable so that the factories from directives or pipes can take precedence.
          configurable: true
        });
      }
    }

    var ɵ0$6 = getClosureSafeProperty;
    /** @type {?} */

    var USE_VALUE$1 = getClosureSafeProperty({
      provide: String,
      useValue: ɵ0$6
    });
    /**
     * @param {?} meta
     * @return {?}
     */

    function isUseClassProvider(meta) {
      return (
        /** @type {?} */
        meta.useClass !== undefined
      );
    }
    /**
     * @param {?} meta
     * @return {?}
     */


    function isUseValueProvider(meta) {
      return USE_VALUE$1 in meta;
    }
    /**
     * @param {?} meta
     * @return {?}
     */


    function isUseFactoryProvider(meta) {
      return (
        /** @type {?} */
        meta.useFactory !== undefined
      );
    }
    /**
     * @param {?} meta
     * @return {?}
     */


    function isUseExistingProvider(meta) {
      return (
        /** @type {?} */
        meta.useExisting !== undefined
      );
    }
    /**
     * @param {?} type
     * @param {?=} srcMeta
     * @return {?}
     */


    function getInjectableMetadata(type, srcMeta) {
      // Allow the compilation of a class with a `@Injectable()` decorator without parameters

      /** @type {?} */
      var meta = srcMeta || {
        providedIn: null
      };
      /** @type {?} */

      var compilerMeta = {
        name: type.name,
        type: type,
        typeArgumentCount: 0,
        providedIn: meta.providedIn,
        userDeps: undefined
      };

      if ((isUseClassProvider(meta) || isUseFactoryProvider(meta)) && meta.deps !== undefined) {
        compilerMeta.userDeps = convertDependencies(meta.deps);
      }

      if (isUseClassProvider(meta)) {
        // The user explicitly specified useClass, and may or may not have provided deps.
        compilerMeta.useClass = resolveForwardRef(meta.useClass);
      } else if (isUseValueProvider(meta)) {
        // The user explicitly specified useValue.
        compilerMeta.useValue = resolveForwardRef(meta.useValue);
      } else if (isUseFactoryProvider(meta)) {
        // The user explicitly specified useFactory.
        compilerMeta.useFactory = meta.useFactory;
      } else if (isUseExistingProvider(meta)) {
        // The user explicitly specified useExisting.
        compilerMeta.useExisting = resolveForwardRef(meta.useExisting);
      }

      return compilerMeta;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/di/util.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var ɵ0$7 = getClosureSafeProperty;
    /** @type {?} */

    var USE_VALUE$2 = getClosureSafeProperty({
      provide: String,
      useValue: ɵ0$7
    });
    /** @type {?} */

    var EMPTY_ARRAY$1 = [];
    /**
     * @param {?} type
     * @param {?=} provider
     * @return {?}
     */

    function convertInjectableProviderToFactory(type, provider) {
      if (!provider) {
        /** @type {?} */
        var reflectionCapabilities = new ReflectionCapabilities();
        /** @type {?} */

        var deps = reflectionCapabilities.parameters(type); // TODO - convert to flags.

        return (
          /**
          * @return {?}
          */
          function () {
            return _construct(type, _toConsumableArray(injectArgs(
            /** @type {?} */
            deps)));
          }
        );
      }

      if (USE_VALUE$2 in provider) {
        /** @type {?} */
        var valueProvider =
        /** @type {?} */
        provider;
        return (
          /**
          * @return {?}
          */
          function () {
            return valueProvider.useValue;
          }
        );
      } else if (
      /** @type {?} */
      provider.useExisting) {
        /** @type {?} */
        var existingProvider =
        /** @type {?} */
        provider;
        return (
          /**
          * @return {?}
          */
          function () {
            return ɵɵinject(resolveForwardRef(existingProvider.useExisting));
          }
        );
      } else if (
      /** @type {?} */
      provider.useFactory) {
        /** @type {?} */
        var factoryProvider =
        /** @type {?} */
        provider;
        return (
          /**
          * @return {?}
          */
          function () {
            return factoryProvider.useFactory.apply(factoryProvider, _toConsumableArray(injectArgs(factoryProvider.deps || EMPTY_ARRAY$1)));
          }
        );
      } else if (
      /** @type {?} */
      provider.useClass) {
        /** @type {?} */
        var classProvider =
        /** @type {?} */
        provider;
        /** @type {?} */

        var _deps =
        /** @type {?} */
        provider.deps;

        if (!_deps) {
          /** @type {?} */
          var _reflectionCapabilities = new ReflectionCapabilities();

          _deps = _reflectionCapabilities.parameters(type);
        }

        return (
          /**
          * @return {?}
          */
          function () {
            return _construct(resolveForwardRef(classProvider.useClass), _toConsumableArray(injectArgs(_deps)));
          }
        );
      } else {
        /** @type {?} */
        var _deps2 =
        /** @type {?} */
        provider.deps;

        if (!_deps2) {
          /** @type {?} */
          var _reflectionCapabilities2 = new ReflectionCapabilities();

          _deps2 = _reflectionCapabilities2.parameters(type);
        }

        return (
          /**
          * @return {?}
          */
          function () {
            return _construct(type, _toConsumableArray(injectArgs(
            /** @type {?} */
            _deps2)));
          }
        );
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/di/injectable.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Type of the Injectable decorator / constructor function.
     *
     * \@publicApi
     * @record
     */


    function InjectableDecorator() {} // WARNING: interface has both a type and a value, skipping emit


    var ɵ0$8 =
    /**
    * @param {?} type
    * @param {?} meta
    * @return {?}
    */
    function ɵ0$8(type, meta) {
      return SWITCH_COMPILE_INJECTABLE(
      /** @type {?} */
      type, meta);
    };
    /**
     * Injectable decorator and metadata.
     *
     * \@Annotation
     * \@publicApi
     * @type {?}
     */


    var Injectable = makeDecorator('Injectable', undefined, undefined, undefined, ɵ0$8);
    /**
     * Supports \@Injectable() in JIT mode for Render2.
     * @param {?} injectableType
     * @param {?=} options
     * @return {?}
     */

    function render2CompileInjectable(injectableType, options) {
      if (options && options.providedIn !== undefined && !getInjectableDef(injectableType)) {
        /** @type {?} */
        injectableType.ɵprov = ɵɵdefineInjectable({
          token: injectableType,
          providedIn: options.providedIn,
          factory: convertInjectableProviderToFactory(injectableType, options)
        });
      }
    }
    /** @type {?} */


    var SWITCH_COMPILE_INJECTABLE__POST_R3__ = compileInjectable;
    /** @type {?} */

    var SWITCH_COMPILE_INJECTABLE__PRE_R3__ = render2CompileInjectable;
    /** @type {?} */

    var SWITCH_COMPILE_INJECTABLE = SWITCH_COMPILE_INJECTABLE__POST_R3__;
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/di/scope.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * An internal token whose presence in an injector indicates that the injector should treat itself
     * as a root scoped injector when processing requests for unknown tokens which may indicate
     * they are provided in the root scope.
     * @type {?}
     */

    var INJECTOR_SCOPE = new InjectionToken('Set Injector scope.');
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/di/r3_injector.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Marker which indicates that a value has not yet been created from the factory function.
     * @type {?}
     */

    var NOT_YET = {};
    /**
     * Marker which indicates that the factory function for a token is in the process of being called.
     *
     * If the injector is asked to inject a token with its value set to CIRCULAR, that indicates
     * injection of a dependency has recursively attempted to inject the original token, and there is
     * a circular dependency among the providers.
     * @type {?}
     */

    var CIRCULAR = {};
    /** @type {?} */

    var EMPTY_ARRAY$2 =
    /** @type {?} */
    [];
    /**
     * A lazily initialized NullInjector.
     * @type {?}
     */

    var NULL_INJECTOR = undefined;
    /**
     * @return {?}
     */

    function getNullInjector() {
      if (NULL_INJECTOR === undefined) {
        NULL_INJECTOR = new NullInjector();
      }

      return NULL_INJECTOR;
    }
    /**
     * An entry in the injector which tracks information about the given token, including a possible
     * current value.
     * @record
     * @template T
     */


    function Record() {}

    if (false) {}
    /**
     * Create a new `Injector` which is configured using a `defType` of `InjectorType<any>`s.
     *
     * \@publicApi
     * @param {?} defType
     * @param {?=} parent
     * @param {?=} additionalProviders
     * @param {?=} name
     * @return {?}
     */


    function createInjector(defType) {
      var parent = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
      var additionalProviders = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
      var name = arguments.length > 3 ? arguments[3] : undefined;

      /** @type {?} */
      var injector = createInjectorWithoutInjectorInstances(defType, parent, additionalProviders, name);

      injector._resolveInjectorDefTypes();

      return injector;
    }
    /**
     * Creates a new injector without eagerly resolving its injector types. Can be used in places
     * where resolving the injector types immediately can lead to an infinite loop. The injector types
     * should be resolved at a later point by calling `_resolveInjectorDefTypes`.
     * @param {?} defType
     * @param {?=} parent
     * @param {?=} additionalProviders
     * @param {?=} name
     * @return {?}
     */


    function createInjectorWithoutInjectorInstances(defType) {
      var parent = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
      var additionalProviders = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
      var name = arguments.length > 3 ? arguments[3] : undefined;
      return new R3Injector(defType, additionalProviders, parent || getNullInjector(), name);
    }

    var R3Injector = /*#__PURE__*/function () {
      /**
       * @param {?} def
       * @param {?} additionalProviders
       * @param {?} parent
       * @param {?=} source
       */
      function R3Injector(def, additionalProviders, parent) {
        var _this153 = this;

        var source = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : null;

        _classCallCheck(this, R3Injector);

        this.parent = parent;
        /**
         * Map of tokens to records which contain the instances of those tokens.
         * - `null` value implies that we don't have the record. Used by tree-shakable injectors
         * to prevent further searches.
         */

        this.records = new Map();
        /**
         * The transitive set of `InjectorType`s which define this injector.
         */

        this.injectorDefTypes = new Set();
        /**
         * Set of values instantiated by this injector which contain `ngOnDestroy` lifecycle hooks.
         */

        this.onDestroy = new Set();
        this._destroyed = false;
        /** @type {?} */

        var dedupStack = []; // Start off by creating Records for every provider declared in every InjectorType
        // included transitively in additional providers then do the same for `def`. This order is
        // important because `def` may include providers that override ones in additionalProviders.

        additionalProviders && deepForEach(additionalProviders,
        /**
        * @param {?} provider
        * @return {?}
        */
        function (provider) {
          return _this153.processProvider(provider, def, additionalProviders);
        });
        deepForEach([def],
        /**
        * @param {?} injectorDef
        * @return {?}
        */
        function (injectorDef) {
          return _this153.processInjectorType(injectorDef, [], dedupStack);
        }); // Make sure the INJECTOR token provides this injector.

        this.records.set(INJECTOR, makeRecord(undefined, this)); // Detect whether this injector has the APP_ROOT_SCOPE token and thus should provide
        // any injectable scoped to APP_ROOT_SCOPE.

        /** @type {?} */

        var record = this.records.get(INJECTOR_SCOPE);
        this.scope = record != null ? record.value : null; // Source name, used for debugging

        this.source = source || (typeof def === 'object' ? null : stringify(def));
      }
      /**
       * Flag indicating that this injector was previously destroyed.
       * @return {?}
       */


      _createClass2(R3Injector, [{
        key: "destroy",

        /**
         * Destroy the injector and release references to every instance or provider associated with it.
         *
         * Also calls the `OnDestroy` lifecycle hooks of every instance that was created for which a
         * hook was found.
         * @return {?}
         */
        value: function destroy() {
          this.assertNotDestroyed(); // Set destroyed = true first, in case lifecycle hooks re-enter destroy().

          this._destroyed = true;

          try {
            // Call all the lifecycle hooks.
            this.onDestroy.forEach(
            /**
            * @param {?} service
            * @return {?}
            */
            function (service) {
              return service.ngOnDestroy();
            });
          } finally {
            // Release all references.
            this.records.clear();
            this.onDestroy.clear();
            this.injectorDefTypes.clear();
          }
        }
        /**
         * @template T
         * @param {?} token
         * @param {?=} notFoundValue
         * @param {?=} flags
         * @return {?}
         */

      }, {
        key: "get",
        value: function get(token) {
          var notFoundValue = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : THROW_IF_NOT_FOUND;
          var flags = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : InjectFlags.Default;
          this.assertNotDestroyed(); // Set the injection context.

          /** @type {?} */

          var previousInjector = setCurrentInjector(this);

          try {
            // Check for the SkipSelf flag.
            if (!(flags & InjectFlags.SkipSelf)) {
              // SkipSelf isn't set, check if the record belongs to this injector.

              /** @type {?} */
              var record = this.records.get(token);

              if (record === undefined) {
                // No record, but maybe the token is scoped to this injector. Look for an injectable
                // def with a scope matching this injector.

                /** @type {?} */
                var def = couldBeInjectableType(token) && getInjectableDef(token);

                if (def && this.injectableDefInScope(def)) {
                  // Found an injectable def and it's scoped to this injector. Pretend as if it was here
                  // all along.
                  record = makeRecord(injectableDefOrInjectorDefFactory(token), NOT_YET);
                } else {
                  record = null;
                }

                this.records.set(token, record);
              } // If a record was found, get the instance for it and return it.


              if (record != null
              /* NOT null || undefined */
              ) {
                  return this.hydrate(token, record);
                }
            } // Select the next injector based on the Self flag - if self is set, the next injector is
            // the NullInjector, otherwise it's the parent.

            /** @type {?} */


            var nextInjector = !(flags & InjectFlags.Self) ? this.parent : getNullInjector(); // Set the notFoundValue based on the Optional flag - if optional is set and notFoundValue
            // is undefined, the value is null, otherwise it's the notFoundValue.

            notFoundValue = flags & InjectFlags.Optional && notFoundValue === THROW_IF_NOT_FOUND ? null : notFoundValue;
            return nextInjector.get(token, notFoundValue);
          } catch (e) {
            if (e.name === 'NullInjectorError') {
              /** @type {?} */
              var path = e[NG_TEMP_TOKEN_PATH] = e[NG_TEMP_TOKEN_PATH] || [];
              path.unshift(stringify(token));

              if (previousInjector) {
                // We still have a parent injector, keep throwing
                throw e;
              } else {
                // Format & throw the final error message when we don't have any previous injector
                return catchInjectorError(e, token, 'R3InjectorError', this.source);
              }
            } else {
              throw e;
            }
          } finally {
            // Lastly, clean up the state by restoring the previous injector.
            setCurrentInjector(previousInjector);
          }
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_resolveInjectorDefTypes",
        value: function _resolveInjectorDefTypes() {
          var _this154 = this;

          this.injectorDefTypes.forEach(
          /**
          * @param {?} defType
          * @return {?}
          */
          function (defType) {
            return _this154.get(defType);
          });
        }
        /**
         * @return {?}
         */

      }, {
        key: "toString",
        value: function toString() {
          /** @type {?} */
          var tokens =
          /** @type {?} */
          [];
          /** @type {?} */

          var records = this.records;
          records.forEach(
          /**
          * @param {?} v
          * @param {?} token
          * @return {?}
          */
          function (v, token) {
            return tokens.push(stringify(token));
          });
          return "R3Injector[".concat(tokens.join(', '), "]");
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "assertNotDestroyed",
        value: function assertNotDestroyed() {
          if (this._destroyed) {
            throw new Error('Injector has already been destroyed.');
          }
        }
        /**
         * Add an `InjectorType` or `InjectorTypeWithProviders` and all of its transitive providers
         * to this injector.
         *
         * If an `InjectorTypeWithProviders` that declares providers besides the type is specified,
         * the function will return "true" to indicate that the providers of the type definition need
         * to be processed. This allows us to process providers of injector types after all imports of
         * an injector definition are processed. (following View Engine semantics: see FW-1349)
         * @private
         * @param {?} defOrWrappedDef
         * @param {?} parents
         * @param {?} dedupStack
         * @return {?}
         */

      }, {
        key: "processInjectorType",
        value: function processInjectorType(defOrWrappedDef, parents, dedupStack) {
          var _this155 = this;

          defOrWrappedDef = resolveForwardRef(defOrWrappedDef);
          if (!defOrWrappedDef) return false; // Either the defOrWrappedDef is an InjectorType (with injector def) or an
          // InjectorDefTypeWithProviders (aka ModuleWithProviders). Detecting either is a megamorphic
          // read, so care is taken to only do the read once.
          // First attempt to read the injector def (`ɵinj`).

          /** @type {?} */

          var def = getInjectorDef(defOrWrappedDef); // If that's not present, then attempt to read ngModule from the InjectorDefTypeWithProviders.

          /** @type {?} */

          var ngModule = def == null &&
          /** @type {?} */
          defOrWrappedDef.ngModule || undefined; // Determine the InjectorType. In the case where `defOrWrappedDef` is an `InjectorType`,
          // then this is easy. In the case of an InjectorDefTypeWithProviders, then the definition type
          // is the `ngModule`.

          /** @type {?} */

          var defType = ngModule === undefined ?
          /** @type {?} */
          defOrWrappedDef : ngModule; // Check for circular dependencies.

          if (ngDevMode && parents.indexOf(defType) !== -1) {
            /** @type {?} */
            var defName = stringify(defType);
            throw new Error("Circular dependency in DI detected for type ".concat(defName, ". Dependency path: ").concat(parents.map(
            /**
            * @param {?} defType
            * @return {?}
            */
            function (defType) {
              return stringify(defType);
            }).join(' > '), " > ").concat(defName, "."));
          } // Check for multiple imports of the same module

          /** @type {?} */


          var isDuplicate = dedupStack.indexOf(defType) !== -1; // Finally, if defOrWrappedType was an `InjectorDefTypeWithProviders`, then the actual
          // `InjectorDef` is on its `ngModule`.

          if (ngModule !== undefined) {
            def = getInjectorDef(ngModule);
          } // If no definition was found, it might be from exports. Remove it.


          if (def == null) {
            return false;
          } // Add providers in the same way that @NgModule resolution did:
          // First, include providers from any imports.


          if (def.imports != null && !isDuplicate) {
            // Before processing defType's imports, add it to the set of parents. This way, if it ends
            // up deeply importing itself, this can be detected.
            ngDevMode && parents.push(defType); // Add it to the set of dedups. This way we can detect multiple imports of the same module

            dedupStack.push(defType);
            /** @type {?} */

            var importTypesWithProviders;

            try {
              deepForEach(def.imports,
              /**
              * @param {?} imported
              * @return {?}
              */
              function (imported) {
                if (_this155.processInjectorType(imported, parents, dedupStack)) {
                  if (importTypesWithProviders === undefined) importTypesWithProviders = []; // If the processed import is an injector type with providers, we store it in the
                  // list of import types with providers, so that we can process those afterwards.

                  importTypesWithProviders.push(imported);
                }
              });
            } finally {
              // Remove it from the parents set when finished.
              ngDevMode && parents.pop();
            } // Imports which are declared with providers (TypeWithProviders) need to be processed
            // after all imported modules are processed. This is similar to how View Engine
            // processes/merges module imports in the metadata resolver. See: FW-1349.


            if (importTypesWithProviders !== undefined) {
              var _loop3 = function _loop3(i) {
                var _importTypesWithProvi = importTypesWithProviders[i],
                    ngModule = _importTypesWithProvi.ngModule,
                    providers = _importTypesWithProvi.providers;
                deepForEach(
                /** @type {?} */
                providers,
                /**
                * @param {?} provider
                * @return {?}
                */
                function (provider) {
                  return _this155.processProvider(provider, ngModule, providers || EMPTY_ARRAY$2);
                });
              };

              for (var i = 0; i < importTypesWithProviders.length; i++) {
                _loop3(i);
              }
            }
          } // Track the InjectorType and add a provider for it. It's important that this is done after the
          // def's imports.


          this.injectorDefTypes.add(defType);
          this.records.set(defType, makeRecord(def.factory, NOT_YET)); // Next, include providers listed on the definition itself.

          /** @type {?} */

          var defProviders = def.providers;

          if (defProviders != null && !isDuplicate) {
            /** @type {?} */
            var injectorType =
            /** @type {?} */
            defOrWrappedDef;
            deepForEach(defProviders,
            /**
            * @param {?} provider
            * @return {?}
            */
            function (provider) {
              return _this155.processProvider(provider, injectorType, defProviders);
            });
          }

          return ngModule !== undefined &&
          /** @type {?} */
          defOrWrappedDef.providers !== undefined;
        }
        /**
         * Process a `SingleProvider` and add it.
         * @private
         * @param {?} provider
         * @param {?} ngModuleType
         * @param {?} providers
         * @return {?}
         */

      }, {
        key: "processProvider",
        value: function processProvider(provider, ngModuleType, providers) {
          // Determine the token from the provider. Either it's its own token, or has a {provide: ...}
          // property.
          provider = resolveForwardRef(provider);
          /** @type {?} */

          var token = isTypeProvider(provider) ? provider : resolveForwardRef(provider && provider.provide); // Construct a `Record` for the provider.

          /** @type {?} */

          var record = providerToRecord(provider, ngModuleType, providers);

          if (!isTypeProvider(provider) && provider.multi === true) {
            // If the provider indicates that it's a multi-provider, process it specially.
            // First check whether it's been defined already.

            /** @type {?} */
            var multiRecord = this.records.get(token);

            if (multiRecord) {
              // It has. Throw a nice error if
              if (multiRecord.multi === undefined) {
                throwMixedMultiProviderError();
              }
            } else {
              multiRecord = makeRecord(undefined, NOT_YET, true);

              multiRecord.factory =
              /**
              * @return {?}
              */
              function () {
                return injectArgs(
                /** @type {?} */

                /** @type {?} */
                multiRecord.multi);
              };

              this.records.set(token, multiRecord);
            }

            token = provider;

            /** @type {?} */
            multiRecord.multi.push(provider);
          } else {
            /** @type {?} */
            var existing = this.records.get(token);

            if (existing && existing.multi !== undefined) {
              throwMixedMultiProviderError();
            }
          }

          this.records.set(token, record);
        }
        /**
         * @private
         * @template T
         * @param {?} token
         * @param {?} record
         * @return {?}
         */

      }, {
        key: "hydrate",
        value: function hydrate(token, record) {
          if (record.value === CIRCULAR) {
            throwCyclicDependencyError(stringify(token));
          } else if (record.value === NOT_YET) {
            record.value = CIRCULAR;
            record.value =
            /** @type {?} */
            record.factory();
          }

          if (typeof record.value === 'object' && record.value && hasOnDestroy(record.value)) {
            this.onDestroy.add(record.value);
          }

          return (
            /** @type {?} */
            record.value
          );
        }
        /**
         * @private
         * @param {?} def
         * @return {?}
         */

      }, {
        key: "injectableDefInScope",
        value: function injectableDefInScope(def) {
          if (!def.providedIn) {
            return false;
          } else if (typeof def.providedIn === 'string') {
            return def.providedIn === 'any' || def.providedIn === this.scope;
          } else {
            return this.injectorDefTypes.has(def.providedIn);
          }
        }
      }, {
        key: "destroyed",
        get: function get() {
          return this._destroyed;
        }
      }]);

      return R3Injector;
    }();

    if (false) {}
    /**
     * @param {?} token
     * @return {?}
     */


    function injectableDefOrInjectorDefFactory(token) {
      // Most tokens will have an injectable def directly on them, which specifies a factory directly.

      /** @type {?} */
      var injectableDef = getInjectableDef(token);
      /** @type {?} */

      var factory = injectableDef !== null ? injectableDef.factory : getFactoryDef(token);

      if (factory !== null) {
        return factory;
      } // If the token is an NgModule, it's also injectable but the factory is on its injector def
      // (`ɵinj`)

      /** @type {?} */


      var injectorDef = getInjectorDef(token);

      if (injectorDef !== null) {
        return injectorDef.factory;
      } // InjectionTokens should have an injectable def (ɵprov) and thus should be handled above.
      // If it's missing that, it's an error.


      if (token instanceof InjectionToken) {
        throw new Error("Token ".concat(stringify(token), " is missing a \u0275prov definition."));
      } // Undecorated types can sometimes be created if they have no constructor arguments.


      if (token instanceof Function) {
        return getUndecoratedInjectableFactory(token);
      } // There was no way to resolve a factory for this token.


      throw new Error('unreachable');
    }
    /**
     * @param {?} token
     * @return {?}
     */


    function getUndecoratedInjectableFactory(token) {
      // If the token has parameters then it has dependencies that we cannot resolve implicitly.

      /** @type {?} */
      var paramLength = token.length;

      if (paramLength > 0) {
        /** @type {?} */
        var args = newArray(paramLength, '?');
        throw new Error("Can't resolve all parameters for ".concat(stringify(token), ": (").concat(args.join(', '), ")."));
      } // The constructor function appears to have no parameters.
      // This might be because it inherits from a super-class. In which case, use an injectable
      // def from an ancestor if there is one.
      // Otherwise this really is a simple class with no dependencies, so return a factory that
      // just instantiates the zero-arg constructor.

      /** @type {?} */


      var inheritedInjectableDef = getInheritedInjectableDef(token);

      if (inheritedInjectableDef !== null) {
        return (
          /**
          * @return {?}
          */
          function () {
            return inheritedInjectableDef.factory(
            /** @type {?} */
            token);
          }
        );
      } else {
        return (
          /**
          * @return {?}
          */
          function () {
            return new
            /** @type {?} */
            token();
          }
        );
      }
    }
    /**
     * @param {?} provider
     * @param {?} ngModuleType
     * @param {?} providers
     * @return {?}
     */


    function providerToRecord(provider, ngModuleType, providers) {
      if (isValueProvider(provider)) {
        return makeRecord(undefined, provider.useValue);
      } else {
        /** @type {?} */
        var factory = providerToFactory(provider, ngModuleType, providers);
        return makeRecord(factory, NOT_YET);
      }
    }
    /**
     * Converts a `SingleProvider` into a factory function.
     *
     * @param {?} provider provider to convert to factory
     * @param {?=} ngModuleType
     * @param {?=} providers
     * @return {?}
     */


    function providerToFactory(provider, ngModuleType, providers) {
      /** @type {?} */
      var factory = undefined;

      if (isTypeProvider(provider)) {
        /** @type {?} */
        var unwrappedProvider = resolveForwardRef(provider);
        return getFactoryDef(unwrappedProvider) || injectableDefOrInjectorDefFactory(unwrappedProvider);
      } else {
        if (isValueProvider(provider)) {
          factory =
          /**
          * @return {?}
          */
          function factory() {
            return resolveForwardRef(provider.useValue);
          };
        } else if (isFactoryProvider(provider)) {
          factory =
          /**
          * @return {?}
          */
          function factory() {
            return provider.useFactory.apply(provider, _toConsumableArray(injectArgs(provider.deps || [])));
          };
        } else if (isExistingProvider(provider)) {
          factory =
          /**
          * @return {?}
          */
          function factory() {
            return ɵɵinject(resolveForwardRef(provider.useExisting));
          };
        } else {
          /** @type {?} */
          var classRef = resolveForwardRef(provider && (
          /** @type {?} */
          provider.useClass || provider.provide));

          if (!classRef) {
            throwInvalidProviderError(ngModuleType, providers, provider);
          }

          if (hasDeps(provider)) {
            factory =
            /**
            * @return {?}
            */
            function factory() {
              return _construct(classRef, _toConsumableArray(injectArgs(provider.deps)));
            };
          } else {
            return getFactoryDef(classRef) || injectableDefOrInjectorDefFactory(classRef);
          }
        }
      }

      return factory;
    }
    /**
     * @template T
     * @param {?} factory
     * @param {?} value
     * @param {?=} multi
     * @return {?}
     */


    function makeRecord(factory, value) {
      var multi = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
      return {
        factory: factory,
        value: value,
        multi: multi ? [] : undefined
      };
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function isValueProvider(value) {
      return value !== null && typeof value == 'object' && USE_VALUE in value;
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function isExistingProvider(value) {
      return !!(value &&
      /** @type {?} */
      value.useExisting);
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function isFactoryProvider(value) {
      return !!(value &&
      /** @type {?} */
      value.useFactory);
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function isTypeProvider(value) {
      return typeof value === 'function';
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function isClassProvider(value) {
      return !!
      /** @type {?} */
      value.useClass;
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function hasDeps(value) {
      return !!
      /** @type {?} */
      value.deps;
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function hasOnDestroy(value) {
      return value !== null && typeof value === 'object' && typeof
      /** @type {?} */
      value.ngOnDestroy === 'function';
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function couldBeInjectableType(value) {
      return typeof value === 'function' || typeof value === 'object' && value instanceof InjectionToken;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/di/injector.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} providers
     * @param {?} parent
     * @param {?} name
     * @return {?}
     */


    function INJECTOR_IMPL__PRE_R3__(providers, parent, name) {
      return new StaticInjector(providers, parent, name);
    }
    /**
     * @param {?} providers
     * @param {?} parent
     * @param {?} name
     * @return {?}
     */


    function INJECTOR_IMPL__POST_R3__(providers, parent, name) {
      return createInjector({
        name: name
      }, parent, providers, name);
    }
    /** @type {?} */


    var INJECTOR_IMPL = INJECTOR_IMPL__POST_R3__;
    /**
     * Concrete injectors implement this interface. Injectors are configured
     * with [providers](guide/glossary#provider) that associate
     * dependencies of various types with [injection tokens](guide/glossary#di-token).
     *
     * @see ["DI Providers"](guide/dependency-injection-providers).
     * @see `StaticProvider`
     *
     * \@usageNotes
     *
     *  The following example creates a service injector instance.
     *
     * {\@example core/di/ts/provider_spec.ts region='ConstructorProvider'}
     *
     * ### Usage example
     *
     * {\@example core/di/ts/injector_spec.ts region='Injector'}
     *
     * `Injector` returns itself when given `Injector` as a token:
     *
     * {\@example core/di/ts/injector_spec.ts region='injectInjector'}
     *
     * \@publicApi
     * @abstract
     */

    var Injector = /*#__PURE__*/function () {
      function Injector() {
        _classCallCheck(this, Injector);
      }

      _createClass2(Injector, null, [{
        key: "create",

        /**
         * @param {?} options
         * @param {?=} parent
         * @return {?}
         */
        value: function create(options, parent) {
          if (Array.isArray(options)) {
            return INJECTOR_IMPL(options, parent, '');
          } else {
            return INJECTOR_IMPL(options.providers, options.parent, options.name || '');
          }
        }
      }]);

      return Injector;
    }();

    Injector.THROW_IF_NOT_FOUND = THROW_IF_NOT_FOUND;
    Injector.NULL = new NullInjector();
    /** @nocollapse */

    Injector.ɵprov = ɵɵdefineInjectable({
      token: Injector,
      providedIn:
      /** @type {?} */
      'any',
      factory:
      /**
      * @return {?}
      */
      function factory() {
        return ɵɵinject(INJECTOR);
      }
    });
    /**
     * \@internal
     * @nocollapse
     */

    Injector.__NG_ELEMENT_ID__ = -1;

    if (false) {}
    /** @type {?} */


    var IDENT =
    /**
    * @template T
    * @param {?} value
    * @return {?}
    */
    function IDENT(value) {
      return value;
    };

    var ɵ0$9 = IDENT;
    /** @type {?} */

    var EMPTY =
    /** @type {?} */
    [];
    /** @type {?} */

    var CIRCULAR$1 = IDENT;
    /** @type {?} */

    var MULTI_PROVIDER_FN =
    /**
    * @return {?}
    */
    function MULTI_PROVIDER_FN() {
      return Array.prototype.slice.call(arguments);
    };

    var ɵ1$1 = MULTI_PROVIDER_FN;
    /** @enum {number} */

    var OptionFlags = {
      Optional: 1,
      CheckSelf: 2,
      CheckParent: 4,
      Default: 6
    };
    /** @type {?} */

    var NO_NEW_LINE$1 = 'ɵ';

    var StaticInjector = /*#__PURE__*/function () {
      /**
       * @param {?} providers
       * @param {?=} parent
       * @param {?=} source
       */
      function StaticInjector(providers) {
        var parent = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : Injector.NULL;
        var source = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;

        _classCallCheck(this, StaticInjector);

        this.parent = parent;
        this.source = source;
        /** @type {?} */

        var records = this._records = new Map();
        records.set(Injector,
        /** @type {?} */
        {
          token: Injector,
          fn: IDENT,
          deps: EMPTY,
          value: this,
          useNew: false
        });
        records.set(INJECTOR,
        /** @type {?} */
        {
          token: INJECTOR,
          fn: IDENT,
          deps: EMPTY,
          value: this,
          useNew: false
        });
        this.scope = recursivelyProcessProviders(records, providers);
      }
      /**
       * @param {?} token
       * @param {?=} notFoundValue
       * @param {?=} flags
       * @return {?}
       */


      _createClass2(StaticInjector, [{
        key: "get",
        value: function get(token, notFoundValue) {
          var flags = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : InjectFlags.Default;

          /** @type {?} */
          var records = this._records;
          /** @type {?} */

          var record = records.get(token);

          if (record === undefined) {
            // This means we have never seen this record, see if it is tree shakable provider.

            /** @type {?} */
            var injectableDef = getInjectableDef(token);

            if (injectableDef) {
              /** @type {?} */
              var providedIn = injectableDef && injectableDef.providedIn;

              if (providedIn === 'any' || providedIn != null && providedIn === this.scope) {
                records.set(token, record = resolveProvider({
                  provide: token,
                  useFactory: injectableDef.factory,
                  deps: EMPTY
                }));
              }
            }

            if (record === undefined) {
              // Set record to null to make sure that we don't go through expensive lookup above again.
              records.set(token, null);
            }
          }
          /** @type {?} */


          var lastInjector = setCurrentInjector(this);

          try {
            return tryResolveToken(token, record, records, this.parent, notFoundValue, flags);
          } catch (e) {
            return catchInjectorError(e, token, 'StaticInjectorError', this.source);
          } finally {
            setCurrentInjector(lastInjector);
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "toString",
        value: function toString() {
          /** @type {?} */
          var tokens =
          /** @type {?} */
          [];
          /** @type {?} */

          var records = this._records;
          records.forEach(
          /**
          * @param {?} v
          * @param {?} token
          * @return {?}
          */
          function (v, token) {
            return tokens.push(stringify(token));
          });
          return "StaticInjector[".concat(tokens.join(', '), "]");
        }
      }]);

      return StaticInjector;
    }();

    if (false) {}
    /**
     * @record
     */


    function Record$1() {}

    if (false) {}
    /**
     * @record
     */


    function DependencyRecord() {}

    if (false) {}
    /**
     * @param {?} provider
     * @return {?}
     */


    function resolveProvider(provider) {
      /** @type {?} */
      var deps = computeDeps(provider);
      /** @type {?} */

      var fn = IDENT;
      /** @type {?} */

      var value = EMPTY;
      /** @type {?} */

      var useNew = false;
      /** @type {?} */

      var provide = resolveForwardRef(provider.provide);

      if (USE_VALUE in provider) {
        // We need to use USE_VALUE in provider since provider.useValue could be defined as undefined.
        value =
        /** @type {?} */
        provider.useValue;
      } else if (
      /** @type {?} */
      provider.useFactory) {
        fn =
        /** @type {?} */
        provider.useFactory;
      } else if (
      /** @type {?} */
      provider.useExisting) {// Just use IDENT
      } else if (
      /** @type {?} */
      provider.useClass) {
        useNew = true;
        fn = resolveForwardRef(
        /** @type {?} */
        provider.useClass);
      } else if (typeof provide == 'function') {
        useNew = true;
        fn = provide;
      } else {
        throw staticError('StaticProvider does not have [useValue|useFactory|useExisting|useClass] or [provide] is not newable', provider);
      }

      return {
        deps: deps,
        fn: fn,
        useNew: useNew,
        value: value
      };
    }
    /**
     * @param {?} token
     * @return {?}
     */


    function multiProviderMixError(token) {
      return staticError('Cannot mix multi providers and regular providers', token);
    }
    /**
     * @param {?} records
     * @param {?} provider
     * @return {?}
     */


    function recursivelyProcessProviders(records, provider) {
      /** @type {?} */
      var scope = null;

      if (provider) {
        provider = resolveForwardRef(provider);

        if (Array.isArray(provider)) {
          // if we have an array recurse into the array
          for (var i = 0; i < provider.length; i++) {
            scope = recursivelyProcessProviders(records, provider[i]) || scope;
          }
        } else if (typeof provider === 'function') {
          // Functions were supported in ReflectiveInjector, but are not here. For safety give useful
          // error messages
          throw staticError('Function/Class not supported', provider);
        } else if (provider && typeof provider === 'object' && provider.provide) {
          // At this point we have what looks like a provider: {provide: ?, ....}

          /** @type {?} */
          var token = resolveForwardRef(provider.provide);
          /** @type {?} */

          var resolvedProvider = resolveProvider(provider);

          if (provider.multi === true) {
            // This is a multi provider.

            /** @type {?} */
            var multiProvider = records.get(token);

            if (multiProvider) {
              if (multiProvider.fn !== MULTI_PROVIDER_FN) {
                throw multiProviderMixError(token);
              }
            } else {
              // Create a placeholder factory which will look up the constituents of the multi provider.
              records.set(token, multiProvider =
              /** @type {?} */
              {
                token: provider.provide,
                deps: [],
                useNew: false,
                fn: MULTI_PROVIDER_FN,
                value: EMPTY
              });
            } // Treat the provider as the token.


            token = provider;
            multiProvider.deps.push({
              token: token,
              options: 6
              /* Default */

            });
          }
          /** @type {?} */


          var record = records.get(token);

          if (record && record.fn == MULTI_PROVIDER_FN) {
            throw multiProviderMixError(token);
          }

          if (token === INJECTOR_SCOPE) {
            scope = resolvedProvider.value;
          }

          records.set(token, resolvedProvider);
        } else {
          throw staticError('Unexpected provider', provider);
        }
      }

      return scope;
    }
    /**
     * @param {?} token
     * @param {?} record
     * @param {?} records
     * @param {?} parent
     * @param {?} notFoundValue
     * @param {?} flags
     * @return {?}
     */


    function tryResolveToken(token, record, records, parent, notFoundValue, flags) {
      try {
        return resolveToken(token, record, records, parent, notFoundValue, flags);
      } catch (e) {
        // ensure that 'e' is of type Error.
        if (!(e instanceof Error)) {
          e = new Error(e);
        }
        /** @type {?} */


        var path = e[NG_TEMP_TOKEN_PATH] = e[NG_TEMP_TOKEN_PATH] || [];
        path.unshift(token);

        if (record && record.value == CIRCULAR$1) {
          // Reset the Circular flag.
          record.value = EMPTY;
        }

        throw e;
      }
    }
    /**
     * @param {?} token
     * @param {?} record
     * @param {?} records
     * @param {?} parent
     * @param {?} notFoundValue
     * @param {?} flags
     * @return {?}
     */


    function resolveToken(token, record, records, parent, notFoundValue, flags) {
      /** @type {?} */
      var value;

      if (record && !(flags & InjectFlags.SkipSelf)) {
        // If we don't have a record, this implies that we don't own the provider hence don't know how
        // to resolve it.
        value = record.value;

        if (value == CIRCULAR$1) {
          throw Error(NO_NEW_LINE$1 + 'Circular dependency');
        } else if (value === EMPTY) {
          record.value = CIRCULAR$1;
          /** @type {?} */

          var obj = undefined;
          /** @type {?} */

          var useNew = record.useNew;
          /** @type {?} */

          var fn = record.fn;
          /** @type {?} */

          var depRecords = record.deps;
          /** @type {?} */

          var deps = EMPTY;

          if (depRecords.length) {
            deps = [];

            for (var i = 0; i < depRecords.length; i++) {
              /** @type {?} */
              var depRecord = depRecords[i];
              /** @type {?} */

              var options = depRecord.options;
              /** @type {?} */

              var childRecord = options & 2
              /* CheckSelf */
              ? records.get(depRecord.token) : undefined;
              deps.push(tryResolveToken( // Current Token to resolve
              depRecord.token, // A record which describes how to resolve the token.
              // If undefined, this means we don't have such a record
              childRecord, // Other records we know about.
              records, // If we don't know how to resolve dependency and we should not check parent for it,
              // than pass in Null injector.
              !childRecord && !(options & 4
              /* CheckParent */
              ) ? Injector.NULL : parent, options & 1
              /* Optional */
              ? null : Injector.THROW_IF_NOT_FOUND, InjectFlags.Default));
            }
          }

          record.value = value = useNew ? _construct(
          /** @type {?} */
          fn, _toConsumableArray(deps)) : fn.apply(obj, deps);
        }
      } else if (!(flags & InjectFlags.Self)) {
        value = parent.get(token, notFoundValue, InjectFlags.Default);
      } else if (!(flags & InjectFlags.Optional)) {
        value = Injector.NULL.get(token, notFoundValue);
      } else {
        value = Injector.NULL.get(token, typeof notFoundValue !== 'undefined' ? notFoundValue : null);
      }

      return value;
    }
    /**
     * @param {?} provider
     * @return {?}
     */


    function computeDeps(provider) {
      /** @type {?} */
      var deps = EMPTY;
      /** @type {?} */

      var providerDeps =
      /** @type {?} */
      provider.deps;

      if (providerDeps && providerDeps.length) {
        deps = [];

        for (var i = 0; i < providerDeps.length; i++) {
          /** @type {?} */
          var options = 6
          /* Default */
          ;
          /** @type {?} */

          var token = resolveForwardRef(providerDeps[i]);

          if (Array.isArray(token)) {
            for (var j = 0, annotations = token; j < annotations.length; j++) {
              /** @type {?} */
              var annotation = annotations[j];

              if (annotation instanceof Optional || annotation == Optional) {
                options = options | 1
                /* Optional */
                ;
              } else if (annotation instanceof SkipSelf || annotation == SkipSelf) {
                options = options & ~2
                /* CheckSelf */
                ;
              } else if (annotation instanceof Self || annotation == Self) {
                options = options & ~4
                /* CheckParent */
                ;
              } else if (annotation instanceof Inject) {
                token =
                /** @type {?} */
                annotation.token;
              } else {
                token = resolveForwardRef(annotation);
              }
            }
          }

          deps.push({
            token: token,
            options: options
          });
        }
      } else if (
      /** @type {?} */
      provider.useExisting) {
        /** @type {?} */
        var _token = resolveForwardRef(
        /** @type {?} */
        provider.useExisting);

        deps = [{
          token: _token,
          options: 6
          /* Default */

        }];
      } else if (!providerDeps && !(USE_VALUE in provider)) {
        // useValue & useExisting are the only ones which are exempt from deps all others need it.
        throw staticError('\'deps\' required', provider);
      }

      return deps;
    }
    /**
     * @param {?} text
     * @param {?} obj
     * @return {?}
     */


    function staticError(text, obj) {
      return new Error(formatError(text, obj, 'StaticInjectorError'));
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/di/reflective_errors.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} keys
     * @return {?}
     */


    function findFirstClosedCycle(keys) {
      /** @type {?} */
      var res = [];

      for (var i = 0; i < keys.length; ++i) {
        if (res.indexOf(keys[i]) > -1) {
          res.push(keys[i]);
          return res;
        }

        res.push(keys[i]);
      }

      return res;
    }
    /**
     * @param {?} keys
     * @return {?}
     */


    function constructResolvingPath(keys) {
      if (keys.length > 1) {
        /** @type {?} */
        var reversed = findFirstClosedCycle(keys.slice().reverse());
        /** @type {?} */

        var tokenStrs = reversed.map(
        /**
        * @param {?} k
        * @return {?}
        */
        function (k) {
          return stringify(k.token);
        });
        return ' (' + tokenStrs.join(' -> ') + ')';
      }

      return '';
    }
    /**
     * @record
     */


    function InjectionError() {}

    if (false) {}
    /**
     * @param {?} injector
     * @param {?} key
     * @param {?} constructResolvingMessage
     * @param {?=} originalError
     * @return {?}
     */


    function injectionError(injector, key, constructResolvingMessage, originalError) {
      /** @type {?} */
      var keys = [key];
      /** @type {?} */

      var errMsg = constructResolvingMessage(keys);
      /** @type {?} */

      var error =
      /** @type {?} */
      originalError ? wrappedError(errMsg, originalError) : Error(errMsg);
      error.addKey = addKey;
      error.keys = keys;
      error.injectors = [injector];
      error.constructResolvingMessage = constructResolvingMessage;

      /** @type {?} */
      error[ERROR_ORIGINAL_ERROR] = originalError;
      return error;
    }
    /**
     * @this {?}
     * @param {?} injector
     * @param {?} key
     * @return {?}
     */


    function addKey(injector, key) {
      this.injectors.push(injector);
      this.keys.push(key); // Note: This updated message won't be reflected in the `.stack` property

      this.message = this.constructResolvingMessage(this.keys);
    }
    /**
     * Thrown when trying to retrieve a dependency by key from {\@link Injector}, but the
     * {\@link Injector} does not have a {\@link Provider} for the given key.
     *
     * \@usageNotes
     * ### Example
     *
     * ```typescript
     * class A {
     *   constructor(b:B) {}
     * }
     *
     * expect(() => Injector.resolveAndCreate([A])).toThrowError();
     * ```
     * @param {?} injector
     * @param {?} key
     * @return {?}
     */


    function noProviderError(injector, key) {
      return injectionError(injector, key,
      /**
      * @param {?} keys
      * @return {?}
      */
      function (keys) {
        /** @type {?} */
        var first = stringify(keys[0].token);
        return "No provider for ".concat(first, "!").concat(constructResolvingPath(keys));
      });
    }
    /**
     * Thrown when dependencies form a cycle.
     *
     * \@usageNotes
     * ### Example
     *
     * ```typescript
     * var injector = Injector.resolveAndCreate([
     *   {provide: "one", useFactory: (two) => "two", deps: [[new Inject("two")]]},
     *   {provide: "two", useFactory: (one) => "one", deps: [[new Inject("one")]]}
     * ]);
     *
     * expect(() => injector.get("one")).toThrowError();
     * ```
     *
     * Retrieving `A` or `B` throws a `CyclicDependencyError` as the graph above cannot be constructed.
     * @param {?} injector
     * @param {?} key
     * @return {?}
     */


    function cyclicDependencyError(injector, key) {
      return injectionError(injector, key,
      /**
      * @param {?} keys
      * @return {?}
      */
      function (keys) {
        return "Cannot instantiate cyclic dependency!".concat(constructResolvingPath(keys));
      });
    }
    /**
     * Thrown when a constructing type returns with an Error.
     *
     * The `InstantiationError` class contains the original error plus the dependency graph which caused
     * this object to be instantiated.
     *
     * \@usageNotes
     * ### Example
     *
     * ```typescript
     * class A {
     *   constructor() {
     *     throw new Error('message');
     *   }
     * }
     *
     * var injector = Injector.resolveAndCreate([A]);
     * try {
     *   injector.get(A);
     * } catch (e) {
     *   expect(e instanceof InstantiationError).toBe(true);
     *   expect(e.originalException.message).toEqual("message");
     *   expect(e.originalStack).toBeDefined();
     * }
     * ```
     * @param {?} injector
     * @param {?} originalException
     * @param {?} originalStack
     * @param {?} key
     * @return {?}
     */


    function instantiationError(injector, originalException, originalStack, key) {
      return injectionError(injector, key,
      /**
      * @param {?} keys
      * @return {?}
      */
      function (keys) {
        /** @type {?} */
        var first = stringify(keys[0].token);
        return "".concat(originalException.message, ": Error during instantiation of ").concat(first, "!").concat(constructResolvingPath(keys), ".");
      }, originalException);
    }
    /**
     * Thrown when an object other then {\@link Provider} (or `Type`) is passed to {\@link Injector}
     * creation.
     *
     * \@usageNotes
     * ### Example
     *
     * ```typescript
     * expect(() => Injector.resolveAndCreate(["not a type"])).toThrowError();
     * ```
     * @param {?} provider
     * @return {?}
     */


    function invalidProviderError(provider) {
      return Error("Invalid provider - only instances of Provider and Type are allowed, got: ".concat(provider));
    }
    /**
     * Thrown when the class has no annotation information.
     *
     * Lack of annotation information prevents the {\@link Injector} from determining which dependencies
     * need to be injected into the constructor.
     *
     * \@usageNotes
     * ### Example
     *
     * ```typescript
     * class A {
     *   constructor(b) {}
     * }
     *
     * expect(() => Injector.resolveAndCreate([A])).toThrowError();
     * ```
     *
     * This error is also thrown when the class not marked with {\@link Injectable} has parameter types.
     *
     * ```typescript
     * class B {}
     *
     * class A {
     *   constructor(b:B) {} // no information about the parameter types of A is available at runtime.
     * }
     *
     * expect(() => Injector.resolveAndCreate([A,B])).toThrowError();
     * ```
     *
     * @param {?} typeOrFunc
     * @param {?} params
     * @return {?}
     */


    function noAnnotationError(typeOrFunc, params) {
      /** @type {?} */
      var signature = [];

      for (var i = 0, ii = params.length; i < ii; i++) {
        /** @type {?} */
        var parameter = params[i];

        if (!parameter || parameter.length == 0) {
          signature.push('?');
        } else {
          signature.push(parameter.map(stringify).join(' '));
        }
      }

      return Error('Cannot resolve all parameters for \'' + stringify(typeOrFunc) + '\'(' + signature.join(', ') + '). ' + 'Make sure that all the parameters are decorated with Inject or have valid type annotations and that \'' + stringify(typeOrFunc) + '\' is decorated with Injectable.');
    }
    /**
     * Thrown when getting an object by index.
     *
     * \@usageNotes
     * ### Example
     *
     * ```typescript
     * class A {}
     *
     * var injector = Injector.resolveAndCreate([A]);
     *
     * expect(() => injector.getAt(100)).toThrowError();
     * ```
     *
     * @param {?} index
     * @return {?}
     */


    function outOfBoundsError(index) {
      return Error("Index ".concat(index, " is out-of-bounds."));
    } // TODO: add a working example after alpha38 is released

    /**
     * Thrown when a multi provider and a regular provider are bound to the same token.
     *
     * \@usageNotes
     * ### Example
     *
     * ```typescript
     * expect(() => Injector.resolveAndCreate([
     *   { provide: "Strings", useValue: "string1", multi: true},
     *   { provide: "Strings", useValue: "string2", multi: false}
     * ])).toThrowError();
     * ```
     * @param {?} provider1
     * @param {?} provider2
     * @return {?}
     */


    function mixingMultiProvidersWithRegularProvidersError(provider1, provider2) {
      return Error("Cannot mix multi providers and regular providers, got: ".concat(provider1, " ").concat(provider2));
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/di/reflective_key.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * A unique object used for retrieving items from the {\@link ReflectiveInjector}.
     *
     * Keys have:
     * - a system-wide unique `id`.
     * - a `token`.
     *
     * `Key` is used internally by {\@link ReflectiveInjector} because its system-wide unique `id` allows
     * the
     * injector to store created objects in a more efficient way.
     *
     * `Key` should not be created directly. {\@link ReflectiveInjector} creates keys automatically when
     * resolving
     * providers.
     *
     * @deprecated No replacement
     * \@publicApi
     */


    var ReflectiveKey = /*#__PURE__*/function () {
      /**
       * Private
       * @param {?} token
       * @param {?} id
       */
      function ReflectiveKey(token, id) {
        _classCallCheck(this, ReflectiveKey);

        this.token = token;
        this.id = id;

        if (!token) {
          throw new Error('Token must be defined!');
        }

        this.displayName = stringify(this.token);
      }
      /**
       * Retrieves a `Key` for a token.
       * @param {?} token
       * @return {?}
       */


      _createClass2(ReflectiveKey, null, [{
        key: "get",
        value: function get(token) {
          return _globalKeyRegistry.get(resolveForwardRef(token));
        }
        /**
         * @return {?} the number of keys registered in the system.
         */

      }, {
        key: "numberOfKeys",
        get: function get() {
          return _globalKeyRegistry.numberOfKeys;
        }
      }]);

      return ReflectiveKey;
    }();

    if (false) {}

    var KeyRegistry = /*#__PURE__*/function () {
      function KeyRegistry() {
        _classCallCheck(this, KeyRegistry);

        this._allKeys = new Map();
      }
      /**
       * @param {?} token
       * @return {?}
       */


      _createClass2(KeyRegistry, [{
        key: "get",
        value: function get(token) {
          if (token instanceof ReflectiveKey) return token;

          if (this._allKeys.has(token)) {
            return (
              /** @type {?} */
              this._allKeys.get(token)
            );
          }
          /** @type {?} */


          var newKey = new ReflectiveKey(token, ReflectiveKey.numberOfKeys);

          this._allKeys.set(token, newKey);

          return newKey;
        }
        /**
         * @return {?}
         */

      }, {
        key: "numberOfKeys",
        get: function get() {
          return this._allKeys.size;
        }
      }]);

      return KeyRegistry;
    }();

    if (false) {}
    /** @type {?} */


    var _globalKeyRegistry = new KeyRegistry();
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Provides access to reflection data about symbols. Used internally by Angular
     * to power dependency injection and compilation.
     */


    var Reflector = /*#__PURE__*/function () {
      function Reflector(reflectionCapabilities) {
        _classCallCheck(this, Reflector);

        this.reflectionCapabilities = reflectionCapabilities;
      }

      _createClass2(Reflector, [{
        key: "updateCapabilities",
        value: function updateCapabilities(caps) {
          this.reflectionCapabilities = caps;
        }
      }, {
        key: "factory",
        value: function factory(type) {
          return this.reflectionCapabilities.factory(type);
        }
      }, {
        key: "parameters",
        value: function parameters(typeOrFunc) {
          return this.reflectionCapabilities.parameters(typeOrFunc);
        }
      }, {
        key: "annotations",
        value: function annotations(typeOrFunc) {
          return this.reflectionCapabilities.annotations(typeOrFunc);
        }
      }, {
        key: "propMetadata",
        value: function propMetadata(typeOrFunc) {
          return this.reflectionCapabilities.propMetadata(typeOrFunc);
        }
      }, {
        key: "hasLifecycleHook",
        value: function hasLifecycleHook(type, lcProperty) {
          return this.reflectionCapabilities.hasLifecycleHook(type, lcProperty);
        }
      }, {
        key: "getter",
        value: function getter(name) {
          return this.reflectionCapabilities.getter(name);
        }
      }, {
        key: "setter",
        value: function setter(name) {
          return this.reflectionCapabilities.setter(name);
        }
      }, {
        key: "method",
        value: function method(name) {
          return this.reflectionCapabilities.method(name);
        }
      }, {
        key: "importUri",
        value: function importUri(type) {
          return this.reflectionCapabilities.importUri(type);
        }
      }, {
        key: "resourceUri",
        value: function resourceUri(type) {
          return this.reflectionCapabilities.resourceUri(type);
        }
      }, {
        key: "resolveIdentifier",
        value: function resolveIdentifier(name, moduleUrl, members, runtime) {
          return this.reflectionCapabilities.resolveIdentifier(name, moduleUrl, members, runtime);
        }
      }, {
        key: "resolveEnum",
        value: function resolveEnum(identifier, name) {
          return this.reflectionCapabilities.resolveEnum(identifier, name);
        }
      }]);

      return Reflector;
    }();
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * The {@link Reflector} used internally in Angular to access metadata
     * about symbols.
     */


    var reflector = new Reflector(new ReflectionCapabilities());
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/di/reflective_provider.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @record
     */

    function NormalizedProvider() {}
    /**
     * `Dependency` is used by the framework to extend DI.
     * This is internal to Angular and should not be used directly.
     */


    var ReflectiveDependency = /*#__PURE__*/function () {
      /**
       * @param {?} key
       * @param {?} optional
       * @param {?} visibility
       */
      function ReflectiveDependency(key, optional, visibility) {
        _classCallCheck(this, ReflectiveDependency);

        this.key = key;
        this.optional = optional;
        this.visibility = visibility;
      }
      /**
       * @param {?} key
       * @return {?}
       */


      _createClass2(ReflectiveDependency, null, [{
        key: "fromKey",
        value: function fromKey(key) {
          return new ReflectiveDependency(key, false, null);
        }
      }]);

      return ReflectiveDependency;
    }();

    if (false) {}
    /** @type {?} */


    var _EMPTY_LIST = [];
    /**
     * An internal resolved representation of a `Provider` used by the `Injector`.
     *
     * \@usageNotes
     * This is usually created automatically by `Injector.resolveAndCreate`.
     *
     * It can be created manually, as follows:
     *
     * ### Example
     *
     * ```typescript
     * var resolvedProviders = Injector.resolve([{ provide: 'message', useValue: 'Hello' }]);
     * var injector = Injector.fromResolvedProviders(resolvedProviders);
     *
     * expect(injector.get('message')).toEqual('Hello');
     * ```
     *
     * \@publicApi
     * @record
     */

    function ResolvedReflectiveProvider() {}

    if (false) {}

    var ResolvedReflectiveProvider_ =
    /**
     * @param {?} key
     * @param {?} resolvedFactories
     * @param {?} multiProvider
     */
    function ResolvedReflectiveProvider_(key, resolvedFactories, multiProvider) {
      _classCallCheck(this, ResolvedReflectiveProvider_);

      this.key = key;
      this.resolvedFactories = resolvedFactories;
      this.multiProvider = multiProvider;
      this.resolvedFactory = this.resolvedFactories[0];
    };

    if (false) {}
    /**
     * An internal resolved representation of a factory function created by resolving `Provider`.
     * \@publicApi
     */


    var ResolvedReflectiveFactory =
    /**
     * @param {?} factory
     * @param {?} dependencies
     */
    function ResolvedReflectiveFactory(factory, dependencies) {
      _classCallCheck(this, ResolvedReflectiveFactory);

      this.factory = factory;
      this.dependencies = dependencies;
    };

    if (false) {}
    /**
     * Resolve a single provider.
     * @param {?} provider
     * @return {?}
     */


    function resolveReflectiveFactory(provider) {
      /** @type {?} */
      var factoryFn;
      /** @type {?} */

      var resolvedDeps;

      if (provider.useClass) {
        /** @type {?} */
        var useClass = resolveForwardRef(provider.useClass);
        factoryFn = reflector.factory(useClass);
        resolvedDeps = _dependenciesFor(useClass);
      } else if (provider.useExisting) {
        factoryFn =
        /**
        * @param {?} aliasInstance
        * @return {?}
        */
        function factoryFn(aliasInstance) {
          return aliasInstance;
        };

        resolvedDeps = [ReflectiveDependency.fromKey(ReflectiveKey.get(provider.useExisting))];
      } else if (provider.useFactory) {
        factoryFn = provider.useFactory;
        resolvedDeps = constructDependencies(provider.useFactory, provider.deps);
      } else {
        factoryFn =
        /**
        * @return {?}
        */
        function factoryFn() {
          return provider.useValue;
        };

        resolvedDeps = _EMPTY_LIST;
      }

      return new ResolvedReflectiveFactory(factoryFn, resolvedDeps);
    }
    /**
     * Converts the `Provider` into `ResolvedProvider`.
     *
     * `Injector` internally only uses `ResolvedProvider`, `Provider` contains convenience provider
     * syntax.
     * @param {?} provider
     * @return {?}
     */


    function resolveReflectiveProvider(provider) {
      return new ResolvedReflectiveProvider_(ReflectiveKey.get(provider.provide), [resolveReflectiveFactory(provider)], provider.multi || false);
    }
    /**
     * Resolve a list of Providers.
     * @param {?} providers
     * @return {?}
     */


    function resolveReflectiveProviders(providers) {
      /** @type {?} */
      var normalized = _normalizeProviders(providers, []);
      /** @type {?} */


      var resolved = normalized.map(resolveReflectiveProvider);
      /** @type {?} */

      var resolvedProviderMap = mergeResolvedReflectiveProviders(resolved, new Map());
      return Array.from(resolvedProviderMap.values());
    }
    /**
     * Merges a list of ResolvedProviders into a list where each key is contained exactly once and
     * multi providers have been merged.
     * @param {?} providers
     * @param {?} normalizedProvidersMap
     * @return {?}
     */


    function mergeResolvedReflectiveProviders(providers, normalizedProvidersMap) {
      for (var i = 0; i < providers.length; i++) {
        /** @type {?} */
        var provider = providers[i];
        /** @type {?} */

        var existing = normalizedProvidersMap.get(provider.key.id);

        if (existing) {
          if (provider.multiProvider !== existing.multiProvider) {
            throw mixingMultiProvidersWithRegularProvidersError(existing, provider);
          }

          if (provider.multiProvider) {
            for (var j = 0; j < provider.resolvedFactories.length; j++) {
              existing.resolvedFactories.push(provider.resolvedFactories[j]);
            }
          } else {
            normalizedProvidersMap.set(provider.key.id, provider);
          }
        } else {
          /** @type {?} */
          var resolvedProvider = void 0;

          if (provider.multiProvider) {
            resolvedProvider = new ResolvedReflectiveProvider_(provider.key, provider.resolvedFactories.slice(), provider.multiProvider);
          } else {
            resolvedProvider = provider;
          }

          normalizedProvidersMap.set(provider.key.id, resolvedProvider);
        }
      }

      return normalizedProvidersMap;
    }
    /**
     * @param {?} providers
     * @param {?} res
     * @return {?}
     */


    function _normalizeProviders(providers, res) {
      providers.forEach(
      /**
      * @param {?} b
      * @return {?}
      */
      function (b) {
        if (b instanceof Type) {
          res.push(
          /** @type {?} */
          {
            provide: b,
            useClass: b
          });
        } else if (b && typeof b == 'object' &&
        /** @type {?} */
        b.provide !== undefined) {
          res.push(
          /** @type {?} */
          b);
        } else if (Array.isArray(b)) {
          _normalizeProviders(b, res);
        } else {
          throw invalidProviderError(b);
        }
      });
      return res;
    }
    /**
     * @param {?} typeOrFunc
     * @param {?=} dependencies
     * @return {?}
     */


    function constructDependencies(typeOrFunc, dependencies) {
      if (!dependencies) {
        return _dependenciesFor(typeOrFunc);
      } else {
        /** @type {?} */
        var params = dependencies.map(
        /**
        * @param {?} t
        * @return {?}
        */
        function (t) {
          return [t];
        });
        return dependencies.map(
        /**
        * @param {?} t
        * @return {?}
        */
        function (t) {
          return _extractToken(typeOrFunc, t, params);
        });
      }
    }
    /**
     * @param {?} typeOrFunc
     * @return {?}
     */


    function _dependenciesFor(typeOrFunc) {
      /** @type {?} */
      var params = reflector.parameters(typeOrFunc);
      if (!params) return [];

      if (params.some(
      /**
      * @param {?} p
      * @return {?}
      */
      function (p) {
        return p == null;
      })) {
        throw noAnnotationError(typeOrFunc, params);
      }

      return params.map(
      /**
      * @param {?} p
      * @return {?}
      */
      function (p) {
        return _extractToken(typeOrFunc, p, params);
      });
    }
    /**
     * @param {?} typeOrFunc
     * @param {?} metadata
     * @param {?} params
     * @return {?}
     */


    function _extractToken(typeOrFunc, metadata, params) {
      /** @type {?} */
      var token = null;
      /** @type {?} */

      var optional = false;

      if (!Array.isArray(metadata)) {
        if (metadata instanceof Inject) {
          return _createDependency(metadata.token, optional, null);
        } else {
          return _createDependency(metadata, optional, null);
        }
      }
      /** @type {?} */


      var visibility = null;

      for (var i = 0; i < metadata.length; ++i) {
        /** @type {?} */
        var paramMetadata = metadata[i];

        if (paramMetadata instanceof Type) {
          token = paramMetadata;
        } else if (paramMetadata instanceof Inject) {
          token = paramMetadata.token;
        } else if (paramMetadata instanceof Optional) {
          optional = true;
        } else if (paramMetadata instanceof Self || paramMetadata instanceof SkipSelf) {
          visibility = paramMetadata;
        } else if (paramMetadata instanceof InjectionToken) {
          token = paramMetadata;
        }
      }

      token = resolveForwardRef(token);

      if (token != null) {
        return _createDependency(token, optional, visibility);
      } else {
        throw noAnnotationError(typeOrFunc, params);
      }
    }
    /**
     * @param {?} token
     * @param {?} optional
     * @param {?} visibility
     * @return {?}
     */


    function _createDependency(token, optional, visibility) {
      return new ReflectiveDependency(ReflectiveKey.get(token), optional, visibility);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/di/reflective_injector.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */
    // Threshold for the dynamic version

    /** @type {?} */


    var UNDEFINED = {};
    /**
     * A ReflectiveDependency injection container used for instantiating objects and resolving
     * dependencies.
     *
     * An `Injector` is a replacement for a `new` operator, which can automatically resolve the
     * constructor dependencies.
     *
     * In typical use, application code asks for the dependencies in the constructor and they are
     * resolved by the `Injector`.
     *
     * \@usageNotes
     * ### Example
     *
     * The following example creates an `Injector` configured to create `Engine` and `Car`.
     *
     * ```typescript
     * \@Injectable()
     * class Engine {
     * }
     *
     * \@Injectable()
     * class Car {
     *   constructor(public engine:Engine) {}
     * }
     *
     * var injector = ReflectiveInjector.resolveAndCreate([Car, Engine]);
     * var car = injector.get(Car);
     * expect(car instanceof Car).toBe(true);
     * expect(car.engine instanceof Engine).toBe(true);
     * ```
     *
     * Notice, we don't use the `new` operator because we explicitly want to have the `Injector`
     * resolve all of the object's dependencies automatically.
     *
     * @deprecated from v5 - slow and brings in a lot of code, Use `Injector.create` instead.
     * \@publicApi
     * @abstract
     */

    var ReflectiveInjector = /*#__PURE__*/function () {
      function ReflectiveInjector() {
        _classCallCheck(this, ReflectiveInjector);
      }

      _createClass2(ReflectiveInjector, null, [{
        key: "resolve",

        /**
         * Turns an array of provider definitions into an array of resolved providers.
         *
         * A resolution is a process of flattening multiple nested arrays and converting individual
         * providers into an array of `ResolvedReflectiveProvider`s.
         *
         * \@usageNotes
         * ### Example
         *
         * ```typescript
         * \@Injectable()
         * class Engine {
         * }
         *  /
         * class Car {
         *   constructor(public engine:Engine) {}
         * }
         *
         * var providers = ReflectiveInjector.resolve([Car, [[Engine]]]);
         *
         * expect(providers.length).toEqual(2);
         *
         * expect(providers[0] instanceof ResolvedReflectiveProvider).toBe(true);
         * expect(providers[0].key.displayName).toBe("Car");
         * expect(providers[0].dependencies.length).toEqual(1);
         * expect(providers[0].factory).toBeDefined();
         *
         * expect(providers[1].key.displayName).toBe("Engine");
         * });
         * ```
         *
         * @param {?} providers
         * @return {?}
         */
        value: function resolve(providers) {
          return resolveReflectiveProviders(providers);
        }
        /**
         * Resolves an array of providers and creates an injector from those providers.
         *
         * The passed-in providers can be an array of `Type`, `Provider`,
         * or a recursive array of more providers.
         *
         * \@usageNotes
         * ### Example
         *
         * ```typescript
         * \@Injectable()
         * class Engine {
         * }
         *  /
         * class Car {
         *   constructor(public engine:Engine) {}
         * }
         *
         * var injector = ReflectiveInjector.resolveAndCreate([Car, Engine]);
         * expect(injector.get(Car) instanceof Car).toBe(true);
         * ```
         * @param {?} providers
         * @param {?=} parent
         * @return {?}
         */

      }, {
        key: "resolveAndCreate",
        value: function resolveAndCreate(providers, parent) {
          /** @type {?} */
          var ResolvedReflectiveProviders = ReflectiveInjector.resolve(providers);
          return ReflectiveInjector.fromResolvedProviders(ResolvedReflectiveProviders, parent);
        }
        /**
         * Creates an injector from previously resolved providers.
         *
         * This API is the recommended way to construct injectors in performance-sensitive parts.
         *
         * \@usageNotes
         * ### Example
         *
         * ```typescript
         * \@Injectable()
         * class Engine {
         * }
         *  /
         * class Car {
         *   constructor(public engine:Engine) {}
         * }
         *
         * var providers = ReflectiveInjector.resolve([Car, Engine]);
         * var injector = ReflectiveInjector.fromResolvedProviders(providers);
         * expect(injector.get(Car) instanceof Car).toBe(true);
         * ```
         * @param {?} providers
         * @param {?=} parent
         * @return {?}
         */

      }, {
        key: "fromResolvedProviders",
        value: function fromResolvedProviders(providers, parent) {
          return new ReflectiveInjector_(providers, parent);
        }
      }]);

      return ReflectiveInjector;
    }();

    if (false) {}

    var ReflectiveInjector_ = /*#__PURE__*/function () {
      /**
       * Private
       * @param {?} _providers
       * @param {?=} _parent
       */
      function ReflectiveInjector_(_providers, _parent) {
        _classCallCheck(this, ReflectiveInjector_);

        /**
         * \@internal
         */
        this._constructionCounter = 0;
        this._providers = _providers;
        this.parent = _parent || null;
        /** @type {?} */

        var len = _providers.length;
        this.keyIds = [];
        this.objs = [];

        for (var i = 0; i < len; i++) {
          this.keyIds[i] = _providers[i].key.id;
          this.objs[i] = UNDEFINED;
        }
      }
      /**
       * @param {?} token
       * @param {?=} notFoundValue
       * @return {?}
       */


      _createClass2(ReflectiveInjector_, [{
        key: "get",
        value: function get(token) {
          var notFoundValue = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : THROW_IF_NOT_FOUND;
          return this._getByKey(ReflectiveKey.get(token), null, notFoundValue);
        }
        /**
         * @param {?} providers
         * @return {?}
         */

      }, {
        key: "resolveAndCreateChild",
        value: function resolveAndCreateChild(providers) {
          /** @type {?} */
          var ResolvedReflectiveProviders = ReflectiveInjector.resolve(providers);
          return this.createChildFromResolved(ResolvedReflectiveProviders);
        }
        /**
         * @param {?} providers
         * @return {?}
         */

      }, {
        key: "createChildFromResolved",
        value: function createChildFromResolved(providers) {
          /** @type {?} */
          var inj = new ReflectiveInjector_(providers);

          /** @type {?} */
          inj.parent = this;
          return inj;
        }
        /**
         * @param {?} provider
         * @return {?}
         */

      }, {
        key: "resolveAndInstantiate",
        value: function resolveAndInstantiate(provider) {
          return this.instantiateResolved(ReflectiveInjector.resolve([provider])[0]);
        }
        /**
         * @param {?} provider
         * @return {?}
         */

      }, {
        key: "instantiateResolved",
        value: function instantiateResolved(provider) {
          return this._instantiateProvider(provider);
        }
        /**
         * @param {?} index
         * @return {?}
         */

      }, {
        key: "getProviderAtIndex",
        value: function getProviderAtIndex(index) {
          if (index < 0 || index >= this._providers.length) {
            throw outOfBoundsError(index);
          }

          return this._providers[index];
        }
        /**
         * \@internal
         * @param {?} provider
         * @return {?}
         */

      }, {
        key: "_new",
        value: function _new(provider) {
          if (this._constructionCounter++ > this._getMaxNumberOfObjects()) {
            throw cyclicDependencyError(this, provider.key);
          }

          return this._instantiateProvider(provider);
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_getMaxNumberOfObjects",
        value: function _getMaxNumberOfObjects() {
          return this.objs.length;
        }
        /**
         * @private
         * @param {?} provider
         * @return {?}
         */

      }, {
        key: "_instantiateProvider",
        value: function _instantiateProvider(provider) {
          if (provider.multiProvider) {
            /** @type {?} */
            var res = [];

            for (var i = 0; i < provider.resolvedFactories.length; ++i) {
              res[i] = this._instantiate(provider, provider.resolvedFactories[i]);
            }

            return res;
          } else {
            return this._instantiate(provider, provider.resolvedFactories[0]);
          }
        }
        /**
         * @private
         * @param {?} provider
         * @param {?} ResolvedReflectiveFactory
         * @return {?}
         */

      }, {
        key: "_instantiate",
        value: function _instantiate(provider, ResolvedReflectiveFactory) {
          var _this156 = this;

          /** @type {?} */
          var factory = ResolvedReflectiveFactory.factory;
          /** @type {?} */

          var deps;

          try {
            deps = ResolvedReflectiveFactory.dependencies.map(
            /**
            * @param {?} dep
            * @return {?}
            */
            function (dep) {
              return _this156._getByReflectiveDependency(dep);
            });
          } catch (e) {
            if (e.addKey) {
              e.addKey(this, provider.key);
            }

            throw e;
          }
          /** @type {?} */


          var obj;

          try {
            obj = factory.apply(void 0, _toConsumableArray(deps));
          } catch (e) {
            throw instantiationError(this, e, e.stack, provider.key);
          }

          return obj;
        }
        /**
         * @private
         * @param {?} dep
         * @return {?}
         */

      }, {
        key: "_getByReflectiveDependency",
        value: function _getByReflectiveDependency(dep) {
          return this._getByKey(dep.key, dep.visibility, dep.optional ? null : THROW_IF_NOT_FOUND);
        }
        /**
         * @private
         * @param {?} key
         * @param {?} visibility
         * @param {?} notFoundValue
         * @return {?}
         */

      }, {
        key: "_getByKey",
        value: function _getByKey(key, visibility, notFoundValue) {
          if (key === ReflectiveInjector_.INJECTOR_KEY) {
            return this;
          }

          if (visibility instanceof Self) {
            return this._getByKeySelf(key, notFoundValue);
          } else {
            return this._getByKeyDefault(key, notFoundValue, visibility);
          }
        }
        /**
         * @private
         * @param {?} keyId
         * @return {?}
         */

      }, {
        key: "_getObjByKeyId",
        value: function _getObjByKeyId(keyId) {
          for (var i = 0; i < this.keyIds.length; i++) {
            if (this.keyIds[i] === keyId) {
              if (this.objs[i] === UNDEFINED) {
                this.objs[i] = this._new(this._providers[i]);
              }

              return this.objs[i];
            }
          }

          return UNDEFINED;
        }
        /**
         * \@internal
         * @param {?} key
         * @param {?} notFoundValue
         * @return {?}
         */

      }, {
        key: "_throwOrNull",
        value: function _throwOrNull(key, notFoundValue) {
          if (notFoundValue !== THROW_IF_NOT_FOUND) {
            return notFoundValue;
          } else {
            throw noProviderError(this, key);
          }
        }
        /**
         * \@internal
         * @param {?} key
         * @param {?} notFoundValue
         * @return {?}
         */

      }, {
        key: "_getByKeySelf",
        value: function _getByKeySelf(key, notFoundValue) {
          /** @type {?} */
          var obj = this._getObjByKeyId(key.id);

          return obj !== UNDEFINED ? obj : this._throwOrNull(key, notFoundValue);
        }
        /**
         * \@internal
         * @param {?} key
         * @param {?} notFoundValue
         * @param {?} visibility
         * @return {?}
         */

      }, {
        key: "_getByKeyDefault",
        value: function _getByKeyDefault(key, notFoundValue, visibility) {
          /** @type {?} */
          var inj;

          if (visibility instanceof SkipSelf) {
            inj = this.parent;
          } else {
            inj = this;
          }

          while (inj instanceof ReflectiveInjector_) {
            /** @type {?} */
            var inj_ =
            /** @type {?} */
            inj;
            /** @type {?} */

            var obj = inj_._getObjByKeyId(key.id);

            if (obj !== UNDEFINED) return obj;
            inj = inj_.parent;
          }

          if (inj !== null) {
            return inj.get(key.token, notFoundValue);
          } else {
            return this._throwOrNull(key, notFoundValue);
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "toString",

        /**
         * @return {?}
         */
        value: function toString() {
          return this.displayName;
        }
      }, {
        key: "displayName",
        get: function get() {
          /** @type {?} */
          var providers = _mapProviders(this,
          /**
          * @param {?} b
          * @return {?}
          */
          function (b) {
            return ' "' + b.key.displayName + '" ';
          }).join(', ');

          return "ReflectiveInjector(providers: [".concat(providers, "])");
        }
      }]);

      return ReflectiveInjector_;
    }();

    ReflectiveInjector_.INJECTOR_KEY = ReflectiveKey.get(Injector);

    if (false) {}
    /**
     * @param {?} injector
     * @param {?} fn
     * @return {?}
     */


    function _mapProviders(injector, fn) {
      /** @type {?} */
      var res = [];

      for (var i = 0; i < injector._providers.length; ++i) {
        res[i] = fn(injector.getProviderAtIndex(i));
      }

      return res;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/di/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/di.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/metadata/di.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * A DI token that you can use to create a virtual [provider](guide/glossary#provider)
     * that will populate the `entryComponents` field of components and NgModules
     * based on its `useValue` property value.
     * All components that are referenced in the `useValue` value (either directly
     * or in a nested array or map) are added to the `entryComponents` property.
     *
     * \@usageNotes
     *
     * The following example shows how the router can populate the `entryComponents`
     * field of an NgModule based on a router configuration that refers
     * to components.
     *
     * ```typescript
     * // helper function inside the router
     * function provideRoutes(routes) {
     *   return [
     *     {provide: ROUTES, useValue: routes},
     *     {provide: ANALYZE_FOR_ENTRY_COMPONENTS, useValue: routes, multi: true}
     *   ];
     * }
     *
     * // user code
     * let routes = [
     *   {path: '/root', component: RootComp},
     *   {path: '/teams', component: TeamsComp}
     * ];
     *
     * \@NgModule({
     *   providers: [provideRoutes(routes)]
     * })
     * class ModuleWithRoutes {}
     * ```
     *
     * \@publicApi
     * @deprecated Since 9.0.0. With Ivy, this property is no longer necessary.
     * @type {?}
     */


    var ANALYZE_FOR_ENTRY_COMPONENTS = new InjectionToken('AnalyzeForEntryComponents');
    /**
     * Type of the `Attribute` decorator / constructor function.
     *
     * \@publicApi
     * @record
     */

    function AttributeDecorator$1() {}
    /**
     * Type of the Attribute metadata.
     *
     * \@publicApi
     * @record
     */


    function Attribute$1() {}

    if (false) {} // WARNING: interface has both a type and a value, skipping emit

    /**
     * Base class for query metadata.
     *
     * @see `ContentChildren`.
     * @see `ContentChild`.
     * @see `ViewChildren`.
     * @see `ViewChild`.
     *
     * \@publicApi
     * @abstract
     */


    var Query = function Query() {
      _classCallCheck(this, Query);
    };
    /**
     * Type of the ContentChildren decorator / constructor function.
     *
     * @see `ContentChildren`.
     * \@publicApi
     * @record
     */


    function ContentChildrenDecorator() {}

    var ɵ0$a =
    /**
    * @param {?=} selector
    * @param {?=} data
    * @return {?}
    */
    function ɵ0$a(selector) {
      var data = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
      return Object.assign({
        selector: selector,
        first: false,
        isViewQuery: false,
        descendants: false
      }, data);
    };
    /**
     * ContentChildren decorator and metadata.
     *
     *
     * \@Annotation
     * \@publicApi
     * @type {?}
     */


    var ContentChildren = makePropDecorator('ContentChildren', ɵ0$a, Query);
    /**
     * Type of the ContentChild decorator / constructor function.
     *
     * \@publicApi
     * @record
     */

    function ContentChildDecorator() {}

    var ɵ1$2 =
    /**
    * @param {?=} selector
    * @param {?=} data
    * @return {?}
    */
    function ɵ1$2(selector) {
      var data = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
      return Object.assign({
        selector: selector,
        first: true,
        isViewQuery: false,
        descendants: true
      }, data);
    };
    /**
     * ContentChild decorator and metadata.
     *
     *
     * \@Annotation
     *
     * \@publicApi
     * @type {?}
     */


    var ContentChild = makePropDecorator('ContentChild', ɵ1$2, Query);
    /**
     * Type of the ViewChildren decorator / constructor function.
     *
     * @see `ViewChildren`.
     *
     * \@publicApi
     * @record
     */

    function ViewChildrenDecorator() {}

    var ɵ2 =
    /**
    * @param {?=} selector
    * @param {?=} data
    * @return {?}
    */
    function ɵ2(selector) {
      var data = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
      return Object.assign({
        selector: selector,
        first: false,
        isViewQuery: true,
        descendants: true
      }, data);
    };
    /**
     * ViewChildren decorator and metadata.
     *
     * \@Annotation
     * \@publicApi
     * @type {?}
     */


    var ViewChildren = makePropDecorator('ViewChildren', ɵ2, Query);
    /**
     * Type of the ViewChild decorator / constructor function.
     *
     * @see `ViewChild`.
     * \@publicApi
     * @record
     */

    function ViewChildDecorator() {}

    var ɵ3 =
    /**
    * @param {?} selector
    * @param {?} data
    * @return {?}
    */
    function ɵ3(selector, data) {
      return Object.assign({
        selector: selector,
        first: true,
        isViewQuery: true,
        descendants: true
      }, data);
    };
    /**
     * ViewChild decorator and metadata.
     *
     * \@Annotation
     * \@publicApi
     * @type {?}
     */


    var ViewChild = makePropDecorator('ViewChild', ɵ3, Query);
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/metadata/resource_loading.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Used to resolve resource URLs on `\@Component` when used with JIT compilation.
     *
     * Example:
     * ```
     * \@Component({
     *   selector: 'my-comp',
     *   templateUrl: 'my-comp.html', // This requires asynchronous resolution
     * })
     * class MyComponent{
     * }
     *
     * // Calling `renderComponent` will fail because `renderComponent` is a synchronous process
     * // and `MyComponent`'s `\@Component.templateUrl` needs to be resolved asynchronously.
     *
     * // Calling `resolveComponentResources()` will resolve `\@Component.templateUrl` into
     * // `\@Component.template`, which allows `renderComponent` to proceed in a synchronous manner.
     *
     * // Use browser's `fetch()` function as the default resource resolution strategy.
     * resolveComponentResources(fetch).then(() => {
     *   // After resolution all URLs have been converted into `template` strings.
     *   renderComponent(MyComponent);
     * });
     *
     * ```
     *
     * NOTE: In AOT the resolution happens during compilation, and so there should be no need
     * to call this method outside JIT mode.
     *
     * @param {?} resourceResolver a function which is responsible for returning a `Promise` to the
     * contents of the resolved URL. Browser's `fetch()` method is a good default implementation.
     * @return {?}
     */

    function resolveComponentResources(resourceResolver) {
      // Store all promises which are fetching the resources.

      /** @type {?} */
      var componentResolved = []; // Cache so that we don't fetch the same resource more than once.

      /** @type {?} */

      var urlMap = new Map();
      /**
       * @param {?} url
       * @return {?}
       */

      function cachedResourceResolve(url) {
        /** @type {?} */
        var promise = urlMap.get(url);

        if (!promise) {
          /** @type {?} */
          var resp = resourceResolver(url);
          urlMap.set(url, promise = resp.then(unwrapResponse));
        }

        return promise;
      }

      componentResourceResolutionQueue.forEach(
      /**
      * @param {?} component
      * @param {?} type
      * @return {?}
      */
      function (component, type) {
        /** @type {?} */
        var promises = [];

        if (component.templateUrl) {
          promises.push(cachedResourceResolve(component.templateUrl).then(
          /**
          * @param {?} template
          * @return {?}
          */
          function (template) {
            component.template = template;
          }));
        }
        /** @type {?} */


        var styleUrls = component.styleUrls;
        /** @type {?} */

        var styles = component.styles || (component.styles = []);
        /** @type {?} */

        var styleOffset = component.styles.length;
        styleUrls && styleUrls.forEach(
        /**
        * @param {?} styleUrl
        * @param {?} index
        * @return {?}
        */
        function (styleUrl, index) {
          styles.push(''); // pre-allocate array.

          promises.push(cachedResourceResolve(styleUrl).then(
          /**
          * @param {?} style
          * @return {?}
          */
          function (style) {
            styles[styleOffset + index] = style;
            styleUrls.splice(styleUrls.indexOf(styleUrl), 1);

            if (styleUrls.length == 0) {
              component.styleUrls = undefined;
            }
          }));
        });
        /** @type {?} */

        var fullyResolved = Promise.all(promises).then(
        /**
        * @return {?}
        */
        function () {
          return componentDefResolved(type);
        });
        componentResolved.push(fullyResolved);
      });
      clearResolutionOfComponentResourcesQueue();
      return Promise.all(componentResolved).then(
      /**
      * @return {?}
      */
      function () {
        return undefined;
      });
    }
    /** @type {?} */


    var componentResourceResolutionQueue = new Map(); // Track when existing ɵcmp for a Type is waiting on resources.

    /** @type {?} */

    var componentDefPendingResolution = new Set();
    /**
     * @param {?} type
     * @param {?} metadata
     * @return {?}
     */

    function maybeQueueResolutionOfComponentResources(type, metadata) {
      if (componentNeedsResolution(metadata)) {
        componentResourceResolutionQueue.set(type, metadata);
        componentDefPendingResolution.add(type);
      }
    }
    /**
     * @param {?} type
     * @return {?}
     */


    function isComponentDefPendingResolution(type) {
      return componentDefPendingResolution.has(type);
    }
    /**
     * @param {?} component
     * @return {?}
     */


    function componentNeedsResolution(component) {
      return !!(component.templateUrl && !component.hasOwnProperty('template') || component.styleUrls && component.styleUrls.length);
    }
    /**
     * @return {?}
     */


    function clearResolutionOfComponentResourcesQueue() {
      /** @type {?} */
      var old = componentResourceResolutionQueue;
      componentResourceResolutionQueue = new Map();
      return old;
    }
    /**
     * @param {?} queue
     * @return {?}
     */


    function restoreComponentResolutionQueue(queue) {
      componentDefPendingResolution.clear();
      queue.forEach(
      /**
      * @param {?} _
      * @param {?} type
      * @return {?}
      */
      function (_, type) {
        return componentDefPendingResolution.add(type);
      });
      componentResourceResolutionQueue = queue;
    }
    /**
     * @return {?}
     */


    function isComponentResourceResolutionQueueEmpty() {
      return componentResourceResolutionQueue.size === 0;
    }
    /**
     * @param {?} response
     * @return {?}
     */


    function unwrapResponse(response) {
      return typeof response == 'string' ? response : response.text();
    }
    /**
     * @param {?} type
     * @return {?}
     */


    function componentDefResolved(type) {
      componentDefPendingResolution["delete"](type);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/styling/static_styling.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Compute the static styling (class/style) from `TAttributes`.
     *
     * This function should be called during `firstCreatePass` only.
     *
     * @param {?} tNode The `TNode` into which the styling information should be loaded.
     * @param {?} attrs `TAttributes` containing the styling information.
     * @return {?}
     */


    function computeStaticStyling(tNode, attrs) {
      ngDevMode && assertFirstCreatePass(getTView(), 'Expecting to be called in first template pass only');
      /** @type {?} */

      var styles = tNode.styles;
      /** @type {?} */

      var classes = tNode.classes;
      /** @type {?} */

      var mode = 0;

      for (var i = 0; i < attrs.length; i++) {
        /** @type {?} */
        var value = attrs[i];

        if (typeof value === 'number') {
          mode = value;
        } else if (mode == 1
        /* Classes */
        ) {
            classes = concatStringsWithSpace(classes,
            /** @type {?} */
            value);
          } else if (mode == 2
        /* Styles */
        ) {
            /** @type {?} */
            var style =
            /** @type {?} */
            value;
            /** @type {?} */

            var styleValue =
            /** @type {?} */
            attrs[++i];
            styles = concatStringsWithSpace(styles, style + ': ' + styleValue + ';');
          }
      }

      styles !== null && (tNode.styles = styles);
      classes !== null && (tNode.classes = classes);
    }
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */


    var _symbolIterator = null;

    function getSymbolIterator() {
      if (!_symbolIterator) {
        var _Symbol = _global['Symbol'];

        if (_Symbol && _Symbol.iterator) {
          _symbolIterator = _Symbol.iterator;
        } else {
          // es6-shim specific logic
          var keys = Object.getOwnPropertyNames(Map.prototype);

          for (var i = 0; i < keys.length; ++i) {
            var key = keys[i];

            if (key !== 'entries' && key !== 'size' && Map.prototype[key] === Map.prototype['entries']) {
              _symbolIterator = key;
            }
          }
        }
      }

      return _symbolIterator;
    }
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */


    function isIterable(obj) {
      return obj !== null && typeof obj === 'object' && obj[getSymbolIterator()] !== undefined;
    }

    function isListLikeIterable(obj) {
      if (!isJsObject(obj)) return false;
      return Array.isArray(obj) || !(obj instanceof Map) && // JS Map are iterables but return entries as [k, v]
      getSymbolIterator() in obj; // JS Iterable have a Symbol.iterator prop
    }

    function areIterablesEqual(a, b, comparator) {
      var iterator1 = a[getSymbolIterator()]();
      var iterator2 = b[getSymbolIterator()]();

      while (true) {
        var item1 = iterator1.next();
        var item2 = iterator2.next();
        if (item1.done && item2.done) return true;
        if (item1.done || item2.done) return false;
        if (!comparator(item1.value, item2.value)) return false;
      }
    }

    function iterateListLike(obj, fn) {
      if (Array.isArray(obj)) {
        for (var i = 0; i < obj.length; i++) {
          fn(obj[i]);
        }
      } else {
        var iterator = obj[getSymbolIterator()]();
        var item;

        while (!(item = iterator.next()).done) {
          fn(item.value);
        }
      }
    }

    function isJsObject(o) {
      return o !== null && (typeof o === 'function' || typeof o === 'object');
    }
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */
    // JS has NaN !== NaN


    function looseIdentical(a, b) {
      return a === b || typeof a === 'number' && typeof b === 'number' && isNaN(a) && isNaN(b);
    }

    function devModeEqual(a, b) {
      var isListLikeIterableA = isListLikeIterable(a);
      var isListLikeIterableB = isListLikeIterable(b);

      if (isListLikeIterableA && isListLikeIterableB) {
        return areIterablesEqual(a, b, devModeEqual);
      } else {
        var isAObject = a && (typeof a === 'object' || typeof a === 'function');
        var isBObject = b && (typeof b === 'object' || typeof b === 'function');

        if (!isListLikeIterableA && isAObject && !isListLikeIterableB && isBObject) {
          return true;
        } else {
          return looseIdentical(a, b);
        }
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/change_detection/change_detection_util.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} a
     * @param {?} b
     * @return {?}
     */


    function devModeEqual$1(a, b) {
      /** @type {?} */
      var isListLikeIterableA = isListLikeIterable$1(a);
      /** @type {?} */

      var isListLikeIterableB = isListLikeIterable$1(b);

      if (isListLikeIterableA && isListLikeIterableB) {
        return areIterablesEqual$1(a, b, devModeEqual$1);
      } else {
        /** @type {?} */
        var isAObject = a && (typeof a === 'object' || typeof a === 'function');
        /** @type {?} */

        var isBObject = b && (typeof b === 'object' || typeof b === 'function');

        if (!isListLikeIterableA && isAObject && !isListLikeIterableB && isBObject) {
          return true;
        } else {
          return looseIdentical(a, b);
        }
      }
    }
    /**
     * Indicates that the result of a {\@link Pipe} transformation has changed even though the
     * reference has not changed.
     *
     * Wrapped values are unwrapped automatically during the change detection, and the unwrapped value
     * is stored.
     *
     * Example:
     *
     * ```
     * if (this._latestValue === this._latestReturnedValue) {
     *    return this._latestReturnedValue;
     *  } else {
     *    this._latestReturnedValue = this._latestValue;
     *    return WrappedValue.wrap(this._latestValue); // this will force update
     *  }
     * ```
     *
     * \@publicApi
     */


    var WrappedValue = /*#__PURE__*/function () {
      /**
       * @param {?} value
       */
      function WrappedValue(value) {
        _classCallCheck(this, WrappedValue);

        this.wrapped = value;
      }
      /**
       * Creates a wrapped value.
       * @param {?} value
       * @return {?}
       */


      _createClass2(WrappedValue, null, [{
        key: "wrap",
        value: function wrap(value) {
          return new WrappedValue(value);
        }
        /**
         * Returns the underlying value of a wrapped value.
         * Returns the given `value` when it is not wrapped.
         *
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "unwrap",
        value: function unwrap(value) {
          return WrappedValue.isWrapped(value) ? value.wrapped : value;
        }
        /**
         * Returns true if `value` is a wrapped value.
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "isWrapped",
        value: function isWrapped(value) {
          return value instanceof WrappedValue;
        }
      }]);

      return WrappedValue;
    }();

    if (false) {}
    /**
     * @param {?} obj
     * @return {?}
     */


    function isListLikeIterable$1(obj) {
      if (!isJsObject$1(obj)) return false;
      return Array.isArray(obj) || !(obj instanceof Map) && // JS Map are iterables but return entries as [k, v]
      getSymbolIterator() in obj; // JS Iterable have a Symbol.iterator prop
    }
    /**
     * @param {?} a
     * @param {?} b
     * @param {?} comparator
     * @return {?}
     */


    function areIterablesEqual$1(a, b, comparator) {
      /** @type {?} */
      var iterator1 = a[getSymbolIterator()]();
      /** @type {?} */

      var iterator2 = b[getSymbolIterator()]();

      while (true) {
        /** @type {?} */
        var item1 = iterator1.next();
        /** @type {?} */

        var item2 = iterator2.next();
        if (item1.done && item2.done) return true;
        if (item1.done || item2.done) return false;
        if (!comparator(item1.value, item2.value)) return false;
      }
    }
    /**
     * @param {?} obj
     * @param {?} fn
     * @return {?}
     */


    function iterateListLike$1(obj, fn) {
      if (Array.isArray(obj)) {
        for (var i = 0; i < obj.length; i++) {
          fn(obj[i]);
        }
      } else {
        /** @type {?} */
        var iterator = obj[getSymbolIterator()]();
        /** @type {?} */

        var item;

        while (!(item = iterator.next()).done) {
          fn(item.value);
        }
      }
    }
    /**
     * @param {?} o
     * @return {?}
     */


    function isJsObject$1(o) {
      return o !== null && (typeof o === 'function' || typeof o === 'object');
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/bindings.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */
    // TODO(misko): consider inlining

    /**
     * Updates binding and returns the value.
     * @param {?} lView
     * @param {?} bindingIndex
     * @param {?} value
     * @return {?}
     */


    function updateBinding(lView, bindingIndex, value) {
      return lView[bindingIndex] = value;
    }
    /**
     * Gets the current binding value.
     * @param {?} lView
     * @param {?} bindingIndex
     * @return {?}
     */


    function getBinding(lView, bindingIndex) {
      ngDevMode && assertDataInRange(lView, bindingIndex);
      ngDevMode && assertNotSame(lView[bindingIndex], NO_CHANGE, 'Stored value should never be NO_CHANGE.');
      return lView[bindingIndex];
    }
    /**
     * Updates binding if changed, then returns whether it was updated.
     *
     * This function also checks the `CheckNoChangesMode` and throws if changes are made.
     * Some changes (Objects/iterables) during `CheckNoChangesMode` are exempt to comply with VE
     * behavior.
     *
     * @param {?} lView current `LView`
     * @param {?} bindingIndex The binding in the `LView` to check
     * @param {?} value New value to check against `lView[bindingIndex]`
     * @return {?} `true` if the bindings has changed. (Throws if binding has changed during
     *          `CheckNoChangesMode`)
     */


    function bindingUpdated(lView, bindingIndex, value) {
      ngDevMode && assertNotSame(value, NO_CHANGE, 'Incoming value should never be NO_CHANGE.');
      ngDevMode && assertLessThan(bindingIndex, lView.length, "Slot should have been initialized to NO_CHANGE");
      /** @type {?} */

      var oldValue = lView[bindingIndex];

      if (Object.is(oldValue, value)) {
        return false;
      } else {
        if (ngDevMode && getCheckNoChangesMode()) {
          // View engine didn't report undefined values as changed on the first checkNoChanges pass
          // (before the change detection was run).

          /** @type {?} */
          var oldValueToCompare = oldValue !== NO_CHANGE ? oldValue : undefined;

          if (!devModeEqual$1(oldValueToCompare, value)) {
            /** @type {?} */
            var details = getExpressionChangedErrorDetails(lView, bindingIndex, oldValueToCompare, value);
            throwErrorIfNoChangesMode(oldValue === NO_CHANGE, details.oldValue, details.newValue, details.propName);
          } // There was a change, but the `devModeEqual` decided that the change is exempt from an error.
          // For this reason we exit as if no change. The early exit is needed to prevent the changed
          // value to be written into `LView` (If we would write the new value that we would not see it
          // as change on next CD.)


          return false;
        }

        lView[bindingIndex] = value;
        return true;
      }
    }
    /**
     * Updates 2 bindings if changed, then returns whether either was updated.
     * @param {?} lView
     * @param {?} bindingIndex
     * @param {?} exp1
     * @param {?} exp2
     * @return {?}
     */


    function bindingUpdated2(lView, bindingIndex, exp1, exp2) {
      /** @type {?} */
      var different = bindingUpdated(lView, bindingIndex, exp1);
      return bindingUpdated(lView, bindingIndex + 1, exp2) || different;
    }
    /**
     * Updates 3 bindings if changed, then returns whether any was updated.
     * @param {?} lView
     * @param {?} bindingIndex
     * @param {?} exp1
     * @param {?} exp2
     * @param {?} exp3
     * @return {?}
     */


    function bindingUpdated3(lView, bindingIndex, exp1, exp2, exp3) {
      /** @type {?} */
      var different = bindingUpdated2(lView, bindingIndex, exp1, exp2);
      return bindingUpdated(lView, bindingIndex + 2, exp3) || different;
    }
    /**
     * Updates 4 bindings if changed, then returns whether any was updated.
     * @param {?} lView
     * @param {?} bindingIndex
     * @param {?} exp1
     * @param {?} exp2
     * @param {?} exp3
     * @param {?} exp4
     * @return {?}
     */


    function bindingUpdated4(lView, bindingIndex, exp1, exp2, exp3, exp4) {
      /** @type {?} */
      var different = bindingUpdated2(lView, bindingIndex, exp1, exp2);
      return bindingUpdated2(lView, bindingIndex + 2, exp3, exp4) || different;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/attribute.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Updates the value of or removes a bound attribute on an Element.
     *
     * Used in the case of `[attr.title]="value"`
     *
     * \@codeGenApi
     * @param {?} name name The name of the attribute.
     * @param {?} value value The attribute is removed when value is `null` or `undefined`.
     *                  Otherwise the attribute value is set to the stringified value.
     * @param {?=} sanitizer An optional function used to sanitize the value.
     * @param {?=} namespace Optional namespace to use when setting the attribute.
     *
     * @return {?}
     */


    function ɵɵattribute(name, value, sanitizer, namespace) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var bindingIndex = nextBindingIndex();

      if (bindingUpdated(lView, bindingIndex, value)) {
        /** @type {?} */
        var tView = getTView();
        /** @type {?} */

        var tNode = getSelectedTNode();
        elementAttributeInternal(tNode, lView, name, value, sanitizer, namespace);
        ngDevMode && storePropertyBindingMetadata(tView.data, tNode, 'attr.' + name, bindingIndex);
      }

      return ɵɵattribute;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/interpolation.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Create interpolation bindings with a variable number of expressions.
     *
     * If there are 1 to 8 expressions `interpolation1()` to `interpolation8()` should be used instead.
     * Those are faster because there is no need to create an array of expressions and iterate over it.
     *
     * `values`:
     * - has static text at even indexes,
     * - has evaluated expressions at odd indexes.
     *
     * Returns the concatenated string when any of the arguments changes, `NO_CHANGE` otherwise.
     * @param {?} lView
     * @param {?} values
     * @return {?}
     */


    function interpolationV(lView, values) {
      ngDevMode && assertLessThan(2, values.length, 'should have at least 3 values');
      ngDevMode && assertEqual(values.length % 2, 1, 'should have an odd number of values');
      /** @type {?} */

      var isBindingUpdated = false;
      /** @type {?} */

      var bindingIndex = getBindingIndex();

      for (var i = 1; i < values.length; i += 2) {
        // Check if bindings (odd indexes) have changed
        isBindingUpdated = bindingUpdated(lView, bindingIndex++, values[i]) || isBindingUpdated;
      }

      setBindingIndex(bindingIndex);

      if (!isBindingUpdated) {
        return NO_CHANGE;
      } // Build the updated content

      /** @type {?} */


      var content = values[0];

      for (var _i13 = 1; _i13 < values.length; _i13 += 2) {
        content += renderStringify(values[_i13]) + values[_i13 + 1];
      }

      return content;
    }
    /**
     * Creates an interpolation binding with 1 expression.
     *
     * @param {?} lView
     * @param {?} prefix static value used for concatenation only.
     * @param {?} v0 value checked for change.
     * @param {?} suffix static value used for concatenation only.
     * @return {?}
     */


    function interpolation1(lView, prefix, v0, suffix) {
      /** @type {?} */
      var different = bindingUpdated(lView, nextBindingIndex(), v0);
      return different ? prefix + renderStringify(v0) + suffix : NO_CHANGE;
    }
    /**
     * Creates an interpolation binding with 2 expressions.
     * @param {?} lView
     * @param {?} prefix
     * @param {?} v0
     * @param {?} i0
     * @param {?} v1
     * @param {?} suffix
     * @return {?}
     */


    function interpolation2(lView, prefix, v0, i0, v1, suffix) {
      /** @type {?} */
      var bindingIndex = getBindingIndex();
      /** @type {?} */

      var different = bindingUpdated2(lView, bindingIndex, v0, v1);
      incrementBindingIndex(2);
      return different ? prefix + renderStringify(v0) + i0 + renderStringify(v1) + suffix : NO_CHANGE;
    }
    /**
     * Creates an interpolation binding with 3 expressions.
     * @param {?} lView
     * @param {?} prefix
     * @param {?} v0
     * @param {?} i0
     * @param {?} v1
     * @param {?} i1
     * @param {?} v2
     * @param {?} suffix
     * @return {?}
     */


    function interpolation3(lView, prefix, v0, i0, v1, i1, v2, suffix) {
      /** @type {?} */
      var bindingIndex = getBindingIndex();
      /** @type {?} */

      var different = bindingUpdated3(lView, bindingIndex, v0, v1, v2);
      incrementBindingIndex(3);
      return different ? prefix + renderStringify(v0) + i0 + renderStringify(v1) + i1 + renderStringify(v2) + suffix : NO_CHANGE;
    }
    /**
     * Create an interpolation binding with 4 expressions.
     * @param {?} lView
     * @param {?} prefix
     * @param {?} v0
     * @param {?} i0
     * @param {?} v1
     * @param {?} i1
     * @param {?} v2
     * @param {?} i2
     * @param {?} v3
     * @param {?} suffix
     * @return {?}
     */


    function interpolation4(lView, prefix, v0, i0, v1, i1, v2, i2, v3, suffix) {
      /** @type {?} */
      var bindingIndex = getBindingIndex();
      /** @type {?} */

      var different = bindingUpdated4(lView, bindingIndex, v0, v1, v2, v3);
      incrementBindingIndex(4);
      return different ? prefix + renderStringify(v0) + i0 + renderStringify(v1) + i1 + renderStringify(v2) + i2 + renderStringify(v3) + suffix : NO_CHANGE;
    }
    /**
     * Creates an interpolation binding with 5 expressions.
     * @param {?} lView
     * @param {?} prefix
     * @param {?} v0
     * @param {?} i0
     * @param {?} v1
     * @param {?} i1
     * @param {?} v2
     * @param {?} i2
     * @param {?} v3
     * @param {?} i3
     * @param {?} v4
     * @param {?} suffix
     * @return {?}
     */


    function interpolation5(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix) {
      /** @type {?} */
      var bindingIndex = getBindingIndex();
      /** @type {?} */

      var different = bindingUpdated4(lView, bindingIndex, v0, v1, v2, v3);
      different = bindingUpdated(lView, bindingIndex + 4, v4) || different;
      incrementBindingIndex(5);
      return different ? prefix + renderStringify(v0) + i0 + renderStringify(v1) + i1 + renderStringify(v2) + i2 + renderStringify(v3) + i3 + renderStringify(v4) + suffix : NO_CHANGE;
    }
    /**
     * Creates an interpolation binding with 6 expressions.
     * @param {?} lView
     * @param {?} prefix
     * @param {?} v0
     * @param {?} i0
     * @param {?} v1
     * @param {?} i1
     * @param {?} v2
     * @param {?} i2
     * @param {?} v3
     * @param {?} i3
     * @param {?} v4
     * @param {?} i4
     * @param {?} v5
     * @param {?} suffix
     * @return {?}
     */


    function interpolation6(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix) {
      /** @type {?} */
      var bindingIndex = getBindingIndex();
      /** @type {?} */

      var different = bindingUpdated4(lView, bindingIndex, v0, v1, v2, v3);
      different = bindingUpdated2(lView, bindingIndex + 4, v4, v5) || different;
      incrementBindingIndex(6);
      return different ? prefix + renderStringify(v0) + i0 + renderStringify(v1) + i1 + renderStringify(v2) + i2 + renderStringify(v3) + i3 + renderStringify(v4) + i4 + renderStringify(v5) + suffix : NO_CHANGE;
    }
    /**
     * Creates an interpolation binding with 7 expressions.
     * @param {?} lView
     * @param {?} prefix
     * @param {?} v0
     * @param {?} i0
     * @param {?} v1
     * @param {?} i1
     * @param {?} v2
     * @param {?} i2
     * @param {?} v3
     * @param {?} i3
     * @param {?} v4
     * @param {?} i4
     * @param {?} v5
     * @param {?} i5
     * @param {?} v6
     * @param {?} suffix
     * @return {?}
     */


    function interpolation7(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix) {
      /** @type {?} */
      var bindingIndex = getBindingIndex();
      /** @type {?} */

      var different = bindingUpdated4(lView, bindingIndex, v0, v1, v2, v3);
      different = bindingUpdated3(lView, bindingIndex + 4, v4, v5, v6) || different;
      incrementBindingIndex(7);
      return different ? prefix + renderStringify(v0) + i0 + renderStringify(v1) + i1 + renderStringify(v2) + i2 + renderStringify(v3) + i3 + renderStringify(v4) + i4 + renderStringify(v5) + i5 + renderStringify(v6) + suffix : NO_CHANGE;
    }
    /**
     * Creates an interpolation binding with 8 expressions.
     * @param {?} lView
     * @param {?} prefix
     * @param {?} v0
     * @param {?} i0
     * @param {?} v1
     * @param {?} i1
     * @param {?} v2
     * @param {?} i2
     * @param {?} v3
     * @param {?} i3
     * @param {?} v4
     * @param {?} i4
     * @param {?} v5
     * @param {?} i5
     * @param {?} v6
     * @param {?} i6
     * @param {?} v7
     * @param {?} suffix
     * @return {?}
     */


    function interpolation8(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix) {
      /** @type {?} */
      var bindingIndex = getBindingIndex();
      /** @type {?} */

      var different = bindingUpdated4(lView, bindingIndex, v0, v1, v2, v3);
      different = bindingUpdated4(lView, bindingIndex + 4, v4, v5, v6, v7) || different;
      incrementBindingIndex(8);
      return different ? prefix + renderStringify(v0) + i0 + renderStringify(v1) + i1 + renderStringify(v2) + i2 + renderStringify(v3) + i3 + renderStringify(v4) + i4 + renderStringify(v5) + i5 + renderStringify(v6) + i6 + renderStringify(v7) + suffix : NO_CHANGE;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/attribute_interpolation.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     *
     * Update an interpolated attribute on an element with single bound value surrounded by text.
     *
     * Used when the value passed to a property has 1 interpolated value in it:
     *
     * ```html
     * <div attr.title="prefix{{v0}}suffix"></div>
     * ```
     *
     * Its compiled representation is::
     *
     * ```ts
     * ɵɵattributeInterpolate1('title', 'prefix', v0, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} attrName The name of the attribute to update
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} sanitizer An optional sanitizer function
     * @param {?=} namespace
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵattributeInterpolate1(attrName, prefix, v0, suffix, sanitizer, namespace) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation1(lView, prefix, v0, suffix);

      if (interpolatedValue !== NO_CHANGE) {
        /** @type {?} */
        var tNode = getSelectedTNode();
        elementAttributeInternal(tNode, lView, attrName, interpolatedValue, sanitizer, namespace);
        ngDevMode && storePropertyBindingMetadata(getTView().data, tNode, 'attr.' + attrName, getBindingIndex() - 1, prefix, suffix);
      }

      return ɵɵattributeInterpolate1;
    }
    /**
     *
     * Update an interpolated attribute on an element with 2 bound values surrounded by text.
     *
     * Used when the value passed to a property has 2 interpolated values in it:
     *
     * ```html
     * <div attr.title="prefix{{v0}}-{{v1}}suffix"></div>
     * ```
     *
     * Its compiled representation is::
     *
     * ```ts
     * ɵɵattributeInterpolate2('title', 'prefix', v0, '-', v1, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} attrName The name of the attribute to update
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} sanitizer An optional sanitizer function
     * @param {?=} namespace
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵattributeInterpolate2(attrName, prefix, v0, i0, v1, suffix, sanitizer, namespace) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation2(lView, prefix, v0, i0, v1, suffix);

      if (interpolatedValue !== NO_CHANGE) {
        /** @type {?} */
        var tNode = getSelectedTNode();
        elementAttributeInternal(tNode, lView, attrName, interpolatedValue, sanitizer, namespace);
        ngDevMode && storePropertyBindingMetadata(getTView().data, tNode, 'attr.' + attrName, getBindingIndex() - 2, prefix, i0, suffix);
      }

      return ɵɵattributeInterpolate2;
    }
    /**
     *
     * Update an interpolated attribute on an element with 3 bound values surrounded by text.
     *
     * Used when the value passed to a property has 3 interpolated values in it:
     *
     * ```html
     * <div attr.title="prefix{{v0}}-{{v1}}-{{v2}}suffix"></div>
     * ```
     *
     * Its compiled representation is::
     *
     * ```ts
     * ɵɵattributeInterpolate3(
     * 'title', 'prefix', v0, '-', v1, '-', v2, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} attrName The name of the attribute to update
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} sanitizer An optional sanitizer function
     * @param {?=} namespace
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵattributeInterpolate3(attrName, prefix, v0, i0, v1, i1, v2, suffix, sanitizer, namespace) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation3(lView, prefix, v0, i0, v1, i1, v2, suffix);

      if (interpolatedValue !== NO_CHANGE) {
        /** @type {?} */
        var tNode = getSelectedTNode();
        elementAttributeInternal(tNode, lView, attrName, interpolatedValue, sanitizer, namespace);
        ngDevMode && storePropertyBindingMetadata(getTView().data, tNode, 'attr.' + attrName, getBindingIndex() - 3, prefix, i0, i1, suffix);
      }

      return ɵɵattributeInterpolate3;
    }
    /**
     *
     * Update an interpolated attribute on an element with 4 bound values surrounded by text.
     *
     * Used when the value passed to a property has 4 interpolated values in it:
     *
     * ```html
     * <div attr.title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}suffix"></div>
     * ```
     *
     * Its compiled representation is::
     *
     * ```ts
     * ɵɵattributeInterpolate4(
     * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} attrName The name of the attribute to update
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} sanitizer An optional sanitizer function
     * @param {?=} namespace
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵattributeInterpolate4(attrName, prefix, v0, i0, v1, i1, v2, i2, v3, suffix, sanitizer, namespace) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation4(lView, prefix, v0, i0, v1, i1, v2, i2, v3, suffix);

      if (interpolatedValue !== NO_CHANGE) {
        /** @type {?} */
        var tNode = getSelectedTNode();
        elementAttributeInternal(tNode, lView, attrName, interpolatedValue, sanitizer, namespace);
        ngDevMode && storePropertyBindingMetadata(getTView().data, tNode, 'attr.' + attrName, getBindingIndex() - 4, prefix, i0, i1, i2, suffix);
      }

      return ɵɵattributeInterpolate4;
    }
    /**
     *
     * Update an interpolated attribute on an element with 5 bound values surrounded by text.
     *
     * Used when the value passed to a property has 5 interpolated values in it:
     *
     * ```html
     * <div attr.title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}suffix"></div>
     * ```
     *
     * Its compiled representation is::
     *
     * ```ts
     * ɵɵattributeInterpolate5(
     * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} attrName The name of the attribute to update
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} i3 Static value used for concatenation only.
     * @param {?} v4 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} sanitizer An optional sanitizer function
     * @param {?=} namespace
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵattributeInterpolate5(attrName, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix, sanitizer, namespace) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation5(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix);

      if (interpolatedValue !== NO_CHANGE) {
        /** @type {?} */
        var tNode = getSelectedTNode();
        elementAttributeInternal(tNode, lView, attrName, interpolatedValue, sanitizer, namespace);
        ngDevMode && storePropertyBindingMetadata(getTView().data, tNode, 'attr.' + attrName, getBindingIndex() - 5, prefix, i0, i1, i2, i3, suffix);
      }

      return ɵɵattributeInterpolate5;
    }
    /**
     *
     * Update an interpolated attribute on an element with 6 bound values surrounded by text.
     *
     * Used when the value passed to a property has 6 interpolated values in it:
     *
     * ```html
     * <div attr.title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}suffix"></div>
     * ```
     *
     * Its compiled representation is::
     *
     * ```ts
     * ɵɵattributeInterpolate6(
     *    'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} attrName The name of the attribute to update
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} i3 Static value used for concatenation only.
     * @param {?} v4 Value checked for change.
     * @param {?} i4 Static value used for concatenation only.
     * @param {?} v5 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} sanitizer An optional sanitizer function
     * @param {?=} namespace
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵattributeInterpolate6(attrName, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix, sanitizer, namespace) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation6(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix);

      if (interpolatedValue !== NO_CHANGE) {
        /** @type {?} */
        var tNode = getSelectedTNode();
        elementAttributeInternal(tNode, lView, attrName, interpolatedValue, sanitizer, namespace);
        ngDevMode && storePropertyBindingMetadata(getTView().data, tNode, 'attr.' + attrName, getBindingIndex() - 6, prefix, i0, i1, i2, i3, i4, suffix);
      }

      return ɵɵattributeInterpolate6;
    }
    /**
     *
     * Update an interpolated attribute on an element with 7 bound values surrounded by text.
     *
     * Used when the value passed to a property has 7 interpolated values in it:
     *
     * ```html
     * <div attr.title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}suffix"></div>
     * ```
     *
     * Its compiled representation is::
     *
     * ```ts
     * ɵɵattributeInterpolate7(
     *    'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} attrName The name of the attribute to update
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} i3 Static value used for concatenation only.
     * @param {?} v4 Value checked for change.
     * @param {?} i4 Static value used for concatenation only.
     * @param {?} v5 Value checked for change.
     * @param {?} i5 Static value used for concatenation only.
     * @param {?} v6 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} sanitizer An optional sanitizer function
     * @param {?=} namespace
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵattributeInterpolate7(attrName, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix, sanitizer, namespace) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation7(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix);

      if (interpolatedValue !== NO_CHANGE) {
        /** @type {?} */
        var tNode = getSelectedTNode();
        elementAttributeInternal(tNode, lView, attrName, interpolatedValue, sanitizer, namespace);
        ngDevMode && storePropertyBindingMetadata(getTView().data, tNode, 'attr.' + attrName, getBindingIndex() - 7, prefix, i0, i1, i2, i3, i4, i5, suffix);
      }

      return ɵɵattributeInterpolate7;
    }
    /**
     *
     * Update an interpolated attribute on an element with 8 bound values surrounded by text.
     *
     * Used when the value passed to a property has 8 interpolated values in it:
     *
     * ```html
     * <div attr.title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}suffix"></div>
     * ```
     *
     * Its compiled representation is::
     *
     * ```ts
     * ɵɵattributeInterpolate8(
     *  'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} attrName The name of the attribute to update
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} i3 Static value used for concatenation only.
     * @param {?} v4 Value checked for change.
     * @param {?} i4 Static value used for concatenation only.
     * @param {?} v5 Value checked for change.
     * @param {?} i5 Static value used for concatenation only.
     * @param {?} v6 Value checked for change.
     * @param {?} i6 Static value used for concatenation only.
     * @param {?} v7 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} sanitizer An optional sanitizer function
     * @param {?=} namespace
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵattributeInterpolate8(attrName, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix, sanitizer, namespace) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation8(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix);

      if (interpolatedValue !== NO_CHANGE) {
        /** @type {?} */
        var tNode = getSelectedTNode();
        elementAttributeInternal(tNode, lView, attrName, interpolatedValue, sanitizer, namespace);
        ngDevMode && storePropertyBindingMetadata(getTView().data, tNode, 'attr.' + attrName, getBindingIndex() - 8, prefix, i0, i1, i2, i3, i4, i5, i6, suffix);
      }

      return ɵɵattributeInterpolate8;
    }
    /**
     * Update an interpolated attribute on an element with 9 or more bound values surrounded by text.
     *
     * Used when the number of interpolated values exceeds 8.
     *
     * ```html
     * <div
     *  title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}-{{v8}}-{{v9}}suffix"></div>
     * ```
     *
     * Its compiled representation is::
     *
     * ```ts
     * ɵɵattributeInterpolateV(
     *  'title', ['prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, '-', v9,
     *  'suffix']);
     * ```
     *
     * \@codeGenApi
     * @param {?} attrName The name of the attribute to update.
     * @param {?} values The collection of values and the strings in-between those values, beginning with
     * a string prefix and ending with a string suffix.
     * (e.g. `['prefix', value0, '-', value1, '-', value2, ..., value99, 'suffix']`)
     * @param {?=} sanitizer An optional sanitizer function
     * @param {?=} namespace
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵattributeInterpolateV(attrName, values, sanitizer, namespace) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolated = interpolationV(lView, values);

      if (interpolated !== NO_CHANGE) {
        /** @type {?} */
        var tNode = getSelectedTNode();
        elementAttributeInternal(tNode, lView, attrName, interpolated, sanitizer, namespace);

        if (ngDevMode) {
          /** @type {?} */
          var interpolationInBetween = [values[0]];

          for (var i = 2; i < values.length; i += 2) {
            interpolationInBetween.push(values[i]);
          }

          storePropertyBindingMetadata.apply(void 0, [getTView().data, tNode, 'attr.' + attrName, getBindingIndex() - interpolationInBetween.length + 1].concat(interpolationInBetween));
        }
      }

      return ɵɵattributeInterpolateV;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/change_detection.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Synchronously perform change detection on a component (and possibly its sub-components).
     *
     * This function triggers change detection in a synchronous way on a component.
     *
     * @param {?} component The component which the change detection should be performed on.
     * @return {?}
     */


    function detectChanges(component) {
      /** @type {?} */
      var view = getComponentViewByInstance(component);
      detectChangesInternal(view[TVIEW], view, component);
    }
    /**
     * Marks the component as dirty (needing change detection). Marking a component dirty will
     * schedule a change detection on it at some point in the future.
     *
     * Marking an already dirty component as dirty won't do anything. Only one outstanding change
     * detection can be scheduled per component tree.
     *
     * @param {?} component Component to mark as dirty.
     * @return {?}
     */


    function markDirty(component) {
      ngDevMode && assertDefined(component, 'component');
      /** @type {?} */

      var rootView =
      /** @type {?} */
      markViewDirty(getComponentViewByInstance(component));
      ngDevMode && assertDefined(rootView[CONTEXT], 'rootContext should be defined');
      scheduleTick(
      /** @type {?} */
      rootView[CONTEXT], 1
      /* DetectChanges */
      );
    }
    /**
     * Used to perform change detection on the whole application.
     *
     * This is equivalent to `detectChanges`, but invoked on root component. Additionally, `tick`
     * executes lifecycle hooks and conditionally checks components based on their
     * `ChangeDetectionStrategy` and dirtiness.
     *
     * The preferred way to trigger change detection is to call `markDirty`. `markDirty` internally
     * schedules `tick` using a scheduler in order to coalesce multiple `markDirty` calls into a
     * single change detection run. By default, the scheduler is `requestAnimationFrame`, but can
     * be changed when calling `renderComponent` and providing the `scheduler` option.
     * @template T
     * @param {?} component
     * @return {?}
     */


    function tick(component) {
      /** @type {?} */
      var rootView = getRootView(component);
      /** @type {?} */

      var rootContext =
      /** @type {?} */
      rootView[CONTEXT];
      tickRootContext(rootContext);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/container.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Creates an LContainer for inline views, e.g.
     *
     * % if (showing) {
     *   <div></div>
     * % }
     *
     * \@codeGenApi
     * @param {?} index The index of the container in the data array
     *
     * @return {?}
     */


    function ɵɵcontainer(index) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var tView = getTView();
      /** @type {?} */

      var tNode = containerInternal(tView, lView, index, null, null);

      if (tView.firstCreatePass) {
        tNode.tViews = [];
      }

      setIsNotParent();
    }
    /**
     * @param {?} index
     * @param {?} tView
     * @param {?} lView
     * @param {?} templateFn
     * @param {?} decls
     * @param {?} vars
     * @param {?=} tagName
     * @param {?=} attrsIndex
     * @param {?=} localRefsIndex
     * @return {?}
     */


    function templateFirstCreatePass(index, tView, lView, templateFn, decls, vars, tagName, attrsIndex, localRefsIndex) {
      ngDevMode && assertFirstCreatePass(tView);
      ngDevMode && ngDevMode.firstCreatePass++;
      /** @type {?} */

      var tViewConsts = tView.consts; // TODO(pk): refactor getOrCreateTNode to have the "create" only version

      /** @type {?} */

      var tNode = getOrCreateTNode(tView, lView[T_HOST], index, 0
      /* Container */
      , tagName || null, getConstant(tViewConsts, attrsIndex));
      resolveDirectives(tView, lView, tNode, getConstant(tViewConsts, localRefsIndex));
      registerPostOrderHooks(tView, tNode);
      /** @type {?} */

      var embeddedTView = tNode.tViews = createTView(2
      /* Embedded */
      , -1, templateFn, decls, vars, tView.directiveRegistry, tView.pipeRegistry, null, tView.schemas, tViewConsts);
      /** @type {?} */

      var embeddedTViewNode =
      /** @type {?} */
      createTNode(tView, null, 2
      /* View */
      , -1, null, null);
      embeddedTViewNode.injectorIndex = tNode.injectorIndex;
      embeddedTView.node = embeddedTViewNode;

      if (tView.queries !== null) {
        tView.queries.template(tView, tNode);
        embeddedTView.queries = tView.queries.embeddedTView(tNode);
      }

      return tNode;
    }
    /**
     * Creates an LContainer for an ng-template (dynamically-inserted view), e.g.
     *
     * <ng-template #foo>
     *    <div></div>
     * </ng-template>
     *
     * \@codeGenApi
     * @param {?} index The index of the container in the data array
     * @param {?} templateFn Inline template
     * @param {?} decls The number of nodes, local refs, and pipes for this template
     * @param {?} vars The number of bindings for this template
     * @param {?=} tagName The name of the container element, if applicable
     * @param {?=} attrsIndex Index of template attributes in the `consts` array.
     * @param {?=} localRefsIndex
     * @param {?=} localRefExtractor A function which extracts local-refs values from the template.
     *        Defaults to the current element associated with the local-ref.
     *
     * @return {?}
     */


    function ɵɵtemplate(index, templateFn, decls, vars, tagName, attrsIndex, localRefsIndex, localRefExtractor) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var tView = getTView();
      /** @type {?} */

      var adjustedIndex = index + HEADER_OFFSET;
      /** @type {?} */

      var tNode = tView.firstCreatePass ? templateFirstCreatePass(index, tView, lView, templateFn, decls, vars, tagName, attrsIndex, localRefsIndex) :
      /** @type {?} */
      tView.data[adjustedIndex];
      setPreviousOrParentTNode(tNode, false);
      /** @type {?} */

      var comment = lView[RENDERER].createComment(ngDevMode ? 'container' : '');
      appendChild(tView, lView, comment, tNode);
      attachPatchData(comment, lView);
      addToViewTree(lView, lView[adjustedIndex] = createLContainer(comment, lView, comment, tNode));

      if (isDirectiveHost(tNode)) {
        createDirectivesInstances(tView, lView, tNode);
      }

      if (localRefsIndex != null) {
        saveResolvedLocalsInData(lView, tNode, localRefExtractor);
      }
    }
    /**
     * Sets a container up to receive views.
     *
     * \@codeGenApi
     * @param {?} index The index of the container in the data array
     *
     * @return {?}
     */


    function ɵɵcontainerRefreshStart(index) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var tView = getTView();
      /** @type {?} */

      var previousOrParentTNode =
      /** @type {?} */
      load(tView.data, index);
      ngDevMode && assertNodeType(previousOrParentTNode, 0
      /* Container */
      );
      setPreviousOrParentTNode(previousOrParentTNode, true);
      lView[index + HEADER_OFFSET][ACTIVE_INDEX] = 0; // We need to execute init hooks here so ngOnInit hooks are called in top level views
      // before they are called in embedded views (for backwards compatibility).

      if (!getCheckNoChangesMode()) {
        /** @type {?} */
        var hooksInitPhaseCompleted = (lView[FLAGS] & 3
        /* InitPhaseStateMask */
        ) === 3
        /* InitPhaseCompleted */
        ;

        if (hooksInitPhaseCompleted) {
          /** @type {?} */
          var preOrderCheckHooks = tView.preOrderCheckHooks;

          if (preOrderCheckHooks !== null) {
            executeCheckHooks(lView, preOrderCheckHooks, null);
          }
        } else {
          /** @type {?} */
          var preOrderHooks = tView.preOrderHooks;

          if (preOrderHooks !== null) {
            executeInitAndCheckHooks(lView, preOrderHooks, 0
            /* OnInitHooksToBeRun */
            , null);
          }

          incrementInitPhaseFlags(lView, 0
          /* OnInitHooksToBeRun */
          );
        }
      }
    }
    /**
     * Marks the end of the LContainer.
     *
     * Marking the end of LContainer is the time when to child views get inserted or removed.
     *
     * \@codeGenApi
     * @return {?}
     */


    function ɵɵcontainerRefreshEnd() {
      /** @type {?} */
      var previousOrParentTNode = getPreviousOrParentTNode();

      if (getIsParent()) {
        setIsNotParent();
      } else {
        ngDevMode && assertNodeType(previousOrParentTNode, 2
        /* View */
        );
        ngDevMode && assertHasParent(previousOrParentTNode);
        previousOrParentTNode =
        /** @type {?} */
        previousOrParentTNode.parent;
        setPreviousOrParentTNode(previousOrParentTNode, false);
      }

      ngDevMode && assertNodeType(previousOrParentTNode, 0
      /* Container */
      );
      /** @type {?} */

      var lContainer = getLView()[previousOrParentTNode.index];
      /** @type {?} */

      var nextIndex = getLContainerActiveIndex(lContainer); // remove extra views at the end of the container

      while (nextIndex < lContainer.length - CONTAINER_HEADER_OFFSET) {
        removeView(lContainer, nextIndex);
      }
    }
    /**
     * @param {?} tView
     * @param {?} lView
     * @param {?} nodeIndex
     * @param {?} tagName
     * @param {?} attrs
     * @return {?}
     */


    function containerInternal(tView, lView, nodeIndex, tagName, attrs) {
      ngDevMode && assertEqual(getBindingIndex(), tView.bindingStartIndex, 'container nodes should be created before any bindings');
      /** @type {?} */

      var adjustedIndex = nodeIndex + HEADER_OFFSET;
      ngDevMode && assertDataInRange(lView, nodeIndex + HEADER_OFFSET);
      ngDevMode && ngDevMode.rendererCreateComment++;
      /** @type {?} */

      var comment = lView[adjustedIndex] = lView[RENDERER].createComment(ngDevMode ? 'container' : '');
      /** @type {?} */

      var tNode = getOrCreateTNode(tView, lView[T_HOST], nodeIndex, 0
      /* Container */
      , tagName, attrs);
      /** @type {?} */

      var lContainer = lView[adjustedIndex] = createLContainer(comment, lView, comment, tNode);
      appendChild(tView, lView, comment, tNode);
      attachPatchData(comment, lView); // Containers are added to the current view tree instead of their embedded views
      // because views can be removed and re-inserted.

      addToViewTree(lView, lContainer);
      ngDevMode && assertNodeType(getPreviousOrParentTNode(), 0
      /* Container */
      );
      return tNode;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/storage.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Store a value in the `data` at a given `index`.
     * @template T
     * @param {?} tView
     * @param {?} lView
     * @param {?} index
     * @param {?} value
     * @return {?}
     */


    function store(tView, lView, index, value) {
      // We don't store any static data for local variables, so the first time
      // we see the template, we should store as null to avoid a sparse array

      /** @type {?} */
      var adjustedIndex = index + HEADER_OFFSET;

      if (adjustedIndex >= tView.data.length) {
        tView.data[adjustedIndex] = null;
        tView.blueprint[adjustedIndex] = null;
      }

      lView[adjustedIndex] = value;
    }
    /**
     * Retrieves a local reference from the current contextViewData.
     *
     * If the reference to retrieve is in a parent view, this instruction is used in conjunction
     * with a nextContext() call, which walks up the tree and updates the contextViewData instance.
     *
     * \@codeGenApi
     * @template T
     * @param {?} index The index of the local ref in contextViewData.
     *
     * @return {?}
     */


    function ɵɵreference(index) {
      /** @type {?} */
      var contextLView = getContextLView();
      return load(contextLView, index);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/di.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @template T
     * @param {?} token
     * @param {?=} flags
     * @return {?}
     */


    function ɵɵdirectiveInject(token) {
      var flags = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : InjectFlags.Default;

      /** @type {?} */
      var lView = getLView(); // Fall back to inject() if view hasn't been created. This situation can happen in tests
      // if inject utilities are used before bootstrapping.

      if (lView == null) return ɵɵinject(token, flags);
      /** @type {?} */

      var tNode = getPreviousOrParentTNode();
      return getOrCreateInjectable(
      /** @type {?} */
      tNode, lView, resolveForwardRef(token), flags);
    }
    /**
     * Facade for the attribute injection from DI.
     *
     * \@codeGenApi
     * @param {?} attrNameToInject
     * @return {?}
     */


    function ɵɵinjectAttribute(attrNameToInject) {
      return injectAttributeImpl(getPreviousOrParentTNode(), attrNameToInject);
    }
    /**
     * Throws an error indicating that a factory function could not be generated by the compiler for a
     * particular class.
     *
     * This instruction allows the actual error message to be optimized away when ngDevMode is turned
     * off, saving bytes of generated code while still providing a good experience in dev mode.
     *
     * The name of the class is not mentioned here, but will be in the generated factory function name
     * and thus in the stack trace.
     *
     * \@codeGenApi
     * @return {?}
     */


    function ɵɵinvalidFactory() {
      /** @type {?} */
      var msg = ngDevMode ? "This constructor was not compatible with Dependency Injection." : 'invalid';
      throw new Error(msg);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/property.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Update a property on a selected element.
     *
     * Operates on the element selected by index via the {\@link select} instruction.
     *
     * If the property name also exists as an input property on one of the element's directives,
     * the component property will be set instead of the element property. This check must
     * be conducted at runtime so child components that add new `\@Inputs` don't have to be re-compiled
     *
     * \@codeGenApi
     * @template T
     * @param {?} propName Name of property. Because it is going to DOM, this is not subject to
     *        renaming as part of minification.
     * @param {?} value New value to write.
     * @param {?=} sanitizer An optional function used to sanitize the value.
     * @return {?} This function returns itself so that it may be chained
     * (e.g. `property('name', ctx.name)('title', ctx.title)`)
     *
     */


    function ɵɵproperty(propName, value, sanitizer) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var bindingIndex = nextBindingIndex();

      if (bindingUpdated(lView, bindingIndex, value)) {
        /** @type {?} */
        var tView = getTView();
        /** @type {?} */

        var tNode = getSelectedTNode();
        elementPropertyInternal(tView, tNode, lView, propName, value, lView[RENDERER], sanitizer, false);
        ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, bindingIndex);
      }

      return ɵɵproperty;
    }
    /**
     * Given `<div style="..." my-dir>` and `MyDir` with `\@Input('style')` we need to write to
     * directive input.
     * @param {?} tView
     * @param {?} tNode
     * @param {?} lView
     * @param {?} value
     * @param {?} isClassBased
     * @return {?}
     */


    function setDirectiveInputsWhichShadowsStyling(tView, tNode, lView, value, isClassBased) {
      /** @type {?} */
      var inputs =
      /** @type {?} */
      tNode.inputs;
      /** @type {?} */

      var property = isClassBased ? 'class' : 'style'; // We support both 'class' and `className` hence the fallback.

      setInputsForProperty(tView, lView, inputs[property], property, value);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/element.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} index
     * @param {?} tView
     * @param {?} lView
     * @param {?} native
     * @param {?} name
     * @param {?=} attrsIndex
     * @param {?=} localRefsIndex
     * @return {?}
     */


    function elementStartFirstCreatePass(index, tView, lView, _native12, name, attrsIndex, localRefsIndex) {
      ngDevMode && assertFirstCreatePass(tView);
      ngDevMode && ngDevMode.firstCreatePass++;
      /** @type {?} */

      var tViewConsts = tView.consts;
      /** @type {?} */

      var attrs = getConstant(tViewConsts, attrsIndex);
      /** @type {?} */

      var tNode = getOrCreateTNode(tView, lView[T_HOST], index, 3
      /* Element */
      , name, attrs);
      /** @type {?} */

      var hasDirectives = resolveDirectives(tView, lView, tNode, getConstant(tViewConsts, localRefsIndex));
      ngDevMode && warnAboutUnknownElement(tView, lView, _native12, tNode, hasDirectives);

      if (tNode.mergedAttrs !== null) {
        computeStaticStyling(tNode, tNode.mergedAttrs);
      }

      if (tView.queries !== null) {
        tView.queries.elementStart(tView, tNode);
      }

      return tNode;
    }
    /**
     * Create DOM element. The instruction must later be followed by `elementEnd()` call.
     *
     * \@codeGenApi
     * @param {?} index Index of the element in the LView array
     * @param {?} name Name of the DOM Node
     * @param {?=} attrsIndex Index of the element's attributes in the `consts` array.
     * @param {?=} localRefsIndex Index of the element's local references in the `consts` array.
     *
     * Attributes and localRefs are passed as an array of strings where elements with an even index
     * hold an attribute name and elements with an odd index hold an attribute value, ex.:
     * ['id', 'warning5', 'class', 'alert']
     *
     * @return {?}
     */


    function ɵɵelementStart(index, name, attrsIndex, localRefsIndex) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var tView = getTView();
      /** @type {?} */

      var adjustedIndex = HEADER_OFFSET + index;
      ngDevMode && assertEqual(getBindingIndex(), tView.bindingStartIndex, 'elements should be created before any bindings');
      ngDevMode && ngDevMode.rendererCreateElement++;
      ngDevMode && assertDataInRange(lView, adjustedIndex);
      /** @type {?} */

      var renderer = lView[RENDERER];
      /** @type {?} */

      var _native13 = lView[adjustedIndex] = elementCreate(name, renderer, getNamespace());
      /** @type {?} */


      var tNode = tView.firstCreatePass ? elementStartFirstCreatePass(index, tView, lView, _native13, name, attrsIndex, localRefsIndex) :
      /** @type {?} */
      tView.data[adjustedIndex];
      setPreviousOrParentTNode(tNode, true);
      /** @type {?} */

      var mergedAttrs = tNode.mergedAttrs;

      if (mergedAttrs !== null) {
        setUpAttributes(renderer, _native13, mergedAttrs);
      }
      /** @type {?} */


      var classes = tNode.classes;

      if (classes !== null) {
        writeDirectClass(renderer, _native13, classes);
      }
      /** @type {?} */


      var styles = tNode.styles;

      if (styles !== null) {
        writeDirectStyle(renderer, _native13, styles);
      }

      appendChild(tView, lView, _native13, tNode); // any immediate children of a component or template container must be pre-emptively
      // monkey-patched with the component view data so that the element can be inspected
      // later on using any element discovery utility methods (see `element_discovery.ts`)

      if (getElementDepthCount() === 0) {
        attachPatchData(_native13, lView);
      }

      increaseElementDepthCount();

      if (isDirectiveHost(tNode)) {
        createDirectivesInstances(tView, lView, tNode);
        executeContentQueries(tView, tNode, lView);
      }

      if (localRefsIndex !== null) {
        saveResolvedLocalsInData(lView, tNode);
      }
    }
    /**
     * Mark the end of the element.
     *
     * \@codeGenApi
     * @return {?}
     */


    function ɵɵelementEnd() {
      /** @type {?} */
      var previousOrParentTNode = getPreviousOrParentTNode();
      ngDevMode && assertDefined(previousOrParentTNode, 'No parent node to close.');

      if (getIsParent()) {
        setIsNotParent();
      } else {
        ngDevMode && assertHasParent(getPreviousOrParentTNode());
        previousOrParentTNode =
        /** @type {?} */
        previousOrParentTNode.parent;
        setPreviousOrParentTNode(previousOrParentTNode, false);
      }
      /** @type {?} */


      var tNode = previousOrParentTNode;
      ngDevMode && assertNodeType(tNode, 3
      /* Element */
      );
      decreaseElementDepthCount();
      /** @type {?} */

      var tView = getTView();

      if (tView.firstCreatePass) {
        registerPostOrderHooks(tView, previousOrParentTNode);

        if (isContentQueryHost(previousOrParentTNode)) {
          /** @type {?} */
          tView.queries.elementEnd(previousOrParentTNode);
        }
      }

      if (tNode.classes !== null && hasClassInput(tNode)) {
        setDirectiveInputsWhichShadowsStyling(tView, tNode, getLView(), tNode.classes, true);
      }

      if (tNode.styles !== null && hasStyleInput(tNode)) {
        setDirectiveInputsWhichShadowsStyling(tView, tNode, getLView(), tNode.styles, false);
      }
    }
    /**
     * Creates an empty element using {\@link elementStart} and {\@link elementEnd}
     *
     * \@codeGenApi
     * @param {?} index Index of the element in the data array
     * @param {?} name Name of the DOM Node
     * @param {?=} attrsIndex Index of the element's attributes in the `consts` array.
     * @param {?=} localRefsIndex Index of the element's local references in the `consts` array.
     *
     * @return {?}
     */


    function ɵɵelement(index, name, attrsIndex, localRefsIndex) {
      ɵɵelementStart(index, name, attrsIndex, localRefsIndex);
      ɵɵelementEnd();
    }
    /**
     * @param {?} tView
     * @param {?} lView
     * @param {?} element
     * @param {?} tNode
     * @param {?} hasDirectives
     * @return {?}
     */


    function warnAboutUnknownElement(tView, lView, element, tNode, hasDirectives) {
      /** @type {?} */
      var schemas = tView.schemas; // If `schemas` is set to `null`, that's an indication that this Component was compiled in AOT
      // mode where this check happens at compile time. In JIT mode, `schemas` is always present and
      // defined as an array (as an empty array in case `schemas` field is not defined) and we should
      // execute the check below.

      if (schemas === null) return;
      /** @type {?} */

      var tagName = tNode.tagName; // If the element matches any directive, it's considered as valid.

      if (!hasDirectives && tagName !== null) {
        // The element is unknown if it's an instance of HTMLUnknownElement or it isn't registered
        // as a custom element. Note that unknown elements with a dash in their name won't be instances
        // of HTMLUnknownElement in browsers that support web components.

        /** @type {?} */
        var isUnknown = // Note that we can't check for `typeof HTMLUnknownElement === 'function'`,
        // because while most browsers return 'function', IE returns 'object'.
        typeof HTMLUnknownElement !== 'undefined' && HTMLUnknownElement && element instanceof HTMLUnknownElement || typeof customElements !== 'undefined' && tagName.indexOf('-') > -1 && !customElements.get(tagName);

        if (isUnknown && !matchingSchemas(tView, lView, tagName)) {
          /** @type {?} */
          var warning = "'".concat(tagName, "' is not a known element:\n");
          warning += "1. If '".concat(tagName, "' is an Angular component, then verify that it is part of this module.\n");

          if (tagName && tagName.indexOf('-') > -1) {
            warning += "2. If '".concat(tagName, "' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.");
          } else {
            warning += "2. To allow any element add 'NO_ERRORS_SCHEMA' to the '@NgModule.schemas' of this component.";
          }

          console.warn(warning);
        }
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/element_container.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} index
     * @param {?} tView
     * @param {?} lView
     * @param {?=} attrsIndex
     * @param {?=} localRefsIndex
     * @return {?}
     */


    function elementContainerStartFirstCreatePass(index, tView, lView, attrsIndex, localRefsIndex) {
      ngDevMode && ngDevMode.firstCreatePass++;
      /** @type {?} */

      var tViewConsts = tView.consts;
      /** @type {?} */

      var attrs = getConstant(tViewConsts, attrsIndex);
      /** @type {?} */

      var tNode = getOrCreateTNode(tView, lView[T_HOST], index, 4
      /* ElementContainer */
      , 'ng-container', attrs); // While ng-container doesn't necessarily support styling, we use the style context to identify
      // and execute directives on the ng-container.

      if (attrs !== null) {
        computeStaticStyling(tNode, attrs);
      }
      /** @type {?} */


      var localRefs = getConstant(tViewConsts, localRefsIndex);
      resolveDirectives(tView, lView, tNode, localRefs);

      if (tView.queries !== null) {
        tView.queries.elementStart(tView, tNode);
      }

      return tNode;
    }
    /**
     * Creates a logical container for other nodes (<ng-container>) backed by a comment node in the DOM.
     * The instruction must later be followed by `elementContainerEnd()` call.
     *
     * \@codeGenApi
     * @param {?} index Index of the element in the LView array
     * @param {?=} attrsIndex Index of the container attributes in the `consts` array.
     * @param {?=} localRefsIndex Index of the container's local references in the `consts` array.
     *
     * Even if this instruction accepts a set of attributes no actual attribute values are propagated to
     * the DOM (as a comment node can't have attributes). Attributes are here only for directive
     * matching purposes and setting initial inputs of directives.
     *
     * @return {?}
     */


    function ɵɵelementContainerStart(index, attrsIndex, localRefsIndex) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var tView = getTView();
      /** @type {?} */

      var adjustedIndex = index + HEADER_OFFSET;
      ngDevMode && assertDataInRange(lView, adjustedIndex);
      ngDevMode && assertEqual(getBindingIndex(), tView.bindingStartIndex, 'element containers should be created before any bindings');
      /** @type {?} */

      var tNode = tView.firstCreatePass ? elementContainerStartFirstCreatePass(index, tView, lView, attrsIndex, localRefsIndex) :
      /** @type {?} */
      tView.data[adjustedIndex];
      setPreviousOrParentTNode(tNode, true);
      ngDevMode && ngDevMode.rendererCreateComment++;
      /** @type {?} */

      var _native14 = lView[adjustedIndex] = lView[RENDERER].createComment(ngDevMode ? 'ng-container' : '');

      appendChild(tView, lView, _native14, tNode);
      attachPatchData(_native14, lView);

      if (isDirectiveHost(tNode)) {
        createDirectivesInstances(tView, lView, tNode);
        executeContentQueries(tView, tNode, lView);
      }

      if (localRefsIndex != null) {
        saveResolvedLocalsInData(lView, tNode);
      }
    }
    /**
     * Mark the end of the <ng-container>.
     *
     * \@codeGenApi
     * @return {?}
     */


    function ɵɵelementContainerEnd() {
      /** @type {?} */
      var previousOrParentTNode = getPreviousOrParentTNode();
      /** @type {?} */

      var tView = getTView();

      if (getIsParent()) {
        setIsNotParent();
      } else {
        ngDevMode && assertHasParent(previousOrParentTNode);
        previousOrParentTNode =
        /** @type {?} */
        previousOrParentTNode.parent;
        setPreviousOrParentTNode(previousOrParentTNode, false);
      }

      ngDevMode && assertNodeType(previousOrParentTNode, 4
      /* ElementContainer */
      );

      if (tView.firstCreatePass) {
        registerPostOrderHooks(tView, previousOrParentTNode);

        if (isContentQueryHost(previousOrParentTNode)) {
          /** @type {?} */
          tView.queries.elementEnd(previousOrParentTNode);
        }
      }
    }
    /**
     * Creates an empty logical container using {\@link elementContainerStart}
     * and {\@link elementContainerEnd}
     *
     * \@codeGenApi
     * @param {?} index Index of the element in the LView array
     * @param {?=} attrsIndex Index of the container attributes in the `consts` array.
     * @param {?=} localRefsIndex Index of the container's local references in the `consts` array.
     *
     * @return {?}
     */


    function ɵɵelementContainer(index, attrsIndex, localRefsIndex) {
      ɵɵelementContainerStart(index, attrsIndex, localRefsIndex);
      ɵɵelementContainerEnd();
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/embedded_view.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Marks the start of an embedded view.
     *
     * \@codeGenApi
     * @param {?} viewBlockId The ID of this view
     * @param {?} decls
     * @param {?} vars
     * @return {?} boolean Whether or not this view is in creation mode
     *
     */


    function ɵɵembeddedViewStart(viewBlockId, decls, vars) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var previousOrParentTNode = getPreviousOrParentTNode(); // The previous node can be a view node if we are processing an inline for loop

      /** @type {?} */

      var containerTNode = previousOrParentTNode.type === 2
      /* View */
      ?
      /** @type {?} */
      previousOrParentTNode.parent : previousOrParentTNode;
      /** @type {?} */

      var lContainer =
      /** @type {?} */
      lView[containerTNode.index];
      ngDevMode && assertNodeType(containerTNode, 0
      /* Container */
      );
      /** @type {?} */

      var viewToRender = scanForView(lContainer, getLContainerActiveIndex(lContainer), viewBlockId);

      if (viewToRender) {
        setIsParent();
        enterView(viewToRender, viewToRender[TVIEW].node);
      } else {
        // When we create a new LView, we always reset the state of the instructions.
        viewToRender = createLView(lView, getOrCreateEmbeddedTView(viewBlockId, decls, vars,
        /** @type {?} */
        containerTNode), null, 16
        /* CheckAlways */
        , null, null);
        /** @type {?} */

        var tParentNode = getIsParent() ? previousOrParentTNode : previousOrParentTNode && previousOrParentTNode.parent;
        assignTViewNodeToLView(viewToRender[TVIEW], tParentNode, viewBlockId, viewToRender);
        enterView(viewToRender, viewToRender[TVIEW].node);
      }

      if (lContainer) {
        if (isCreationMode(viewToRender)) {
          // it is a new view, insert it into collection of views for a given container
          insertView(viewToRender[TVIEW], viewToRender, lContainer, getLContainerActiveIndex(lContainer));
        }

        lContainer[ACTIVE_INDEX] += 2
        /* INCREMENT */
        ;
      }

      return isCreationMode(viewToRender) ? 1
      /* Create */
      | 2
      /* Update */
      : 2
      /* Update */
      ;
    }
    /**
     * Initialize the TView (e.g. static data) for the active embedded view.
     *
     * Each embedded view block must create or retrieve its own TView. Otherwise, the embedded view's
     * static data for a particular node would overwrite the static data for a node in the view above
     * it with the same index (since it's in the same template).
     *
     * @param {?} viewIndex The index of the TView in TNode.tViews
     * @param {?} decls The number of nodes, local refs, and pipes in this template
     * @param {?} vars The number of bindings and pure function bindings in this template
     * @param {?} parent
     * @return {?} TView
     */


    function getOrCreateEmbeddedTView(viewIndex, decls, vars, parent) {
      /** @type {?} */
      var tView = getLView()[TVIEW];
      ngDevMode && assertNodeType(parent, 0
      /* Container */
      );
      /** @type {?} */

      var containerTViews =
      /** @type {?} */
      parent.tViews;
      ngDevMode && assertDefined(containerTViews, 'TView expected');
      ngDevMode && assertEqual(Array.isArray(containerTViews), true, 'TViews should be in an array');

      if (viewIndex >= containerTViews.length || containerTViews[viewIndex] == null) {
        containerTViews[viewIndex] = createTView(2
        /* Embedded */
        , viewIndex, null, decls, vars, tView.directiveRegistry, tView.pipeRegistry, null, null, tView.consts);
      }

      return containerTViews[viewIndex];
    }
    /**
     * Looks for a view with a given view block id inside a provided LContainer.
     * Removes views that need to be deleted in the process.
     *
     * @param {?} lContainer to search for views
     * @param {?} startIdx starting index in the views array to search from
     * @param {?} viewBlockId exact view block id to look for
     * @return {?}
     */


    function scanForView(lContainer, startIdx, viewBlockId) {
      for (var i = startIdx + CONTAINER_HEADER_OFFSET; i < lContainer.length; i++) {
        /** @type {?} */
        var viewAtPositionId = lContainer[i][TVIEW].id;

        if (viewAtPositionId === viewBlockId) {
          return lContainer[i];
        } else if (viewAtPositionId < viewBlockId) {
          // found a view that should not be at this position - remove
          removeView(lContainer, i - CONTAINER_HEADER_OFFSET);
        } else {
          // found a view with id greater than the one we are searching for
          // which means that required view doesn't exist and can't be found at
          // later positions in the views array - stop the searchdef.cont here
          break;
        }
      }

      return null;
    }
    /**
     * Marks the end of an embedded view.
     *
     * \@codeGenApi
     * @return {?}
     */


    function ɵɵembeddedViewEnd() {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var tView = getTView();
      /** @type {?} */

      var viewHost = lView[T_HOST];
      /** @type {?} */

      var context = lView[CONTEXT];

      if (isCreationMode(lView)) {
        renderView(tView, lView, context); // creation mode pass
      }

      refreshView(tView, lView, tView.template, context); // update mode pass
      // update mode pass

      /** @type {?} */

      var lContainer =
      /** @type {?} */
      lView[PARENT];
      ngDevMode && assertLContainerOrUndefined(lContainer);
      leaveView();
      setPreviousOrParentTNode(
      /** @type {?} */
      viewHost, false);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/get_current_view.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Returns the current OpaqueViewState instance.
     *
     * Used in conjunction with the restoreView() instruction to save a snapshot
     * of the current view and restore it when listeners are invoked. This allows
     * walking the declaration view tree in listeners to get vars from parent views.
     *
     * \@codeGenApi
     * @return {?}
     */


    function ɵɵgetCurrentView() {
      return (
        /** @type {?} */

        /** @type {?} */
        getLView()
      );
    }
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Determine if the argument is shaped like a Promise
     */


    function isPromise(obj) {
      // allow any Promise/A+ compliant thenable.
      // It's up to the caller to ensure that obj.then conforms to the spec
      return !!obj && typeof obj.then === 'function';
    }
    /**
     * Determine if the argument is an Observable
     */


    function isObservable(obj) {
      // TODO: use isObservable once we update pass rxjs 6.1
      // https://github.com/ReactiveX/rxjs/blob/master/CHANGELOG.md#610-2018-05-03
      return !!obj && typeof obj.subscribe === 'function';
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/listener.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Adds an event listener to the current node.
     *
     * If an output exists on one of the node's directives, it also subscribes to the output
     * and saves the subscription for later cleanup.
     *
     * \@codeGenApi
     * @param {?} eventName Name of the event
     * @param {?} listenerFn The function to be called when event emits
     * @param {?=} useCapture Whether or not to use capture in event listener
     * @param {?=} eventTargetResolver Function that returns global target information in case this listener
     * should be attached to a global object like window, document or body
     *
     * @return {?}
     */


    function ɵɵlistener(eventName, listenerFn) {
      var useCapture = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
      var eventTargetResolver = arguments.length > 3 ? arguments[3] : undefined;

      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var tView = getTView();
      /** @type {?} */

      var tNode = getPreviousOrParentTNode();
      listenerInternal(tView, lView, lView[RENDERER], tNode, eventName, listenerFn, useCapture, eventTargetResolver);
      return ɵɵlistener;
    }
    /**
     * Registers a synthetic host listener (e.g. `(\@foo.start)`) on a component or directive.
     *
     * This instruction is for compatibility purposes and is designed to ensure that a
     * synthetic host listener (e.g. `\@HostListener('\@foo.start')`) properly gets rendered
     * in the component's renderer. Normally all host listeners are evaluated with the
     * parent component's renderer, but, in the case of animation \@triggers, they need
     * to be evaluated with the sub component's renderer (because that's where the
     * animation triggers are defined).
     *
     * Do not use this instruction as a replacement for `listener`. This instruction
     * only exists to ensure compatibility with the ViewEngine's host binding behavior.
     *
     * \@codeGenApi
     * @param {?} eventName Name of the event
     * @param {?} listenerFn The function to be called when event emits
     * @param {?=} useCapture Whether or not to use capture in event listener
     * @param {?=} eventTargetResolver Function that returns global target information in case this listener
     * should be attached to a global object like window, document or body
     *
     * @return {?}
     */


    function ɵɵcomponentHostSyntheticListener(eventName, listenerFn) {
      var useCapture = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
      var eventTargetResolver = arguments.length > 3 ? arguments[3] : undefined;

      /** @type {?} */
      var tNode = getPreviousOrParentTNode();
      /** @type {?} */

      var lView = getLView();
      /** @type {?} */

      var tView = getTView();
      /** @type {?} */

      var currentDef = getCurrentDirectiveDef(tView.data);
      /** @type {?} */

      var renderer = loadComponentRenderer(currentDef, tNode, lView);
      listenerInternal(tView, lView, renderer, tNode, eventName, listenerFn, useCapture, eventTargetResolver);
      return ɵɵcomponentHostSyntheticListener;
    }
    /**
     * A utility function that checks if a given element has already an event handler registered for an
     * event with a specified name. The TView.cleanup data structure is used to find out which events
     * are registered for a given element.
     * @param {?} tView
     * @param {?} lView
     * @param {?} eventName
     * @param {?} tNodeIdx
     * @return {?}
     */


    function findExistingListener(tView, lView, eventName, tNodeIdx) {
      /** @type {?} */
      var tCleanup = tView.cleanup;

      if (tCleanup != null) {
        for (var i = 0; i < tCleanup.length - 1; i += 2) {
          /** @type {?} */
          var cleanupEventName = tCleanup[i];

          if (cleanupEventName === eventName && tCleanup[i + 1] === tNodeIdx) {
            // We have found a matching event name on the same node but it might not have been
            // registered yet, so we must explicitly verify entries in the LView cleanup data
            // structures.

            /** @type {?} */
            var lCleanup =
            /** @type {?} */
            lView[CLEANUP];
            /** @type {?} */

            var listenerIdxInLCleanup = tCleanup[i + 2];
            return lCleanup.length > listenerIdxInLCleanup ? lCleanup[listenerIdxInLCleanup] : null;
          } // TView.cleanup can have a mix of 4-elements entries (for event handler cleanups) or
          // 2-element entries (for directive and queries destroy hooks). As such we can encounter
          // blocks of 4 or 2 items in the tView.cleanup and this is why we iterate over 2 elements
          // first and jump another 2 elements if we detect listeners cleanup (4 elements). Also check
          // documentation of TView.cleanup for more details of this data structure layout.


          if (typeof cleanupEventName === 'string') {
            i += 2;
          }
        }
      }

      return null;
    }
    /**
     * @param {?} tView
     * @param {?} lView
     * @param {?} renderer
     * @param {?} tNode
     * @param {?} eventName
     * @param {?} listenerFn
     * @param {?=} useCapture
     * @param {?=} eventTargetResolver
     * @return {?}
     */


    function listenerInternal(tView, lView, renderer, tNode, eventName, listenerFn) {
      var useCapture = arguments.length > 6 && arguments[6] !== undefined ? arguments[6] : false;
      var eventTargetResolver = arguments.length > 7 ? arguments[7] : undefined;

      /** @type {?} */
      var isTNodeDirectiveHost = isDirectiveHost(tNode);
      /** @type {?} */

      var firstCreatePass = tView.firstCreatePass;
      /** @type {?} */

      var tCleanup = firstCreatePass && (tView.cleanup || (tView.cleanup = [])); // When the ɵɵlistener instruction was generated and is executed we know that there is either a
      // native listener or a directive output on this element. As such we we know that we will have to
      // register a listener and store its cleanup function on LView.

      /** @type {?} */

      var lCleanup = getLCleanup(lView);
      ngDevMode && assertNodeOfPossibleTypes(tNode, 3
      /* Element */
      , 0
      /* Container */
      , 4
      /* ElementContainer */
      );
      /** @type {?} */

      var processOutputs = true; // add native event listener - applicable to elements only

      if (tNode.type === 3
      /* Element */
      ) {
          /** @type {?} */
          var _native15 =
          /** @type {?} */
          getNativeByTNode(tNode, lView);
          /** @type {?} */


          var resolved = eventTargetResolver ? eventTargetResolver(_native15) :
          /** @type {?} */
          EMPTY_OBJ;
          /** @type {?} */

          var target = resolved.target || _native15;
          /** @type {?} */

          var lCleanupIndex = lCleanup.length;
          /** @type {?} */

          var idxOrTargetGetter = eventTargetResolver ?
          /**
          * @param {?} _lView
          * @return {?}
          */
          function (_lView) {
            return eventTargetResolver(unwrapRNode(_lView[tNode.index])).target;
          } : tNode.index; // In order to match current behavior, native DOM event listeners must be added for all
          // events (including outputs).

          if (isProceduralRenderer(renderer)) {
            // There might be cases where multiple directives on the same element try to register an event
            // handler function for the same event. In this situation we want to avoid registration of
            // several native listeners as each registration would be intercepted by NgZone and
            // trigger change detection. This would mean that a single user action would result in several
            // change detections being invoked. To avoid this situation we want to have only one call to
            // native handler registration (for the same element and same type of event).
            //
            // In order to have just one native event handler in presence of multiple handler functions,
            // we just register a first handler function as a native event listener and then chain
            // (coalesce) other handler functions on top of the first native handler function.

            /** @type {?} */
            var existingListener = null; // Please note that the coalescing described here doesn't happen for events specifying an
            // alternative target (ex. (document:click)) - this is to keep backward compatibility with the
            // view engine.
            // Also, we don't have to search for existing listeners is there are no directives
            // matching on a given node as we can't register multiple event handlers for the same event in
            // a template (this would mean having duplicate attributes).

            if (!eventTargetResolver && isTNodeDirectiveHost) {
              existingListener = findExistingListener(tView, lView, eventName, tNode.index);
            }

            if (existingListener !== null) {
              // Attach a new listener to coalesced listeners list, maintaining the order in which
              // listeners are registered. For performance reasons, we keep a reference to the last
              // listener in that list (in `__ngLastListenerFn__` field), so we can avoid going through
              // the entire set each time we need to add a new listener.

              /** @type {?} */
              var lastListenerFn =
              /** @type {?} */
              existingListener.__ngLastListenerFn__ || existingListener;
              lastListenerFn.__ngNextListenerFn__ = listenerFn;

              /** @type {?} */
              existingListener.__ngLastListenerFn__ = listenerFn;
              processOutputs = false;
            } else {
              // The first argument of `listen` function in Procedural Renderer is:
              // - either a target name (as a string) in case of global target (window, document, body)
              // - or element reference (in all other cases)
              listenerFn = wrapListener(tNode, lView, listenerFn, false
              /** preventDefault */
              );
              /** @type {?} */

              var cleanupFn = renderer.listen(resolved.name || target, eventName, listenerFn);
              ngDevMode && ngDevMode.rendererAddEventListener++;
              lCleanup.push(listenerFn, cleanupFn);
              tCleanup && tCleanup.push(eventName, idxOrTargetGetter, lCleanupIndex, lCleanupIndex + 1);
            }
          } else {
            listenerFn = wrapListener(tNode, lView, listenerFn, true
            /** preventDefault */
            );
            target.addEventListener(eventName, listenerFn, useCapture);
            ngDevMode && ngDevMode.rendererAddEventListener++;
            lCleanup.push(listenerFn);
            tCleanup && tCleanup.push(eventName, idxOrTargetGetter, lCleanupIndex, useCapture);
          }
        } // subscribe to directive outputs

      /** @type {?} */


      var outputs = tNode.outputs;
      /** @type {?} */

      var props;

      if (processOutputs && outputs !== null && (props = outputs[eventName])) {
        /** @type {?} */
        var propsLength = props.length;

        if (propsLength) {
          for (var i = 0; i < propsLength; i += 2) {
            /** @type {?} */
            var index =
            /** @type {?} */
            props[i];
            ngDevMode && assertDataInRange(lView, index);
            /** @type {?} */

            var minifiedName = props[i + 1];
            /** @type {?} */

            var directiveInstance = lView[index];
            /** @type {?} */

            var output = directiveInstance[minifiedName];

            if (ngDevMode && !isObservable(output)) {
              throw new Error("@Output ".concat(minifiedName, " not initialized in '").concat(directiveInstance.constructor.name, "'."));
            }
            /** @type {?} */


            var subscription = output.subscribe(listenerFn);
            /** @type {?} */

            var idx = lCleanup.length;
            lCleanup.push(listenerFn, subscription);
            tCleanup && tCleanup.push(eventName, tNode.index, idx, -(idx + 1));
          }
        }
      }
    }
    /**
     * @param {?} lView
     * @param {?} listenerFn
     * @param {?} e
     * @return {?}
     */


    function executeListenerWithErrorHandling(lView, listenerFn, e) {
      try {
        // Only explicitly returning false from a listener should preventDefault
        return listenerFn(e) !== false;
      } catch (error) {
        handleError(lView, error);
        return false;
      }
    }
    /**
     * Wraps an event listener with a function that marks ancestors dirty and prevents default behavior,
     * if applicable.
     *
     * @param {?} tNode The TNode associated with this listener
     * @param {?} lView The LView that contains this listener
     * @param {?} listenerFn The listener function to call
     * @param {?} wrapWithPreventDefault Whether or not to prevent default behavior
     * (the procedural renderer does this already, so in those cases, we should skip)
     * @return {?}
     */


    function wrapListener(tNode, lView, listenerFn, wrapWithPreventDefault) {
      // Note: we are performing most of the work in the listener function itself
      // to optimize listener registration.
      return (
        /**
        * @param {?} e
        * @return {?}
        */
        function wrapListenerIn_markDirtyAndPreventDefault(e) {
          // Ivy uses `Function` as a special token that allows us to unwrap the function
          // so that it can be invoked programmatically by `DebugNode.triggerEventHandler`.
          if (e === Function) {
            return listenerFn;
          } // In order to be backwards compatible with View Engine, events on component host nodes
          // must also mark the component view itself dirty (i.e. the view that it owns).

          /** @type {?} */


          var startView = tNode.flags & 2
          /* isComponentHost */
          ? getComponentLViewByIndex(tNode.index, lView) : lView; // See interfaces/view.ts for more on LViewFlags.ManualOnPush

          if ((lView[FLAGS] & 32
          /* ManualOnPush */
          ) === 0) {
            markViewDirty(startView);
          }
          /** @type {?} */


          var result = executeListenerWithErrorHandling(lView, listenerFn, e); // A just-invoked listener function might have coalesced listeners so we need to check for
          // their presence and invoke as needed.

          /** @type {?} */

          var nextListenerFn =
          /** @type {?} */
          wrapListenerIn_markDirtyAndPreventDefault.__ngNextListenerFn__;

          while (nextListenerFn) {
            // We should prevent default if any of the listeners explicitly return false
            result = executeListenerWithErrorHandling(lView, nextListenerFn, e) && result;
            nextListenerFn =
            /** @type {?} */
            nextListenerFn.__ngNextListenerFn__;
          }

          if (wrapWithPreventDefault && result === false) {
            e.preventDefault(); // Necessary for legacy browsers that don't support preventDefault (e.g. IE)

            e.returnValue = false;
          }

          return result;
        }
      );
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/namespace.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/next_context.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Retrieves a context at the level specified and saves it as the global, contextViewData.
     * Will get the next level up if level is not specified.
     *
     * This is used to save contexts of parent views so they can be bound in embedded views, or
     * in conjunction with reference() to bind a ref from a parent view.
     *
     * \@codeGenApi
     * @template T
     * @param {?=} level The relative level of the view from which to grab context compared to contextVewData
     * @return {?} context
     *
     */


    function ɵɵnextContext() {
      var level = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 1;
      return nextContextImpl(level);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/projection.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Checks a given node against matching projection slots and returns the
     * determined slot index. Returns "null" if no slot matched the given node.
     *
     * This function takes into account the parsed ngProjectAs selector from the
     * node's attributes. If present, it will check whether the ngProjectAs selector
     * matches any of the projection slot selectors.
     * @param {?} tNode
     * @param {?} projectionSlots
     * @return {?}
     */


    function matchingProjectionSlotIndex(tNode, projectionSlots) {
      /** @type {?} */
      var wildcardNgContentIndex = null;
      /** @type {?} */

      var ngProjectAsAttrVal = getProjectAsAttrValue(tNode);

      for (var i = 0; i < projectionSlots.length; i++) {
        /** @type {?} */
        var slotValue = projectionSlots[i]; // The last wildcard projection slot should match all nodes which aren't matching
        // any selector. This is necessary to be backwards compatible with view engine.

        if (slotValue === '*') {
          wildcardNgContentIndex = i;
          continue;
        } // If we ran into an `ngProjectAs` attribute, we should match its parsed selector
        // to the list of selectors, otherwise we fall back to matching against the node.


        if (ngProjectAsAttrVal === null ? isNodeMatchingSelectorList(tNode, slotValue,
        /* isProjectionMode */
        true) : isSelectorInSelectorList(ngProjectAsAttrVal, slotValue)) {
          return i; // first matching selector "captures" a given node
        }
      }

      return wildcardNgContentIndex;
    }
    /**
     * Instruction to distribute projectable nodes among <ng-content> occurrences in a given template.
     * It takes all the selectors from the entire component's template and decides where
     * each projected node belongs (it re-distributes nodes among "buckets" where each "bucket" is
     * backed by a selector).
     *
     * This function requires CSS selectors to be provided in 2 forms: parsed (by a compiler) and text,
     * un-parsed form.
     *
     * The parsed form is needed for efficient matching of a node against a given CSS selector.
     * The un-parsed, textual form is needed for support of the ngProjectAs attribute.
     *
     * Having a CSS selector in 2 different formats is not ideal, but alternatives have even more
     * drawbacks:
     * - having only a textual form would require runtime parsing of CSS selectors;
     * - we can't have only a parsed as we can't re-construct textual form from it (as entered by a
     * template author).
     *
     * \@codeGenApi
     * @param {?=} projectionSlots
     * @return {?}
     */


    function ɵɵprojectionDef(projectionSlots) {
      /** @type {?} */
      var componentNode =
      /** @type {?} */
      getLView()[DECLARATION_COMPONENT_VIEW][T_HOST];

      if (!componentNode.projection) {
        // If no explicit projection slots are defined, fall back to a single
        // projection slot with the wildcard selector.

        /** @type {?} */
        var numProjectionSlots = projectionSlots ? projectionSlots.length : 1;
        /** @type {?} */

        var projectionHeads = componentNode.projection = newArray(numProjectionSlots,
        /** @type {?} */

        /** @type {?} */
        null);
        /** @type {?} */

        var tails = projectionHeads.slice();
        /** @type {?} */

        var componentChild = componentNode.child;

        while (componentChild !== null) {
          /** @type {?} */
          var slotIndex = projectionSlots ? matchingProjectionSlotIndex(componentChild, projectionSlots) : 0;

          if (slotIndex !== null) {
            if (tails[slotIndex]) {
              /** @type {?} */
              tails[slotIndex].projectionNext = componentChild;
            } else {
              projectionHeads[slotIndex] = componentChild;
            }

            tails[slotIndex] = componentChild;
          }

          componentChild = componentChild.next;
        }
      }
    }
    /** @type {?} */


    var delayProjection = false;
    /**
     * @param {?} value
     * @return {?}
     */

    function setDelayProjection(value) {
      delayProjection = value;
    }
    /**
     * Inserts previously re-distributed projected nodes. This instruction must be preceded by a call
     * to the projectionDef instruction.
     *
     * \@codeGenApi
     * @param {?} nodeIndex
     * @param {?=} selectorIndex
     * @param {?=} attrs
     * @return {?}
     */


    function ɵɵprojection(nodeIndex) {
      var selectorIndex = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
      var attrs = arguments.length > 2 ? arguments[2] : undefined;

      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var tView = getTView();
      /** @type {?} */

      var tProjectionNode = getOrCreateTNode(tView, lView[T_HOST], nodeIndex, 1
      /* Projection */
      , null, attrs || null); // We can't use viewData[HOST_NODE] because projection nodes can be nested in embedded views.

      if (tProjectionNode.projection === null) tProjectionNode.projection = selectorIndex; // `<ng-content>` has no content

      setIsNotParent(); // We might need to delay the projection of nodes if they are in the middle of an i18n block

      if (!delayProjection) {
        // re-distribution of projectable nodes is stored on a component's view level
        applyProjection(tView, lView, tProjectionNode);
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/property_interpolation.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     *
     * Update an interpolated property on an element with a lone bound value
     *
     * Used when the value passed to a property has 1 interpolated value in it, an no additional text
     * surrounds that interpolated value:
     *
     * ```html
     * <div title="{{v0}}"></div>
     * ```
     *
     * Its compiled representation is::
     *
     * ```ts
     * ɵɵpropertyInterpolate('title', v0);
     * ```
     *
     * If the property name also exists as an input property on one of the element's directives,
     * the component property will be set instead of the element property. This check must
     * be conducted at runtime so child components that add new `\@Inputs` don't have to be re-compiled.
     *
     * \@codeGenApi
     * @param {?} propName The name of the property to update
     * @param {?} v0 Value checked for change.
     * @param {?=} sanitizer An optional sanitizer function
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵpropertyInterpolate(propName, v0, sanitizer) {
      ɵɵpropertyInterpolate1(propName, '', v0, '', sanitizer);
      return ɵɵpropertyInterpolate;
    }
    /**
     *
     * Update an interpolated property on an element with single bound value surrounded by text.
     *
     * Used when the value passed to a property has 1 interpolated value in it:
     *
     * ```html
     * <div title="prefix{{v0}}suffix"></div>
     * ```
     *
     * Its compiled representation is::
     *
     * ```ts
     * ɵɵpropertyInterpolate1('title', 'prefix', v0, 'suffix');
     * ```
     *
     * If the property name also exists as an input property on one of the element's directives,
     * the component property will be set instead of the element property. This check must
     * be conducted at runtime so child components that add new `\@Inputs` don't have to be re-compiled.
     *
     * \@codeGenApi
     * @param {?} propName The name of the property to update
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} sanitizer An optional sanitizer function
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵpropertyInterpolate1(propName, prefix, v0, suffix, sanitizer) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation1(lView, prefix, v0, suffix);

      if (interpolatedValue !== NO_CHANGE) {
        /** @type {?} */
        var tView = getTView();
        /** @type {?} */

        var tNode = getSelectedTNode();
        elementPropertyInternal(tView, tNode, lView, propName, interpolatedValue, lView[RENDERER], sanitizer, false);
        ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, getBindingIndex() - 1, prefix, suffix);
      }

      return ɵɵpropertyInterpolate1;
    }
    /**
     *
     * Update an interpolated property on an element with 2 bound values surrounded by text.
     *
     * Used when the value passed to a property has 2 interpolated values in it:
     *
     * ```html
     * <div title="prefix{{v0}}-{{v1}}suffix"></div>
     * ```
     *
     * Its compiled representation is::
     *
     * ```ts
     * ɵɵpropertyInterpolate2('title', 'prefix', v0, '-', v1, 'suffix');
     * ```
     *
     * If the property name also exists as an input property on one of the element's directives,
     * the component property will be set instead of the element property. This check must
     * be conducted at runtime so child components that add new `\@Inputs` don't have to be re-compiled.
     *
     * \@codeGenApi
     * @param {?} propName The name of the property to update
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} sanitizer An optional sanitizer function
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵpropertyInterpolate2(propName, prefix, v0, i0, v1, suffix, sanitizer) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation2(lView, prefix, v0, i0, v1, suffix);

      if (interpolatedValue !== NO_CHANGE) {
        /** @type {?} */
        var tView = getTView();
        /** @type {?} */

        var tNode = getSelectedTNode();
        elementPropertyInternal(tView, tNode, lView, propName, interpolatedValue, lView[RENDERER], sanitizer, false);
        ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, getBindingIndex() - 2, prefix, i0, suffix);
      }

      return ɵɵpropertyInterpolate2;
    }
    /**
     *
     * Update an interpolated property on an element with 3 bound values surrounded by text.
     *
     * Used when the value passed to a property has 3 interpolated values in it:
     *
     * ```html
     * <div title="prefix{{v0}}-{{v1}}-{{v2}}suffix"></div>
     * ```
     *
     * Its compiled representation is::
     *
     * ```ts
     * ɵɵpropertyInterpolate3(
     * 'title', 'prefix', v0, '-', v1, '-', v2, 'suffix');
     * ```
     *
     * If the property name also exists as an input property on one of the element's directives,
     * the component property will be set instead of the element property. This check must
     * be conducted at runtime so child components that add new `\@Inputs` don't have to be re-compiled.
     *
     * \@codeGenApi
     * @param {?} propName The name of the property to update
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} sanitizer An optional sanitizer function
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵpropertyInterpolate3(propName, prefix, v0, i0, v1, i1, v2, suffix, sanitizer) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation3(lView, prefix, v0, i0, v1, i1, v2, suffix);

      if (interpolatedValue !== NO_CHANGE) {
        /** @type {?} */
        var tView = getTView();
        /** @type {?} */

        var tNode = getSelectedTNode();
        elementPropertyInternal(tView, tNode, lView, propName, interpolatedValue, lView[RENDERER], sanitizer, false);
        ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, getBindingIndex() - 3, prefix, i0, i1, suffix);
      }

      return ɵɵpropertyInterpolate3;
    }
    /**
     *
     * Update an interpolated property on an element with 4 bound values surrounded by text.
     *
     * Used when the value passed to a property has 4 interpolated values in it:
     *
     * ```html
     * <div title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}suffix"></div>
     * ```
     *
     * Its compiled representation is::
     *
     * ```ts
     * ɵɵpropertyInterpolate4(
     * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, 'suffix');
     * ```
     *
     * If the property name also exists as an input property on one of the element's directives,
     * the component property will be set instead of the element property. This check must
     * be conducted at runtime so child components that add new `\@Inputs` don't have to be re-compiled.
     *
     * \@codeGenApi
     * @param {?} propName The name of the property to update
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} sanitizer An optional sanitizer function
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵpropertyInterpolate4(propName, prefix, v0, i0, v1, i1, v2, i2, v3, suffix, sanitizer) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation4(lView, prefix, v0, i0, v1, i1, v2, i2, v3, suffix);

      if (interpolatedValue !== NO_CHANGE) {
        /** @type {?} */
        var tView = getTView();
        /** @type {?} */

        var tNode = getSelectedTNode();
        elementPropertyInternal(tView, tNode, lView, propName, interpolatedValue, lView[RENDERER], sanitizer, false);
        ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, getBindingIndex() - 4, prefix, i0, i1, i2, suffix);
      }

      return ɵɵpropertyInterpolate4;
    }
    /**
     *
     * Update an interpolated property on an element with 5 bound values surrounded by text.
     *
     * Used when the value passed to a property has 5 interpolated values in it:
     *
     * ```html
     * <div title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}suffix"></div>
     * ```
     *
     * Its compiled representation is::
     *
     * ```ts
     * ɵɵpropertyInterpolate5(
     * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, 'suffix');
     * ```
     *
     * If the property name also exists as an input property on one of the element's directives,
     * the component property will be set instead of the element property. This check must
     * be conducted at runtime so child components that add new `\@Inputs` don't have to be re-compiled.
     *
     * \@codeGenApi
     * @param {?} propName The name of the property to update
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} i3 Static value used for concatenation only.
     * @param {?} v4 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} sanitizer An optional sanitizer function
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵpropertyInterpolate5(propName, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix, sanitizer) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation5(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix);

      if (interpolatedValue !== NO_CHANGE) {
        /** @type {?} */
        var tView = getTView();
        /** @type {?} */

        var tNode = getSelectedTNode();
        elementPropertyInternal(tView, tNode, lView, propName, interpolatedValue, lView[RENDERER], sanitizer, false);
        ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, getBindingIndex() - 5, prefix, i0, i1, i2, i3, suffix);
      }

      return ɵɵpropertyInterpolate5;
    }
    /**
     *
     * Update an interpolated property on an element with 6 bound values surrounded by text.
     *
     * Used when the value passed to a property has 6 interpolated values in it:
     *
     * ```html
     * <div title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}suffix"></div>
     * ```
     *
     * Its compiled representation is::
     *
     * ```ts
     * ɵɵpropertyInterpolate6(
     *    'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, 'suffix');
     * ```
     *
     * If the property name also exists as an input property on one of the element's directives,
     * the component property will be set instead of the element property. This check must
     * be conducted at runtime so child components that add new `\@Inputs` don't have to be re-compiled.
     *
     * \@codeGenApi
     * @param {?} propName The name of the property to update
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} i3 Static value used for concatenation only.
     * @param {?} v4 Value checked for change.
     * @param {?} i4 Static value used for concatenation only.
     * @param {?} v5 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} sanitizer An optional sanitizer function
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵpropertyInterpolate6(propName, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix, sanitizer) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation6(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix);

      if (interpolatedValue !== NO_CHANGE) {
        /** @type {?} */
        var tView = getTView();
        /** @type {?} */

        var tNode = getSelectedTNode();
        elementPropertyInternal(tView, tNode, lView, propName, interpolatedValue, lView[RENDERER], sanitizer, false);
        ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, getBindingIndex() - 6, prefix, i0, i1, i2, i3, i4, suffix);
      }

      return ɵɵpropertyInterpolate6;
    }
    /**
     *
     * Update an interpolated property on an element with 7 bound values surrounded by text.
     *
     * Used when the value passed to a property has 7 interpolated values in it:
     *
     * ```html
     * <div title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}suffix"></div>
     * ```
     *
     * Its compiled representation is::
     *
     * ```ts
     * ɵɵpropertyInterpolate7(
     *    'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, 'suffix');
     * ```
     *
     * If the property name also exists as an input property on one of the element's directives,
     * the component property will be set instead of the element property. This check must
     * be conducted at runtime so child components that add new `\@Inputs` don't have to be re-compiled.
     *
     * \@codeGenApi
     * @param {?} propName The name of the property to update
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} i3 Static value used for concatenation only.
     * @param {?} v4 Value checked for change.
     * @param {?} i4 Static value used for concatenation only.
     * @param {?} v5 Value checked for change.
     * @param {?} i5 Static value used for concatenation only.
     * @param {?} v6 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} sanitizer An optional sanitizer function
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵpropertyInterpolate7(propName, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix, sanitizer) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation7(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix);

      if (interpolatedValue !== NO_CHANGE) {
        /** @type {?} */
        var tView = getTView();
        /** @type {?} */

        var tNode = getSelectedTNode();
        elementPropertyInternal(tView, tNode, lView, propName, interpolatedValue, lView[RENDERER], sanitizer, false);
        ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, getBindingIndex() - 7, prefix, i0, i1, i2, i3, i4, i5, suffix);
      }

      return ɵɵpropertyInterpolate7;
    }
    /**
     *
     * Update an interpolated property on an element with 8 bound values surrounded by text.
     *
     * Used when the value passed to a property has 8 interpolated values in it:
     *
     * ```html
     * <div title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}suffix"></div>
     * ```
     *
     * Its compiled representation is::
     *
     * ```ts
     * ɵɵpropertyInterpolate8(
     *  'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, 'suffix');
     * ```
     *
     * If the property name also exists as an input property on one of the element's directives,
     * the component property will be set instead of the element property. This check must
     * be conducted at runtime so child components that add new `\@Inputs` don't have to be re-compiled.
     *
     * \@codeGenApi
     * @param {?} propName The name of the property to update
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} i3 Static value used for concatenation only.
     * @param {?} v4 Value checked for change.
     * @param {?} i4 Static value used for concatenation only.
     * @param {?} v5 Value checked for change.
     * @param {?} i5 Static value used for concatenation only.
     * @param {?} v6 Value checked for change.
     * @param {?} i6 Static value used for concatenation only.
     * @param {?} v7 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} sanitizer An optional sanitizer function
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵpropertyInterpolate8(propName, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix, sanitizer) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation8(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix);

      if (interpolatedValue !== NO_CHANGE) {
        /** @type {?} */
        var tView = getTView();
        /** @type {?} */

        var tNode = getSelectedTNode();
        elementPropertyInternal(tView, tNode, lView, propName, interpolatedValue, lView[RENDERER], sanitizer, false);
        ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, getBindingIndex() - 8, prefix, i0, i1, i2, i3, i4, i5, i6, suffix);
      }

      return ɵɵpropertyInterpolate8;
    }
    /**
     * Update an interpolated property on an element with 9 or more bound values surrounded by text.
     *
     * Used when the number of interpolated values exceeds 8.
     *
     * ```html
     * <div
     *  title="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}-{{v8}}-{{v9}}suffix"></div>
     * ```
     *
     * Its compiled representation is::
     *
     * ```ts
     * ɵɵpropertyInterpolateV(
     *  'title', ['prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, '-', v9,
     *  'suffix']);
     * ```
     *
     * If the property name also exists as an input property on one of the element's directives,
     * the component property will be set instead of the element property. This check must
     * be conducted at runtime so child components that add new `\@Inputs` don't have to be re-compiled.
     *
     * \@codeGenApi
     * @param {?} propName The name of the property to update.
     * @param {?} values The collection of values and the strings inbetween those values, beginning with a
     * string prefix and ending with a string suffix.
     * (e.g. `['prefix', value0, '-', value1, '-', value2, ..., value99, 'suffix']`)
     * @param {?=} sanitizer An optional sanitizer function
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵpropertyInterpolateV(propName, values, sanitizer) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolationV(lView, values);

      if (interpolatedValue !== NO_CHANGE) {
        /** @type {?} */
        var tView = getTView();
        /** @type {?} */

        var tNode = getSelectedTNode();
        elementPropertyInternal(tView, tNode, lView, propName, interpolatedValue, lView[RENDERER], sanitizer, false);

        if (ngDevMode) {
          /** @type {?} */
          var interpolationInBetween = [values[0]];

          for (var i = 2; i < values.length; i += 2) {
            interpolationInBetween.push(values[i]);
          }

          storePropertyBindingMetadata.apply(void 0, [tView.data, tNode, propName, getBindingIndex() - interpolationInBetween.length + 1].concat(interpolationInBetween));
        }
      }

      return ɵɵpropertyInterpolateV;
    }
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * This file contains reuseable "empty" symbols that can be used as default return values
     * in different parts of the rendering code. Because the same symbols are returned, this
     * allows for identity checks against these values to be consistently used by the framework
     * code.
     */


    var EMPTY_OBJ$1 = {};
    var EMPTY_ARRAY$3 = []; // freezing the values prevents any code from accidentally inserting new values in

    if ((typeof ngDevMode === 'undefined' || ngDevMode) && initNgDevMode()) {
      // These property accesses can be ignored because ngDevMode will be set to false
      // when optimizing code and the whole if statement will be dropped.
      // tslint:disable-next-line:no-toplevel-property-access
      Object.freeze(EMPTY_OBJ$1); // tslint:disable-next-line:no-toplevel-property-access

      Object.freeze(EMPTY_ARRAY$3);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/styling/style_binding_list.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * NOTE: The word `styling` is used interchangeably as style or class styling.
     *
     * This file contains code to link styling instructions together so that they can be replayed in
     * priority order. The file exists because Ivy styling instruction execution order does not match
     * that of the priority order. The purpose of this code is to create a linked list so that the
     * instructions can be traversed in priority order when computing the styles.
     *
     * Assume we are dealing with the following code:
     * ```
     * \@Component({
     *   template: `
     *     <my-cmp [style]=" {color: '#001'} "
     *             [style.color]=" #002 "
     *             dir-style-color-1
     *             dir-style-color-2> `
     * })
     * class ExampleComponent {
     *   static ngComp = ... {
     *     ...
     *     // Compiler ensures that `ɵɵstyleProp` is after `ɵɵstyleMap`
     *     ɵɵstyleMap({color: '#001'});
     *     ɵɵstyleProp('color', '#002');
     *     ...
     *   }
     * }
     *
     * \@Directive({
     *   selector: `[dir-style-color-1]',
     * })
     * class Style1Directive {
     * \@HostBinding('style') style = {color: '#005'};
     * \@HostBinding('style.color') color = '#006';
     *
     *   static ngDir = ... {
     *     ...
     *     // Compiler ensures that `ɵɵstyleProp` is after `ɵɵstyleMap`
     *     ɵɵstyleMap({color: '#005'});
     *     ɵɵstyleProp('color', '#006');
     *     ...
     *   }
     * }
     *
     * \@Directive({
     *   selector: `[dir-style-color-2]',
     * })
     * class Style2Directive {
     * \@HostBinding('style') style = {color: '#007'};
     * \@HostBinding('style.color') color = '#008';
     *
     *   static ngDir = ... {
     *     ...
     *     // Compiler ensures that `ɵɵstyleProp` is after `ɵɵstyleMap`
     *     ɵɵstyleMap({color: '#007'});
     *     ɵɵstyleProp('color', '#008');
     *     ...
     *   }
     * }
     *
     * \@Directive({
     *   selector: `my-cmp',
     * })
     * class MyComponent {
     * \@HostBinding('style') style = {color: '#003'};
     * \@HostBinding('style.color') color = '#004';
     *
     *   static ngComp = ... {
     *     ...
     *     // Compiler ensures that `ɵɵstyleProp` is after `ɵɵstyleMap`
     *     ɵɵstyleMap({color: '#003'});
     *     ɵɵstyleProp('color', '#004');
     *     ...
     *   }
     * }
     * ```
     *
     * The Order of instruction execution is:
     *
     * NOTE: the comment binding location is for illustrative purposes only.
     *
     * ```
     * // Template: (ExampleComponent)
     *     ɵɵstyleMap({color: '#001'});   // Binding index: 10
     *     ɵɵstyleProp('color', '#002');  // Binding index: 12
     * // MyComponent
     *     ɵɵstyleMap({color: '#003'});   // Binding index: 20
     *     ɵɵstyleProp('color', '#004');  // Binding index: 22
     * // Style1Directive
     *     ɵɵstyleMap({color: '#005'});   // Binding index: 24
     *     ɵɵstyleProp('color', '#006');  // Binding index: 26
     * // Style2Directive
     *     ɵɵstyleMap({color: '#007'});   // Binding index: 28
     *     ɵɵstyleProp('color', '#008');  // Binding index: 30
     * ```
     *
     * The correct priority order of concatenation is:
     *
     * ```
     * // MyComponent
     *     ɵɵstyleMap({color: '#003'});   // Binding index: 20
     *     ɵɵstyleProp('color', '#004');  // Binding index: 22
     * // Style1Directive
     *     ɵɵstyleMap({color: '#005'});   // Binding index: 24
     *     ɵɵstyleProp('color', '#006');  // Binding index: 26
     * // Style2Directive
     *     ɵɵstyleMap({color: '#007'});   // Binding index: 28
     *     ɵɵstyleProp('color', '#008');  // Binding index: 30
     * // Template: (ExampleComponent)
     *     ɵɵstyleMap({color: '#001'});   // Binding index: 10
     *     ɵɵstyleProp('color', '#002');  // Binding index: 12
     * ```
     *
     * What color should be rendered?
     *
     * Once the items are correctly sorted in the list, the answer is simply the last item in the
     * concatenation list which is `#002`.
     *
     * To do so we keep a linked list of all of the bindings which pertain to this element.
     * Notice that the bindings are inserted in the order of execution, but the `TView.data` allows
     * us to traverse them in the order of priority.
     *
     * |Idx|`TView.data`|`LView`          | Notes
     * |---|------------|-----------------|--------------
     * |...|            |                 |
     * |10 |`null`      |`{color: '#001'}`| `ɵɵstyleMap('color', {color: '#001'})`
     * |11 |`30 | 12`   | ...             |
     * |12 |`color`     |`'#002'`         | `ɵɵstyleProp('color', '#002')`
     * |13 |`10 | 0`    | ...             |
     * |...|            |                 |
     * |20 |`null`      |`{color: '#003'}`| `ɵɵstyleMap('color', {color: '#003'})`
     * |21 |`0 | 22`    | ...             |
     * |22 |`color`     |`'#004'`         | `ɵɵstyleProp('color', '#004')`
     * |23 |`20 | 24`   | ...             |
     * |24 |`null`      |`{color: '#005'}`| `ɵɵstyleMap('color', {color: '#005'})`
     * |25 |`22 | 26`   | ...             |
     * |26 |`color`     |`'#006'`         | `ɵɵstyleProp('color', '#006')`
     * |27 |`24 | 28`   | ...             |
     * |28 |`null`      |`{color: '#007'}`| `ɵɵstyleMap('color', {color: '#007'})`
     * |29 |`26 | 30`   | ...             |
     * |30 |`color`     |`'#008'`         | `ɵɵstyleProp('color', '#008')`
     * |31 |`28 | 10`   | ...             |
     *
     * The above data structure allows us to re-concatenate the styling no matter which data binding
     * changes.
     *
     * NOTE: in addition to keeping track of next/previous index the `TView.data` also stores prev/next
     * duplicate bit. The duplicate bit if true says there either is a binding with the same name or
     * there is a map (which may contain the name). This information is useful in knowing if other
     * styles with higher priority need to be searched for overwrites.
     *
     * NOTE: See `should support example in 'tnode_linked_list.ts' documentation` in
     * `tnode_linked_list_spec.ts` for working example.
     * @type {?}
     */


    var __unused_const_as_closure_does_not_like_standalone_comment_blocks__;
    /**
     * Insert new `tStyleValue` at `TData` and link existing style bindings such that we maintain linked
     * list of styles and compute the duplicate flag.
     *
     * Note: this function is executed during `firstUpdatePass` only to populate the `TView.data`.
     *
     * The function works by keeping track of `tStylingRange` which contains two pointers pointing to
     * the head/tail of the template portion of the styles.
     *  - if `isHost === false` (we are template) then insertion is at tail of `TStylingRange`
     *  - if `isHost === true` (we are host binding) then insertion is at head of `TStylingRange`
     *
     * @param {?} tData The `TData` to insert into.
     * @param {?} tNode `TNode` associated with the styling element.
     * @param {?} tStylingKeyWithStatic
     * @param {?} index location of where `tStyleValue` should be stored (and linked into list.)
     * @param {?} isHostBinding `true` if the insertion is for a `hostBinding`. (insertion is in front of
     *               template.)
     * @param {?} isClassBinding True if the associated `tStylingKey` as a `class` styling.
     *                       `tNode.classBindings` should be used (or `tNode.styleBindings` otherwise.)
     * @return {?}
     */


    function insertTStylingBinding(tData, tNode, tStylingKeyWithStatic, index, isHostBinding, isClassBinding) {
      ngDevMode && assertFirstUpdatePass(getTView());
      /** @type {?} */

      var tBindings = isClassBinding ? tNode.classBindings : tNode.styleBindings;
      /** @type {?} */

      var tmplHead = getTStylingRangePrev(tBindings);
      /** @type {?} */

      var tmplTail = getTStylingRangeNext(tBindings);
      tData[index] = tStylingKeyWithStatic;
      /** @type {?} */

      var isKeyDuplicateOfStatic = false;
      /** @type {?} */

      var tStylingKey;

      if (Array.isArray(tStylingKeyWithStatic)) {
        // We are case when the `TStylingKey` contains static fields as well.

        /** @type {?} */
        var staticKeyValueArray =
        /** @type {?} */
        tStylingKeyWithStatic;
        tStylingKey = staticKeyValueArray[1]; // unwrap.
        // We need to check if our key is present in the static so that we can mark it as duplicate.

        if (tStylingKey === null || keyValueArrayIndexOf(staticKeyValueArray,
        /** @type {?} */
        tStylingKey) > 0) {
          // tStylingKey is present in the statics, need to mark it as duplicate.
          isKeyDuplicateOfStatic = true;
        }
      } else {
        tStylingKey = tStylingKeyWithStatic;
      }

      if (isHostBinding) {
        // We are inserting host bindings
        // If we don't have template bindings then `tail` is 0.

        /** @type {?} */
        var hasTemplateBindings = tmplTail !== 0; // This is important to know because that means that the `head` can't point to the first
        // template bindings (there are none.) Instead the head points to the tail of the template.

        if (hasTemplateBindings) {
          // template head's "prev" will point to last host binding or to 0 if no host bindings yet

          /** @type {?} */
          var previousNode = getTStylingRangePrev(
          /** @type {?} */
          tData[tmplHead + 1]);
          tData[index + 1] = toTStylingRange(previousNode, tmplHead); // if a host binding has already been registered, we need to update the next of that host
          // binding to point to this one

          if (previousNode !== 0) {
            // We need to update the template-tail value to point to us.
            tData[previousNode + 1] = setTStylingRangeNext(
            /** @type {?} */
            tData[previousNode + 1], index);
          } // The "previous" of the template binding head should point to this host binding


          tData[tmplHead + 1] = setTStylingRangePrev(
          /** @type {?} */
          tData[tmplHead + 1], index);
        } else {
          tData[index + 1] = toTStylingRange(tmplHead, 0); // if a host binding has already been registered, we need to update the next of that host
          // binding to point to this one

          if (tmplHead !== 0) {
            // We need to update the template-tail value to point to us.
            tData[tmplHead + 1] = setTStylingRangeNext(
            /** @type {?} */
            tData[tmplHead + 1], index);
          } // if we don't have template, the head points to template-tail, and needs to be advanced.


          tmplHead = index;
        }
      } else {
        // We are inserting in template section.
        // We need to set this binding's "previous" to the current template tail
        tData[index + 1] = toTStylingRange(tmplTail, 0);
        ngDevMode && assertEqual(tmplHead !== 0 && tmplTail === 0, false, 'Adding template bindings after hostBindings is not allowed.');

        if (tmplHead === 0) {
          tmplHead = index;
        } else {
          // We need to update the previous value "next" to point to this binding
          tData[tmplTail + 1] = setTStylingRangeNext(
          /** @type {?} */
          tData[tmplTail + 1], index);
        }

        tmplTail = index;
      } // Now we need to update / compute the duplicates.
      // Starting with our location search towards head (least priority)


      if (isKeyDuplicateOfStatic) {
        tData[index + 1] = setTStylingRangePrevDuplicate(
        /** @type {?} */
        tData[index + 1]);
      }

      markDuplicates(tData, tStylingKey, index, true, isClassBinding);
      markDuplicates(tData, tStylingKey, index, false, isClassBinding);
      markDuplicateOfResidualStyling(tNode, tStylingKey, tData, index, isClassBinding);
      tBindings = toTStylingRange(tmplHead, tmplTail);

      if (isClassBinding) {
        tNode.classBindings = tBindings;
      } else {
        tNode.styleBindings = tBindings;
      }
    }
    /**
     * Look into the residual styling to see if the current `tStylingKey` is duplicate of residual.
     *
     * @param {?} tNode `TNode` where the residual is stored.
     * @param {?} tStylingKey `TStylingKey` to store.
     * @param {?} tData `TData` associated with the current `LView`.
     * @param {?} index location of where `tStyleValue` should be stored (and linked into list.)
     * @param {?} isClassBinding True if the associated `tStylingKey` as a `class` styling.
     *                       `tNode.classBindings` should be used (or `tNode.styleBindings` otherwise.)
     * @return {?}
     */


    function markDuplicateOfResidualStyling(tNode, tStylingKey, tData, index, isClassBinding) {
      /** @type {?} */
      var residual = isClassBinding ? tNode.residualClasses : tNode.residualStyles;

      if (residual != null
      /* or undefined */
      && typeof tStylingKey == 'string' && keyValueArrayIndexOf(residual, tStylingKey) >= 0) {
        // We have duplicate in the residual so mark ourselves as duplicate.
        tData[index + 1] = setTStylingRangeNextDuplicate(
        /** @type {?} */
        tData[index + 1]);
      }
    }
    /**
     * Marks `TStyleValue`s as duplicates if another style binding in the list has the same
     * `TStyleValue`.
     *
     * NOTE: this function is intended to be called twice once with `isPrevDir` set to `true` and once
     * with it set to `false` to search both the previous as well as next items in the list.
     *
     * No duplicate case
     * ```
     *   [style.color]
     *   [style.width.px] <<- index
     *   [style.height.px]
     * ```
     *
     * In the above case adding `[style.width.px]` to the existing `[style.color]` produces no
     * duplicates because `width` is not found in any other part of the linked list.
     *
     * Duplicate case
     * ```
     *   [style.color]
     *   [style.width.em]
     *   [style.width.px] <<- index
     * ```
     * In the above case adding `[style.width.px]` will produce a duplicate with `[style.width.em]`
     * because `width` is found in the chain.
     *
     * Map case 1
     * ```
     *   [style.width.px]
     *   [style.color]
     *   [style]  <<- index
     * ```
     * In the above case adding `[style]` will produce a duplicate with any other bindings because
     * `[style]` is a Map and as such is fully dynamic and could produce `color` or `width`.
     *
     * Map case 2
     * ```
     *   [style]
     *   [style.width.px]
     *   [style.color]  <<- index
     * ```
     * In the above case adding `[style.color]` will produce a duplicate because there is already a
     * `[style]` binding which is a Map and as such is fully dynamic and could produce `color` or
     * `width`.
     *
     * NOTE: Once `[style]` (Map) is added into the system all things are mapped as duplicates.
     * NOTE: We use `style` as example, but same logic is applied to `class`es as well.
     *
     * @param {?} tData `TData` where the linked list is stored.
     * @param {?} tStylingKey `TStylingKeyPrimitive` which contains the value to compare to other keys in
     *        the linked list.
     * @param {?} index Starting location in the linked list to search from
     * @param {?} isPrevDir Direction.
     *        - `true` for previous (lower priority);
     *        - `false` for next (higher priority).
     * @param {?} isClassBinding
     * @return {?}
     */


    function markDuplicates(tData, tStylingKey, index, isPrevDir, isClassBinding) {
      /** @type {?} */
      var tStylingAtIndex =
      /** @type {?} */
      tData[index + 1];
      /** @type {?} */

      var isMap = tStylingKey === null;
      /** @type {?} */

      var cursor = isPrevDir ? getTStylingRangePrev(tStylingAtIndex) : getTStylingRangeNext(tStylingAtIndex);
      /** @type {?} */

      var foundDuplicate = false; // We keep iterating as long as we have a cursor
      // AND either:
      // - we found what we are looking for, OR
      // - we are a map in which case we have to continue searching even after we find what we were
      //   looking for since we are a wild card and everything needs to be flipped to duplicate.

      while (cursor !== 0 && (foundDuplicate === false || isMap)) {
        ngDevMode && assertDataInRange(tData, cursor);
        /** @type {?} */

        var tStylingValueAtCursor =
        /** @type {?} */
        tData[cursor];
        /** @type {?} */

        var tStyleRangeAtCursor =
        /** @type {?} */
        tData[cursor + 1];

        if (isStylingMatch(tStylingValueAtCursor, tStylingKey)) {
          foundDuplicate = true;
          tData[cursor + 1] = isPrevDir ? setTStylingRangeNextDuplicate(tStyleRangeAtCursor) : setTStylingRangePrevDuplicate(tStyleRangeAtCursor);
        }

        cursor = isPrevDir ? getTStylingRangePrev(tStyleRangeAtCursor) : getTStylingRangeNext(tStyleRangeAtCursor);
      }

      if (foundDuplicate) {
        // if we found a duplicate, than mark ourselves.
        tData[index + 1] = isPrevDir ? setTStylingRangePrevDuplicate(tStylingAtIndex) : setTStylingRangeNextDuplicate(tStylingAtIndex);
      }
    }
    /**
     * Determines if two `TStylingKey`s are a match.
     *
     * When computing weather a binding contains a duplicate, we need to compare if the instruction
     * `TStylingKey` has a match.
     *
     * Here are examples of `TStylingKey`s which match given `tStylingKeyCursor` is:
     * - `color`
     *    - `color`    // Match another color
     *    - `null`     // That means that `tStylingKey` is a `classMap`/`styleMap` instruction
     *    - `['', 'color', 'other', true]` // wrapped `color` so match
     *    - `['', null, 'other', true]`       // wrapped `null` so match
     *    - `['', 'width', 'color', 'value']` // wrapped static value contains a match on `'color'`
     * - `null`       // `tStylingKeyCursor` always match as it is `classMap`/`styleMap` instruction
     *
     * @param {?} tStylingKeyCursor
     * @param {?} tStylingKey
     * @return {?}
     */


    function isStylingMatch(tStylingKeyCursor, tStylingKey) {
      ngDevMode && assertNotEqual(Array.isArray(tStylingKey), true, 'Expected that \'tStylingKey\' has been unwrapped');

      if (tStylingKeyCursor === null || // If the cursor is `null` it means that we have map at that
      // location so we must assume that we have a match.
      tStylingKey == null || // If `tStylingKey` is `null` then it is a map therefor assume that it
      // contains a match.
      (Array.isArray(tStylingKeyCursor) ? tStylingKeyCursor[1] : tStylingKeyCursor) === tStylingKey // If the keys match explicitly than we are a match.
      ) {
          return true;
        } else if (Array.isArray(tStylingKeyCursor) && typeof tStylingKey === 'string') {
        // if we did not find a match, but `tStylingKeyCursor` is `KeyValueArray` that means cursor has
        // statics and we need to check those as well.
        return keyValueArrayIndexOf(tStylingKeyCursor, tStylingKey) >= 0; // see if we are matching the key
      }

      return false;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/styling/styling_parser.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Stores the locations of key/value indexes while parsing styling.
     *
     * In case of `cssText` parsing the indexes are like so:
     * ```
     *   "key1: value1; key2: value2; key3: value3"
     *                  ^   ^ ^     ^             ^
     *                  |   | |     |             +-- textEnd
     *                  |   | |     +---------------- valueEnd
     *                  |   | +---------------------- value
     *                  |   +------------------------ keyEnd
     *                  +---------------------------- key
     * ```
     *
     * In case of `className` parsing the indexes are like so:
     * ```
     *   "key1 key2 key3"
     *         ^   ^    ^
     *         |   |    +-- textEnd
     *         |   +------------------------ keyEnd
     *         +---------------------------- key
     * ```
     * NOTE: `value` and `valueEnd` are used only for styles, not classes.
     * @record
     */


    function ParserState() {}

    if (false) {} // Global state of the parser. (This makes parser non-reentrant, but that is not an issue)

    /** @type {?} */


    var parserState = {
      textEnd: 0,
      key: 0,
      keyEnd: 0,
      value: 0,
      valueEnd: 0
    };
    /**
     * Retrieves the last parsed `key` of style.
     * @param {?} text the text to substring the key from.
     * @return {?}
     */

    function getLastParsedKey(text) {
      return text.substring(parserState.key, parserState.keyEnd);
    }
    /**
     * Retrieves the last parsed `value` of style.
     * @param {?} text the text to substring the key from.
     * @return {?}
     */


    function getLastParsedValue(text) {
      return text.substring(parserState.value, parserState.valueEnd);
    }
    /**
     * Initializes `className` string for parsing and parses the first token.
     *
     * This function is intended to be used in this format:
     * ```
     * for (let i = parseClassName(text); i >= 0; i = parseClassNameNext(text, i)) {
     *   const key = getLastParsedKey();
     *   ...
     * }
     * ```
     * @param {?} text `className` to parse
     * @return {?} index where the next invocation of `parseClassNameNext` should resume.
     */


    function parseClassName(text) {
      resetParserState(text);
      return parseClassNameNext(text, consumeWhitespace(text, 0, parserState.textEnd));
    }
    /**
     * Parses next `className` token.
     *
     * This function is intended to be used in this format:
     * ```
     * for (let i = parseClassName(text); i >= 0; i = parseClassNameNext(text, i)) {
     *   const key = getLastParsedKey();
     *   ...
     * }
     * ```
     *
     * @param {?} text `className` to parse
     * @param {?} index where the parsing should resume.
     * @return {?} index where the next invocation of `parseClassNameNext` should resume.
     */


    function parseClassNameNext(text, index) {
      /** @type {?} */
      var end = parserState.textEnd;

      if (end === index) {
        return -1;
      }

      index = parserState.keyEnd = consumeClassToken(text, parserState.key = index, end);
      return consumeWhitespace(text, index, end);
    }
    /**
     * Initializes `cssText` string for parsing and parses the first key/values.
     *
     * This function is intended to be used in this format:
     * ```
     * for (let i = parseStyle(text); i >= 0; i = parseStyleNext(text, i))) {
     *   const key = getLastParsedKey();
     *   const value = getLastParsedValue();
     *   ...
     * }
     * ```
     * @param {?} text `cssText` to parse
     * @return {?} index where the next invocation of `parseStyleNext` should resume.
     */


    function parseStyle(text) {
      resetParserState(text);
      return parseStyleNext(text, consumeWhitespace(text, 0, parserState.textEnd));
    }
    /**
     * Parses the next `cssText` key/values.
     *
     * This function is intended to be used in this format:
     * ```
     * for (let i = parseStyle(text); i >= 0; i = parseStyleNext(text, i))) {
     *   const key = getLastParsedKey();
     *   const value = getLastParsedValue();
     *   ...
     * }
     *
     * @param {?} text `cssText` to parse
     * @param {?} startIndex
     * @return {?} index where the next invocation of `parseStyleNext` should resume.
     */


    function parseStyleNext(text, startIndex) {
      /** @type {?} */
      var end = parserState.textEnd;
      /** @type {?} */

      var index = parserState.key = consumeWhitespace(text, startIndex, end);

      if (end === index) {
        // we reached an end so just quit
        return -1;
      }

      index = parserState.keyEnd = consumeStyleKey(text, index, end);
      index = consumeSeparator(text, index, end, 58
      /* COLON */
      );
      index = parserState.value = consumeWhitespace(text, index, end);
      index = parserState.valueEnd = consumeStyleValue(text, index, end);
      return consumeSeparator(text, index, end, 59
      /* SEMI_COLON */
      );
    }
    /**
     * Reset the global state of the styling parser.
     * @param {?} text The styling text to parse.
     * @return {?}
     */


    function resetParserState(text) {
      parserState.key = 0;
      parserState.keyEnd = 0;
      parserState.value = 0;
      parserState.valueEnd = 0;
      parserState.textEnd = text.length;
    }
    /**
     * Returns index of next non-whitespace character.
     *
     * @param {?} text Text to scan
     * @param {?} startIndex Starting index of character where the scan should start.
     * @param {?} endIndex Ending index of character where the scan should end.
     * @return {?} Index of next non-whitespace character (May be the same as `start` if no whitespace at
     *          that location.)
     */


    function consumeWhitespace(text, startIndex, endIndex) {
      while (startIndex < endIndex && text.charCodeAt(startIndex) <= 32
      /* SPACE */
      ) {
        startIndex++;
      }

      return startIndex;
    }
    /**
     * Returns index of last char in class token.
     *
     * @param {?} text Text to scan
     * @param {?} startIndex Starting index of character where the scan should start.
     * @param {?} endIndex Ending index of character where the scan should end.
     * @return {?} Index after last char in class token.
     */


    function consumeClassToken(text, startIndex, endIndex) {
      while (startIndex < endIndex && text.charCodeAt(startIndex) > 32
      /* SPACE */
      ) {
        startIndex++;
      }

      return startIndex;
    }
    /**
     * Consumes all of the characters belonging to style key and token.
     *
     * @param {?} text Text to scan
     * @param {?} startIndex Starting index of character where the scan should start.
     * @param {?} endIndex Ending index of character where the scan should end.
     * @return {?} Index after last style key character.
     */


    function consumeStyleKey(text, startIndex, endIndex) {
      /** @type {?} */
      var ch;

      while (startIndex < endIndex && ((ch = text.charCodeAt(startIndex)) === 45
      /* DASH */
      || ch === 95
      /* UNDERSCORE */
      || (ch & -33
      /* UPPER_CASE */
      ) >= 65
      /* A */
      && (ch & -33
      /* UPPER_CASE */
      ) <= 90
      /* Z */
      )) {
        startIndex++;
      }

      return startIndex;
    }
    /**
     * Consumes all whitespace and the separator `:` after the style key.
     *
     * @param {?} text Text to scan
     * @param {?} startIndex Starting index of character where the scan should start.
     * @param {?} endIndex Ending index of character where the scan should end.
     * @param {?} separator
     * @return {?} Index after separator and surrounding whitespace.
     */


    function consumeSeparator(text, startIndex, endIndex, separator) {
      startIndex = consumeWhitespace(text, startIndex, endIndex);

      if (startIndex < endIndex) {
        if (ngDevMode && text.charCodeAt(startIndex) !== separator) {
          malformedStyleError(text, String.fromCharCode(separator), startIndex);
        }

        startIndex++;
      }

      return startIndex;
    }
    /**
     * Consumes style value honoring `url()` and `""` text.
     *
     * @param {?} text Text to scan
     * @param {?} startIndex Starting index of character where the scan should start.
     * @param {?} endIndex Ending index of character where the scan should end.
     * @return {?} Index after last style value character.
     */


    function consumeStyleValue(text, startIndex, endIndex) {
      /** @type {?} */
      var ch1 = -1; // 1st previous character

      /** @type {?} */

      var ch2 = -1; // 2nd previous character

      /** @type {?} */

      var ch3 = -1; // 3rd previous character

      /** @type {?} */

      var i = startIndex;
      /** @type {?} */

      var lastChIndex = i;

      while (i < endIndex) {
        /** @type {?} */
        var ch = text.charCodeAt(i++);

        if (ch === 59
        /* SEMI_COLON */
        ) {
            return lastChIndex;
          } else if (ch === 34
        /* DOUBLE_QUOTE */
        || ch === 39
        /* SINGLE_QUOTE */
        ) {
            lastChIndex = i = consumeQuotedText(text, ch, i, endIndex);
          } else if (startIndex === i - 4 && // We have seen only 4 characters so far "URL(" (Ignore "foo_URL()")
        ch3 === 85
        /* U */
        && ch2 === 82
        /* R */
        && ch1 === 76
        /* L */
        && ch === 40
        /* OPEN_PAREN */
        ) {
            lastChIndex = i = consumeQuotedText(text, 41
            /* CLOSE_PAREN */
            , i, endIndex);
          } else if (ch > 32
        /* SPACE */
        ) {
            // if we have a non-whitespace character then capture its location
            lastChIndex = i;
          }

        ch3 = ch2;
        ch2 = ch1;
        ch1 = ch & -33
        /* UPPER_CASE */
        ;
      }

      return lastChIndex;
    }
    /**
     * Consumes all of the quoted characters.
     *
     * @param {?} text Text to scan
     * @param {?} quoteCharCode CharCode of either `"` or `'` quote or `)` for `url(...)`.
     * @param {?} startIndex Starting index of character where the scan should start.
     * @param {?} endIndex Ending index of character where the scan should end.
     * @return {?} Index after quoted characters.
     */


    function consumeQuotedText(text, quoteCharCode, startIndex, endIndex) {
      /** @type {?} */
      var ch1 = -1; // 1st previous character

      /** @type {?} */

      var index = startIndex;

      while (index < endIndex) {
        /** @type {?} */
        var ch = text.charCodeAt(index++);

        if (ch == quoteCharCode && ch1 !== 92
        /* BACK_SLASH */
        ) {
            return index;
          }

        if (ch == 92
        /* BACK_SLASH */
        && ch1 === 92
        /* BACK_SLASH */
        ) {
            // two back slashes cancel each other out. For example `"\\"` should properly end the
            // quotation. (It should not assume that the last `"` is escaped.)
            ch1 = 0;
          } else {
          ch1 = ch;
        }
      }

      throw ngDevMode ? malformedStyleError(text, String.fromCharCode(quoteCharCode), endIndex) : new Error();
    }
    /**
     * @param {?} text
     * @param {?} expecting
     * @param {?} index
     * @return {?}
     */


    function malformedStyleError(text, expecting, index) {
      ngDevMode && assertEqual(typeof text === 'string', true, 'String expected here');
      throw throwError("Malformed style at location ".concat(index, " in string '") + text.substring(0, index) + '[>>' + text.substring(index, index + 1) + '<<]' + text.substr(index + 1) + "'. Expecting '".concat(expecting, "'."));
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/styling.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Sets the current style sanitizer function which will then be used
     * within all follow-up prop and map-based style binding instructions
     * for the given element.
     *
     * Note that once styling has been applied to the element (i.e. once
     * `advance(n)` is executed or the hostBindings/template function exits)
     * then the active `sanitizerFn` will be set to `null`. This means that
     * once styling is applied to another element then a another call to
     * `styleSanitizer` will need to be made.
     *
     * \@codeGenApi
     * @param {?} sanitizer
     * @return {?}
     */


    function ɵɵstyleSanitizer(sanitizer) {
      setCurrentStyleSanitizer(sanitizer);
    }
    /**
     * Update a style binding on an element with the provided value.
     *
     * If the style value is falsy then it will be removed from the element
     * (or assigned a different value depending if there are any styles placed
     * on the element with `styleMap` or any static styles that are
     * present from when the element was created with `styling`).
     *
     * Note that the styling element is updated as part of `stylingApply`.
     *
     * \@codeGenApi
     * @param {?} prop A valid CSS property.
     * @param {?} value New value to write (`null` or an empty string to remove).
     * @param {?=} suffix Optional suffix. Used with scalar values to add unit such as `px`.
     *        Note that when a suffix is provided then the underlying sanitizer will
     *        be ignored.
     *
     * Note that this will apply the provided style value to the host element if this function is called
     * within a host binding function.
     *
     * @return {?}
     */


    function ɵɵstyleProp(prop, value, suffix) {
      checkStylingProperty(prop, value, suffix, false);
      return ɵɵstyleProp;
    }
    /**
     * Update a class binding on an element with the provided value.
     *
     * This instruction is meant to handle the `[class.foo]="exp"` case and,
     * therefore, the class binding itself must already be allocated using
     * `styling` within the creation block.
     *
     * \@codeGenApi
     * @param {?} className
     * @param {?} value A true/false value which will turn the class on or off.
     *
     * Note that this will apply the provided class value to the host element if this function
     * is called within a host binding function.
     *
     * @return {?}
     */


    function ɵɵclassProp(className, value) {
      checkStylingProperty(className, value, null, true);
      return ɵɵclassProp;
    }
    /**
     * Update style bindings using an object literal on an element.
     *
     * This instruction is meant to apply styling via the `[style]="exp"` template bindings.
     * When styles are applied to the element they will then be updated with respect to
     * any styles/classes set via `styleProp`. If any styles are set to falsy
     * then they will be removed from the element.
     *
     * Note that the styling instruction will not be applied until `stylingApply` is called.
     *
     * \@codeGenApi
     * @param {?} styles A key/value style map of the styles that will be applied to the given element.
     *        Any missing styles (that have already been applied to the element beforehand) will be
     *        removed (unset) from the element's styling.
     *
     * Note that this will apply the provided styleMap value to the host element if this function
     * is called within a host binding.
     *
     * @return {?}
     */


    function ɵɵstyleMap(styles) {
      checkStylingMap(styleKeyValueArraySet, styleStringParser, styles, false);
    }
    /**
     * Parse text as style and add values to KeyValueArray.
     *
     * This code is pulled out to a separate function so that it can be tree shaken away if it is not
     * needed. It is only referenced from `ɵɵstyleMap`.
     *
     * @param {?} keyValueArray KeyValueArray to add parsed values to.
     * @param {?} text text to parse.
     * @return {?}
     */


    function styleStringParser(keyValueArray, text) {
      for (var i = parseStyle(text); i >= 0; i = parseStyleNext(text, i)) {
        styleKeyValueArraySet(keyValueArray, getLastParsedKey(text), getLastParsedValue(text));
      }
    }
    /**
     * Update class bindings using an object literal or class-string on an element.
     *
     * This instruction is meant to apply styling via the `[class]="exp"` template bindings.
     * When classes are applied to the element they will then be updated with
     * respect to any styles/classes set via `classProp`. If any
     * classes are set to falsy then they will be removed from the element.
     *
     * Note that the styling instruction will not be applied until `stylingApply` is called.
     * Note that this will the provided classMap value to the host element if this function is called
     * within a host binding.
     *
     * \@codeGenApi
     * @param {?} classes A key/value map or string of CSS classes that will be added to the
     *        given element. Any missing classes (that have already been applied to the element
     *        beforehand) will be removed (unset) from the element's list of CSS classes.
     *
     * @return {?}
     */


    function ɵɵclassMap(classes) {
      checkStylingMap(keyValueArraySet, classStringParser, classes, true);
    }
    /**
     * Parse text as class and add values to KeyValueArray.
     *
     * This code is pulled out to a separate function so that it can be tree shaken away if it is not
     * needed. It is only referenced from `ɵɵclassMap`.
     *
     * @param {?} keyValueArray KeyValueArray to add parsed values to.
     * @param {?} text text to parse.
     * @return {?}
     */


    function classStringParser(keyValueArray, text) {
      for (var i = parseClassName(text); i >= 0; i = parseClassNameNext(text, i)) {
        keyValueArraySet(keyValueArray, getLastParsedKey(text), true);
      }
    }
    /**
     * Common code between `ɵɵclassProp` and `ɵɵstyleProp`.
     *
     * @param {?} prop property name.
     * @param {?} value binding value.
     * @param {?} suffixOrSanitizer suffix or sanitization function
     * @param {?} isClassBased `true` if `class` change (`false` if `style`)
     * @return {?}
     */


    function checkStylingProperty(prop, value, suffixOrSanitizer, isClassBased) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var tView = getTView(); // Styling instructions use 2 slots per binding.
      // 1. one for the value / TStylingKey
      // 2. one for the intermittent-value / TStylingRange

      /** @type {?} */

      var bindingIndex = incrementBindingIndex(2);

      if (tView.firstUpdatePass) {
        stylingFirstUpdatePass(tView, prop, bindingIndex, isClassBased);
      }

      if (value !== NO_CHANGE && bindingUpdated(lView, bindingIndex, value)) {
        // This is a work around. Once PR#34480 lands the sanitizer is passed explicitly and this line
        // can be removed.

        /** @type {?} */
        var styleSanitizer;

        if (suffixOrSanitizer == null) {
          if (styleSanitizer = getCurrentStyleSanitizer()) {
            suffixOrSanitizer =
            /** @type {?} */
            styleSanitizer;
          }
        }
        /** @type {?} */


        var tNode =
        /** @type {?} */
        tView.data[getSelectedIndex() + HEADER_OFFSET];
        updateStyling(tView, tNode, lView, lView[RENDERER], prop, lView[bindingIndex + 1] = normalizeAndApplySuffixOrSanitizer(value, suffixOrSanitizer), isClassBased, bindingIndex);
      }
    }
    /**
     * Common code between `ɵɵclassMap` and `ɵɵstyleMap`.
     *
     * @param {?} keyValueArraySet (See `keyValueArraySet` in "util/array_utils") Gets passed in as a
     * function so that
     *        `style` can pass in version which does sanitization. This is done for tree shaking
     *        purposes.
     * @param {?} stringParser Parser used to parse `value` if `string`. (Passed in as `style` and `class`
     *        have different parsers.)
     * @param {?} value bound value from application
     * @param {?} isClassBased `true` if `class` change (`false` if `style`)
     * @return {?}
     */


    function checkStylingMap(keyValueArraySet, stringParser, value, isClassBased) {
      /** @type {?} */
      var tView = getTView();
      /** @type {?} */

      var bindingIndex = incrementBindingIndex(2);

      if (tView.firstUpdatePass) {
        stylingFirstUpdatePass(tView, null, bindingIndex, isClassBased);
      }
      /** @type {?} */


      var lView = getLView();

      if (value !== NO_CHANGE && bindingUpdated(lView, bindingIndex, value)) {
        // `getSelectedIndex()` should be here (rather than in instruction) so that it is guarded by the
        // if so as not to read unnecessarily.

        /** @type {?} */
        var tNode =
        /** @type {?} */
        tView.data[getSelectedIndex() + HEADER_OFFSET];

        if (hasStylingInputShadow(tNode, isClassBased) && !isInHostBindings(tView, bindingIndex)) {
          if (ngDevMode) {
            // verify that if we are shadowing then `TData` is appropriately marked so that we skip
            // processing this binding in styling resolution.

            /** @type {?} */
            var tStylingKey = tView.data[bindingIndex];
            assertEqual(Array.isArray(tStylingKey) ? tStylingKey[1] : tStylingKey, false, 'Styling linked list shadow input should be marked as \'false\'');
          } // VE does not concatenate the static portion like we are doing here.
          // Instead VE just ignores the static completely if dynamic binding is present.
          // Because of locality we have already set the static portion because we don't know if there
          // is a dynamic portion until later. If we would ignore the static portion it would look like
          // the binding has removed it. This would confuse `[ngStyle]`/`[ngClass]` to do the wrong
          // thing as it would think that the static portion was removed. For this reason we
          // concatenate it so that `[ngStyle]`/`[ngClass]`  can continue to work on changed.

          /** @type {?} */


          var staticPrefix = isClassBased ? tNode.classes : tNode.styles;
          ngDevMode && isClassBased === false && staticPrefix !== null && assertEqual(staticPrefix.endsWith(';'), true, 'Expecting static portion to end with \';\'');

          if (staticPrefix !== null) {
            // We want to make sure that falsy values of `value` become empty strings.
            value = concatStringsWithSpace(staticPrefix, value ? value : '');
          } // Given `<div [style] my-dir>` such that `my-dir` has `@Input('style')`.
          // This takes over the `[style]` binding. (Same for `[class]`)


          setDirectiveInputsWhichShadowsStyling(tView, tNode, lView, value, isClassBased);
        } else {
          updateStylingMap(tView, tNode, lView, lView[RENDERER], lView[bindingIndex + 1], lView[bindingIndex + 1] = toStylingKeyValueArray(keyValueArraySet, stringParser, value), isClassBased, bindingIndex);
        }
      }
    }
    /**
     * Determines when the binding is in `hostBindings` section
     *
     * @param {?} tView Current `TView`
     * @param {?} bindingIndex index of binding which we would like if it is in `hostBindings`
     * @return {?}
     */


    function isInHostBindings(tView, bindingIndex) {
      // All host bindings are placed after the expando section.
      return bindingIndex >= tView.expandoStartIndex;
    }
    /**
     * Collects the necessary information to insert the binding into a linked list of style bindings
     * using `insertTStylingBinding`.
     *
     * @param {?} tView `TView` where the binding linked list will be stored.
     * @param {?} tStylingKey Property/key of the binding.
     * @param {?} bindingIndex Index of binding associated with the `prop`
     * @param {?} isClassBased `true` if `class` change (`false` if `style`)
     * @return {?}
     */


    function stylingFirstUpdatePass(tView, tStylingKey, bindingIndex, isClassBased) {
      ngDevMode && assertFirstUpdatePass(tView);
      /** @type {?} */

      var tData = tView.data;

      if (tData[bindingIndex + 1] === null) {
        // The above check is necessary because we don't clear first update pass until first successful
        // (no exception) template execution. This prevents the styling instruction from double adding
        // itself to the list.
        // `getSelectedIndex()` should be here (rather than in instruction) so that it is guarded by the
        // if so as not to read unnecessarily.

        /** @type {?} */
        var tNode =
        /** @type {?} */
        tData[getSelectedIndex() + HEADER_OFFSET];
        /** @type {?} */

        var isHostBindings = isInHostBindings(tView, bindingIndex);

        if (hasStylingInputShadow(tNode, isClassBased) && tStylingKey === null && !isHostBindings) {
          // `tStylingKey === null` implies that we are either `[style]` or `[class]` binding.
          // If there is a directive which uses `@Input('style')` or `@Input('class')` than
          // we need to neutralize this binding since that directive is shadowing it.
          // We turn this into a noop by setting the key to `false`
          tStylingKey = false;
        }

        tStylingKey = wrapInStaticStylingKey(tData, tNode, tStylingKey, isClassBased);
        insertTStylingBinding(tData, tNode, tStylingKey, bindingIndex, isHostBindings, isClassBased);
      }
    }
    /**
     * Adds static styling information to the binding if applicable.
     *
     * The linked list of styles not only stores the list and keys, but also stores static styling
     * information on some of the keys. This function determines if the key should contain the styling
     * information and computes it.
     *
     * See `TStylingStatic` for more details.
     *
     * @param {?} tData `TData` where the linked list is stored.
     * @param {?} tNode `TNode` for which the styling is being computed.
     * @param {?} stylingKey `TStylingKeyPrimitive` which may need to be wrapped into `TStylingKey`
     * @param {?} isClassBased `true` if `class` (`false` if `style`)
     * @return {?}
     */


    function wrapInStaticStylingKey(tData, tNode, stylingKey, isClassBased) {
      /** @type {?} */
      var hostDirectiveDef = getCurrentDirectiveDef(tData);
      /** @type {?} */

      var residual = isClassBased ? tNode.residualClasses : tNode.residualStyles;

      if (hostDirectiveDef === null) {
        // We are in template node.
        // If template node already had styling instruction then it has already collected the static
        // styling and there is no need to collect them again. We know that we are the first styling
        // instruction because the `TNode.*Bindings` points to 0 (nothing has been inserted yet).

        /** @type {?} */
        var isFirstStylingInstructionInTemplate = (
        /** @type {?} */

        /** @type {?} */
        isClassBased ? tNode.classBindings : tNode.styleBindings) === 0;

        if (isFirstStylingInstructionInTemplate) {
          // It would be nice to be able to get the statics from `mergeAttrs`, however, at this point
          // they are already merged and it would not be possible to figure which property belongs where
          // in the priority.
          stylingKey = collectStylingFromDirectives(null, tData, tNode, stylingKey, isClassBased);
          stylingKey = collectStylingFromTAttrs(stylingKey, tNode.attrs, isClassBased); // We know that if we have styling binding in template we can't have residual.

          residual = null;
        }
      } else {
        // We are in host binding node and there was no binding instruction in template node.
        // This means that we need to compute the residual.

        /** @type {?} */
        var directiveStylingLast = tNode.directiveStylingLast;
        /** @type {?} */

        var isFirstStylingInstructionInHostBinding = directiveStylingLast === -1 || tData[directiveStylingLast] !== hostDirectiveDef;

        if (isFirstStylingInstructionInHostBinding) {
          stylingKey = collectStylingFromDirectives(hostDirectiveDef, tData, tNode, stylingKey, isClassBased);

          if (residual === null) {
            // - If `null` than either:
            //    - Template styling instruction already ran and it has consumed the static
            //      styling into its `TStylingKey` and so there is no need to update residual. Instead
            //      we need to update the `TStylingKey` associated with the first template node
            //      instruction. OR
            //    - Some other styling instruction ran and determined that there are no residuals

            /** @type {?} */
            var templateStylingKey = getTemplateHeadTStylingKey(tData, tNode, isClassBased);

            if (templateStylingKey !== undefined && Array.isArray(templateStylingKey)) {
              // Only recompute if `templateStylingKey` had static values. (If no static value found
              // then there is nothing to do since this operation can only produce less static keys, not
              // more.)
              templateStylingKey = collectStylingFromDirectives(null, tData, tNode, templateStylingKey[1]
              /* unwrap previous statics */
              , isClassBased);
              templateStylingKey = collectStylingFromTAttrs(templateStylingKey, tNode.attrs, isClassBased);
              setTemplateHeadTStylingKey(tData, tNode, isClassBased, templateStylingKey);
            }
          } else {
            // We only need to recompute residual if it is not `null`.
            // - If existing residual (implies there was no template styling). This means that some of
            //   the statics may have moved from the residual to the `stylingKey` and so we have to
            //   recompute.
            // - If `undefined` this is the first time we are running.
            residual = collectResidual(tData, tNode, isClassBased);
          }
        }
      }

      if (residual !== undefined) {
        isClassBased ? tNode.residualClasses = residual : tNode.residualStyles = residual;
      }

      return stylingKey;
    }
    /**
     * Retrieve the `TStylingKey` for the template styling instruction.
     *
     * This is needed since `hostBinding` styling instructions are inserted after the template
     * instruction. While the template instruction needs to update the residual in `TNode` the
     * `hostBinding` instructions need to update the `TStylingKey` of the template instruction because
     * the template instruction is downstream from the `hostBindings` instructions.
     *
     * @param {?} tData `TData` where the linked list is stored.
     * @param {?} tNode `TNode` for which the styling is being computed.
     * @param {?} isClassBased `true` if `class` (`false` if `style`)
     * @return {?} `TStylingKey` if found or `undefined` if not found.
     */


    function getTemplateHeadTStylingKey(tData, tNode, isClassBased) {
      /** @type {?} */
      var bindings = isClassBased ? tNode.classBindings : tNode.styleBindings;

      if (getTStylingRangeNext(bindings) === 0) {
        // There does not seem to be a styling instruction in the `template`.
        return undefined;
      }

      return (
        /** @type {?} */
        tData[getTStylingRangePrev(bindings)]
      );
    }
    /**
     * Update the `TStylingKey` of the first template instruction in `TNode`.
     *
     * Logically `hostBindings` styling instructions are of lower priority than that of the template.
     * However, they execute after the template styling instructions. This means that they get inserted
     * in front of the template styling instructions.
     *
     * If we have a template styling instruction and a new `hostBindings` styling instruction is
     * executed it means that it may need to steal static fields from the template instruction. This
     * method allows us to update the first template instruction `TStylingKey` with a new value.
     *
     * Assume:
     * ```
     * <div my-dir style="color: red" [style.color]="tmplExp"></div>
     *
     * \@Directive({
     *   host: {
     *     'style': 'width: 100px',
     *     '[style.color]': 'dirExp',
     *   }
     * })
     * class MyDir {}
     * ```
     *
     * when `[style.color]="tmplExp"` executes it creates this data structure.
     * ```
     *  ['', 'color', 'color', 'red', 'width', '100px'],
     * ```
     *
     * The reason for this is that the template instruction does not know if there are styling
     * instructions and must assume that there are none and must collect all of the static styling.
     * (both
     * `color' and 'width`)
     *
     * When `'[style.color]': 'dirExp',` executes we need to insert a new data into the linked list.
     * ```
     *  ['', 'color', 'width', '100px'],  // newly inserted
     *  ['', 'color', 'color', 'red', 'width', '100px'], // this is wrong
     * ```
     *
     * Notice that the template statics is now wrong as it incorrectly contains `width` so we need to
     * update it like so:
     * ```
     *  ['', 'color', 'width', '100px'],
     *  ['', 'color', 'color', 'red'],    // UPDATE
     * ```
     *
     * @param {?} tData `TData` where the linked list is stored.
     * @param {?} tNode `TNode` for which the styling is being computed.
     * @param {?} isClassBased `true` if `class` (`false` if `style`)
     * @param {?} tStylingKey New `TStylingKey` which is replacing the old one.
     * @return {?}
     */


    function setTemplateHeadTStylingKey(tData, tNode, isClassBased, tStylingKey) {
      /** @type {?} */
      var bindings = isClassBased ? tNode.classBindings : tNode.styleBindings;
      ngDevMode && assertNotEqual(getTStylingRangeNext(bindings), 0, 'Expecting to have at least one template styling binding.');
      tData[getTStylingRangePrev(bindings)] = tStylingKey;
    }
    /**
     * Collect all static values after the current `TNode.directiveStylingLast` index.
     *
     * Collect the remaining styling information which has not yet been collected by an existing
     * styling instruction.
     *
     * @param {?} tData `TData` where the `DirectiveDefs` are stored.
     * @param {?} tNode `TNode` which contains the directive range.
     * @param {?} isClassBased `true` if `class` (`false` if `style`)
     * @return {?}
     */


    function collectResidual(tData, tNode, isClassBased) {
      /** @type {?} */
      var residual = undefined;
      /** @type {?} */

      var directiveEnd = tNode.directiveEnd;
      ngDevMode && assertNotEqual(tNode.directiveStylingLast, -1, 'By the time this function gets called at least one hostBindings-node styling instruction must have executed.'); // We add `1 + tNode.directiveStart` because we need to skip the current directive (as we are
      // collecting things after the last `hostBindings` directive which had a styling instruction.)

      for (var i = 1 + tNode.directiveStylingLast; i < directiveEnd; i++) {
        /** @type {?} */
        var attrs =
        /** @type {?} */
        tData[i].hostAttrs;
        residual =
        /** @type {?} */
        collectStylingFromTAttrs(residual, attrs, isClassBased);
      }

      return (
        /** @type {?} */
        collectStylingFromTAttrs(residual, tNode.attrs, isClassBased)
      );
    }
    /**
     * Collect the static styling information with lower priority than `hostDirectiveDef`.
     *
     * (This is opposite of residual styling.)
     *
     * @param {?} hostDirectiveDef `DirectiveDef` for which we want to collect lower priority static
     *        styling. (Or `null` if template styling)
     * @param {?} tData `TData` where the linked list is stored.
     * @param {?} tNode `TNode` for which the styling is being computed.
     * @param {?} stylingKey Existing `TStylingKey` to update or wrap.
     * @param {?} isClassBased `true` if `class` (`false` if `style`)
     * @return {?}
     */


    function collectStylingFromDirectives(hostDirectiveDef, tData, tNode, stylingKey, isClassBased) {
      // We need to loop because there can be directives which have `hostAttrs` but don't have
      // `hostBindings` so this loop catches up to the current directive..

      /** @type {?} */
      var currentDirective = null;
      /** @type {?} */

      var directiveEnd = tNode.directiveEnd;
      /** @type {?} */

      var directiveStylingLast = tNode.directiveStylingLast;

      if (directiveStylingLast === -1) {
        directiveStylingLast = tNode.directiveStart;
      } else {
        directiveStylingLast++;
      }

      while (directiveStylingLast < directiveEnd) {
        currentDirective =
        /** @type {?} */
        tData[directiveStylingLast];
        ngDevMode && assertDefined(currentDirective, 'expected to be defined');
        stylingKey = collectStylingFromTAttrs(stylingKey, currentDirective.hostAttrs, isClassBased);
        if (currentDirective === hostDirectiveDef) break;
        directiveStylingLast++;
      }

      if (hostDirectiveDef !== null) {
        // we only advance the styling cursor if we are collecting data from host bindings.
        // Template executes before host bindings and so if we would update the index,
        // host bindings would not get their statics.
        tNode.directiveStylingLast = directiveStylingLast;
      }

      return stylingKey;
    }
    /**
     * Convert `TAttrs` into `TStylingStatic`.
     *
     * @param {?} stylingKey existing `TStylingKey` to update or wrap.
     * @param {?} attrs `TAttributes` to process.
     * @param {?} isClassBased `true` if `class` (`false` if `style`)
     * @return {?}
     */


    function collectStylingFromTAttrs(stylingKey, attrs, isClassBased) {
      /** @type {?} */
      var desiredMarker = isClassBased ? 1
      /* Classes */
      : 2
      /* Styles */
      ;
      /** @type {?} */

      var currentMarker = -1
      /* ImplicitAttributes */
      ;

      if (attrs !== null) {
        for (var i = 0; i < attrs.length; i++) {
          /** @type {?} */
          var item =
          /** @type {?} */
          attrs[i];

          if (typeof item === 'number') {
            currentMarker = item;
          } else {
            if (currentMarker === desiredMarker) {
              if (!Array.isArray(stylingKey)) {
                stylingKey = stylingKey === undefined ? [] :
                /** @type {?} */
                ['', stylingKey];
              }

              keyValueArraySet(
              /** @type {?} */
              stylingKey, item, isClassBased ? true : attrs[++i]);
            }
          }
        }
      }

      return stylingKey === undefined ? null : stylingKey;
    }
    /**
     * Convert user input to `KeyValueArray`.
     *
     * This function takes user input which could be `string`, Object literal, or iterable and converts
     * it into a consistent representation. The output of this is `KeyValueArray` (which is an array
     * where
     * even indexes contain keys and odd indexes contain values for those keys).
     *
     * The advantage of converting to `KeyValueArray` is that we can perform diff in an input
     * independent
     * way.
     * (ie we can compare `foo bar` to `['bar', 'baz'] and determine a set of changes which need to be
     * applied)
     *
     * The fact that `KeyValueArray` is sorted is very important because it allows us to compute the
     * difference in linear fashion without the need to allocate any additional data.
     *
     * For example if we kept this as a `Map` we would have to iterate over previous `Map` to determine
     * which values need to be deleted, over the new `Map` to determine additions, and we would have to
     * keep additional `Map` to keep track of duplicates or items which have not yet been visited.
     *
     * @param {?} keyValueArraySet (See `keyValueArraySet` in "util/array_utils") Gets passed in as a
     * function so that
     *        `style` can pass in version which does sanitization. This is done for tree shaking
     *        purposes.
     * @param {?} stringParser The parser is passed in so that it will be tree shakable. See
     *        `styleStringParser` and `classStringParser`
     * @param {?} value The value to parse/convert to `KeyValueArray`
     * @return {?}
     */


    function toStylingKeyValueArray(keyValueArraySet, stringParser, value) {
      if (value == null
      /*|| value === undefined */
      || value === '') return (
        /** @type {?} */
        EMPTY_ARRAY$3
      );
      /** @type {?} */

      var styleKeyValueArray =
      /** @type {?} */
      [];
      /** @type {?} */

      var unwrappedValue =
      /** @type {?} */
      unwrapSafeValue(value);

      if (Array.isArray(unwrappedValue)) {
        for (var i = 0; i < unwrappedValue.length; i++) {
          keyValueArraySet(styleKeyValueArray, unwrappedValue[i], true);
        }
      } else if (typeof unwrappedValue === 'object') {
        for (var key in unwrappedValue) {
          if (unwrappedValue.hasOwnProperty(key)) {
            keyValueArraySet(styleKeyValueArray, key, unwrappedValue[key]);
          }
        }
      } else if (typeof unwrappedValue === 'string') {
        stringParser(styleKeyValueArray, unwrappedValue);
      } else {
        ngDevMode && throwError('Unsupported styling type ' + typeof unwrappedValue + ': ' + unwrappedValue);
      }

      return styleKeyValueArray;
    }
    /**
     * Set a `value` for a `key` taking style sanitization into account.
     *
     * See: `keyValueArraySet` for details
     *
     * @param {?} keyValueArray KeyValueArray to add to.
     * @param {?} key Style key to add. (This key will be checked if it needs sanitization)
     * @param {?} value The value to set (If key needs sanitization it will be sanitized)
     * @return {?}
     */


    function styleKeyValueArraySet(keyValueArray, key, value) {
      if (stylePropNeedsSanitization(key)) {
        value = ɵɵsanitizeStyle(value);
      }

      keyValueArraySet(keyValueArray, key, value);
    }
    /**
     * Update map based styling.
     *
     * Map based styling could be anything which contains more than one binding. For example `string`,
     * or object literal. Dealing with all of these types would complicate the logic so
     * instead this function expects that the complex input is first converted into normalized
     * `KeyValueArray`. The advantage of normalization is that we get the values sorted, which makes it
     * very cheap to compute deltas between the previous and current value.
     *
     * @param {?} tView Associated `TView.data` contains the linked list of binding priorities.
     * @param {?} tNode `TNode` where the binding is located.
     * @param {?} lView `LView` contains the values associated with other styling binding at this `TNode`.
     * @param {?} renderer Renderer to use if any updates.
     * @param {?} oldKeyValueArray Previous value represented as `KeyValueArray`
     * @param {?} newKeyValueArray Current value represented as `KeyValueArray`
     * @param {?} isClassBased `true` if `class` (`false` if `style`)
     * @param {?} bindingIndex Binding index of the binding.
     * @return {?}
     */


    function updateStylingMap(tView, tNode, lView, renderer, oldKeyValueArray, newKeyValueArray, isClassBased, bindingIndex) {
      if (
      /** @type {?} */
      oldKeyValueArray === NO_CHANGE) {
        // On first execution the oldKeyValueArray is NO_CHANGE => treat it as empty KeyValueArray.
        oldKeyValueArray =
        /** @type {?} */
        EMPTY_ARRAY$3;
      }
      /** @type {?} */


      var oldIndex = 0;
      /** @type {?} */

      var newIndex = 0;
      /** @type {?} */

      var oldKey = 0 < oldKeyValueArray.length ? oldKeyValueArray[0] : null;
      /** @type {?} */

      var newKey = 0 < newKeyValueArray.length ? newKeyValueArray[0] : null;

      while (oldKey !== null || newKey !== null) {
        ngDevMode && assertLessThan(oldIndex, 999, 'Are we stuck in infinite loop?');
        ngDevMode && assertLessThan(newIndex, 999, 'Are we stuck in infinite loop?');
        /** @type {?} */

        var oldValue = oldIndex < oldKeyValueArray.length ? oldKeyValueArray[oldIndex + 1] : undefined;
        /** @type {?} */

        var newValue = newIndex < newKeyValueArray.length ? newKeyValueArray[newIndex + 1] : undefined;
        /** @type {?} */

        var setKey = null;
        /** @type {?} */

        var setValue = undefined;

        if (oldKey === newKey) {
          // UPDATE: Keys are equal => new value is overwriting old value.
          oldIndex += 2;
          newIndex += 2;

          if (oldValue !== newValue) {
            setKey = newKey;
            setValue = newValue;
          }
        } else if (newKey === null || oldKey !== null && oldKey <
        /** @type {?} */
        newKey) {
          // DELETE: oldKey key is missing or we did not find the oldKey in the newValue
          // (because the keyValueArray is sorted and `newKey` is found later alphabetically).
          // `"background" < "color"` so we need to delete `"background"` because it is not found in the
          // new array.
          oldIndex += 2;
          setKey = oldKey;
        } else {
          // CREATE: newKey's is earlier alphabetically than oldKey's (or no oldKey) => we have new key.
          // `"color" > "background"` so we need to add `color` because it is in new array but not in
          // old array.
          ngDevMode && assertDefined(newKey, 'Expecting to have a valid key');
          newIndex += 2;
          setKey = newKey;
          setValue = newValue;
        }

        if (setKey !== null) {
          updateStyling(tView, tNode, lView, renderer, setKey, setValue, isClassBased, bindingIndex);
        }

        oldKey = oldIndex < oldKeyValueArray.length ? oldKeyValueArray[oldIndex] : null;
        newKey = newIndex < newKeyValueArray.length ? newKeyValueArray[newIndex] : null;
      }
    }
    /**
     * Update a simple (property name) styling.
     *
     * This function takes `prop` and updates the DOM to that value. The function takes the binding
     * value as well as binding priority into consideration to determine which value should be written
     * to DOM. (For example it may be determined that there is a higher priority overwrite which blocks
     * the DOM write, or if the value goes to `undefined` a lower priority overwrite may be consulted.)
     *
     * @param {?} tView Associated `TView.data` contains the linked list of binding priorities.
     * @param {?} tNode `TNode` where the binding is located.
     * @param {?} lView `LView` contains the values associated with other styling binding at this `TNode`.
     * @param {?} renderer Renderer to use if any updates.
     * @param {?} prop Either style property name or a class name.
     * @param {?} value Either style value for `prop` or `true`/`false` if `prop` is class.
     * @param {?} isClassBased `true` if `class` (`false` if `style`)
     * @param {?} bindingIndex Binding index of the binding.
     * @return {?}
     */


    function updateStyling(tView, tNode, lView, renderer, prop, value, isClassBased, bindingIndex) {
      if (tNode.type !== 3
      /* Element */
      ) {
          // It is possible to have styling on non-elements (such as ng-container).
          // This is rare, but it does happen. In such a case, just ignore the binding.
          return;
        }
      /** @type {?} */


      var tData = tView.data;
      /** @type {?} */

      var tRange =
      /** @type {?} */
      tData[bindingIndex + 1];
      /** @type {?} */

      var higherPriorityValue = getTStylingRangeNextDuplicate(tRange) ? findStylingValue(tData, tNode, lView, prop, getTStylingRangeNext(tRange), isClassBased) : undefined;

      if (!isStylingValuePresent(higherPriorityValue)) {
        // We don't have a next duplicate, or we did not find a duplicate value.
        if (!isStylingValuePresent(value)) {
          // We should delete current value or restore to lower priority value.
          if (getTStylingRangePrevDuplicate(tRange)) {
            // We have a possible prev duplicate, let's retrieve it.
            value = findStylingValue(tData, null, lView, prop, bindingIndex, isClassBased);
          }
        }
        /** @type {?} */


        var rNode =
        /** @type {?} */
        getNativeByIndex(getSelectedIndex(), lView);
        applyStyling(renderer, isClassBased, rNode, prop, value);
      }
    }
    /**
     * Search for styling value with higher priority which is overwriting current value, or a
     * value of lower priority to which we should fall back if the value is `undefined`.
     *
     * When value is being applied at a location, related values need to be consulted.
     * - If there is a higher priority binding, we should be using that one instead.
     *   For example `<div  [style]="{color:exp1}" [style.color]="exp2">` change to `exp1`
     *   requires that we check `exp2` to see if it is set to value other than `undefined`.
     * - If there is a lower priority binding and we are changing to `undefined`
     *   For example `<div  [style]="{color:exp1}" [style.color]="exp2">` change to `exp2` to
     *   `undefined` requires that we check `exp1` (and static values) and use that as new value.
     *
     * NOTE: The styling stores two values.
     * 1. The raw value which came from the application is stored at `index + 0` location. (This value
     *    is used for dirty checking).
     * 2. The normalized value (converted to `KeyValueArray` if map and sanitized) is stored at `index +
     * 1`.
     *    The advantage of storing the sanitized value is that once the value is written we don't need
     *    to worry about sanitizing it later or keeping track of the sanitizer.
     *
     * @param {?} tData `TData` used for traversing the priority.
     * @param {?} tNode `TNode` to use for resolving static styling. Also controls search direction.
     *   - `TNode` search next and quit as soon as `isStylingValuePresent(value)` is true.
     *      If no value found consult `tNode.residualStyle`/`tNode.residualClass` for default value.
     *   - `null` search prev and go all the way to end. Return last value where
     *     `isStylingValuePresent(value)` is true.
     * @param {?} lView `LView` used for retrieving the actual values.
     * @param {?} prop Property which we are interested in.
     * @param {?} index Starting index in the linked list of styling bindings where the search should start.
     * @param {?} isClassBased `true` if `class` (`false` if `style`)
     * @return {?}
     */


    function findStylingValue(tData, tNode, lView, prop, index, isClassBased) {
      // `TNode` to use for resolving static styling. Also controls search direction.
      //   - `TNode` search next and quit as soon as `isStylingValuePresent(value)` is true.
      //      If no value found consult `tNode.residualStyle`/`tNode.residualClass` for default value.
      //   - `null` search prev and go all the way to end. Return last value where
      //     `isStylingValuePresent(value)` is true.

      /** @type {?} */
      var isPrevDirection = tNode === null;
      /** @type {?} */

      var value = undefined;

      while (index > 0) {
        /** @type {?} */
        var rawKey =
        /** @type {?} */
        tData[index];
        /** @type {?} */

        var containsStatics = Array.isArray(rawKey); // Unwrap the key if we contain static values.

        /** @type {?} */

        var key = containsStatics ?
        /** @type {?} */
        rawKey[1] : rawKey;
        /** @type {?} */

        var isStylingMap = key === null;
        /** @type {?} */

        var valueAtLViewIndex = lView[index + 1];

        if (valueAtLViewIndex === NO_CHANGE) {
          // In firstUpdatePass the styling instructions create a linked list of styling.
          // On subsequent passes it is possible for a styling instruction to try to read a binding
          // which
          // has not yet executed. In that case we will find `NO_CHANGE` and we should assume that
          // we have `undefined` (or empty array in case of styling-map instruction) instead. This
          // allows the resolution to apply the value (which may later be overwritten when the
          // binding actually executes.)
          valueAtLViewIndex = isStylingMap ? EMPTY_ARRAY$3 : undefined;
        }
        /** @type {?} */


        var currentValue = isStylingMap ? keyValueArrayGet(valueAtLViewIndex, prop) : key === prop ? valueAtLViewIndex : undefined;

        if (containsStatics && !isStylingValuePresent(currentValue)) {
          currentValue = keyValueArrayGet(
          /** @type {?} */
          rawKey, prop);
        }

        if (isStylingValuePresent(currentValue)) {
          value = currentValue;

          if (isPrevDirection) {
            return value;
          }
        }
        /** @type {?} */


        var tRange =
        /** @type {?} */
        tData[index + 1];
        index = isPrevDirection ? getTStylingRangePrev(tRange) : getTStylingRangeNext(tRange);
      }

      if (tNode !== null) {
        // in case where we are going in next direction AND we did not find anything, we need to
        // consult residual styling

        /** @type {?} */
        var residual = isClassBased ? tNode.residualClasses : tNode.residualStyles;

        if (residual != null
        /** OR residual !=== undefined */
        ) {
            value = keyValueArrayGet(
            /** @type {?} */
            residual, prop);
          }
      }

      return value;
    }
    /**
     * Determines if the binding value should be used (or if the value is 'undefined' and hence priority
     * resolution should be used.)
     *
     * @param {?} value Binding style value.
     * @return {?}
     */


    function isStylingValuePresent(value) {
      // Currently only `undefined` value is considered non-binding. That is `undefined` says I don't
      // have an opinion as to what this binding should be and you should consult other bindings by
      // priority to determine the valid value.
      // This is extracted into a single function so that we have a single place to control this.
      return value !== undefined;
    }
    /**
     * Sanitizes or adds suffix to the value.
     *
     * If value is `null`/`undefined` no suffix is added
     * @param {?} value
     * @param {?} suffixOrSanitizer
     * @return {?}
     */


    function normalizeAndApplySuffixOrSanitizer(value, suffixOrSanitizer) {
      if (value == null
      /** || value === undefined */
      ) {// do nothing
        } else if (typeof suffixOrSanitizer === 'function') {
        // sanitize the value.
        value = suffixOrSanitizer(value);
      } else if (typeof suffixOrSanitizer === 'string') {
        value = value + suffixOrSanitizer;
      } else if (typeof value === 'object') {
        value = stringify(unwrapSafeValue(value));
      }

      return value;
    }
    /**
     * Tests if the `TNode` has input shadow.
     *
     * An input shadow is when a directive steals (shadows) the input by using `\@Input('style')` or
     * `\@Input('class')` as input.
     *
     * @param {?} tNode `TNode` which we would like to see if it has shadow.
     * @param {?} isClassBased `true` if `class` (`false` if `style`)
     * @return {?}
     */


    function hasStylingInputShadow(tNode, isClassBased) {
      return (tNode.flags & (isClassBased ? 16
      /* hasClassInput */
      : 32
      /* hasStyleInput */
      )) !== 0;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/text.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Create static text node
     *
     * \@codeGenApi
     * @param {?} index Index of the node in the data array
     * @param {?=} value Static string value to write.
     *
     * @return {?}
     */


    function ɵɵtext(index) {
      var value = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';

      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var tView = getTView();
      /** @type {?} */

      var adjustedIndex = index + HEADER_OFFSET;
      ngDevMode && assertEqual(getBindingIndex(), tView.bindingStartIndex, 'text nodes should be created before any bindings');
      ngDevMode && assertDataInRange(lView, adjustedIndex);
      /** @type {?} */

      var tNode = tView.firstCreatePass ? getOrCreateTNode(tView, lView[T_HOST], index, 3
      /* Element */
      , null, null) :
      /** @type {?} */
      tView.data[adjustedIndex];
      /** @type {?} */

      var textNative = lView[adjustedIndex] = createTextNode(value, lView[RENDERER]);
      appendChild(tView, lView, textNative, tNode); // Text nodes are self closing.

      setPreviousOrParentTNode(tNode, false);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/text_interpolation.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     *
     * Update text content with a lone bound value
     *
     * Used when a text node has 1 interpolated value in it, an no additional text
     * surrounds that interpolated value:
     *
     * ```html
     * <div>{{v0}}</div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵtextInterpolate(v0);
     * ```
     * @see textInterpolateV
     * \@codeGenApi
     * @param {?} v0
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵtextInterpolate(v0) {
      ɵɵtextInterpolate1('', v0, '');
      return ɵɵtextInterpolate;
    }
    /**
     *
     * Update text content with single bound value surrounded by other text.
     *
     * Used when a text node has 1 interpolated value in it:
     *
     * ```html
     * <div>prefix{{v0}}suffix</div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵtextInterpolate1('prefix', v0, 'suffix');
     * ```
     * @see textInterpolateV
     * \@codeGenApi
     * @param {?} prefix
     * @param {?} v0
     * @param {?} suffix
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵtextInterpolate1(prefix, v0, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolated = interpolation1(lView, prefix, v0, suffix);

      if (interpolated !== NO_CHANGE) {
        textBindingInternal(lView, getSelectedIndex(),
        /** @type {?} */
        interpolated);
      }

      return ɵɵtextInterpolate1;
    }
    /**
     *
     * Update text content with 2 bound values surrounded by other text.
     *
     * Used when a text node has 2 interpolated values in it:
     *
     * ```html
     * <div>prefix{{v0}}-{{v1}}suffix</div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵtextInterpolate2('prefix', v0, '-', v1, 'suffix');
     * ```
     * @see textInterpolateV
     * \@codeGenApi
     * @param {?} prefix
     * @param {?} v0
     * @param {?} i0
     * @param {?} v1
     * @param {?} suffix
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵtextInterpolate2(prefix, v0, i0, v1, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolated = interpolation2(lView, prefix, v0, i0, v1, suffix);

      if (interpolated !== NO_CHANGE) {
        textBindingInternal(lView, getSelectedIndex(),
        /** @type {?} */
        interpolated);
      }

      return ɵɵtextInterpolate2;
    }
    /**
     *
     * Update text content with 3 bound values surrounded by other text.
     *
     * Used when a text node has 3 interpolated values in it:
     *
     * ```html
     * <div>prefix{{v0}}-{{v1}}-{{v2}}suffix</div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵtextInterpolate3(
     * 'prefix', v0, '-', v1, '-', v2, 'suffix');
     * ```
     * @see textInterpolateV
     * \@codeGenApi
     * @param {?} prefix
     * @param {?} v0
     * @param {?} i0
     * @param {?} v1
     * @param {?} i1
     * @param {?} v2
     * @param {?} suffix
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵtextInterpolate3(prefix, v0, i0, v1, i1, v2, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolated = interpolation3(lView, prefix, v0, i0, v1, i1, v2, suffix);

      if (interpolated !== NO_CHANGE) {
        textBindingInternal(lView, getSelectedIndex(),
        /** @type {?} */
        interpolated);
      }

      return ɵɵtextInterpolate3;
    }
    /**
     *
     * Update text content with 4 bound values surrounded by other text.
     *
     * Used when a text node has 4 interpolated values in it:
     *
     * ```html
     * <div>prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}suffix</div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵtextInterpolate4(
     * 'prefix', v0, '-', v1, '-', v2, '-', v3, 'suffix');
     * ```
     * @see ɵɵtextInterpolateV
     * \@codeGenApi
     * @param {?} prefix
     * @param {?} v0
     * @param {?} i0
     * @param {?} v1
     * @param {?} i1
     * @param {?} v2
     * @param {?} i2
     * @param {?} v3
     * @param {?} suffix
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵtextInterpolate4(prefix, v0, i0, v1, i1, v2, i2, v3, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolated = interpolation4(lView, prefix, v0, i0, v1, i1, v2, i2, v3, suffix);

      if (interpolated !== NO_CHANGE) {
        textBindingInternal(lView, getSelectedIndex(),
        /** @type {?} */
        interpolated);
      }

      return ɵɵtextInterpolate4;
    }
    /**
     *
     * Update text content with 5 bound values surrounded by other text.
     *
     * Used when a text node has 5 interpolated values in it:
     *
     * ```html
     * <div>prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}suffix</div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵtextInterpolate5(
     * 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, 'suffix');
     * ```
     * @see textInterpolateV
     * \@codeGenApi
     * @param {?} prefix
     * @param {?} v0
     * @param {?} i0
     * @param {?} v1
     * @param {?} i1
     * @param {?} v2
     * @param {?} i2
     * @param {?} v3
     * @param {?} i3
     * @param {?} v4
     * @param {?} suffix
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵtextInterpolate5(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolated = interpolation5(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix);

      if (interpolated !== NO_CHANGE) {
        textBindingInternal(lView, getSelectedIndex(),
        /** @type {?} */
        interpolated);
      }

      return ɵɵtextInterpolate5;
    }
    /**
     *
     * Update text content with 6 bound values surrounded by other text.
     *
     * Used when a text node has 6 interpolated values in it:
     *
     * ```html
     * <div>prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}suffix</div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵtextInterpolate6(
     *    'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, 'suffix');
     * ```
     *
     * @see textInterpolateV
     * \@codeGenApi
     * @param {?} prefix
     * @param {?} v0
     * @param {?} i0
     * @param {?} v1
     * @param {?} i1
     * @param {?} v2
     * @param {?} i2
     * @param {?} v3
     * @param {?} i3
     * @param {?} v4
     * @param {?} i4 Static value used for concatenation only.
     * @param {?} v5 Value checked for change. \@returns itself, so that it may be chained.
     * @param {?} suffix
     * @return {?}
     */


    function ɵɵtextInterpolate6(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolated = interpolation6(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix);

      if (interpolated !== NO_CHANGE) {
        textBindingInternal(lView, getSelectedIndex(),
        /** @type {?} */
        interpolated);
      }

      return ɵɵtextInterpolate6;
    }
    /**
     *
     * Update text content with 7 bound values surrounded by other text.
     *
     * Used when a text node has 7 interpolated values in it:
     *
     * ```html
     * <div>prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}suffix</div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵtextInterpolate7(
     *    'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, 'suffix');
     * ```
     * @see textInterpolateV
     * \@codeGenApi
     * @param {?} prefix
     * @param {?} v0
     * @param {?} i0
     * @param {?} v1
     * @param {?} i1
     * @param {?} v2
     * @param {?} i2
     * @param {?} v3
     * @param {?} i3
     * @param {?} v4
     * @param {?} i4
     * @param {?} v5
     * @param {?} i5
     * @param {?} v6
     * @param {?} suffix
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵtextInterpolate7(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolated = interpolation7(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix);

      if (interpolated !== NO_CHANGE) {
        textBindingInternal(lView, getSelectedIndex(),
        /** @type {?} */
        interpolated);
      }

      return ɵɵtextInterpolate7;
    }
    /**
     *
     * Update text content with 8 bound values surrounded by other text.
     *
     * Used when a text node has 8 interpolated values in it:
     *
     * ```html
     * <div>prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}suffix</div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵtextInterpolate8(
     *  'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, 'suffix');
     * ```
     * @see textInterpolateV
     * \@codeGenApi
     * @param {?} prefix
     * @param {?} v0
     * @param {?} i0
     * @param {?} v1
     * @param {?} i1
     * @param {?} v2
     * @param {?} i2
     * @param {?} v3
     * @param {?} i3
     * @param {?} v4
     * @param {?} i4
     * @param {?} v5
     * @param {?} i5
     * @param {?} v6
     * @param {?} i6
     * @param {?} v7
     * @param {?} suffix
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵtextInterpolate8(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolated = interpolation8(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix);

      if (interpolated !== NO_CHANGE) {
        textBindingInternal(lView, getSelectedIndex(),
        /** @type {?} */
        interpolated);
      }

      return ɵɵtextInterpolate8;
    }
    /**
     * Update text content with 9 or more bound values other surrounded by text.
     *
     * Used when the number of interpolated values exceeds 8.
     *
     * ```html
     * <div>prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}-{{v8}}-{{v9}}suffix</div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵtextInterpolateV(
     *  ['prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, '-', v9,
     *  'suffix']);
     * ```
     * .
     * \@codeGenApi
     * @param {?} values The collection of values and the strings in between those values, beginning with
     * a string prefix and ending with a string suffix.
     * (e.g. `['prefix', value0, '-', value1, '-', value2, ..., value99, 'suffix']`)
     *
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵtextInterpolateV(values) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolated = interpolationV(lView, values);

      if (interpolated !== NO_CHANGE) {
        textBindingInternal(lView, getSelectedIndex(),
        /** @type {?} */
        interpolated);
      }

      return ɵɵtextInterpolateV;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/class_map_interpolation.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     *
     * Update an interpolated class on an element with single bound value surrounded by text.
     *
     * Used when the value passed to a property has 1 interpolated value in it:
     *
     * ```html
     * <div class="prefix{{v0}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵclassMapInterpolate1('prefix', v0, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @return {?}
     */


    function ɵɵclassMapInterpolate1(prefix, v0, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation1(lView, prefix, v0, suffix);
      checkStylingMap(keyValueArraySet, classStringParser, interpolatedValue, true);
    }
    /**
     *
     * Update an interpolated class on an element with 2 bound values surrounded by text.
     *
     * Used when the value passed to a property has 2 interpolated values in it:
     *
     * ```html
     * <div class="prefix{{v0}}-{{v1}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵclassMapInterpolate2('prefix', v0, '-', v1, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @return {?}
     */


    function ɵɵclassMapInterpolate2(prefix, v0, i0, v1, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation2(lView, prefix, v0, i0, v1, suffix);
      checkStylingMap(keyValueArraySet, classStringParser, interpolatedValue, true);
    }
    /**
     *
     * Update an interpolated class on an element with 3 bound values surrounded by text.
     *
     * Used when the value passed to a property has 3 interpolated values in it:
     *
     * ```html
     * <div class="prefix{{v0}}-{{v1}}-{{v2}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵclassMapInterpolate3(
     * 'prefix', v0, '-', v1, '-', v2, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @return {?}
     */


    function ɵɵclassMapInterpolate3(prefix, v0, i0, v1, i1, v2, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation3(lView, prefix, v0, i0, v1, i1, v2, suffix);
      checkStylingMap(keyValueArraySet, classStringParser, interpolatedValue, true);
    }
    /**
     *
     * Update an interpolated class on an element with 4 bound values surrounded by text.
     *
     * Used when the value passed to a property has 4 interpolated values in it:
     *
     * ```html
     * <div class="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵclassMapInterpolate4(
     * 'prefix', v0, '-', v1, '-', v2, '-', v3, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @return {?}
     */


    function ɵɵclassMapInterpolate4(prefix, v0, i0, v1, i1, v2, i2, v3, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation4(lView, prefix, v0, i0, v1, i1, v2, i2, v3, suffix);
      checkStylingMap(keyValueArraySet, classStringParser, interpolatedValue, true);
    }
    /**
     *
     * Update an interpolated class on an element with 5 bound values surrounded by text.
     *
     * Used when the value passed to a property has 5 interpolated values in it:
     *
     * ```html
     * <div class="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵclassMapInterpolate5(
     * 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} i3 Static value used for concatenation only.
     * @param {?} v4 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @return {?}
     */


    function ɵɵclassMapInterpolate5(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation5(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix);
      checkStylingMap(keyValueArraySet, classStringParser, interpolatedValue, true);
    }
    /**
     *
     * Update an interpolated class on an element with 6 bound values surrounded by text.
     *
     * Used when the value passed to a property has 6 interpolated values in it:
     *
     * ```html
     * <div class="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵclassMapInterpolate6(
     *    'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} i3 Static value used for concatenation only.
     * @param {?} v4 Value checked for change.
     * @param {?} i4 Static value used for concatenation only.
     * @param {?} v5 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @return {?}
     */


    function ɵɵclassMapInterpolate6(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation6(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix);
      checkStylingMap(keyValueArraySet, classStringParser, interpolatedValue, true);
    }
    /**
     *
     * Update an interpolated class on an element with 7 bound values surrounded by text.
     *
     * Used when the value passed to a property has 7 interpolated values in it:
     *
     * ```html
     * <div class="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵclassMapInterpolate7(
     *    'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} i3 Static value used for concatenation only.
     * @param {?} v4 Value checked for change.
     * @param {?} i4 Static value used for concatenation only.
     * @param {?} v5 Value checked for change.
     * @param {?} i5 Static value used for concatenation only.
     * @param {?} v6 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @return {?}
     */


    function ɵɵclassMapInterpolate7(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation7(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix);
      checkStylingMap(keyValueArraySet, classStringParser, interpolatedValue, true);
    }
    /**
     *
     * Update an interpolated class on an element with 8 bound values surrounded by text.
     *
     * Used when the value passed to a property has 8 interpolated values in it:
     *
     * ```html
     * <div class="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵclassMapInterpolate8(
     *  'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} i3 Static value used for concatenation only.
     * @param {?} v4 Value checked for change.
     * @param {?} i4 Static value used for concatenation only.
     * @param {?} v5 Value checked for change.
     * @param {?} i5 Static value used for concatenation only.
     * @param {?} v6 Value checked for change.
     * @param {?} i6 Static value used for concatenation only.
     * @param {?} v7 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @return {?}
     */


    function ɵɵclassMapInterpolate8(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation8(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix);
      checkStylingMap(keyValueArraySet, classStringParser, interpolatedValue, true);
    }
    /**
     * Update an interpolated class on an element with 9 or more bound values surrounded by text.
     *
     * Used when the number of interpolated values exceeds 8.
     *
     * ```html
     * <div
     *  class="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}-{{v8}}-{{v9}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵclassMapInterpolateV(
     *  ['prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, '-', v9,
     *  'suffix']);
     * ```
     * .
     * \@codeGenApi
     * @param {?} values The collection of values and the strings in-between those values, beginning with
     * a string prefix and ending with a string suffix.
     * (e.g. `['prefix', value0, '-', value1, '-', value2, ..., value99, 'suffix']`)
     * @return {?}
     */


    function ɵɵclassMapInterpolateV(values) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolationV(lView, values);
      checkStylingMap(keyValueArraySet, classStringParser, interpolatedValue, true);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/style_map_interpolation.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     *
     * Update an interpolated style on an element with single bound value surrounded by text.
     *
     * Used when the value passed to a property has 1 interpolated value in it:
     *
     * ```html
     * <div style="key: {{v0}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵstyleMapInterpolate1('key: ', v0, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @return {?}
     */


    function ɵɵstyleMapInterpolate1(prefix, v0, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation1(lView, prefix, v0, suffix);
      ɵɵstyleMap(interpolatedValue);
    }
    /**
     *
     * Update an interpolated style on an element with 2 bound values surrounded by text.
     *
     * Used when the value passed to a property has 2 interpolated values in it:
     *
     * ```html
     * <div style="key: {{v0}}; key1: {{v1}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵstyleMapInterpolate2('key: ', v0, '; key1: ', v1, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @return {?}
     */


    function ɵɵstyleMapInterpolate2(prefix, v0, i0, v1, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation2(lView, prefix, v0, i0, v1, suffix);
      ɵɵstyleMap(interpolatedValue);
    }
    /**
     *
     * Update an interpolated style on an element with 3 bound values surrounded by text.
     *
     * Used when the value passed to a property has 3 interpolated values in it:
     *
     * ```html
     * <div style="key: {{v0}}; key2: {{v1}}; key2: {{v2}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵstyleMapInterpolate3(
     *     'key: ', v0, '; key1: ', v1, '; key2: ', v2, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @return {?}
     */


    function ɵɵstyleMapInterpolate3(prefix, v0, i0, v1, i1, v2, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation3(lView, prefix, v0, i0, v1, i1, v2, suffix);
      ɵɵstyleMap(interpolatedValue);
    }
    /**
     *
     * Update an interpolated style on an element with 4 bound values surrounded by text.
     *
     * Used when the value passed to a property has 4 interpolated values in it:
     *
     * ```html
     * <div style="key: {{v0}}; key1: {{v1}}; key2: {{v2}}; key3: {{v3}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵstyleMapInterpolate4(
     *     'key: ', v0, '; key1: ', v1, '; key2: ', v2, '; key3: ', v3, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @return {?}
     */


    function ɵɵstyleMapInterpolate4(prefix, v0, i0, v1, i1, v2, i2, v3, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation4(lView, prefix, v0, i0, v1, i1, v2, i2, v3, suffix);
      ɵɵstyleMap(interpolatedValue);
    }
    /**
     *
     * Update an interpolated style on an element with 5 bound values surrounded by text.
     *
     * Used when the value passed to a property has 5 interpolated values in it:
     *
     * ```html
     * <div style="key: {{v0}}; key1: {{v1}}; key2: {{v2}}; key3: {{v3}}; key4: {{v4}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵstyleMapInterpolate5(
     *     'key: ', v0, '; key1: ', v1, '; key2: ', v2, '; key3: ', v3, '; key4: ', v4, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} i3 Static value used for concatenation only.
     * @param {?} v4 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @return {?}
     */


    function ɵɵstyleMapInterpolate5(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation5(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix);
      ɵɵstyleMap(interpolatedValue);
    }
    /**
     *
     * Update an interpolated style on an element with 6 bound values surrounded by text.
     *
     * Used when the value passed to a property has 6 interpolated values in it:
     *
     * ```html
     * <div style="key: {{v0}}; key1: {{v1}}; key2: {{v2}}; key3: {{v3}}; key4: {{v4}};
     *             key5: {{v5}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵstyleMapInterpolate6(
     *    'key: ', v0, '; key1: ', v1, '; key2: ', v2, '; key3: ', v3, '; key4: ', v4, '; key5: ', v5,
     *    'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} i3 Static value used for concatenation only.
     * @param {?} v4 Value checked for change.
     * @param {?} i4 Static value used for concatenation only.
     * @param {?} v5 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @return {?}
     */


    function ɵɵstyleMapInterpolate6(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation6(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix);
      ɵɵstyleMap(interpolatedValue);
    }
    /**
     *
     * Update an interpolated style on an element with 7 bound values surrounded by text.
     *
     * Used when the value passed to a property has 7 interpolated values in it:
     *
     * ```html
     * <div style="key: {{v0}}; key1: {{v1}}; key2: {{v2}}; key3: {{v3}}; key4: {{v4}}; key5: {{v5}};
     *             key6: {{v6}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵstyleMapInterpolate7(
     *    'key: ', v0, '; key1: ', v1, '; key2: ', v2, '; key3: ', v3, '; key4: ', v4, '; key5: ', v5,
     *    '; key6: ', v6, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} i3 Static value used for concatenation only.
     * @param {?} v4 Value checked for change.
     * @param {?} i4 Static value used for concatenation only.
     * @param {?} v5 Value checked for change.
     * @param {?} i5 Static value used for concatenation only.
     * @param {?} v6 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @return {?}
     */


    function ɵɵstyleMapInterpolate7(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation7(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix);
      ɵɵstyleMap(interpolatedValue);
    }
    /**
     *
     * Update an interpolated style on an element with 8 bound values surrounded by text.
     *
     * Used when the value passed to a property has 8 interpolated values in it:
     *
     * ```html
     * <div style="key: {{v0}}; key1: {{v1}}; key2: {{v2}}; key3: {{v3}}; key4: {{v4}}; key5: {{v5}};
     *             key6: {{v6}}; key7: {{v7}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵstyleMapInterpolate8(
     *    'key: ', v0, '; key1: ', v1, '; key2: ', v2, '; key3: ', v3, '; key4: ', v4, '; key5: ', v5,
     *    '; key6: ', v6, '; key7: ', v7, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} i3 Static value used for concatenation only.
     * @param {?} v4 Value checked for change.
     * @param {?} i4 Static value used for concatenation only.
     * @param {?} v5 Value checked for change.
     * @param {?} i5 Static value used for concatenation only.
     * @param {?} v6 Value checked for change.
     * @param {?} i6 Static value used for concatenation only.
     * @param {?} v7 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @return {?}
     */


    function ɵɵstyleMapInterpolate8(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation8(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix);
      ɵɵstyleMap(interpolatedValue);
    }
    /**
     * Update an interpolated style on an element with 9 or more bound values surrounded by text.
     *
     * Used when the number of interpolated values exceeds 8.
     *
     * ```html
     * <div
     *  class="key: {{v0}}; key1: {{v1}}; key2: {{v2}}; key3: {{v3}}; key4: {{v4}}; key5: {{v5}};
     *         key6: {{v6}}; key7: {{v7}}; key8: {{v8}}; key9: {{v9}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵstyleMapInterpolateV(
     *    ['key: ', v0, '; key1: ', v1, '; key2: ', v2, '; key3: ', v3, '; key4: ', v4, '; key5: ', v5,
     *     '; key6: ', v6, '; key7: ', v7, '; key8: ', v8, '; key9: ', v9, 'suffix']);
     * ```
     * .
     * \@codeGenApi
     * @param {?} values The collection of values and the strings in-between those values, beginning with
     * a string prefix and ending with a string suffix.
     * (e.g. `['prefix', value0, '; key2: ', value1, '; key2: ', value2, ..., value99, 'suffix']`)
     * @return {?}
     */


    function ɵɵstyleMapInterpolateV(values) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolationV(lView, values);
      ɵɵstyleMap(interpolatedValue);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/style_prop_interpolation.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     *
     * Update an interpolated style property on an element with single bound value surrounded by text.
     *
     * Used when the value passed to a property has 1 interpolated value in it:
     *
     * ```html
     * <div style.color="prefix{{v0}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵstylePropInterpolate1(0, 'prefix', v0, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prop
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵstylePropInterpolate1(prop, prefix, v0, suffix, valueSuffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation1(lView, prefix, v0, suffix);
      checkStylingProperty(prop, interpolatedValue, valueSuffix, false);
      return ɵɵstylePropInterpolate1;
    }
    /**
     *
     * Update an interpolated style property on an element with 2 bound values surrounded by text.
     *
     * Used when the value passed to a property has 2 interpolated values in it:
     *
     * ```html
     * <div style.color="prefix{{v0}}-{{v1}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵstylePropInterpolate2(0, 'prefix', v0, '-', v1, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prop
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵstylePropInterpolate2(prop, prefix, v0, i0, v1, suffix, valueSuffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation2(lView, prefix, v0, i0, v1, suffix);
      checkStylingProperty(prop, interpolatedValue, valueSuffix, false);
      return ɵɵstylePropInterpolate2;
    }
    /**
     *
     * Update an interpolated style property on an element with 3 bound values surrounded by text.
     *
     * Used when the value passed to a property has 3 interpolated values in it:
     *
     * ```html
     * <div style.color="prefix{{v0}}-{{v1}}-{{v2}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵstylePropInterpolate3(0, 'prefix', v0, '-', v1, '-', v2, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prop
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵstylePropInterpolate3(prop, prefix, v0, i0, v1, i1, v2, suffix, valueSuffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation3(lView, prefix, v0, i0, v1, i1, v2, suffix);
      checkStylingProperty(prop, interpolatedValue, valueSuffix, false);
      return ɵɵstylePropInterpolate3;
    }
    /**
     *
     * Update an interpolated style property on an element with 4 bound values surrounded by text.
     *
     * Used when the value passed to a property has 4 interpolated values in it:
     *
     * ```html
     * <div style.color="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵstylePropInterpolate4(0, 'prefix', v0, '-', v1, '-', v2, '-', v3, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prop
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵstylePropInterpolate4(prop, prefix, v0, i0, v1, i1, v2, i2, v3, suffix, valueSuffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation4(lView, prefix, v0, i0, v1, i1, v2, i2, v3, suffix);
      checkStylingProperty(prop, interpolatedValue, valueSuffix, false);
      return ɵɵstylePropInterpolate4;
    }
    /**
     *
     * Update an interpolated style property on an element with 5 bound values surrounded by text.
     *
     * Used when the value passed to a property has 5 interpolated values in it:
     *
     * ```html
     * <div style.color="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵstylePropInterpolate5(0, 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prop
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} i3 Static value used for concatenation only.
     * @param {?} v4 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵstylePropInterpolate5(prop, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix, valueSuffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation5(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix);
      checkStylingProperty(prop, interpolatedValue, valueSuffix, false);
      return ɵɵstylePropInterpolate5;
    }
    /**
     *
     * Update an interpolated style property on an element with 6 bound values surrounded by text.
     *
     * Used when the value passed to a property has 6 interpolated values in it:
     *
     * ```html
     * <div style.color="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵstylePropInterpolate6(0, 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prop
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} i3 Static value used for concatenation only.
     * @param {?} v4 Value checked for change.
     * @param {?} i4 Static value used for concatenation only.
     * @param {?} v5 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵstylePropInterpolate6(prop, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix, valueSuffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation6(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix);
      checkStylingProperty(prop, interpolatedValue, valueSuffix, false);
      return ɵɵstylePropInterpolate6;
    }
    /**
     *
     * Update an interpolated style property on an element with 7 bound values surrounded by text.
     *
     * Used when the value passed to a property has 7 interpolated values in it:
     *
     * ```html
     * <div style.color="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵstylePropInterpolate7(
     *    0, 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prop
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} i3 Static value used for concatenation only.
     * @param {?} v4 Value checked for change.
     * @param {?} i4 Static value used for concatenation only.
     * @param {?} v5 Value checked for change.
     * @param {?} i5 Static value used for concatenation only.
     * @param {?} v6 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵstylePropInterpolate7(prop, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix, valueSuffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation7(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix);
      checkStylingProperty(prop, interpolatedValue, valueSuffix, false);
      return ɵɵstylePropInterpolate7;
    }
    /**
     *
     * Update an interpolated style property on an element with 8 bound values surrounded by text.
     *
     * Used when the value passed to a property has 8 interpolated values in it:
     *
     * ```html
     * <div style.color="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}suffix"></div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵstylePropInterpolate8(0, 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6,
     * '-', v7, 'suffix');
     * ```
     *
     * \@codeGenApi
     * @param {?} prop
     * @param {?} prefix Static value used for concatenation only.
     * @param {?} v0 Value checked for change.
     * @param {?} i0 Static value used for concatenation only.
     * @param {?} v1 Value checked for change.
     * @param {?} i1 Static value used for concatenation only.
     * @param {?} v2 Value checked for change.
     * @param {?} i2 Static value used for concatenation only.
     * @param {?} v3 Value checked for change.
     * @param {?} i3 Static value used for concatenation only.
     * @param {?} v4 Value checked for change.
     * @param {?} i4 Static value used for concatenation only.
     * @param {?} v5 Value checked for change.
     * @param {?} i5 Static value used for concatenation only.
     * @param {?} v6 Value checked for change.
     * @param {?} i6 Static value used for concatenation only.
     * @param {?} v7 Value checked for change.
     * @param {?} suffix Static value used for concatenation only.
     * @param {?=} valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵstylePropInterpolate8(prop, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix, valueSuffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolation8(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix);
      checkStylingProperty(prop, interpolatedValue, valueSuffix, false);
      return ɵɵstylePropInterpolate8;
    }
    /**
     * Update an interpolated style property on an element with 9 or more bound values surrounded by
     * text.
     *
     * Used when the number of interpolated values exceeds 8.
     *
     * ```html
     * <div
     *  style.color="prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}-{{v8}}-{{v9}}suffix">
     * </div>
     * ```
     *
     * Its compiled representation is:
     *
     * ```ts
     * ɵɵstylePropInterpolateV(
     *  0, ['prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, '-', v9,
     *  'suffix']);
     * ```
     *
     * \@codeGenApi
     * @param {?} prop
     * @param {?} values The collection of values and the strings in-between those values, beginning with
     * a string prefix and ending with a string suffix.
     * (e.g. `['prefix', value0, '-', value1, '-', value2, ..., value99, 'suffix']`)
     * @param {?=} valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.
     * @return {?} itself, so that it may be chained.
     */


    function ɵɵstylePropInterpolateV(prop, values, valueSuffix) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var interpolatedValue = interpolationV(lView, values);
      checkStylingProperty(prop, interpolatedValue, valueSuffix, false);
      return ɵɵstylePropInterpolateV;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/host_property.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Update a property on a host element. Only applies to native node properties, not inputs.
     *
     * Operates on the element selected by index via the {\@link select} instruction.
     *
     * \@codeGenApi
     * @template T
     * @param {?} propName Name of property. Because it is going to DOM, this is not subject to
     *        renaming as part of minification.
     * @param {?} value New value to write.
     * @param {?=} sanitizer An optional function used to sanitize the value.
     * @return {?} This function returns itself so that it may be chained
     * (e.g. `property('name', ctx.name)('title', ctx.title)`)
     *
     */


    function ɵɵhostProperty(propName, value, sanitizer) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var bindingIndex = nextBindingIndex();

      if (bindingUpdated(lView, bindingIndex, value)) {
        /** @type {?} */
        var tView = getTView();
        /** @type {?} */

        var tNode = getSelectedTNode();
        elementPropertyInternal(tView, tNode, lView, propName, value, lView[RENDERER], sanitizer, true);
        ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, bindingIndex);
      }

      return ɵɵhostProperty;
    }
    /**
     * Updates a synthetic host binding (e.g. `[\@foo]`) on a component or directive.
     *
     * This instruction is for compatibility purposes and is designed to ensure that a
     * synthetic host binding (e.g. `\@HostBinding('\@foo')`) properly gets rendered in
     * the component's renderer. Normally all host bindings are evaluated with the parent
     * component's renderer, but, in the case of animation \@triggers, they need to be
     * evaluated with the sub component's renderer (because that's where the animation
     * triggers are defined).
     *
     * Do not use this instruction as a replacement for `elementProperty`. This instruction
     * only exists to ensure compatibility with the ViewEngine's host binding behavior.
     *
     * \@codeGenApi
     * @template T
     * @param {?} propName Name of property. Because it is going to DOM, this is not subject to
     *        renaming as part of minification.
     * @param {?} value New value to write.
     * @param {?=} sanitizer An optional function used to sanitize the value.
     *
     * @return {?}
     */


    function ɵɵupdateSyntheticHostBinding(propName, value, sanitizer) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var bindingIndex = nextBindingIndex();

      if (bindingUpdated(lView, bindingIndex, value)) {
        /** @type {?} */
        var tView = getTView();
        /** @type {?} */

        var tNode = getSelectedTNode();
        /** @type {?} */

        var currentDef = getCurrentDirectiveDef(tView.data);
        /** @type {?} */

        var renderer = loadComponentRenderer(currentDef, tNode, lView);
        elementPropertyInternal(tView, tNode, lView, propName, value, renderer, sanitizer, true);
        ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, bindingIndex);
      }

      return ɵɵupdateSyntheticHostBinding;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/instructions/all.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/util/discovery_utils.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Retrieves the component instance associated with a given DOM element.
     *
     * \@usageNotes
     * Given the following DOM structure:
     * ```html
     * <my-app>
     *   <div>
     *     <child-comp></child-comp>
     *   </div>
     * </my-app>
     * ```
     * Calling `getComponent` on `<child-comp>` will return the instance of `ChildComponent`
     * associated with this DOM element.
     *
     * Calling the function on `<my-app>` will return the `MyApp` instance.
     *
     *
     * \@publicApi
     * \@globalApi ng
     * @template T
     * @param {?} element DOM element from which the component should be retrieved.
     * @return {?} Component instance associated with the element or `null` if there
     *    is no component associated with it.
     *
     */


    function getComponent(element) {
      assertDomElement(element);
      /** @type {?} */

      var context = loadLContext(element, false);
      if (context === null) return null;

      if (context.component === undefined) {
        context.component = getComponentAtNodeIndex(context.nodeIndex, context.lView);
      }

      return (
        /** @type {?} */
        context.component
      );
    }
    /**
     * If inside an embedded view (e.g. `*ngIf` or `*ngFor`), retrieves the context of the embedded
     * view that the element is part of. Otherwise retrieves the instance of the component whose view
     * owns the element (in this case, the result is the same as calling `getOwningComponent`).
     *
     * \@publicApi
     * \@globalApi ng
     * @template T
     * @param {?} element Element for which to get the surrounding component instance.
     * @return {?} Instance of the component that is around the element or null if the element isn't
     *    inside any component.
     *
     */


    function getContext(element) {
      assertDomElement(element);
      /** @type {?} */

      var context = loadLContext(element, false);
      return context === null ? null :
      /** @type {?} */
      context.lView[CONTEXT];
    }
    /**
     * Retrieves the component instance whose view contains the DOM element.
     *
     * For example, if `<child-comp>` is used in the template of `<app-comp>`
     * (i.e. a `ViewChild` of `<app-comp>`), calling `getOwningComponent` on `<child-comp>`
     * would return `<app-comp>`.
     *
     * \@publicApi
     * \@globalApi ng
     * @template T
     * @param {?} elementOrDir DOM element, component or directive instance
     *    for which to retrieve the root components.
     * @return {?} Component instance whose view owns the DOM element or null if the element is not
     *    part of a component view.
     *
     */


    function getOwningComponent(elementOrDir) {
      /** @type {?} */
      var context = loadLContext(elementOrDir, false);
      if (context === null) return null;
      /** @type {?} */

      var lView = context.lView;
      /** @type {?} */

      var parent;
      ngDevMode && assertLView(lView);

      while (lView[HOST] === null && (parent =
      /** @type {?} */
      getLViewParent(lView))) {
        // As long as lView[HOST] is null we know we are part of sub-template such as `*ngIf`
        lView = parent;
      }

      return lView[FLAGS] & 512
      /* IsRoot */
      ? null :
      /** @type {?} */
      lView[CONTEXT];
    }
    /**
     * Retrieves all root components associated with a DOM element, directive or component instance.
     * Root components are those which have been bootstrapped by Angular.
     *
     * \@publicApi
     * \@globalApi ng
     * @param {?} elementOrDir DOM element, component or directive instance
     *    for which to retrieve the root components.
     * @return {?} Root components associated with the target object.
     *
     */


    function getRootComponents(elementOrDir) {
      return _toConsumableArray(getRootContext(elementOrDir).components);
    }
    /**
     * Retrieves an `Injector` associated with an element, component or directive instance.
     *
     * \@publicApi
     * \@globalApi ng
     * @param {?} elementOrDir DOM element, component or directive instance for which to
     *    retrieve the injector.
     * @return {?} Injector associated with the element, component or directive instance.
     *
     */


    function getInjector(elementOrDir) {
      /** @type {?} */
      var context = loadLContext(elementOrDir, false);
      if (context === null) return Injector.NULL;
      /** @type {?} */

      var tNode =
      /** @type {?} */
      context.lView[TVIEW].data[context.nodeIndex];
      return new NodeInjector(tNode, context.lView);
    }
    /**
     * Retrieve a set of injection tokens at a given DOM node.
     *
     * @param {?} element Element for which the injection tokens should be retrieved.
     * @return {?}
     */


    function getInjectionTokens(element) {
      /** @type {?} */
      var context = loadLContext(element, false);
      if (context === null) return [];
      /** @type {?} */

      var lView = context.lView;
      /** @type {?} */

      var tView = lView[TVIEW];
      /** @type {?} */

      var tNode =
      /** @type {?} */
      tView.data[context.nodeIndex];
      /** @type {?} */

      var providerTokens = [];
      /** @type {?} */

      var startIndex = tNode.providerIndexes & 65535
      /* ProvidersStartIndexMask */
      ;
      /** @type {?} */

      var endIndex = tNode.directiveEnd;

      for (var i = startIndex; i < endIndex; i++) {
        /** @type {?} */
        var value = tView.data[i];

        if (isDirectiveDefHack(value)) {
          // The fact that we sometimes store Type and sometimes DirectiveDef in this location is a
          // design flaw.  We should always store same type so that we can be monomorphic. The issue
          // is that for Components/Directives we store the def instead the type. The correct behavior
          // is that we should always be storing injectable type in this location.
          value = value.type;
        }

        providerTokens.push(value);
      }

      return providerTokens;
    }
    /**
     * Retrieves directive instances associated with a given DOM element. Does not include
     * component instances.
     *
     * \@usageNotes
     * Given the following DOM structure:
     * ```
     * <my-app>
     *   <button my-button></button>
     *   <my-comp></my-comp>
     * </my-app>
     * ```
     * Calling `getDirectives` on `<button>` will return an array with an instance of the `MyButton`
     * directive that is associated with the DOM element.
     *
     * Calling `getDirectives` on `<my-comp>` will return an empty array.
     *
     * \@publicApi
     * \@globalApi ng
     * @param {?} element DOM element for which to get the directives.
     * @return {?} Array of directives associated with the element.
     *
     */


    function getDirectives(element) {
      /** @type {?} */
      var context =
      /** @type {?} */
      loadLContext(element);

      if (context.directives === undefined) {
        context.directives = getDirectivesAtNodeIndex(context.nodeIndex, context.lView, false);
      } // The `directives` in this case are a named array called `LComponentView`. Clone the
      // result so we don't expose an internal data structure in the user's console.


      return context.directives === null ? [] : _toConsumableArray(context.directives);
    }
    /**
     * @param {?} target
     * @param {?=} throwOnNotFound
     * @return {?}
     */


    function loadLContext(target) {
      var throwOnNotFound = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;

      /** @type {?} */
      var context = getLContext(target);

      if (!context && throwOnNotFound) {
        throw new Error(ngDevMode ? "Unable to find context associated with ".concat(stringifyForError(target)) : 'Invalid ng target');
      }

      return context;
    }
    /**
     * Retrieve map of local references.
     *
     * The references are retrieved as a map of local reference name to element or directive instance.
     *
     * @param {?} target DOM element, component or directive instance for which to retrieve
     *    the local references.
     * @return {?}
     */


    function getLocalRefs(target) {
      /** @type {?} */
      var context = loadLContext(target, false);
      if (context === null) return {};

      if (context.localRefs === undefined) {
        context.localRefs = discoverLocalRefs(context.lView, context.nodeIndex);
      }

      return context.localRefs || {};
    }
    /**
     * Retrieves the host element of a component or directive instance.
     * The host element is the DOM element that matched the selector of the directive.
     *
     * \@publicApi
     * \@globalApi ng
     * @param {?} componentOrDirective Component or directive instance for which the host
     *     element should be retrieved.
     * @return {?} Host element of the target.
     *
     */


    function getHostElement(componentOrDirective) {
      return (
        /** @type {?} */

        /** @type {?} */

        /** @type {?} */
        getLContext(componentOrDirective)["native"]
      );
    }
    /**
     * Retrieves the rendered text for a given component.
     *
     * This function retrieves the host element of a component and
     * and then returns the `textContent` for that element. This implies
     * that the text returned will include re-projected content of
     * the component as well.
     *
     * @param {?} component The component to return the content text for.
     * @return {?}
     */


    function getRenderedText(component) {
      /** @type {?} */
      var hostElement = getHostElement(component);
      return hostElement.textContent || '';
    }
    /**
     * @param {?} node
     * @return {?}
     */


    function loadLContextFromNode(node) {
      if (!(node instanceof Node)) throw new Error('Expecting instance of DOM Element');
      return (
        /** @type {?} */
        loadLContext(node)
      );
    }
    /**
     * Event listener configuration returned from `getListeners`.
     * \@publicApi
     * @record
     */


    function Listener() {}

    if (false) {}
    /**
     * Retrieves a list of event listeners associated with a DOM element. The list does include host
     * listeners, but it does not include event listeners defined outside of the Angular context
     * (e.g. through `addEventListener`).
     *
     * \@usageNotes
     * Given the following DOM structure:
     * ```
     * <my-app>
     *   <div (click)="doSomething()"></div>
     * </my-app>
     *
     * ```
     * Calling `getListeners` on `<div>` will return an object that looks as follows:
     * ```
     * {
     *   name: 'click',
     *   element: <div>,
     *   callback: () => doSomething(),
     *   useCapture: false
     * }
     * ```
     *
     * \@publicApi
     * \@globalApi ng
     * @param {?} element Element for which the DOM listeners should be retrieved.
     * @return {?} Array of event listeners on the DOM element.
     *
     */


    function getListeners(element) {
      assertDomElement(element);
      /** @type {?} */

      var lContext = loadLContext(element, false);
      if (lContext === null) return [];
      /** @type {?} */

      var lView = lContext.lView;
      /** @type {?} */

      var tView = lView[TVIEW];
      /** @type {?} */

      var lCleanup = lView[CLEANUP];
      /** @type {?} */

      var tCleanup = tView.cleanup;
      /** @type {?} */

      var listeners = [];

      if (tCleanup && lCleanup) {
        for (var i = 0; i < tCleanup.length;) {
          /** @type {?} */
          var firstParam = tCleanup[i++];
          /** @type {?} */

          var secondParam = tCleanup[i++];

          if (typeof firstParam === 'string') {
            /** @type {?} */
            var name = firstParam;
            /** @type {?} */

            var listenerElement =
            /** @type {?} */

            /** @type {?} */
            unwrapRNode(lView[secondParam]);
            /** @type {?} */

            var callback = lCleanup[tCleanup[i++]];
            /** @type {?} */

            var useCaptureOrIndx = tCleanup[i++]; // if useCaptureOrIndx is boolean then report it as is.
            // if useCaptureOrIndx is positive number then it in unsubscribe method
            // if useCaptureOrIndx is negative number then it is a Subscription

            /** @type {?} */

            var type = typeof useCaptureOrIndx === 'boolean' || useCaptureOrIndx >= 0 ? 'dom' : 'output';
            /** @type {?} */

            var useCapture = typeof useCaptureOrIndx === 'boolean' ? useCaptureOrIndx : false;

            if (element == listenerElement) {
              listeners.push({
                element: element,
                name: name,
                callback: callback,
                useCapture: useCapture,
                type: type
              });
            }
          }
        }
      }

      listeners.sort(sortListeners);
      return listeners;
    }
    /**
     * @param {?} a
     * @param {?} b
     * @return {?}
     */


    function sortListeners(a, b) {
      if (a.name == b.name) return 0;
      return a.name < b.name ? -1 : 1;
    }
    /**
     * This function should not exist because it is megamorphic and only mostly correct.
     *
     * See call site for more info.
     * @param {?} obj
     * @return {?}
     */


    function isDirectiveDefHack(obj) {
      return obj.type !== undefined && obj.template !== undefined && obj.declaredInputs !== undefined;
    }
    /**
     * Returns the attached `DebugNode` instance for an element in the DOM.
     *
     * @param {?} element DOM element which is owned by an existing component's view.
     * @return {?}
     */


    function getDebugNode(element) {
      /** @type {?} */
      var debugNode = null;
      /** @type {?} */

      var lContext = loadLContextFromNode(element);
      /** @type {?} */

      var lView = lContext.lView;
      /** @type {?} */

      var nodeIndex = lContext.nodeIndex;

      if (nodeIndex !== -1) {
        /** @type {?} */
        var valueInLView = lView[nodeIndex]; // this means that value in the lView is a component with its own
        // data. In this situation the TNode is not accessed at the same spot.

        /** @type {?} */

        var tNode = isLView(valueInLView) ?
        /** @type {?} */
        valueInLView[T_HOST] : getTNode(lView[TVIEW], nodeIndex - HEADER_OFFSET);
        debugNode = buildDebugNode(tNode, lView, nodeIndex);
      }

      return debugNode;
    }
    /**
     * Retrieve the component `LView` from component/element.
     *
     * NOTE: `LView` is a private and should not be leaked outside.
     *       Don't export this method to `ng.*` on window.
     *
     * @param {?} target DOM element or component instance for which to retrieve the LView.
     * @return {?}
     */


    function getComponentLView(target) {
      /** @type {?} */
      var lContext = loadLContext(target);
      /** @type {?} */

      var nodeIndx = lContext.nodeIndex;
      /** @type {?} */

      var lView = lContext.lView;
      /** @type {?} */

      var componentLView = lView[nodeIndx];
      ngDevMode && assertLView(componentLView);
      return componentLView;
    }
    /**
     * Asserts that a value is a DOM Element.
     * @param {?} value
     * @return {?}
     */


    function assertDomElement(value) {
      if (typeof Element !== 'undefined' && !(value instanceof Element)) {
        throw new Error('Expecting instance of DOM Element');
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/util/change_detection_utils.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Marks a component for check (in case of OnPush components) and synchronously
     * performs change detection on the application this component belongs to.
     *
     * \@publicApi
     * \@globalApi ng
     * @param {?} component Component to {\@link ChangeDetectorRef#markForCheck mark for check}.
     *
     * @return {?}
     */


    function applyChanges(component) {
      markDirty(component);
      getRootComponents(component).forEach(
      /**
      * @param {?} rootComponent
      * @return {?}
      */
      function (rootComponent) {
        return detectChanges(rootComponent);
      });
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/util/global_utils.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * This value reflects the property on the window where the dev
     * tools are patched (window.ng).
     *
     * @type {?}
     */


    var GLOBAL_PUBLISH_EXPANDO_KEY = 'ng';
    /** @type {?} */

    var _published = false;
    /**
     * Publishes a collection of default debug tools onto`window.ng`.
     *
     * These functions are available globally when Angular is in development
     * mode and are automatically stripped away from prod mode is on.
     * @return {?}
     */

    function publishDefaultGlobalUtils() {
      if (!_published) {
        _published = true;
        publishGlobalUtil('getComponent', getComponent);
        publishGlobalUtil('getContext', getContext);
        publishGlobalUtil('getListeners', getListeners);
        publishGlobalUtil('getOwningComponent', getOwningComponent);
        publishGlobalUtil('getHostElement', getHostElement);
        publishGlobalUtil('getInjector', getInjector);
        publishGlobalUtil('getRootComponents', getRootComponents);
        publishGlobalUtil('getDirectives', getDirectives);
        publishGlobalUtil('applyChanges', applyChanges);
      }
    }
    /**
     * Publishes the given function to `window.ng` so that it can be
     * used from the browser console when an application is not in production.
     * @param {?} name
     * @param {?} fn
     * @return {?}
     */


    function publishGlobalUtil(name, fn) {
      if (typeof COMPILED === 'undefined' || !COMPILED) {
        // Note: we can't export `ng` when using closure enhanced optimization as:
        // - closure declares globals itself for minified names, which sometimes clobber our `ng` global
        // - we can't declare a closure extern as the namespace `ng` is already used within Google
        //   for typings for AngularJS (via `goog.provide('ng....')`).

        /** @type {?} */
        var w =
        /** @type {?} */

        /** @type {?} */
        _global;
        ngDevMode && assertDefined(fn, 'function not defined');

        if (w) {
          /** @type {?} */
          var container = w[GLOBAL_PUBLISH_EXPANDO_KEY];

          if (!container) {
            container = w[GLOBAL_PUBLISH_EXPANDO_KEY] = {};
          }

          container[name] = fn;
        }
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/component.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Options that control how the component should be bootstrapped.
     * @record
     */


    function CreateComponentOptions() {}

    if (false) {} // TODO: A hack to not pull in the NullInjector from @angular/core.


    var ɵ0$b =
    /**
    * @param {?} token
    * @param {?=} notFoundValue
    * @return {?}
    */
    function ɵ0$b(token, notFoundValue) {
      throw new Error('NullInjector: Not found: ' + stringifyForError(token));
    };
    /** @type {?} */


    var NULL_INJECTOR$1 = {
      get: ɵ0$b
    };
    /**
     * Bootstraps a Component into an existing host element and returns an instance
     * of the component.
     *
     * Use this function to bootstrap a component into the DOM tree. Each invocation
     * of this function will create a separate tree of components, injectors and
     * change detection cycles and lifetimes. To dynamically insert a new component
     * into an existing tree such that it shares the same injection, change detection
     * and object lifetime, use {\@link ViewContainer#createComponent}.
     *
     * @template T
     * @param {?} componentType Component to bootstrap
     * @param {?=} opts
     * @return {?}
     */

    function renderComponent$1(componentType
    /* Type as workaround for: Microsoft/TypeScript/issues/4881 */
    ) {
      var opts = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
      ngDevMode && publishDefaultGlobalUtils();
      ngDevMode && assertComponentType(componentType);
      /** @type {?} */

      var rendererFactory = opts.rendererFactory || domRendererFactory3;
      /** @type {?} */

      var sanitizer = opts.sanitizer || null;
      /** @type {?} */

      var componentDef =
      /** @type {?} */
      getComponentDef(componentType);
      if (componentDef.type != componentType)
      /** @type {?} */
      componentDef.type = componentType; // The first index of the first selector is the tag name.

      /** @type {?} */

      var componentTag =
      /** @type {?} */

      /** @type {?} */

      /** @type {?} */
      componentDef.selectors[0][0];
      /** @type {?} */

      var hostRenderer = rendererFactory.createRenderer(null, null);
      /** @type {?} */

      var hostRNode = locateHostElement(hostRenderer, opts.host || componentTag, componentDef.encapsulation);
      /** @type {?} */

      var rootFlags = componentDef.onPush ? 64
      /* Dirty */
      | 512
      /* IsRoot */
      : 16
      /* CheckAlways */
      | 512
      /* IsRoot */
      ;
      /** @type {?} */

      var rootContext = createRootContext(opts.scheduler, opts.playerHandler);
      /** @type {?} */

      var renderer = rendererFactory.createRenderer(hostRNode, componentDef);
      /** @type {?} */

      var rootTView = createTView(0
      /* Root */
      , -1, null, 1, 0, null, null, null, null, null);
      /** @type {?} */

      var rootView = createLView(null, rootTView, rootContext, rootFlags, null, null, rendererFactory, renderer, undefined, opts.injector || null);
      enterView(rootView, null);
      /** @type {?} */

      var component;

      try {
        if (rendererFactory.begin) rendererFactory.begin();
        /** @type {?} */

        var componentView = createRootComponentView(hostRNode, componentDef, rootView, rendererFactory, renderer, sanitizer);
        component = createRootComponent(componentView, componentDef, rootView, rootContext, opts.hostFeatures || null); // create mode pass

        renderView(rootTView, rootView, null); // update mode pass

        refreshView(rootTView, rootView, null, null);
      } finally {
        leaveView();
        if (rendererFactory.end) rendererFactory.end();
      }

      return component;
    }
    /**
     * Creates the root component view and the root component node.
     *
     * @param {?} rNode Render host element.
     * @param {?} def ComponentDef
     * @param {?} rootView The parent view where the host node is stored
     * @param {?} rendererFactory
     * @param {?} hostRenderer The current renderer
     * @param {?=} sanitizer The sanitizer, if provided
     *
     * @return {?} Component view created
     */


    function createRootComponentView(rNode, def, rootView, rendererFactory, hostRenderer, sanitizer) {
      /** @type {?} */
      var tView = rootView[TVIEW];
      ngDevMode && assertDataInRange(rootView, 0 + HEADER_OFFSET);
      rootView[0 + HEADER_OFFSET] = rNode;
      /** @type {?} */

      var tNode = getOrCreateTNode(tView, null, 0, 3
      /* Element */
      , null, null);
      /** @type {?} */

      var mergedAttrs = tNode.mergedAttrs = def.hostAttrs;

      if (mergedAttrs !== null) {
        computeStaticStyling(tNode, mergedAttrs);

        if (rNode !== null) {
          setUpAttributes(hostRenderer, rNode, mergedAttrs);

          if (tNode.classes !== null) {
            writeDirectClass(hostRenderer, rNode, tNode.classes);
          }

          if (tNode.styles !== null) {
            writeDirectStyle(hostRenderer, rNode, tNode.styles);
          }
        }
      }
      /** @type {?} */


      var viewRenderer = rendererFactory.createRenderer(rNode, def);
      /** @type {?} */

      var componentView = createLView(rootView, getOrCreateTComponentView(def), null, def.onPush ? 64
      /* Dirty */
      : 16
      /* CheckAlways */
      , rootView[HEADER_OFFSET], tNode, rendererFactory, viewRenderer, sanitizer);

      if (tView.firstCreatePass) {
        diPublicInInjector(getOrCreateNodeInjectorForNode(tNode, rootView), tView, def.type);
        markAsComponentHost(tView, tNode);
        initTNodeFlags(tNode, rootView.length, 1);
      }

      addToViewTree(rootView, componentView); // Store component view at node index, with node as the HOST

      return rootView[HEADER_OFFSET] = componentView;
    }
    /**
     * Creates a root component and sets it up with features and host bindings. Shared by
     * renderComponent() and ViewContainerRef.createComponent().
     * @template T
     * @param {?} componentView
     * @param {?} componentDef
     * @param {?} rootLView
     * @param {?} rootContext
     * @param {?} hostFeatures
     * @return {?}
     */


    function createRootComponent(componentView, componentDef, rootLView, rootContext, hostFeatures) {
      /** @type {?} */
      var tView = rootLView[TVIEW]; // Create directive instance with factory() and store at next index in viewData

      /** @type {?} */

      var component = instantiateRootComponent(tView, rootLView, componentDef);
      rootContext.components.push(component);
      componentView[CONTEXT] = component;
      hostFeatures && hostFeatures.forEach(
      /**
      * @param {?} feature
      * @return {?}
      */
      function (feature) {
        return feature(component, componentDef);
      }); // We want to generate an empty QueryList for root content queries for backwards
      // compatibility with ViewEngine.

      if (componentDef.contentQueries) {
        componentDef.contentQueries(1
        /* Create */
        , component, rootLView.length - 1);
      }
      /** @type {?} */


      var rootTNode = getPreviousOrParentTNode();

      if (tView.firstCreatePass && (componentDef.hostBindings !== null || componentDef.hostAttrs !== null)) {
        /** @type {?} */
        var elementIndex = rootTNode.index - HEADER_OFFSET;
        setSelectedIndex(elementIndex);
        /** @type {?} */

        var rootTView = rootLView[TVIEW];
        addHostBindingsToExpandoInstructions(rootTView, componentDef);
        growHostVarsSpace(rootTView, rootLView, componentDef.hostVars);
        invokeHostBindingsInCreationMode(componentDef, component);
      }

      return component;
    }
    /**
     * @param {?=} scheduler
     * @param {?=} playerHandler
     * @return {?}
     */


    function createRootContext(scheduler, playerHandler) {
      return {
        components: [],
        scheduler: scheduler || defaultScheduler,
        clean: CLEAN_PROMISE,
        playerHandler: playerHandler || null,
        flags: 0
        /* Empty */

      };
    }
    /**
     * Used to enable lifecycle hooks on the root component.
     *
     * Include this feature when calling `renderComponent` if the root component
     * you are rendering has lifecycle hooks defined. Otherwise, the hooks won't
     * be called properly.
     *
     * Example:
     *
     * ```
     * renderComponent(AppComponent, {hostFeatures: [LifecycleHooksFeature]});
     * ```
     * @param {?} component
     * @param {?} def
     * @return {?}
     */


    function LifecycleHooksFeature(component, def) {
      /** @type {?} */
      var rootTView =
      /** @type {?} */
      readPatchedLView(component)[TVIEW];
      /** @type {?} */

      var dirIndex = rootTView.data.length - 1; // TODO(misko): replace `as TNode` with createTNode call. (needs refactoring to lose dep on
      // LNode).

      registerPostOrderHooks(rootTView,
      /** @type {?} */
      {
        directiveStart: dirIndex,
        directiveEnd: dirIndex + 1
      });
    }
    /**
     * Wait on component until it is rendered.
     *
     * This function returns a `Promise` which is resolved when the component's
     * change detection is executed. This is determined by finding the scheduler
     * associated with the `component`'s render tree and waiting until the scheduler
     * flushes. If nothing is scheduled, the function returns a resolved promise.
     *
     * Example:
     * ```
     * await whenRendered(myComponent);
     * ```
     *
     * @param {?} component Component to wait upon
     * @return {?} Promise which resolves when the component is rendered.
     */


    function whenRendered(component) {
      return getRootContext(component).clean;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/features/inherit_definition_feature.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} type
     * @return {?}
     */


    function getSuperType(type) {
      return Object.getPrototypeOf(type.prototype).constructor;
    }
    /**
     * Merges the definition from a super class to a sub class.
     * \@codeGenApi
     * @param {?} definition The definition that is a SubClass of another directive of component
     *
     * @return {?}
     */


    function ɵɵInheritDefinitionFeature(definition) {
      /** @type {?} */
      var superType = getSuperType(definition.type);
      /** @type {?} */

      var shouldInheritFields = true;
      /** @type {?} */

      var inheritanceChain = [definition];

      while (superType) {
        /** @type {?} */
        var superDef = undefined;

        if (isComponentDef(definition)) {
          // Don't use getComponentDef/getDirectiveDef. This logic relies on inheritance.
          superDef = superType.ɵcmp || superType.ɵdir;
        } else {
          if (superType.ɵcmp) {
            throw new Error('Directives cannot inherit Components');
          } // Don't use getComponentDef/getDirectiveDef. This logic relies on inheritance.


          superDef = superType.ɵdir;
        }

        if (superDef) {
          if (shouldInheritFields) {
            inheritanceChain.push(superDef); // Some fields in the definition may be empty, if there were no values to put in them that
            // would've justified object creation. Unwrap them if necessary.

            /** @type {?} */

            var writeableDef =
            /** @type {?} */
            definition;
            writeableDef.inputs = maybeUnwrapEmpty(definition.inputs);
            writeableDef.declaredInputs = maybeUnwrapEmpty(definition.declaredInputs);
            writeableDef.outputs = maybeUnwrapEmpty(definition.outputs); // Merge hostBindings

            /** @type {?} */

            var superHostBindings = superDef.hostBindings;
            superHostBindings && inheritHostBindings(definition, superHostBindings); // Merge queries

            /** @type {?} */

            var superViewQuery = superDef.viewQuery;
            /** @type {?} */

            var superContentQueries = superDef.contentQueries;
            superViewQuery && inheritViewQuery(definition, superViewQuery);
            superContentQueries && inheritContentQueries(definition, superContentQueries); // Merge inputs and outputs

            fillProperties(definition.inputs, superDef.inputs);
            fillProperties(definition.declaredInputs, superDef.declaredInputs);
            fillProperties(definition.outputs, superDef.outputs); // Merge animations metadata.
            // If `superDef` is a Component, the `data` field is present (defaults to an empty object).

            if (isComponentDef(superDef) && superDef.data.animation) {
              // If super def is a Component, the `definition` is also a Component, since Directives can
              // not inherit Components (we throw an error above and cannot reach this code).

              /** @type {?} */
              var defData =
              /** @type {?} */
              definition.data;
              defData.animation = (defData.animation || []).concat(superDef.data.animation);
            } // Inherit hooks
            // Assume super class inheritance feature has already run.


            writeableDef.afterContentChecked = writeableDef.afterContentChecked || superDef.afterContentChecked;
            writeableDef.afterContentInit = definition.afterContentInit || superDef.afterContentInit;
            writeableDef.afterViewChecked = definition.afterViewChecked || superDef.afterViewChecked;
            writeableDef.afterViewInit = definition.afterViewInit || superDef.afterViewInit;
            writeableDef.doCheck = definition.doCheck || superDef.doCheck;
            writeableDef.onDestroy = definition.onDestroy || superDef.onDestroy;
            writeableDef.onInit = definition.onInit || superDef.onInit;
          } // Run parent features

          /** @type {?} */


          var features = superDef.features;

          if (features) {
            for (var i = 0; i < features.length; i++) {
              /** @type {?} */
              var feature = features[i];

              if (feature && feature.ngInherit) {
                /** @type {?} */
                feature(definition);
              } // If `InheritDefinitionFeature` is a part of the current `superDef`, it means that this
              // def already has all the necessary information inherited from its super class(es), so we
              // can stop merging fields from super classes. However we need to iterate through the
              // prototype chain to look for classes that might contain other "features" (like
              // NgOnChanges), which we should invoke for the original `definition`. We set the
              // `shouldInheritFields` flag to indicate that, essentially skipping fields inheritance
              // logic and only invoking functions from the "features" list.


              if (feature === ɵɵInheritDefinitionFeature) {
                shouldInheritFields = false;
              }
            }
          }
        }

        superType = Object.getPrototypeOf(superType);
      }

      mergeHostAttrsAcrossInheritance(inheritanceChain);
    }
    /**
     * Merge the `hostAttrs` and `hostVars` from the inherited parent to the base class.
     *
     * @param {?} inheritanceChain A list of `WritableDefs` starting at the top most type and listing
     * sub-types in order. For each type take the `hostAttrs` and `hostVars` and merge it with the child
     * type.
     * @return {?}
     */


    function mergeHostAttrsAcrossInheritance(inheritanceChain) {
      /** @type {?} */
      var hostVars = 0;
      /** @type {?} */

      var hostAttrs = null; // We process the inheritance order from the base to the leaves here.

      for (var i = inheritanceChain.length - 1; i >= 0; i--) {
        /** @type {?} */
        var def = inheritanceChain[i]; // For each `hostVars`, we need to add the superclass amount.

        def.hostVars = hostVars += def.hostVars; // for each `hostAttrs` we need to merge it with superclass.

        def.hostAttrs = mergeHostAttrs(def.hostAttrs, hostAttrs = mergeHostAttrs(hostAttrs, def.hostAttrs));
      }
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function maybeUnwrapEmpty(value) {
      if (value === EMPTY_OBJ) {
        return {};
      } else if (value === EMPTY_ARRAY) {
        return [];
      } else {
        return value;
      }
    }
    /**
     * @param {?} definition
     * @param {?} superViewQuery
     * @return {?}
     */


    function inheritViewQuery(definition, superViewQuery) {
      /** @type {?} */
      var prevViewQuery = definition.viewQuery;

      if (prevViewQuery) {
        definition.viewQuery =
        /**
        * @param {?} rf
        * @param {?} ctx
        * @return {?}
        */
        function (rf, ctx) {
          superViewQuery(rf, ctx);
          prevViewQuery(rf, ctx);
        };
      } else {
        definition.viewQuery = superViewQuery;
      }
    }
    /**
     * @param {?} definition
     * @param {?} superContentQueries
     * @return {?}
     */


    function inheritContentQueries(definition, superContentQueries) {
      /** @type {?} */
      var prevContentQueries = definition.contentQueries;

      if (prevContentQueries) {
        definition.contentQueries =
        /**
        * @param {?} rf
        * @param {?} ctx
        * @param {?} directiveIndex
        * @return {?}
        */
        function (rf, ctx, directiveIndex) {
          superContentQueries(rf, ctx, directiveIndex);
          prevContentQueries(rf, ctx, directiveIndex);
        };
      } else {
        definition.contentQueries = superContentQueries;
      }
    }
    /**
     * @param {?} definition
     * @param {?} superHostBindings
     * @return {?}
     */


    function inheritHostBindings(definition, superHostBindings) {
      /** @type {?} */
      var prevHostBindings = definition.hostBindings;

      if (prevHostBindings) {
        definition.hostBindings =
        /**
        * @param {?} rf
        * @param {?} ctx
        * @return {?}
        */
        function (rf, ctx) {
          superHostBindings(rf, ctx);
          prevHostBindings(rf, ctx);
        };
      } else {
        definition.hostBindings = superHostBindings;
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/features/copy_definition_feature.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Fields which exist on either directive or component definitions, and need to be copied from
     * parent to child classes by the `ɵɵCopyDefinitionFeature`.
     * @type {?}
     */


    var COPY_DIRECTIVE_FIELDS = [// The child class should use the providers of its parent.
    'providersResolver'];
    /**
     * Fields which exist only on component definitions, and need to be copied from parent to child
     * classes by the `ɵɵCopyDefinitionFeature`.
     *
     * The type here allows any field of `ComponentDef` which is not also a property of `DirectiveDef`,
     * since those should go in `COPY_DIRECTIVE_FIELDS` above.
     * @type {?}
     */

    var COPY_COMPONENT_FIELDS = [// The child class should use the template function of its parent, including all template
    // semantics.
    'template', 'decls', 'consts', 'vars', 'onPush', 'ngContentSelectors', // The child class should use the CSS styles of its parent, including all styling semantics.
    'styles', 'encapsulation', // The child class should be checked by the runtime in the same way as its parent.
    'schemas'];
    /**
     * Copies the fields not handled by the `ɵɵInheritDefinitionFeature` from the supertype of a
     * definition.
     *
     * This exists primarily to support ngcc migration of an existing View Engine pattern, where an
     * entire decorator is inherited from a parent to a child class. When ngcc detects this case, it
     * generates a skeleton definition on the child class, and applies this feature.
     *
     * The `ɵɵCopyDefinitionFeature` then copies any needed fields from the parent class' definition,
     * including things like the component template function.
     *
     * \@codeGenApi
     * @param {?} definition The definition of a child class which inherits from a parent class with its
     * own definition.
     *
     * @return {?}
     */

    function ɵɵCopyDefinitionFeature(definition) {
      /** @type {?} */
      var superType =
      /** @type {?} */
      getSuperType(definition.type);
      /** @type {?} */

      var superDef = undefined;

      if (isComponentDef(definition)) {
        // Don't use getComponentDef/getDirectiveDef. This logic relies on inheritance.
        superDef =
        /** @type {?} */
        superType.ɵcmp;
      } else {
        // Don't use getComponentDef/getDirectiveDef. This logic relies on inheritance.
        superDef =
        /** @type {?} */
        superType.ɵdir;
      } // Needed because `definition` fields are readonly.

      /** @type {?} */


      var defAny =
      /** @type {?} */
      definition; // Copy over any fields that apply to either directives or components.

      var _iterator10 = _createForOfIteratorHelper(COPY_DIRECTIVE_FIELDS),
          _step10;

      try {
        for (_iterator10.s(); !(_step10 = _iterator10.n()).done;) {
          var _field = _step10.value;
          defAny[_field] = superDef[_field];
        }
      } catch (err) {
        _iterator10.e(err);
      } finally {
        _iterator10.f();
      }

      if (isComponentDef(superDef)) {
        // Copy over any component-specific fields.
        var _iterator11 = _createForOfIteratorHelper(COPY_COMPONENT_FIELDS),
            _step11;

        try {
          for (_iterator11.s(); !(_step11 = _iterator11.n()).done;) {
            var field = _step11.value;
            defAny[field] = superDef[field];
          }
        } catch (err) {
          _iterator11.e(err);
        } finally {
          _iterator11.f();
        }
      }
    }
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Represents a basic change from a previous to a new value for a single
     * property on a directive instance. Passed as a value in a
     * {@link SimpleChanges} object to the `ngOnChanges` hook.
     *
     * @see `OnChanges`
     *
     * @publicApi
     */


    var SimpleChange = /*#__PURE__*/function () {
      function SimpleChange(previousValue, currentValue, firstChange) {
        _classCallCheck(this, SimpleChange);

        this.previousValue = previousValue;
        this.currentValue = currentValue;
        this.firstChange = firstChange;
      }
      /**
       * Check whether the new value is the first value assigned.
       */


      _createClass2(SimpleChange, [{
        key: "isFirstChange",
        value: function isFirstChange() {
          return this.firstChange;
        }
      }]);

      return SimpleChange;
    }();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/features/ng_onchanges_feature.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var PRIVATE_PREFIX = '__ngOnChanges_';
    /**
     * The NgOnChangesFeature decorates a component with support for the ngOnChanges
     * lifecycle hook, so it should be included in any component that implements
     * that hook.
     *
     * If the component or directive uses inheritance, the NgOnChangesFeature MUST
     * be included as a feature AFTER {\@link InheritDefinitionFeature}, otherwise
     * inherited properties will not be propagated to the ngOnChanges lifecycle
     * hook.
     *
     * Example usage:
     *
     * ```
     * static ɵcmp = defineComponent({
     *   ...
     *   inputs: {name: 'publicName'},
     *   features: [NgOnChangesFeature]
     * });
     * ```
     *
     * \@codeGenApi
     * @template T
     * @param {?} definition
     * @return {?}
     */

    function ɵɵNgOnChangesFeature(definition) {
      if (definition.type.prototype.ngOnChanges) {
        definition.setInput = ngOnChangesSetInput;

        /** @type {?} */
        definition.onChanges = wrapOnChanges();
      }
    } // This option ensures that the ngOnChanges lifecycle hook will be inherited
    // from superclasses (in InheritDefinitionFeature).

    /** @nocollapse */
    // tslint:disable-next-line:no-toplevel-property-access


    /** @type {?} */
    ɵɵNgOnChangesFeature.ngInherit = true;
    /**
     * @return {?}
     */

    function wrapOnChanges() {
      return (
        /**
        * @this {?}
        * @return {?}
        */
        function wrapOnChangesHook_inPreviousChangesStorage() {
          /** @type {?} */
          var simpleChangesStore = getSimpleChangesStore(this);
          /** @type {?} */

          var current = simpleChangesStore && simpleChangesStore.current;

          if (current) {
            /** @type {?} */
            var previous =
            /** @type {?} */
            simpleChangesStore.previous;

            if (previous === EMPTY_OBJ) {
              /** @type {?} */
              simpleChangesStore.previous = current;
            } else {
              // New changes are copied to the previous store, so that we don't lose history for inputs
              // which were not changed this time
              for (var key in current) {
                previous[key] = current[key];
              }
            }

            /** @type {?} */
            simpleChangesStore.current = null;
            this.ngOnChanges(current);
          }
        }
      );
    }
    /**
     * @template T
     * @this {?}
     * @param {?} instance
     * @param {?} value
     * @param {?} publicName
     * @param {?} privateName
     * @return {?}
     */


    function ngOnChangesSetInput(instance, value, publicName, privateName) {
      /** @type {?} */
      var simpleChangesStore = getSimpleChangesStore(instance) || setSimpleChangesStore(instance, {
        previous: EMPTY_OBJ,
        current: null
      });
      /** @type {?} */

      var current = simpleChangesStore.current || (simpleChangesStore.current = {});
      /** @type {?} */

      var previous = simpleChangesStore.previous;
      /** @type {?} */

      var declaredName =
      /** @type {?} */
      this.declaredInputs[publicName];
      /** @type {?} */

      var previousChange = previous[declaredName];
      current[declaredName] = new SimpleChange(previousChange && previousChange.currentValue, value, previous === EMPTY_OBJ);

      /** @type {?} */
      instance[privateName] = value;
    }
    /** @type {?} */


    var SIMPLE_CHANGES_STORE = '__ngSimpleChanges__';
    /**
     * @param {?} instance
     * @return {?}
     */

    function getSimpleChangesStore(instance) {
      return instance[SIMPLE_CHANGES_STORE] || null;
    }
    /**
     * @param {?} instance
     * @param {?} store
     * @return {?}
     */


    function setSimpleChangesStore(instance, store) {
      return instance[SIMPLE_CHANGES_STORE] = store;
    }
    /**
     * @record
     */


    function NgSimpleChangesStore() {}

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/di_setup.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Resolves the providers which are defined in the DirectiveDef.
     *
     * When inserting the tokens and the factories in their respective arrays, we can assume that
     * this method is called first for the component (if any), and then for other directives on the same
     * node.
     * As a consequence,the providers are always processed in that order:
     * 1) The view providers of the component
     * 2) The providers of the component
     * 3) The providers of the other directives
     * This matches the structure of the injectables arrays of a view (for each node).
     * So the tokens and the factories can be pushed at the end of the arrays, except
     * in one case for multi providers.
     *
     * @template T
     * @param {?} def the directive definition
     * @param {?} providers
     * @param {?} viewProviders
     * @return {?}
     */


    function providersResolver(def, providers, viewProviders) {
      /** @type {?} */
      var tView = getTView();

      if (tView.firstCreatePass) {
        /** @type {?} */
        var isComponent = isComponentDef(def); // The list of view providers is processed first, and the flags are updated

        resolveProvider$1(viewProviders, tView.data, tView.blueprint, isComponent, true); // Then, the list of providers is processed, and the flags are updated

        resolveProvider$1(providers, tView.data, tView.blueprint, isComponent, false);
      }
    }
    /**
     * Resolves a provider and publishes it to the DI system.
     * @param {?} provider
     * @param {?} tInjectables
     * @param {?} lInjectablesBlueprint
     * @param {?} isComponent
     * @param {?} isViewProvider
     * @return {?}
     */


    function resolveProvider$1(provider, tInjectables, lInjectablesBlueprint, isComponent, isViewProvider) {
      provider = resolveForwardRef(provider);

      if (Array.isArray(provider)) {
        // Recursively call `resolveProvider`
        // Recursion is OK in this case because this code will not be in hot-path once we implement
        // cloning of the initial state.
        for (var i = 0; i < provider.length; i++) {
          resolveProvider$1(provider[i], tInjectables, lInjectablesBlueprint, isComponent, isViewProvider);
        }
      } else {
        /** @type {?} */
        var tView = getTView();
        /** @type {?} */

        var lView = getLView();
        /** @type {?} */

        var token = isTypeProvider(provider) ? provider : resolveForwardRef(provider.provide);
        /** @type {?} */

        var providerFactory = providerToFactory(provider);
        /** @type {?} */

        var tNode = getPreviousOrParentTNode();
        /** @type {?} */

        var beginIndex = tNode.providerIndexes & 65535
        /* ProvidersStartIndexMask */
        ;
        /** @type {?} */

        var endIndex = tNode.directiveStart;
        /** @type {?} */

        var cptViewProvidersCount = tNode.providerIndexes >> 16
        /* CptViewProvidersCountShift */
        ;

        if (isTypeProvider(provider) || !provider.multi) {
          // Single provider case: the factory is created and pushed immediately

          /** @type {?} */
          var factory = new NodeInjectorFactory(providerFactory, isViewProvider, ɵɵdirectiveInject);
          /** @type {?} */

          var existingFactoryIndex = indexOf(token, tInjectables, isViewProvider ? beginIndex : beginIndex + cptViewProvidersCount, endIndex);

          if (existingFactoryIndex === -1) {
            diPublicInInjector(getOrCreateNodeInjectorForNode(
            /** @type {?} */
            tNode, lView), tView, token);
            registerDestroyHooksIfSupported(tView, provider, tInjectables.length);
            tInjectables.push(token);
            tNode.directiveStart++;
            tNode.directiveEnd++;

            if (isViewProvider) {
              tNode.providerIndexes += 65536
              /* CptViewProvidersCountShifter */
              ;
            }

            lInjectablesBlueprint.push(factory);
            lView.push(factory);
          } else {
            lInjectablesBlueprint[existingFactoryIndex] = factory;
            lView[existingFactoryIndex] = factory;
          }
        } else {
          // Multi provider case:
          // We create a multi factory which is going to aggregate all the values.
          // Since the output of such a factory depends on content or view injection,
          // we create two of them, which are linked together.
          //
          // The first one (for view providers) is always in the first block of the injectables array,
          // and the second one (for providers) is always in the second block.
          // This is important because view providers have higher priority. When a multi token
          // is being looked up, the view providers should be found first.
          // Note that it is not possible to have a multi factory in the third block (directive block).
          //
          // The algorithm to process multi providers is as follows:
          // 1) If the multi provider comes from the `viewProviders` of the component:
          //   a) If the special view providers factory doesn't exist, it is created and pushed.
          //   b) Else, the multi provider is added to the existing multi factory.
          // 2) If the multi provider comes from the `providers` of the component or of another
          // directive:
          //   a) If the multi factory doesn't exist, it is created and provider pushed into it.
          //      It is also linked to the multi factory for view providers, if it exists.
          //   b) Else, the multi provider is added to the existing multi factory.

          /** @type {?} */
          var existingProvidersFactoryIndex = indexOf(token, tInjectables, beginIndex + cptViewProvidersCount, endIndex);
          /** @type {?} */

          var existingViewProvidersFactoryIndex = indexOf(token, tInjectables, beginIndex, beginIndex + cptViewProvidersCount);
          /** @type {?} */

          var doesProvidersFactoryExist = existingProvidersFactoryIndex >= 0 && lInjectablesBlueprint[existingProvidersFactoryIndex];
          /** @type {?} */

          var doesViewProvidersFactoryExist = existingViewProvidersFactoryIndex >= 0 && lInjectablesBlueprint[existingViewProvidersFactoryIndex];

          if (isViewProvider && !doesViewProvidersFactoryExist || !isViewProvider && !doesProvidersFactoryExist) {
            // Cases 1.a and 2.a
            diPublicInInjector(getOrCreateNodeInjectorForNode(
            /** @type {?} */
            tNode, lView), tView, token);
            /** @type {?} */

            var _factory = multiFactory(isViewProvider ? multiViewProvidersFactoryResolver : multiProvidersFactoryResolver, lInjectablesBlueprint.length, isViewProvider, isComponent, providerFactory);

            if (!isViewProvider && doesViewProvidersFactoryExist) {
              lInjectablesBlueprint[existingViewProvidersFactoryIndex].providerFactory = _factory;
            }

            registerDestroyHooksIfSupported(tView, provider, tInjectables.length, 0);
            tInjectables.push(token);
            tNode.directiveStart++;
            tNode.directiveEnd++;

            if (isViewProvider) {
              tNode.providerIndexes += 65536
              /* CptViewProvidersCountShifter */
              ;
            }

            lInjectablesBlueprint.push(_factory);
            lView.push(_factory);
          } else {
            // Cases 1.b and 2.b

            /** @type {?} */
            var indexInFactory = multiFactoryAdd(
            /** @type {?} */
            lInjectablesBlueprint[isViewProvider ? existingViewProvidersFactoryIndex : existingProvidersFactoryIndex], providerFactory, !isViewProvider && isComponent);
            registerDestroyHooksIfSupported(tView, provider, existingProvidersFactoryIndex > -1 ? existingProvidersFactoryIndex : existingViewProvidersFactoryIndex, indexInFactory);
          }

          if (!isViewProvider && isComponent && doesViewProvidersFactoryExist) {
            /** @type {?} */lInjectablesBlueprint[existingViewProvidersFactoryIndex].componentProviders++;
          }
        }
      }
    }
    /**
     * Registers the `ngOnDestroy` hook of a provider, if the provider supports destroy hooks.
     * @param {?} tView `TView` in which to register the hook.
     * @param {?} provider Provider whose hook should be registered.
     * @param {?} contextIndex Index under which to find the context for the hook when it's being invoked.
     * @param {?=} indexInFactory Only required for `multi` providers. Index of the provider in the multi
     * provider factory.
     * @return {?}
     */


    function registerDestroyHooksIfSupported(tView, provider, contextIndex, indexInFactory) {
      /** @type {?} */
      var providerIsTypeProvider = isTypeProvider(provider);

      if (providerIsTypeProvider || isClassProvider(provider)) {
        /** @type {?} */
        var prototype = (
        /** @type {?} */
        provider.useClass || provider).prototype;
        /** @type {?} */

        var ngOnDestroy = prototype.ngOnDestroy;

        if (ngOnDestroy) {
          /** @type {?} */
          var hooks = tView.destroyHooks || (tView.destroyHooks = []);

          if (!providerIsTypeProvider &&
          /** @type {?} */
          provider.multi) {
            ngDevMode && assertDefined(indexInFactory, 'indexInFactory when registering multi factory destroy hook');
            /** @type {?} */

            var existingCallbacksIndex = hooks.indexOf(contextIndex);

            if (existingCallbacksIndex === -1) {
              hooks.push(contextIndex, [indexInFactory, ngOnDestroy]);
            } else {
              /** @type {?} */
              hooks[existingCallbacksIndex + 1].push(
              /** @type {?} */
              indexInFactory, ngOnDestroy);
            }
          } else {
            hooks.push(contextIndex, ngOnDestroy);
          }
        }
      }
    }
    /**
     * Add a factory in a multi factory.
     * @param {?} multiFactory
     * @param {?} factory
     * @param {?} isComponentProvider
     * @return {?} Index at which the factory was inserted.
     */


    function multiFactoryAdd(multiFactory, factory, isComponentProvider) {
      if (isComponentProvider) {
        /** @type {?} */multiFactory.componentProviders++;
      }

      return (
        /** @type {?} */
        multiFactory.multi.push(factory) - 1
      );
    }
    /**
     * Returns the index of item in the array, but only in the begin to end range.
     * @param {?} item
     * @param {?} arr
     * @param {?} begin
     * @param {?} end
     * @return {?}
     */


    function indexOf(item, arr, begin, end) {
      for (var i = begin; i < end; i++) {
        if (arr[i] === item) return i;
      }

      return -1;
    }
    /**
     * Use this with `multi` `providers`.
     * @this {?}
     * @param {?} _
     * @param {?} tData
     * @param {?} lData
     * @param {?} tNode
     * @return {?}
     */


    function multiProvidersFactoryResolver(_, tData, lData, tNode) {
      return multiResolve(
      /** @type {?} */
      this.multi, []);
    }
    /**
     * Use this with `multi` `viewProviders`.
     *
     * This factory knows how to concatenate itself with the existing `multi` `providers`.
     * @this {?}
     * @param {?} _
     * @param {?} tData
     * @param {?} lView
     * @param {?} tNode
     * @return {?}
     */


    function multiViewProvidersFactoryResolver(_, tData, lView, tNode) {
      /** @type {?} */
      var factories =
      /** @type {?} */
      this.multi;
      /** @type {?} */

      var result;

      if (this.providerFactory) {
        /** @type {?} */
        var componentCount =
        /** @type {?} */
        this.providerFactory.componentProviders;
        /** @type {?} */

        var multiProviders = getNodeInjectable(lView, lView[TVIEW],
        /** @type {?} */

        /** @type {?} */
        this.providerFactory.index, tNode); // Copy the section of the array which contains `multi` `providers` from the component

        result = multiProviders.slice(0, componentCount); // Insert the `viewProvider` instances.

        multiResolve(factories, result); // Copy the section of the array which contains `multi` `providers` from other directives

        for (var i = componentCount; i < multiProviders.length; i++) {
          result.push(multiProviders[i]);
        }
      } else {
        result = []; // Insert the `viewProvider` instances.

        multiResolve(factories, result);
      }

      return result;
    }
    /**
     * Maps an array of factories into an array of values.
     * @param {?} factories
     * @param {?} result
     * @return {?}
     */


    function multiResolve(factories, result) {
      for (var i = 0; i < factories.length; i++) {
        /** @type {?} */
        var factory =
        /** @type {?} */

        /** @type {?} */
        factories[i];
        result.push(factory());
      }

      return result;
    }
    /**
     * Creates a multi factory.
     * @param {?} factoryFn
     * @param {?} index
     * @param {?} isViewProvider
     * @param {?} isComponent
     * @param {?} f
     * @return {?}
     */


    function multiFactory(factoryFn, index, isViewProvider, isComponent, f) {
      /** @type {?} */
      var factory = new NodeInjectorFactory(factoryFn, isViewProvider, ɵɵdirectiveInject);
      factory.multi = [];
      factory.index = index;
      factory.componentProviders = 0;
      multiFactoryAdd(factory, f, isComponent && !isViewProvider);
      return factory;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/features/providers_feature.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * This feature resolves the providers of a directive (or component),
     * and publish them into the DI system, making it visible to others for injection.
     *
     * For example:
     * ```ts
     * class ComponentWithProviders {
     *   constructor(private greeter: GreeterDE) {}
     *
     *   static ɵcmp = defineComponent({
     *     type: ComponentWithProviders,
     *     selectors: [['component-with-providers']],
     *    factory: () => new ComponentWithProviders(directiveInject(GreeterDE as any)),
     *    decls: 1,
     *    vars: 1,
     *    template: function(fs: RenderFlags, ctx: ComponentWithProviders) {
     *      if (fs & RenderFlags.Create) {
     *        ɵɵtext(0);
     *      }
     *      if (fs & RenderFlags.Update) {
     *        ɵɵtextInterpolate(ctx.greeter.greet());
     *      }
     *    },
     *    features: [ProvidersFeature([GreeterDE])]
     *  });
     * }
     * ```
     *
     * \@codeGenApi
     * @template T
     * @param {?} providers
     * @param {?=} viewProviders
     * @return {?}
     */


    function ɵɵProvidersFeature(providers) {
      var viewProviders = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
      return (
        /**
        * @param {?} definition
        * @return {?}
        */
        function (definition) {
          definition.providersResolver =
          /**
          * @param {?} def
          * @param {?=} processProvidersFn
          * @return {?}
          */
          function (def, processProvidersFn) {
            return providersResolver(def, //
            processProvidersFn ? processProvidersFn(providers) : providers, //
            viewProviders);
          };
        }
      );
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/linker/component_factory.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Represents a component created by a `ComponentFactory`.
     * Provides access to the component instance and related objects,
     * and provides the means of destroying the instance.
     *
     * \@publicApi
     * @abstract
     * @template C
     */


    var ComponentRef = function ComponentRef() {
      _classCallCheck(this, ComponentRef);
    };

    if (false) {}
    /**
     * Base class for a factory that can create a component dynamically.
     * Instantiate a factory for a given type of component with `resolveComponentFactory()`.
     * Use the resulting `ComponentFactory.create()` method to create a component of that type.
     *
     * @see [Dynamic Components](guide/dynamic-component-loader)
     *
     * \@publicApi
     * @abstract
     * @template C
     */


    var ComponentFactory = function ComponentFactory() {
      _classCallCheck(this, ComponentFactory);
    };

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/linker/component_factory_resolver.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} component
     * @return {?}
     */


    function noComponentFactoryError(component) {
      /** @type {?} */
      var error = Error("No component factory found for ".concat(stringify(component), ". Did you add it to @NgModule.entryComponents?"));

      /** @type {?} */
      error[ERROR_COMPONENT] = component;
      return error;
    }
    /** @type {?} */


    var ERROR_COMPONENT = 'ngComponent';
    /**
     * @param {?} error
     * @return {?}
     */

    function getComponent$1(error) {
      return (
        /** @type {?} */
        error[ERROR_COMPONENT]
      );
    }

    var _NullComponentFactoryResolver = /*#__PURE__*/function () {
      function _NullComponentFactoryResolver() {
        _classCallCheck(this, _NullComponentFactoryResolver);
      }

      _createClass2(_NullComponentFactoryResolver, [{
        key: "resolveComponentFactory",

        /**
         * @template T
         * @param {?} component
         * @return {?}
         */
        value: function resolveComponentFactory(component) {
          throw noComponentFactoryError(component);
        }
      }]);

      return _NullComponentFactoryResolver;
    }();
    /**
     * A simple registry that maps `Components` to generated `ComponentFactory` classes
     * that can be used to create instances of components.
     * Use to obtain the factory for a given component type,
     * then use the factory's `create()` method to create a component of that type.
     *
     * @see [Dynamic Components](guide/dynamic-component-loader)
     * \@publicApi
     * @abstract
     */


    var ComponentFactoryResolver = function ComponentFactoryResolver() {
      _classCallCheck(this, ComponentFactoryResolver);
    };

    ComponentFactoryResolver.NULL = new _NullComponentFactoryResolver();

    if (false) {}

    var CodegenComponentFactoryResolver = /*#__PURE__*/function () {
      /**
       * @param {?} factories
       * @param {?} _parent
       * @param {?} _ngModule
       */
      function CodegenComponentFactoryResolver(factories, _parent, _ngModule) {
        _classCallCheck(this, CodegenComponentFactoryResolver);

        this._parent = _parent;
        this._ngModule = _ngModule;
        this._factories = new Map();

        for (var i = 0; i < factories.length; i++) {
          /** @type {?} */
          var factory = factories[i];

          this._factories.set(factory.componentType, factory);
        }
      }
      /**
       * @template T
       * @param {?} component
       * @return {?}
       */


      _createClass2(CodegenComponentFactoryResolver, [{
        key: "resolveComponentFactory",
        value: function resolveComponentFactory(component) {
          /** @type {?} */
          var factory = this._factories.get(component);

          if (!factory && this._parent) {
            factory = this._parent.resolveComponentFactory(component);
          }

          if (!factory) {
            throw noComponentFactoryError(component);
          }

          return new ComponentFactoryBoundToModule(factory, this._ngModule);
        }
      }]);

      return CodegenComponentFactoryResolver;
    }();

    if (false) {}
    /**
     * @template C
     */


    var ComponentFactoryBoundToModule = /*#__PURE__*/function (_ComponentFactory) {
      _inherits(ComponentFactoryBoundToModule, _ComponentFactory);

      var _super36 = _createSuper(ComponentFactoryBoundToModule);

      /**
       * @param {?} factory
       * @param {?} ngModule
       */
      function ComponentFactoryBoundToModule(factory, ngModule) {
        var _this157;

        _classCallCheck(this, ComponentFactoryBoundToModule);

        _this157 = _super36.call(this);
        _this157.factory = factory;
        _this157.ngModule = ngModule;
        _this157.selector = factory.selector;
        _this157.componentType = factory.componentType;
        _this157.ngContentSelectors = factory.ngContentSelectors;
        _this157.inputs = factory.inputs;
        _this157.outputs = factory.outputs;
        return _this157;
      }
      /**
       * @param {?} injector
       * @param {?=} projectableNodes
       * @param {?=} rootSelectorOrNode
       * @param {?=} ngModule
       * @return {?}
       */


      _createClass2(ComponentFactoryBoundToModule, [{
        key: "create",
        value: function create(injector, projectableNodes, rootSelectorOrNode, ngModule) {
          return this.factory.create(injector, projectableNodes, rootSelectorOrNode, ngModule || this.ngModule);
        }
      }]);

      return ComponentFactoryBoundToModule;
    }(ComponentFactory);

    if (false) {}
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */


    function noop() {} // Do nothing.

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/linker/element_ref.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * A wrapper around a native element inside of a View.
     *
     * An `ElementRef` is backed by a render-specific element. In the browser, this is usually a DOM
     * element.
     *
     * \@security Permitting direct access to the DOM can make your application more vulnerable to
     * XSS attacks. Carefully review any use of `ElementRef` in your code. For more detail, see the
     * [Security Guide](http://g.co/ng/security).
     *
     * \@publicApi
     * @template T
     */
    // Note: We don't expose things like `Injector`, `ViewContainer`, ... here,
    // i.e. users have to ask for what they need. With that, we can build better analysis tools
    // and could do better codegen in the future.


    var ElementRef =
    /**
     * @param {?} nativeElement
     */
    function ElementRef(nativeElement) {
      _classCallCheck(this, ElementRef);

      this.nativeElement = nativeElement;
    };
    /**
     * \@internal
     * @nocollapse
     */


    ElementRef.__NG_ELEMENT_ID__ =
    /**
    * @return {?}
    */
    function () {
      return SWITCH_ELEMENT_REF_FACTORY(ElementRef);
    };

    if (false) {}
    /** @type {?} */


    var SWITCH_ELEMENT_REF_FACTORY__POST_R3__ = injectElementRef;
    /** @type {?} */

    var SWITCH_ELEMENT_REF_FACTORY__PRE_R3__ = noop;
    /** @type {?} */

    var SWITCH_ELEMENT_REF_FACTORY = SWITCH_ELEMENT_REF_FACTORY__POST_R3__;
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render/api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */

    var Renderer2Interceptor = new InjectionToken('Renderer2Interceptor');
    /**
     * Used by `RendererFactory2` to associate custom rendering data and styles
     * with a rendering implementation.
     * \@publicApi
     * @record
     */

    function RendererType2() {}

    if (false) {}
    /**
     * Creates and initializes a custom renderer that implements the `Renderer2` base class.
     *
     * \@publicApi
     * @abstract
     */


    var RendererFactory2 = function RendererFactory2() {
      _classCallCheck(this, RendererFactory2);
    };

    if (false) {}
    /** @enum {number} */


    var RendererStyleFlags2 = {
      // TODO(misko): This needs to be refactored into a separate file so that it can be imported from
      // `node_manipulation.ts` Currently doing the import cause resolution order to change and fails
      // the tests. The work around is to have hard coded value in `node_manipulation.ts` for now.

      /**
       * Marks a style as important.
       */
      Important: 1,

      /**
       * Marks a style as using dash case naming (this-is-dash-case).
       */
      DashCase: 2
    };
    RendererStyleFlags2[RendererStyleFlags2.Important] = 'Important';
    RendererStyleFlags2[RendererStyleFlags2.DashCase] = 'DashCase';
    /**
     * Extend this base class to implement custom rendering. By default, Angular
     * renders a template into DOM. You can use custom rendering to intercept
     * rendering calls, or to render to something other than DOM.
     *
     * Create your custom renderer using `RendererFactory2`.
     *
     * Use a custom renderer to bypass Angular's templating and
     * make custom UI changes that can't be expressed declaratively.
     * For example if you need to set a property or an attribute whose name is
     * not statically known, use the `setProperty()` or
     * `setAttribute()` method.
     *
     * \@publicApi
     * @abstract
     */

    var Renderer2 = function Renderer2() {
      _classCallCheck(this, Renderer2);
    };
    /**
     * \@internal
     * @nocollapse
     */


    Renderer2.__NG_ELEMENT_ID__ =
    /**
    * @return {?}
    */
    function () {
      return SWITCH_RENDERER2_FACTORY();
    };

    if (false) {}
    /** @type {?} */


    var SWITCH_RENDERER2_FACTORY__POST_R3__ = injectRenderer2;
    /** @type {?} */

    var SWITCH_RENDERER2_FACTORY__PRE_R3__ = noop;
    /** @type {?} */

    var SWITCH_RENDERER2_FACTORY = SWITCH_RENDERER2_FACTORY__POST_R3__;
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/sanitization/sanitizer.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Sanitizer is used by the views to sanitize potentially dangerous values.
     *
     * \@publicApi
     * @abstract
     */

    var Sanitizer = function Sanitizer() {
      _classCallCheck(this, Sanitizer);
    };
    /** @nocollapse */


    Sanitizer.ɵprov = ɵɵdefineInjectable({
      token: Sanitizer,
      providedIn: 'root',
      factory:
      /**
      * @return {?}
      */
      function factory() {
        return null;
      }
    });

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/version.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * \@description Represents the version of Angular
     *
     * \@publicApi
     */


    var Version =
    /**
     * @param {?} full
     */
    function Version(full) {
      _classCallCheck(this, Version);

      this.full = full;
      this.major = full.split('.')[0];
      this.minor = full.split('.')[1];
      this.patch = full.split('.').slice(2).join('.');
    };

    if (false) {}
    /**
     * \@publicApi
     * @type {?}
     */


    var VERSION = new Version('9.1.4');
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/change_detection/differs/default_iterable_differ.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    var DefaultIterableDifferFactory = /*#__PURE__*/function () {
      function DefaultIterableDifferFactory() {
        _classCallCheck(this, DefaultIterableDifferFactory);
      }
      /**
       * @param {?} obj
       * @return {?}
       */


      _createClass2(DefaultIterableDifferFactory, [{
        key: "supports",
        value: function supports(obj) {
          return isListLikeIterable$1(obj);
        }
        /**
         * @template V
         * @param {?=} trackByFn
         * @return {?}
         */

      }, {
        key: "create",
        value: function create(trackByFn) {
          return new DefaultIterableDiffer(trackByFn);
        }
      }]);

      return DefaultIterableDifferFactory;
    }();
    /** @type {?} */


    var trackByIdentity =
    /**
    * @param {?} index
    * @param {?} item
    * @return {?}
    */
    function trackByIdentity(index, item) {
      return item;
    };

    var ɵ0$c = trackByIdentity;
    /**
     * @deprecated v4.0.0 - Should not be part of public API.
     * \@publicApi
     * @template V
     */

    var DefaultIterableDiffer = /*#__PURE__*/function () {
      /**
       * @param {?=} trackByFn
       */
      function DefaultIterableDiffer(trackByFn) {
        _classCallCheck(this, DefaultIterableDiffer);

        this.length = 0; // Keeps track of the used records at any point in time (during & across `_check()` calls)

        this._linkedRecords = null; // Keeps track of the removed records at any point in time during `_check()` calls.

        this._unlinkedRecords = null;
        this._previousItHead = null;
        this._itHead = null;
        this._itTail = null;
        this._additionsHead = null;
        this._additionsTail = null;
        this._movesHead = null;
        this._movesTail = null;
        this._removalsHead = null;
        this._removalsTail = null; // Keeps track of records where custom track by is the same, but item identity has changed

        this._identityChangesHead = null;
        this._identityChangesTail = null;
        this._trackByFn = trackByFn || trackByIdentity;
      }
      /**
       * @param {?} fn
       * @return {?}
       */


      _createClass2(DefaultIterableDiffer, [{
        key: "forEachItem",
        value: function forEachItem(fn) {
          /** @type {?} */
          var record;

          for (record = this._itHead; record !== null; record = record._next) {
            fn(record);
          }
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "forEachOperation",
        value: function forEachOperation(fn) {
          /** @type {?} */
          var nextIt = this._itHead;
          /** @type {?} */

          var nextRemove = this._removalsHead;
          /** @type {?} */

          var addRemoveOffset = 0;
          /** @type {?} */

          var moveOffsets = null;

          while (nextIt || nextRemove) {
            // Figure out which is the next record to process
            // Order: remove, add, move

            /** @type {?} */
            var record = !nextRemove || nextIt &&
            /** @type {?} */
            nextIt.currentIndex < getPreviousIndex(nextRemove, addRemoveOffset, moveOffsets) ?
            /** @type {?} */
            nextIt : nextRemove;
            /** @type {?} */

            var adjPreviousIndex = getPreviousIndex(record, addRemoveOffset, moveOffsets);
            /** @type {?} */

            var currentIndex = record.currentIndex; // consume the item, and adjust the addRemoveOffset and update moveDistance if necessary

            if (record === nextRemove) {
              addRemoveOffset--;
              nextRemove = nextRemove._nextRemoved;
            } else {
              nextIt =
              /** @type {?} */
              nextIt._next;

              if (record.previousIndex == null) {
                addRemoveOffset++;
              } else {
                // INVARIANT:  currentIndex < previousIndex
                if (!moveOffsets) moveOffsets = [];
                /** @type {?} */

                var localMovePreviousIndex = adjPreviousIndex - addRemoveOffset;
                /** @type {?} */

                var localCurrentIndex =
                /** @type {?} */
                currentIndex - addRemoveOffset;

                if (localMovePreviousIndex != localCurrentIndex) {
                  for (var i = 0; i < localMovePreviousIndex; i++) {
                    /** @type {?} */
                    var offset = i < moveOffsets.length ? moveOffsets[i] : moveOffsets[i] = 0;
                    /** @type {?} */

                    var index = offset + i;

                    if (localCurrentIndex <= index && index < localMovePreviousIndex) {
                      moveOffsets[i] = offset + 1;
                    }
                  }
                  /** @type {?} */


                  var previousIndex = record.previousIndex;
                  moveOffsets[previousIndex] = localCurrentIndex - localMovePreviousIndex;
                }
              }
            }

            if (adjPreviousIndex !== currentIndex) {
              fn(record, adjPreviousIndex, currentIndex);
            }
          }
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "forEachPreviousItem",
        value: function forEachPreviousItem(fn) {
          /** @type {?} */
          var record;

          for (record = this._previousItHead; record !== null; record = record._nextPrevious) {
            fn(record);
          }
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "forEachAddedItem",
        value: function forEachAddedItem(fn) {
          /** @type {?} */
          var record;

          for (record = this._additionsHead; record !== null; record = record._nextAdded) {
            fn(record);
          }
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "forEachMovedItem",
        value: function forEachMovedItem(fn) {
          /** @type {?} */
          var record;

          for (record = this._movesHead; record !== null; record = record._nextMoved) {
            fn(record);
          }
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "forEachRemovedItem",
        value: function forEachRemovedItem(fn) {
          /** @type {?} */
          var record;

          for (record = this._removalsHead; record !== null; record = record._nextRemoved) {
            fn(record);
          }
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "forEachIdentityChange",
        value: function forEachIdentityChange(fn) {
          /** @type {?} */
          var record;

          for (record = this._identityChangesHead; record !== null; record = record._nextIdentityChange) {
            fn(record);
          }
        }
        /**
         * @param {?} collection
         * @return {?}
         */

      }, {
        key: "diff",
        value: function diff(collection) {
          if (collection == null) collection = [];

          if (!isListLikeIterable$1(collection)) {
            throw new Error("Error trying to diff '".concat(stringify(collection), "'. Only arrays and iterables are allowed"));
          }

          if (this.check(collection)) {
            return this;
          } else {
            return null;
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "onDestroy",
        value: function onDestroy() {}
        /**
         * @param {?} collection
         * @return {?}
         */

      }, {
        key: "check",
        value: function check(collection) {
          var _this158 = this;

          this._reset();
          /** @type {?} */


          var record = this._itHead;
          /** @type {?} */

          var mayBeDirty = false;
          /** @type {?} */

          var index;
          /** @type {?} */

          var item;
          /** @type {?} */

          var itemTrackBy;

          if (Array.isArray(collection)) {
            /** @type {?} */
            this.length = collection.length;

            for (var _index3 = 0; _index3 < this.length; _index3++) {
              item = collection[_index3];
              itemTrackBy = this._trackByFn(_index3, item);

              if (record === null || !looseIdentical(record.trackById, itemTrackBy)) {
                record = this._mismatch(record, item, itemTrackBy, _index3);
                mayBeDirty = true;
              } else {
                if (mayBeDirty) {
                  // TODO(misko): can we limit this to duplicates only?
                  record = this._verifyReinsertion(record, item, itemTrackBy, _index3);
                }

                if (!looseIdentical(record.item, item)) this._addIdentityChange(record, item);
              }

              record = record._next;
            }
          } else {
            index = 0;
            iterateListLike$1(collection,
            /**
            * @param {?} item
            * @return {?}
            */
            function (item) {
              itemTrackBy = _this158._trackByFn(index, item);

              if (record === null || !looseIdentical(record.trackById, itemTrackBy)) {
                record = _this158._mismatch(record, item, itemTrackBy, index);
                mayBeDirty = true;
              } else {
                if (mayBeDirty) {
                  // TODO(misko): can we limit this to duplicates only?
                  record = _this158._verifyReinsertion(record, item, itemTrackBy, index);
                }

                if (!looseIdentical(record.item, item)) _this158._addIdentityChange(record, item);
              }

              record = record._next;
              index++;
            });

            /** @type {?} */
            this.length = index;
          }

          this._truncate(record);

          /** @type {?} */
          this.collection = collection;
          return this.isDirty;
        }
        /* CollectionChanges is considered dirty if it has any additions, moves, removals, or identity
           * changes.
           */

        /**
         * @return {?}
         */

      }, {
        key: "_reset",

        /**
         * Reset the state of the change objects to show no changes. This means set previousKey to
         * currentKey, and clear all of the queues (additions, moves, removals).
         * Set the previousIndexes of moved and added items to their currentIndexes
         * Reset the list of additions, moves and removals
         *
         * \@internal
         * @return {?}
         */
        value: function _reset() {
          if (this.isDirty) {
            /** @type {?} */
            var record;
            /** @type {?} */

            var nextRecord;

            for (record = this._previousItHead = this._itHead; record !== null; record = record._next) {
              record._nextPrevious = record._next;
            }

            for (record = this._additionsHead; record !== null; record = record._nextAdded) {
              record.previousIndex = record.currentIndex;
            }

            this._additionsHead = this._additionsTail = null;

            for (record = this._movesHead; record !== null; record = nextRecord) {
              record.previousIndex = record.currentIndex;
              nextRecord = record._nextMoved;
            }

            this._movesHead = this._movesTail = null;
            this._removalsHead = this._removalsTail = null;
            this._identityChangesHead = this._identityChangesTail = null; // TODO(vicb): when assert gets supported
            // assert(!this.isDirty);
          }
        }
        /**
         * This is the core function which handles differences between collections.
         *
         * - `record` is the record which we saw at this position last time. If null then it is a new
         *   item.
         * - `item` is the current item in the collection
         * - `index` is the position of the item in the collection
         *
         * \@internal
         * @param {?} record
         * @param {?} item
         * @param {?} itemTrackBy
         * @param {?} index
         * @return {?}
         */

      }, {
        key: "_mismatch",
        value: function _mismatch(record, item, itemTrackBy, index) {
          // The previous record after which we will append the current one.

          /** @type {?} */
          var previousRecord;

          if (record === null) {
            previousRecord = this._itTail;
          } else {
            previousRecord = record._prev; // Remove the record from the collection since we know it does not match the item.

            this._remove(record);
          } // Attempt to see if we have seen the item before.


          record = this._linkedRecords === null ? null : this._linkedRecords.get(itemTrackBy, index);

          if (record !== null) {
            // We have seen this before, we need to move it forward in the collection.
            // But first we need to check if identity changed, so we can update in view if necessary
            if (!looseIdentical(record.item, item)) this._addIdentityChange(record, item);

            this._moveAfter(record, previousRecord, index);
          } else {
            // Never seen it, check evicted list.
            record = this._unlinkedRecords === null ? null : this._unlinkedRecords.get(itemTrackBy, null);

            if (record !== null) {
              // It is an item which we have evicted earlier: reinsert it back into the list.
              // But first we need to check if identity changed, so we can update in view if necessary
              if (!looseIdentical(record.item, item)) this._addIdentityChange(record, item);

              this._reinsertAfter(record, previousRecord, index);
            } else {
              // It is a new item: add it.
              record = this._addAfter(new IterableChangeRecord_(item, itemTrackBy), previousRecord, index);
            }
          }

          return record;
        }
        /**
         * This check is only needed if an array contains duplicates. (Short circuit of nothing dirty)
         *
         * Use case: `[a, a]` => `[b, a, a]`
         *
         * If we did not have this check then the insertion of `b` would:
         *   1) evict first `a`
         *   2) insert `b` at `0` index.
         *   3) leave `a` at index `1` as is. <-- this is wrong!
         *   3) reinsert `a` at index 2. <-- this is wrong!
         *
         * The correct behavior is:
         *   1) evict first `a`
         *   2) insert `b` at `0` index.
         *   3) reinsert `a` at index 1.
         *   3) move `a` at from `1` to `2`.
         *
         *
         * Double check that we have not evicted a duplicate item. We need to check if the item type may
         * have already been removed:
         * The insertion of b will evict the first 'a'. If we don't reinsert it now it will be reinserted
         * at the end. Which will show up as the two 'a's switching position. This is incorrect, since a
         * better way to think of it is as insert of 'b' rather then switch 'a' with 'b' and then add 'a'
         * at the end.
         *
         * \@internal
         * @param {?} record
         * @param {?} item
         * @param {?} itemTrackBy
         * @param {?} index
         * @return {?}
         */

      }, {
        key: "_verifyReinsertion",
        value: function _verifyReinsertion(record, item, itemTrackBy, index) {
          /** @type {?} */
          var reinsertRecord = this._unlinkedRecords === null ? null : this._unlinkedRecords.get(itemTrackBy, null);

          if (reinsertRecord !== null) {
            record = this._reinsertAfter(reinsertRecord,
            /** @type {?} */
            record._prev, index);
          } else if (record.currentIndex != index) {
            record.currentIndex = index;

            this._addToMoves(record, index);
          }

          return record;
        }
        /**
         * Get rid of any excess {\@link IterableChangeRecord_}s from the previous collection
         *
         * - `record` The first excess {\@link IterableChangeRecord_}.
         *
         * \@internal
         * @param {?} record
         * @return {?}
         */

      }, {
        key: "_truncate",
        value: function _truncate(record) {
          // Anything after that needs to be removed;
          while (record !== null) {
            /** @type {?} */
            var nextRecord = record._next;

            this._addToRemovals(this._unlink(record));

            record = nextRecord;
          }

          if (this._unlinkedRecords !== null) {
            this._unlinkedRecords.clear();
          }

          if (this._additionsTail !== null) {
            this._additionsTail._nextAdded = null;
          }

          if (this._movesTail !== null) {
            this._movesTail._nextMoved = null;
          }

          if (this._itTail !== null) {
            this._itTail._next = null;
          }

          if (this._removalsTail !== null) {
            this._removalsTail._nextRemoved = null;
          }

          if (this._identityChangesTail !== null) {
            this._identityChangesTail._nextIdentityChange = null;
          }
        }
        /**
         * \@internal
         * @param {?} record
         * @param {?} prevRecord
         * @param {?} index
         * @return {?}
         */

      }, {
        key: "_reinsertAfter",
        value: function _reinsertAfter(record, prevRecord, index) {
          if (this._unlinkedRecords !== null) {
            this._unlinkedRecords.remove(record);
          }
          /** @type {?} */


          var prev = record._prevRemoved;
          /** @type {?} */

          var next = record._nextRemoved;

          if (prev === null) {
            this._removalsHead = next;
          } else {
            prev._nextRemoved = next;
          }

          if (next === null) {
            this._removalsTail = prev;
          } else {
            next._prevRemoved = prev;
          }

          this._insertAfter(record, prevRecord, index);

          this._addToMoves(record, index);

          return record;
        }
        /**
         * \@internal
         * @param {?} record
         * @param {?} prevRecord
         * @param {?} index
         * @return {?}
         */

      }, {
        key: "_moveAfter",
        value: function _moveAfter(record, prevRecord, index) {
          this._unlink(record);

          this._insertAfter(record, prevRecord, index);

          this._addToMoves(record, index);

          return record;
        }
        /**
         * \@internal
         * @param {?} record
         * @param {?} prevRecord
         * @param {?} index
         * @return {?}
         */

      }, {
        key: "_addAfter",
        value: function _addAfter(record, prevRecord, index) {
          this._insertAfter(record, prevRecord, index);

          if (this._additionsTail === null) {
            // TODO(vicb):
            // assert(this._additionsHead === null);
            this._additionsTail = this._additionsHead = record;
          } else {
            // TODO(vicb):
            // assert(_additionsTail._nextAdded === null);
            // assert(record._nextAdded === null);
            this._additionsTail = this._additionsTail._nextAdded = record;
          }

          return record;
        }
        /**
         * \@internal
         * @param {?} record
         * @param {?} prevRecord
         * @param {?} index
         * @return {?}
         */

      }, {
        key: "_insertAfter",
        value: function _insertAfter(record, prevRecord, index) {
          // TODO(vicb):
          // assert(record != prevRecord);
          // assert(record._next === null);
          // assert(record._prev === null);
          // TODO(vicb):
          // assert(record != prevRecord);
          // assert(record._next === null);
          // assert(record._prev === null);

          /** @type {?} */
          var next = prevRecord === null ? this._itHead : prevRecord._next; // TODO(vicb):
          // assert(next != record);
          // assert(prevRecord != record);

          record._next = next;
          record._prev = prevRecord;

          if (next === null) {
            this._itTail = record;
          } else {
            next._prev = record;
          }

          if (prevRecord === null) {
            this._itHead = record;
          } else {
            prevRecord._next = record;
          }

          if (this._linkedRecords === null) {
            this._linkedRecords = new _DuplicateMap();
          }

          this._linkedRecords.put(record);

          record.currentIndex = index;
          return record;
        }
        /**
         * \@internal
         * @param {?} record
         * @return {?}
         */

      }, {
        key: "_remove",
        value: function _remove(record) {
          return this._addToRemovals(this._unlink(record));
        }
        /**
         * \@internal
         * @param {?} record
         * @return {?}
         */

      }, {
        key: "_unlink",
        value: function _unlink(record) {
          if (this._linkedRecords !== null) {
            this._linkedRecords.remove(record);
          }
          /** @type {?} */


          var prev = record._prev;
          /** @type {?} */

          var next = record._next; // TODO(vicb):
          // assert((record._prev = null) === null);
          // assert((record._next = null) === null);

          if (prev === null) {
            this._itHead = next;
          } else {
            prev._next = next;
          }

          if (next === null) {
            this._itTail = prev;
          } else {
            next._prev = prev;
          }

          return record;
        }
        /**
         * \@internal
         * @param {?} record
         * @param {?} toIndex
         * @return {?}
         */

      }, {
        key: "_addToMoves",
        value: function _addToMoves(record, toIndex) {
          // TODO(vicb):
          // assert(record._nextMoved === null);
          if (record.previousIndex === toIndex) {
            return record;
          }

          if (this._movesTail === null) {
            // TODO(vicb):
            // assert(_movesHead === null);
            this._movesTail = this._movesHead = record;
          } else {
            // TODO(vicb):
            // assert(_movesTail._nextMoved === null);
            this._movesTail = this._movesTail._nextMoved = record;
          }

          return record;
        }
        /**
         * @private
         * @param {?} record
         * @return {?}
         */

      }, {
        key: "_addToRemovals",
        value: function _addToRemovals(record) {
          if (this._unlinkedRecords === null) {
            this._unlinkedRecords = new _DuplicateMap();
          }

          this._unlinkedRecords.put(record);

          record.currentIndex = null;
          record._nextRemoved = null;

          if (this._removalsTail === null) {
            // TODO(vicb):
            // assert(_removalsHead === null);
            this._removalsTail = this._removalsHead = record;
            record._prevRemoved = null;
          } else {
            // TODO(vicb):
            // assert(_removalsTail._nextRemoved === null);
            // assert(record._nextRemoved === null);
            record._prevRemoved = this._removalsTail;
            this._removalsTail = this._removalsTail._nextRemoved = record;
          }

          return record;
        }
        /**
         * \@internal
         * @param {?} record
         * @param {?} item
         * @return {?}
         */

      }, {
        key: "_addIdentityChange",
        value: function _addIdentityChange(record, item) {
          record.item = item;

          if (this._identityChangesTail === null) {
            this._identityChangesTail = this._identityChangesHead = record;
          } else {
            this._identityChangesTail = this._identityChangesTail._nextIdentityChange = record;
          }

          return record;
        }
      }, {
        key: "isDirty",
        get: function get() {
          return this._additionsHead !== null || this._movesHead !== null || this._removalsHead !== null || this._identityChangesHead !== null;
        }
      }]);

      return DefaultIterableDiffer;
    }();

    if (false) {}
    /**
     * @template V
     */


    var IterableChangeRecord_ =
    /**
     * @param {?} item
     * @param {?} trackById
     */
    function IterableChangeRecord_(item, trackById) {
      _classCallCheck(this, IterableChangeRecord_);

      this.item = item;
      this.trackById = trackById;
      this.currentIndex = null;
      this.previousIndex = null;
      /**
       * \@internal
       */

      this._nextPrevious = null;
      /**
       * \@internal
       */

      this._prev = null;
      /**
       * \@internal
       */

      this._next = null;
      /**
       * \@internal
       */

      this._prevDup = null;
      /**
       * \@internal
       */

      this._nextDup = null;
      /**
       * \@internal
       */

      this._prevRemoved = null;
      /**
       * \@internal
       */

      this._nextRemoved = null;
      /**
       * \@internal
       */

      this._nextAdded = null;
      /**
       * \@internal
       */

      this._nextMoved = null;
      /**
       * \@internal
       */

      this._nextIdentityChange = null;
    };

    if (false) {} // A linked list of CollectionChangeRecords with the same IterableChangeRecord_.item

    /**
     * @template V
     */


    var _DuplicateItemRecordList = /*#__PURE__*/function () {
      function _DuplicateItemRecordList() {
        _classCallCheck(this, _DuplicateItemRecordList);

        /**
         * \@internal
         */
        this._head = null;
        /**
         * \@internal
         */

        this._tail = null;
      }
      /**
       * Append the record to the list of duplicates.
       *
       * Note: by design all records in the list of duplicates hold the same value in record.item.
       * @param {?} record
       * @return {?}
       */


      _createClass2(_DuplicateItemRecordList, [{
        key: "add",
        value: function add(record) {
          if (this._head === null) {
            this._head = this._tail = record;
            record._nextDup = null;
            record._prevDup = null;
          } else {
            // TODO(vicb):
            // assert(record.item ==  _head.item ||
            //       record.item is num && record.item.isNaN && _head.item is num && _head.item.isNaN);

            /** @type {?} */
            this._tail._nextDup = record;
            record._prevDup = this._tail;
            record._nextDup = null;
            this._tail = record;
          }
        } // Returns a IterableChangeRecord_ having IterableChangeRecord_.trackById == trackById and
        // IterableChangeRecord_.currentIndex >= atOrAfterIndex

        /**
         * @param {?} trackById
         * @param {?} atOrAfterIndex
         * @return {?}
         */

      }, {
        key: "get",
        value: function get(trackById, atOrAfterIndex) {
          /** @type {?} */
          var record;

          for (record = this._head; record !== null; record = record._nextDup) {
            if ((atOrAfterIndex === null || atOrAfterIndex <=
            /** @type {?} */
            record.currentIndex) && looseIdentical(record.trackById, trackById)) {
              return record;
            }
          }

          return null;
        }
        /**
         * Remove one {\@link IterableChangeRecord_} from the list of duplicates.
         *
         * Returns whether the list of duplicates is empty.
         * @param {?} record
         * @return {?}
         */

      }, {
        key: "remove",
        value: function remove(record) {
          // TODO(vicb):
          // assert(() {
          //  // verify that the record being removed is in the list.
          //  for (IterableChangeRecord_ cursor = _head; cursor != null; cursor = cursor._nextDup) {
          //    if (identical(cursor, record)) return true;
          //  }
          //  return false;
          //});
          // TODO(vicb):
          // assert(() {
          //  // verify that the record being removed is in the list.
          //  for (IterableChangeRecord_ cursor = _head; cursor != null; cursor = cursor._nextDup) {
          //    if (identical(cursor, record)) return true;
          //  }
          //  return false;
          //});

          /** @type {?} */
          var prev = record._prevDup;
          /** @type {?} */

          var next = record._nextDup;

          if (prev === null) {
            this._head = next;
          } else {
            prev._nextDup = next;
          }

          if (next === null) {
            this._tail = prev;
          } else {
            next._prevDup = prev;
          }

          return this._head === null;
        }
      }]);

      return _DuplicateItemRecordList;
    }();

    if (false) {}
    /**
     * @template V
     */


    var _DuplicateMap = /*#__PURE__*/function () {
      function _DuplicateMap() {
        _classCallCheck(this, _DuplicateMap);

        this.map = new Map();
      }
      /**
       * @param {?} record
       * @return {?}
       */


      _createClass2(_DuplicateMap, [{
        key: "put",
        value: function put(record) {
          /** @type {?} */
          var key = record.trackById;
          /** @type {?} */

          var duplicates = this.map.get(key);

          if (!duplicates) {
            duplicates = new _DuplicateItemRecordList();
            this.map.set(key, duplicates);
          }

          duplicates.add(record);
        }
        /**
         * Retrieve the `value` using key. Because the IterableChangeRecord_ value may be one which we
         * have already iterated over, we use the `atOrAfterIndex` to pretend it is not there.
         *
         * Use case: `[a, b, c, a, a]` if we are at index `3` which is the second `a` then asking if we
         * have any more `a`s needs to return the second `a`.
         * @param {?} trackById
         * @param {?} atOrAfterIndex
         * @return {?}
         */

      }, {
        key: "get",
        value: function get(trackById, atOrAfterIndex) {
          /** @type {?} */
          var key = trackById;
          /** @type {?} */

          var recordList = this.map.get(key);
          return recordList ? recordList.get(trackById, atOrAfterIndex) : null;
        }
        /**
         * Removes a {\@link IterableChangeRecord_} from the list of duplicates.
         *
         * The list of duplicates also is removed from the map if it gets empty.
         * @param {?} record
         * @return {?}
         */

      }, {
        key: "remove",
        value: function remove(record) {
          /** @type {?} */
          var key = record.trackById;
          /** @type {?} */

          var recordList =
          /** @type {?} */
          this.map.get(key); // Remove the list of duplicates when it gets empty

          if (recordList.remove(record)) {
            this.map["delete"](key);
          }

          return record;
        }
        /**
         * @return {?}
         */

      }, {
        key: "clear",

        /**
         * @return {?}
         */
        value: function clear() {
          this.map.clear();
        }
      }, {
        key: "isEmpty",
        get: function get() {
          return this.map.size === 0;
        }
      }]);

      return _DuplicateMap;
    }();

    if (false) {}
    /**
     * @param {?} item
     * @param {?} addRemoveOffset
     * @param {?} moveOffsets
     * @return {?}
     */


    function getPreviousIndex(item, addRemoveOffset, moveOffsets) {
      /** @type {?} */
      var previousIndex = item.previousIndex;
      if (previousIndex === null) return previousIndex;
      /** @type {?} */

      var moveOffset = 0;

      if (moveOffsets && previousIndex < moveOffsets.length) {
        moveOffset = moveOffsets[previousIndex];
      }

      return previousIndex + addRemoveOffset + moveOffset;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/change_detection/differs/default_keyvalue_differ.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @template K, V
     */


    var DefaultKeyValueDifferFactory = /*#__PURE__*/function () {
      function DefaultKeyValueDifferFactory() {
        _classCallCheck(this, DefaultKeyValueDifferFactory);
      }
      /**
       * @param {?} obj
       * @return {?}
       */


      _createClass2(DefaultKeyValueDifferFactory, [{
        key: "supports",
        value: function supports(obj) {
          return obj instanceof Map || isJsObject$1(obj);
        }
        /**
         * @template K, V
         * @return {?}
         */

      }, {
        key: "create",
        value: function create() {
          return new DefaultKeyValueDiffer();
        }
      }]);

      return DefaultKeyValueDifferFactory;
    }();
    /**
     * @template K, V
     */


    var DefaultKeyValueDiffer = /*#__PURE__*/function () {
      function DefaultKeyValueDiffer() {
        _classCallCheck(this, DefaultKeyValueDiffer);

        this._records = new Map();
        this._mapHead = null; // _appendAfter is used in the check loop

        this._appendAfter = null;
        this._previousMapHead = null;
        this._changesHead = null;
        this._changesTail = null;
        this._additionsHead = null;
        this._additionsTail = null;
        this._removalsHead = null;
        this._removalsTail = null;
      }
      /**
       * @return {?}
       */


      _createClass2(DefaultKeyValueDiffer, [{
        key: "forEachItem",

        /**
         * @param {?} fn
         * @return {?}
         */
        value: function forEachItem(fn) {
          /** @type {?} */
          var record;

          for (record = this._mapHead; record !== null; record = record._next) {
            fn(record);
          }
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "forEachPreviousItem",
        value: function forEachPreviousItem(fn) {
          /** @type {?} */
          var record;

          for (record = this._previousMapHead; record !== null; record = record._nextPrevious) {
            fn(record);
          }
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "forEachChangedItem",
        value: function forEachChangedItem(fn) {
          /** @type {?} */
          var record;

          for (record = this._changesHead; record !== null; record = record._nextChanged) {
            fn(record);
          }
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "forEachAddedItem",
        value: function forEachAddedItem(fn) {
          /** @type {?} */
          var record;

          for (record = this._additionsHead; record !== null; record = record._nextAdded) {
            fn(record);
          }
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "forEachRemovedItem",
        value: function forEachRemovedItem(fn) {
          /** @type {?} */
          var record;

          for (record = this._removalsHead; record !== null; record = record._nextRemoved) {
            fn(record);
          }
        }
        /**
         * @param {?=} map
         * @return {?}
         */

      }, {
        key: "diff",
        value: function diff(map) {
          if (!map) {
            map = new Map();
          } else if (!(map instanceof Map || isJsObject$1(map))) {
            throw new Error("Error trying to diff '".concat(stringify(map), "'. Only maps and objects are allowed"));
          }

          return this.check(map) ? this : null;
        }
        /**
         * @return {?}
         */

      }, {
        key: "onDestroy",
        value: function onDestroy() {}
        /**
         * Check the current state of the map vs the previous.
         * The algorithm is optimised for when the keys do no change.
         * @param {?} map
         * @return {?}
         */

      }, {
        key: "check",
        value: function check(map) {
          var _this159 = this;

          this._reset();
          /** @type {?} */


          var insertBefore = this._mapHead;
          this._appendAfter = null;

          this._forEach(map,
          /**
          * @param {?} value
          * @param {?} key
          * @return {?}
          */
          function (value, key) {
            if (insertBefore && insertBefore.key === key) {
              _this159._maybeAddToChanges(insertBefore, value);

              _this159._appendAfter = insertBefore;
              insertBefore = insertBefore._next;
            } else {
              /** @type {?} */
              var record = _this159._getOrCreateRecordForKey(key, value);

              insertBefore = _this159._insertBeforeOrAppend(insertBefore, record);
            }
          }); // Items remaining at the end of the list have been deleted


          if (insertBefore) {
            if (insertBefore._prev) {
              insertBefore._prev._next = null;
            }

            this._removalsHead = insertBefore;

            for (var record = insertBefore; record !== null; record = record._nextRemoved) {
              if (record === this._mapHead) {
                this._mapHead = null;
              }

              this._records["delete"](record.key);

              record._nextRemoved = record._next;
              record.previousValue = record.currentValue;
              record.currentValue = null;
              record._prev = null;
              record._next = null;
            }
          } // Make sure tails have no next records from previous runs


          if (this._changesTail) this._changesTail._nextChanged = null;
          if (this._additionsTail) this._additionsTail._nextAdded = null;
          return this.isDirty;
        }
        /**
         * Inserts a record before `before` or append at the end of the list when `before` is null.
         *
         * Notes:
         * - This method appends at `this._appendAfter`,
         * - This method updates `this._appendAfter`,
         * - The return value is the new value for the insertion pointer.
         * @private
         * @param {?} before
         * @param {?} record
         * @return {?}
         */

      }, {
        key: "_insertBeforeOrAppend",
        value: function _insertBeforeOrAppend(before, record) {
          if (before) {
            /** @type {?} */
            var prev = before._prev;
            record._next = before;
            record._prev = prev;
            before._prev = record;

            if (prev) {
              prev._next = record;
            }

            if (before === this._mapHead) {
              this._mapHead = record;
            }

            this._appendAfter = before;
            return before;
          }

          if (this._appendAfter) {
            this._appendAfter._next = record;
            record._prev = this._appendAfter;
          } else {
            this._mapHead = record;
          }

          this._appendAfter = record;
          return null;
        }
        /**
         * @private
         * @param {?} key
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "_getOrCreateRecordForKey",
        value: function _getOrCreateRecordForKey(key, value) {
          if (this._records.has(key)) {
            /** @type {?} */
            var _record =
            /** @type {?} */
            this._records.get(key);

            this._maybeAddToChanges(_record, value);
            /** @type {?} */


            var prev = _record._prev;
            /** @type {?} */

            var next = _record._next;

            if (prev) {
              prev._next = next;
            }

            if (next) {
              next._prev = prev;
            }

            _record._next = null;
            _record._prev = null;
            return _record;
          }
          /** @type {?} */


          var record = new KeyValueChangeRecord_(key);

          this._records.set(key, record);

          record.currentValue = value;

          this._addToAdditions(record);

          return record;
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_reset",
        value: function _reset() {
          if (this.isDirty) {
            /** @type {?} */
            var record; // let `_previousMapHead` contain the state of the map before the changes

            this._previousMapHead = this._mapHead;

            for (record = this._previousMapHead; record !== null; record = record._next) {
              record._nextPrevious = record._next;
            } // Update `record.previousValue` with the value of the item before the changes
            // We need to update all changed items (that's those which have been added and changed)


            for (record = this._changesHead; record !== null; record = record._nextChanged) {
              record.previousValue = record.currentValue;
            }

            for (record = this._additionsHead; record != null; record = record._nextAdded) {
              record.previousValue = record.currentValue;
            }

            this._changesHead = this._changesTail = null;
            this._additionsHead = this._additionsTail = null;
            this._removalsHead = null;
          }
        } // Add the record or a given key to the list of changes only when the value has actually changed

        /**
         * @private
         * @param {?} record
         * @param {?} newValue
         * @return {?}
         */

      }, {
        key: "_maybeAddToChanges",
        value: function _maybeAddToChanges(record, newValue) {
          if (!looseIdentical(newValue, record.currentValue)) {
            record.previousValue = record.currentValue;
            record.currentValue = newValue;

            this._addToChanges(record);
          }
        }
        /**
         * @private
         * @param {?} record
         * @return {?}
         */

      }, {
        key: "_addToAdditions",
        value: function _addToAdditions(record) {
          if (this._additionsHead === null) {
            this._additionsHead = this._additionsTail = record;
          } else {
            /** @type {?} */
            this._additionsTail._nextAdded = record;
            this._additionsTail = record;
          }
        }
        /**
         * @private
         * @param {?} record
         * @return {?}
         */

      }, {
        key: "_addToChanges",
        value: function _addToChanges(record) {
          if (this._changesHead === null) {
            this._changesHead = this._changesTail = record;
          } else {
            /** @type {?} */
            this._changesTail._nextChanged = record;
            this._changesTail = record;
          }
        }
        /**
         * \@internal
         * @private
         * @template K, V
         * @param {?} obj
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "_forEach",
        value: function _forEach(obj, fn) {
          if (obj instanceof Map) {
            obj.forEach(fn);
          } else {
            Object.keys(obj).forEach(
            /**
            * @param {?} k
            * @return {?}
            */
            function (k) {
              return fn(obj[k], k);
            });
          }
        }
      }, {
        key: "isDirty",
        get: function get() {
          return this._additionsHead !== null || this._changesHead !== null || this._removalsHead !== null;
        }
      }]);

      return DefaultKeyValueDiffer;
    }();

    if (false) {}
    /**
     * @template K, V
     */


    var KeyValueChangeRecord_ =
    /**
     * @param {?} key
     */
    function KeyValueChangeRecord_(key) {
      _classCallCheck(this, KeyValueChangeRecord_);

      this.key = key;
      this.previousValue = null;
      this.currentValue = null;
      /**
       * \@internal
       */

      this._nextPrevious = null;
      /**
       * \@internal
       */

      this._next = null;
      /**
       * \@internal
       */

      this._prev = null;
      /**
       * \@internal
       */

      this._nextAdded = null;
      /**
       * \@internal
       */

      this._nextRemoved = null;
      /**
       * \@internal
       */

      this._nextChanged = null;
    };

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/change_detection/differs/iterable_differs.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * A strategy for tracking changes over time to an iterable. Used by {\@link NgForOf} to
     * respond to changes in an iterable by effecting equivalent changes in the DOM.
     *
     * \@publicApi
     * @record
     * @template V
     */


    function IterableDiffer() {}

    if (false) {}
    /**
     * An object describing the changes in the `Iterable` collection since last time
     * `IterableDiffer#diff()` was invoked.
     *
     * \@publicApi
     * @record
     * @template V
     */


    function IterableChanges() {}

    if (false) {}
    /**
     * Record representing the item change information.
     *
     * \@publicApi
     * @record
     * @template V
     */


    function IterableChangeRecord() {}

    if (false) {}
    /**
     * @deprecated v4.0.0 - Use IterableChangeRecord instead.
     * \@publicApi
     * @record
     * @template V
     */


    function CollectionChangeRecord() {}
    /**
     * An optional function passed into the `NgForOf` directive that defines how to track
     * changes for items in an iterable.
     * The function takes the iteration index and item ID.
     * When supplied, Angular tracks changes by the return value of the function.
     *
     * \@publicApi
     * @record
     * @template T
     */


    function TrackByFunction() {}
    /**
     * Provides a factory for {\@link IterableDiffer}.
     *
     * \@publicApi
     * @record
     */


    function IterableDifferFactory() {}

    if (false) {}
    /**
     * A repository of different iterable diffing strategies used by NgFor, NgClass, and others.
     *
     * \@publicApi
     */


    var IterableDiffers = /*#__PURE__*/function () {
      /**
       * @param {?} factories
       */
      function IterableDiffers(factories) {
        _classCallCheck(this, IterableDiffers);

        this.factories = factories;
      }
      /**
       * @param {?} factories
       * @param {?=} parent
       * @return {?}
       */


      _createClass2(IterableDiffers, [{
        key: "find",

        /**
         * @param {?} iterable
         * @return {?}
         */
        value: function find(iterable) {
          /** @type {?} */
          var factory = this.factories.find(
          /**
          * @param {?} f
          * @return {?}
          */
          function (f) {
            return f.supports(iterable);
          });

          if (factory != null) {
            return factory;
          } else {
            throw new Error("Cannot find a differ supporting object '".concat(iterable, "' of type '").concat(getTypeNameForDebugging(iterable), "'"));
          }
        }
      }], [{
        key: "create",
        value: function create(factories, parent) {
          if (parent != null) {
            /** @type {?} */
            var copied = parent.factories.slice();
            factories = factories.concat(copied);
          }

          return new IterableDiffers(factories);
        }
        /**
         * Takes an array of {\@link IterableDifferFactory} and returns a provider used to extend the
         * inherited {\@link IterableDiffers} instance with the provided factories and return a new
         * {\@link IterableDiffers} instance.
         *
         * \@usageNotes
         * ### Example
         *
         * The following example shows how to extend an existing list of factories,
         * which will only be applied to the injector for this component and its children.
         * This step is all that's required to make a new {\@link IterableDiffer} available.
         *
         * ```
         * \@Component({
         *   viewProviders: [
         *     IterableDiffers.extend([new ImmutableListDiffer()])
         *   ]
         * })
         * ```
         * @param {?} factories
         * @return {?}
         */

      }, {
        key: "extend",
        value: function extend(factories) {
          return {
            provide: IterableDiffers,
            useFactory:
            /**
            * @param {?} parent
            * @return {?}
            */
            function useFactory(parent) {
              if (!parent) {
                // Typically would occur when calling IterableDiffers.extend inside of dependencies passed
                // to
                // bootstrap(), which would override default pipes instead of extending them.
                throw new Error('Cannot extend IterableDiffers without a parent injector');
              }

              return IterableDiffers.create(factories, parent);
            },
            // Dependency technically isn't optional, but we can provide a better error message this way.
            deps: [[IterableDiffers, new SkipSelf(), new Optional()]]
          };
        }
      }]);

      return IterableDiffers;
    }();
    /** @nocollapse */


    IterableDiffers.ɵprov = ɵɵdefineInjectable({
      token: IterableDiffers,
      providedIn: 'root',
      factory:
      /**
      * @return {?}
      */
      function factory() {
        return new IterableDiffers([new DefaultIterableDifferFactory()]);
      }
    });

    if (false) {}
    /**
     * @param {?} type
     * @return {?}
     */


    function getTypeNameForDebugging(type) {
      return type['name'] || typeof type;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/change_detection/differs/keyvalue_differs.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * A differ that tracks changes made to an object over time.
     *
     * \@publicApi
     * @record
     * @template K, V
     */


    function KeyValueDiffer() {}

    if (false) {}
    /**
     * An object describing the changes in the `Map` or `{[k:string]: string}` since last time
     * `KeyValueDiffer#diff()` was invoked.
     *
     * \@publicApi
     * @record
     * @template K, V
     */


    function KeyValueChanges() {}

    if (false) {}
    /**
     * Record representing the item change information.
     *
     * \@publicApi
     * @record
     * @template K, V
     */


    function KeyValueChangeRecord() {}

    if (false) {}
    /**
     * Provides a factory for {\@link KeyValueDiffer}.
     *
     * \@publicApi
     * @record
     */


    function KeyValueDifferFactory() {}

    if (false) {}
    /**
     * A repository of different Map diffing strategies used by NgClass, NgStyle, and others.
     *
     * \@publicApi
     */


    var KeyValueDiffers = /*#__PURE__*/function () {
      /**
       * @param {?} factories
       */
      function KeyValueDiffers(factories) {
        _classCallCheck(this, KeyValueDiffers);

        this.factories = factories;
      }
      /**
       * @template S
       * @param {?} factories
       * @param {?=} parent
       * @return {?}
       */


      _createClass2(KeyValueDiffers, [{
        key: "find",

        /**
         * @param {?} kv
         * @return {?}
         */
        value: function find(kv) {
          /** @type {?} */
          var factory = this.factories.find(
          /**
          * @param {?} f
          * @return {?}
          */
          function (f) {
            return f.supports(kv);
          });

          if (factory) {
            return factory;
          }

          throw new Error("Cannot find a differ supporting object '".concat(kv, "'"));
        }
      }], [{
        key: "create",
        value: function create(factories, parent) {
          if (parent) {
            /** @type {?} */
            var copied = parent.factories.slice();
            factories = factories.concat(copied);
          }

          return new KeyValueDiffers(factories);
        }
        /**
         * Takes an array of {\@link KeyValueDifferFactory} and returns a provider used to extend the
         * inherited {\@link KeyValueDiffers} instance with the provided factories and return a new
         * {\@link KeyValueDiffers} instance.
         *
         * \@usageNotes
         * ### Example
         *
         * The following example shows how to extend an existing list of factories,
         * which will only be applied to the injector for this component and its children.
         * This step is all that's required to make a new {\@link KeyValueDiffer} available.
         *
         * ```
         * \@Component({
         *   viewProviders: [
         *     KeyValueDiffers.extend([new ImmutableMapDiffer()])
         *   ]
         * })
         * ```
         * @template S
         * @param {?} factories
         * @return {?}
         */

      }, {
        key: "extend",
        value: function extend(factories) {
          return {
            provide: KeyValueDiffers,
            useFactory:
            /**
            * @param {?} parent
            * @return {?}
            */
            function useFactory(parent) {
              if (!parent) {
                // Typically would occur when calling KeyValueDiffers.extend inside of dependencies passed
                // to bootstrap(), which would override default pipes instead of extending them.
                throw new Error('Cannot extend KeyValueDiffers without a parent injector');
              }

              return KeyValueDiffers.create(factories, parent);
            },
            // Dependency technically isn't optional, but we can provide a better error message this way.
            deps: [[KeyValueDiffers, new SkipSelf(), new Optional()]]
          };
        }
      }]);

      return KeyValueDiffers;
    }();
    /** @nocollapse */


    KeyValueDiffers.ɵprov = ɵɵdefineInjectable({
      token: KeyValueDiffers,
      providedIn: 'root',
      factory:
      /**
      * @return {?}
      */
      function factory() {
        return new KeyValueDiffers([new DefaultKeyValueDifferFactory()]);
      }
    });

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/change_detection/change_detection.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Structural diffing for `Object`s and `Map`s.
     * @type {?}
     */


    var keyValDiff = [new DefaultKeyValueDifferFactory()];
    /**
     * Structural diffing for `Iterable` types such as `Array`s.
     * @type {?}
     */

    var iterableDiff = [new DefaultIterableDifferFactory()];
    /** @type {?} */

    var defaultIterableDiffers = new IterableDiffers(iterableDiff);
    /** @type {?} */

    var defaultKeyValueDiffers = new KeyValueDiffers(keyValDiff);
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/linker/template_ref.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Represents an embedded template that can be used to instantiate embedded views.
     * To instantiate embedded views based on a template, use the `ViewContainerRef`
     * method `createEmbeddedView()`.
     *
     * Access a `TemplateRef` instance by placing a directive on an `<ng-template>`
     * element (or directive prefixed with `*`). The `TemplateRef` for the embedded view
     * is injected into the constructor of the directive,
     * using the `TemplateRef` token.
     *
     * You can also use a `Query` to find a `TemplateRef` associated with
     * a component or a directive.
     *
     * @see `ViewContainerRef`
     * @see [Navigate the Component Tree with DI](guide/dependency-injection-navtree)
     *
     * \@publicApi
     * @abstract
     * @template C
     */

    var TemplateRef = function TemplateRef() {
      _classCallCheck(this, TemplateRef);
    };
    /**
     * \@internal
     * @nocollapse
     */


    TemplateRef.__NG_ELEMENT_ID__ =
    /**
    * @return {?}
    */
    function () {
      return SWITCH_TEMPLATE_REF_FACTORY(TemplateRef, ElementRef);
    };

    if (false) {}
    /** @type {?} */


    var SWITCH_TEMPLATE_REF_FACTORY__POST_R3__ = injectTemplateRef;
    /** @type {?} */

    var SWITCH_TEMPLATE_REF_FACTORY__PRE_R3__ = noop;
    /** @type {?} */

    var SWITCH_TEMPLATE_REF_FACTORY = SWITCH_TEMPLATE_REF_FACTORY__POST_R3__;
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/linker/view_container_ref.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Represents a container where one or more views can be attached to a component.
     *
     * Can contain *host views* (created by instantiating a
     * component with the `createComponent()` method), and *embedded views*
     * (created by instantiating a `TemplateRef` with the `createEmbeddedView()` method).
     *
     * A view container instance can contain other view containers,
     * creating a [view hierarchy](guide/glossary#view-tree).
     *
     * @see `ComponentRef`
     * @see `EmbeddedViewRef`
     *
     * \@publicApi
     * @abstract
     */

    var ViewContainerRef = function ViewContainerRef() {
      _classCallCheck(this, ViewContainerRef);
    };
    /**
     * \@internal
     * @nocollapse
     */


    ViewContainerRef.__NG_ELEMENT_ID__ =
    /**
    * @return {?}
    */
    function () {
      return SWITCH_VIEW_CONTAINER_REF_FACTORY(ViewContainerRef, ElementRef);
    };

    if (false) {}
    /** @type {?} */


    var SWITCH_VIEW_CONTAINER_REF_FACTORY__POST_R3__ = injectViewContainerRef;
    /** @type {?} */

    var SWITCH_VIEW_CONTAINER_REF_FACTORY__PRE_R3__ = noop;
    /** @type {?} */

    var SWITCH_VIEW_CONTAINER_REF_FACTORY = SWITCH_VIEW_CONTAINER_REF_FACTORY__POST_R3__;
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/view/errors.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} context
     * @param {?} oldValue
     * @param {?} currValue
     * @param {?} isFirstCheck
     * @return {?}
     */

    function expressionChangedAfterItHasBeenCheckedError(context, oldValue, currValue, isFirstCheck) {
      /** @type {?} */
      var msg = "ExpressionChangedAfterItHasBeenCheckedError: Expression has changed after it was checked. Previous value: '".concat(oldValue, "'. Current value: '").concat(currValue, "'.");

      if (isFirstCheck) {
        msg += " It seems like the view has been created after its parent and its children have been dirty checked." + " Has it been created in a change detection hook ?";
      }

      return viewDebugError(msg, context);
    }
    /**
     * @param {?} err
     * @param {?} context
     * @return {?}
     */


    function viewWrappedDebugError(err, context) {
      if (!(err instanceof Error)) {
        // errors that are not Error instances don't have a stack,
        // so it is ok to wrap them into a new Error object...
        err = new Error(err.toString());
      }

      _addDebugContext(err, context);

      return err;
    }
    /**
     * @param {?} msg
     * @param {?} context
     * @return {?}
     */


    function viewDebugError(msg, context) {
      /** @type {?} */
      var err = new Error(msg);

      _addDebugContext(err, context);

      return err;
    }
    /**
     * @param {?} err
     * @param {?} context
     * @return {?}
     */


    function _addDebugContext(err, context) {
      /** @type {?} */
      err[ERROR_DEBUG_CONTEXT] = context;

      /** @type {?} */
      err[ERROR_LOGGER] = context.logError.bind(context);
    }
    /**
     * @param {?} err
     * @return {?}
     */


    function isViewDebugError(err) {
      return !!getDebugContext(err);
    }
    /**
     * @param {?} action
     * @return {?}
     */


    function viewDestroyedError(action) {
      return new Error("ViewDestroyedError: Attempt to use a destroyed view: ".concat(action));
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/view/types.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Factory for ViewDefinitions/NgModuleDefinitions.
     * We use a function so we can reexeute it in case an error happens and use the given logger
     * function to log the error from the definition of the node, which is shown in all browser
     * logs.
     * @record
     * @template D
     */


    function DefinitionFactory() {}
    /**
     * Function to call console.error at the right source location. This is an indirection
     * via another function as browser will log the location that actually called
     * `console.error`.
     * @record
     */


    function NodeLogger() {}
    /**
     * @record
     * @template DF
     */


    function Definition() {}

    if (false) {}
    /**
     * @record
     */


    function NgModuleDefinition() {}

    if (false) {}
    /**
     * @record
     */


    function NgModuleDefinitionFactory() {}
    /**
     * @record
     */


    function ViewDefinition() {}

    if (false) {}
    /**
     * @record
     */


    function ViewDefinitionFactory() {}
    /**
     * @record
     */


    function ViewUpdateFn() {}
    /**
     * @record
     */


    function NodeCheckFn() {}
    /** @enum {number} */


    var ArgumentType = {
      Inline: 0,
      Dynamic: 1
    };
    /**
     * @record
     */

    function ViewHandleEventFn() {}
    /** @enum {number} */


    var ViewFlags = {
      None: 0,
      OnPush: 2
    };
    /**
     * A node definition in the view.
     *
     * Note: We use one type for all nodes so that loops that loop over all nodes
     * of a ViewDefinition stay monomorphic!
     * @record
     */

    function NodeDef() {}

    if (false) {}
    /** @enum {number} */


    var NodeFlags = {
      None: 0,
      TypeElement: 1,
      TypeText: 2,
      ProjectedTemplate: 4,
      CatRenderNode: 3,
      TypeNgContent: 8,
      TypePipe: 16,
      TypePureArray: 32,
      TypePureObject: 64,
      TypePurePipe: 128,
      CatPureExpression: 224,
      TypeValueProvider: 256,
      TypeClassProvider: 512,
      TypeFactoryProvider: 1024,
      TypeUseExistingProvider: 2048,
      LazyProvider: 4096,
      PrivateProvider: 8192,
      TypeDirective: 16384,
      Component: 32768,
      CatProviderNoDirective: 3840,
      CatProvider: 20224,
      OnInit: 65536,
      OnDestroy: 131072,
      DoCheck: 262144,
      OnChanges: 524288,
      AfterContentInit: 1048576,
      AfterContentChecked: 2097152,
      AfterViewInit: 4194304,
      AfterViewChecked: 8388608,
      EmbeddedViews: 16777216,
      ComponentView: 33554432,
      TypeContentQuery: 67108864,
      TypeViewQuery: 134217728,
      StaticQuery: 268435456,
      DynamicQuery: 536870912,
      TypeNgModule: 1073741824,
      CatQuery: 201326592,
      // mutually exclusive values...
      Types: 201347067
    };
    /**
     * @record
     */

    function BindingDef() {}

    if (false) {}
    /** @enum {number} */


    var BindingFlags = {
      TypeElementAttribute: 1,
      TypeElementClass: 2,
      TypeElementStyle: 4,
      TypeProperty: 8,
      SyntheticProperty: 16,
      SyntheticHostProperty: 32,
      CatSyntheticProperty: 48,
      // mutually exclusive values...
      Types: 15
    };
    /**
     * @record
     */

    function OutputDef() {}

    if (false) {}
    /** @enum {number} */


    var OutputType = {
      ElementOutput: 0,
      DirectiveOutput: 1
    };
    /** @enum {number} */

    var QueryValueType = {
      ElementRef: 0,
      RenderElement: 1,
      TemplateRef: 2,
      ViewContainerRef: 3,
      Provider: 4
    };
    /**
     * @record
     */

    function ElementDef() {}

    if (false) {}
    /**
     * @record
     */


    function ElementHandleEventFn() {}
    /**
     * @record
     */


    function ProviderDef() {}

    if (false) {}
    /**
     * @record
     */


    function NgModuleProviderDef() {}

    if (false) {}
    /**
     * @record
     */


    function DepDef() {}

    if (false) {}
    /** @enum {number} */


    var DepFlags = {
      None: 0,
      SkipSelf: 1,
      Optional: 2,
      Self: 4,
      Value: 8
    };
    /**
     * @record
     */

    function TextDef() {}

    if (false) {}
    /**
     * @record
     */


    function QueryDef() {}

    if (false) {}
    /**
     * @record
     */


    function QueryBindingDef() {}

    if (false) {}
    /** @enum {number} */


    var QueryBindingType = {
      First: 0,
      All: 1
    };
    /**
     * @record
     */

    function NgContentDef() {}

    if (false) {}
    /**
     * @record
     */


    function NgModuleData() {}

    if (false) {}
    /**
     * View instance data.
     * Attention: Adding fields to this is performance sensitive!
     * @record
     */


    function ViewData() {}

    if (false) {}
    /** @enum {number} */


    var ViewState = {
      BeforeFirstCheck: 1,
      FirstCheck: 2,
      Attached: 4,
      ChecksEnabled: 8,
      IsProjectedView: 16,
      CheckProjectedView: 32,
      CheckProjectedViews: 64,
      Destroyed: 128,
      // InitState Uses 3 bits
      InitState_Mask: 1792,
      InitState_BeforeInit: 0,
      InitState_CallingOnInit: 256,
      InitState_CallingAfterContentInit: 512,
      InitState_CallingAfterViewInit: 768,
      InitState_AfterInit: 1024,
      CatDetectChanges: 12,
      CatInit: 13
    }; // Called before each cycle of a view's check to detect whether this is in the
    // initState for which we need to call ngOnInit, ngAfterContentInit or ngAfterViewInit
    // lifecycle methods. Returns true if this check cycle should call lifecycle
    // methods.

    /**
     * @param {?} view
     * @param {?} priorInitState
     * @param {?} newInitState
     * @return {?}
     */

    function shiftInitState(view, priorInitState, newInitState) {
      // Only update the InitState if we are currently in the prior state.
      // For example, only move into CallingInit if we are in BeforeInit. Only
      // move into CallingContentInit if we are in CallingInit. Normally this will
      // always be true because of how checkCycle is called in checkAndUpdateView.
      // However, if checkAndUpdateView is called recursively or if an exception is
      // thrown while checkAndUpdateView is running, checkAndUpdateView starts over
      // from the beginning. This ensures the state is monotonically increasing,
      // terminating in the AfterInit state, which ensures the Init methods are called
      // at least once and only once.

      /** @type {?} */
      var state = view.state;
      /** @type {?} */

      var initState = state & 1792
      /* InitState_Mask */
      ;

      if (initState === priorInitState) {
        view.state = state & ~1792
        /* InitState_Mask */
        | newInitState;
        view.initIndex = -1;
        return true;
      }

      return initState === newInitState;
    } // Returns true if the lifecycle init method should be called for the node with
    // the given init index.

    /**
     * @param {?} view
     * @param {?} initState
     * @param {?} index
     * @return {?}
     */


    function shouldCallLifecycleInitHook(view, initState, index) {
      if ((view.state & 1792
      /* InitState_Mask */
      ) === initState && view.initIndex <= index) {
        view.initIndex = index + 1;
        return true;
      }

      return false;
    }
    /**
     * @record
     */


    function DisposableFn() {}
    /**
     * Node instance data.
     *
     * We have a separate type per NodeType to save memory
     * (TextData | ElementData | ProviderData | PureExpressionData | QueryList<any>)
     *
     * To keep our code monomorphic,
     * we prohibit using `NodeData` directly but enforce the use of accessors (`asElementData`, ...).
     * This way, no usage site can get a `NodeData` from view.nodes and then use it for different
     * purposes.
     */


    var NodeData = function NodeData() {
      _classCallCheck(this, NodeData);
    };

    if (false) {}
    /**
     * Data for an instantiated NodeType.Text.
     *
     * Attention: Adding fields to this is performance sensitive!
     * @record
     */


    function TextData() {}

    if (false) {}
    /**
     * Accessor for view.nodes, enforcing that every usage site stays monomorphic.
     * @param {?} view
     * @param {?} index
     * @return {?}
     */


    function asTextData(view, index) {
      return (
        /** @type {?} */
        view.nodes[index]
      );
    }
    /**
     * Data for an instantiated NodeType.Element.
     *
     * Attention: Adding fields to this is performance sensitive!
     * @record
     */


    function ElementData() {}

    if (false) {}
    /**
     * @record
     */


    function ViewContainerData() {}

    if (false) {}
    /**
     * @record
     */


    function TemplateData() {}

    if (false) {}
    /**
     * Accessor for view.nodes, enforcing that every usage site stays monomorphic.
     * @param {?} view
     * @param {?} index
     * @return {?}
     */


    function asElementData(view, index) {
      return (
        /** @type {?} */
        view.nodes[index]
      );
    }
    /**
     * Data for an instantiated NodeType.Provider.
     *
     * Attention: Adding fields to this is performance sensitive!
     * @record
     */


    function ProviderData() {}

    if (false) {}
    /**
     * Accessor for view.nodes, enforcing that every usage site stays monomorphic.
     * @param {?} view
     * @param {?} index
     * @return {?}
     */


    function asProviderData(view, index) {
      return (
        /** @type {?} */
        view.nodes[index]
      );
    }
    /**
     * Data for an instantiated NodeType.PureExpression.
     *
     * Attention: Adding fields to this is performance sensitive!
     * @record
     */


    function PureExpressionData() {}

    if (false) {}
    /**
     * Accessor for view.nodes, enforcing that every usage site stays monomorphic.
     * @param {?} view
     * @param {?} index
     * @return {?}
     */


    function asPureExpressionData(view, index) {
      return (
        /** @type {?} */
        view.nodes[index]
      );
    }
    /**
     * Accessor for view.nodes, enforcing that every usage site stays monomorphic.
     * @param {?} view
     * @param {?} index
     * @return {?}
     */


    function asQueryList(view, index) {
      return (
        /** @type {?} */
        view.nodes[index]
      );
    }
    /**
     * @record
     */


    function RootData() {}

    if (false) {}
    /**
     * @abstract
     */


    var DebugContext = function DebugContext() {
      _classCallCheck(this, DebugContext);
    };

    if (false) {}
    /** @enum {number} */


    var CheckType = {
      CheckAndUpdate: 0,
      CheckNoChanges: 1
    };
    /**
     * @record
     */

    function ProviderOverride() {}

    if (false) {} // WARNING: interface has both a type and a value, skipping emit

    /**
     * This object is used to prevent cycles in the source files and to have a place where
     * debug mode can hook it. It is lazily filled when `isDevMode` is known.
     * @type {?}
     */


    var Services = {
      setCurrentNode:
      /** @type {?} */
      undefined,
      createRootView:
      /** @type {?} */
      undefined,
      createEmbeddedView:
      /** @type {?} */
      undefined,
      createComponentView:
      /** @type {?} */
      undefined,
      createNgModuleRef:
      /** @type {?} */
      undefined,
      overrideProvider:
      /** @type {?} */
      undefined,
      overrideComponentView:
      /** @type {?} */
      undefined,
      clearOverrides:
      /** @type {?} */
      undefined,
      checkAndUpdateView:
      /** @type {?} */
      undefined,
      checkNoChangesView:
      /** @type {?} */
      undefined,
      destroyView:
      /** @type {?} */
      undefined,
      resolveDep:
      /** @type {?} */
      undefined,
      createDebugContext:
      /** @type {?} */
      undefined,
      handleEvent:
      /** @type {?} */
      undefined,
      updateDirectives:
      /** @type {?} */
      undefined,
      updateRenderer:
      /** @type {?} */
      undefined,
      dirtyParentQueries:
      /** @type {?} */
      undefined
    };
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/view/util.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */

    var NOOP =
    /**
    * @return {?}
    */
    function NOOP() {};
    /** @type {?} */


    var _tokenKeyCache = new Map();
    /**
     * @param {?} token
     * @return {?}
     */


    function tokenKey(token) {
      /** @type {?} */
      var key = _tokenKeyCache.get(token);

      if (!key) {
        key = stringify(token) + '_' + _tokenKeyCache.size;

        _tokenKeyCache.set(token, key);
      }

      return key;
    }
    /**
     * @param {?} view
     * @param {?} nodeIdx
     * @param {?} bindingIdx
     * @param {?} value
     * @return {?}
     */


    function unwrapValue(view, nodeIdx, bindingIdx, value) {
      if (WrappedValue.isWrapped(value)) {
        value = WrappedValue.unwrap(value);
        /** @type {?} */

        var globalBindingIdx = view.def.nodes[nodeIdx].bindingIndex + bindingIdx;
        /** @type {?} */

        var oldValue = WrappedValue.unwrap(view.oldValues[globalBindingIdx]);
        view.oldValues[globalBindingIdx] = new WrappedValue(oldValue);
      }

      return value;
    }
    /** @type {?} */


    var UNDEFINED_RENDERER_TYPE_ID = '$$undefined';
    /** @type {?} */

    var EMPTY_RENDERER_TYPE_ID = '$$empty'; // Attention: this function is called as top level function.
    // Putting any logic in here will destroy closure tree shaking!

    /**
     * @param {?} values
     * @return {?}
     */

    function createRendererType2(values) {
      return {
        id: UNDEFINED_RENDERER_TYPE_ID,
        styles: values.styles,
        encapsulation: values.encapsulation,
        data: values.data
      };
    }
    /** @type {?} */


    var _renderCompCount$1 = 0;
    /**
     * @param {?=} type
     * @return {?}
     */

    function resolveRendererType2(type) {
      if (type && type.id === UNDEFINED_RENDERER_TYPE_ID) {
        // first time we see this RendererType2. Initialize it...

        /** @type {?} */
        var isFilled = type.encapsulation != null && type.encapsulation !== ViewEncapsulation$1.None || type.styles.length || Object.keys(type.data).length;

        if (isFilled) {
          type.id = "c".concat(_renderCompCount$1++);
        } else {
          type.id = EMPTY_RENDERER_TYPE_ID;
        }
      }

      if (type && type.id === EMPTY_RENDERER_TYPE_ID) {
        type = null;
      }

      return type || null;
    }
    /**
     * @param {?} view
     * @param {?} def
     * @param {?} bindingIdx
     * @param {?} value
     * @return {?}
     */


    function checkBinding(view, def, bindingIdx, value) {
      /** @type {?} */
      var oldValues = view.oldValues;

      if (view.state & 2
      /* FirstCheck */
      || !looseIdentical(oldValues[def.bindingIndex + bindingIdx], value)) {
        return true;
      }

      return false;
    }
    /**
     * @param {?} view
     * @param {?} def
     * @param {?} bindingIdx
     * @param {?} value
     * @return {?}
     */


    function checkAndUpdateBinding(view, def, bindingIdx, value) {
      if (checkBinding(view, def, bindingIdx, value)) {
        view.oldValues[def.bindingIndex + bindingIdx] = value;
        return true;
      }

      return false;
    }
    /**
     * @param {?} view
     * @param {?} def
     * @param {?} bindingIdx
     * @param {?} value
     * @return {?}
     */


    function checkBindingNoChanges(view, def, bindingIdx, value) {
      /** @type {?} */
      var oldValue = view.oldValues[def.bindingIndex + bindingIdx];

      if (view.state & 1
      /* BeforeFirstCheck */
      || !devModeEqual$1(oldValue, value)) {
        /** @type {?} */
        var bindingName = def.bindings[bindingIdx].name;
        throw expressionChangedAfterItHasBeenCheckedError(Services.createDebugContext(view, def.nodeIndex), "".concat(bindingName, ": ").concat(oldValue), "".concat(bindingName, ": ").concat(value), (view.state & 1
        /* BeforeFirstCheck */
        ) !== 0);
      }
    }
    /**
     * @param {?} view
     * @return {?}
     */


    function markParentViewsForCheck(view) {
      /** @type {?} */
      var currView = view;

      while (currView) {
        if (currView.def.flags & 2
        /* OnPush */
        ) {
            currView.state |= 8
            /* ChecksEnabled */
            ;
          }

        currView = currView.viewContainerParent || currView.parent;
      }
    }
    /**
     * @param {?} view
     * @param {?} endView
     * @return {?}
     */


    function markParentViewsForCheckProjectedViews(view, endView) {
      /** @type {?} */
      var currView = view;

      while (currView && currView !== endView) {
        currView.state |= 64
        /* CheckProjectedViews */
        ;
        currView = currView.viewContainerParent || currView.parent;
      }
    }
    /**
     * @param {?} view
     * @param {?} nodeIndex
     * @param {?} eventName
     * @param {?} event
     * @return {?}
     */


    function dispatchEvent(view, nodeIndex, eventName, event) {
      try {
        /** @type {?} */
        var nodeDef = view.def.nodes[nodeIndex];
        /** @type {?} */

        var startView = nodeDef.flags & 33554432
        /* ComponentView */
        ? asElementData(view, nodeIndex).componentView : view;
        markParentViewsForCheck(startView);
        return Services.handleEvent(view, nodeIndex, eventName, event);
      } catch (e) {
        // Attention: Don't rethrow, as it would cancel Observable subscriptions!
        view.root.errorHandler.handleError(e);
      }
    }
    /**
     * @param {?} view
     * @return {?}
     */


    function declaredViewContainer(view) {
      if (view.parent) {
        /** @type {?} */
        var parentView = view.parent;
        return asElementData(parentView,
        /** @type {?} */
        view.parentNodeDef.nodeIndex);
      }

      return null;
    }
    /**
     * for component views, this is the host element.
     * for embedded views, this is the index of the parent node
     * that contains the view container.
     * @param {?} view
     * @return {?}
     */


    function viewParentEl(view) {
      /** @type {?} */
      var parentView = view.parent;

      if (parentView) {
        return (
          /** @type {?} */
          view.parentNodeDef.parent
        );
      } else {
        return null;
      }
    }
    /**
     * @param {?} view
     * @param {?} def
     * @return {?}
     */


    function renderNode(view, def) {
      switch (def.flags & 201347067
      /* Types */
      ) {
        case 1
        /* TypeElement */
        :
          return asElementData(view, def.nodeIndex).renderElement;

        case 2
        /* TypeText */
        :
          return asTextData(view, def.nodeIndex).renderText;
      }
    }
    /**
     * @param {?} target
     * @param {?} name
     * @return {?}
     */


    function elementEventFullName(target, name) {
      return target ? "".concat(target, ":").concat(name) : name;
    }
    /**
     * @param {?} view
     * @return {?}
     */


    function isComponentView(view) {
      return !!view.parent && !!(
      /** @type {?} */
      view.parentNodeDef.flags & 32768
      /* Component */
      );
    }
    /**
     * @param {?} view
     * @return {?}
     */


    function isEmbeddedView(view) {
      return !!view.parent && !(
      /** @type {?} */
      view.parentNodeDef.flags & 32768
      /* Component */
      );
    }
    /**
     * @param {?} queryId
     * @return {?}
     */


    function filterQueryId(queryId) {
      return 1 << queryId % 32;
    }
    /**
     * @param {?} matchedQueriesDsl
     * @return {?}
     */


    function splitMatchedQueriesDsl(matchedQueriesDsl) {
      /** @type {?} */
      var matchedQueries = {};
      /** @type {?} */

      var matchedQueryIds = 0;
      /** @type {?} */

      var references = {};

      if (matchedQueriesDsl) {
        matchedQueriesDsl.forEach(
        /**
        * @param {?} __0
        * @return {?}
        */
        function (_ref8) {
          var _ref9 = _slicedToArray(_ref8, 2),
              queryId = _ref9[0],
              valueType = _ref9[1];

          if (typeof queryId === 'number') {
            matchedQueries[queryId] = valueType;
            matchedQueryIds |= filterQueryId(queryId);
          } else {
            references[queryId] = valueType;
          }
        });
      }

      return {
        matchedQueries: matchedQueries,
        references: references,
        matchedQueryIds: matchedQueryIds
      };
    }
    /**
     * @param {?} deps
     * @param {?=} sourceName
     * @return {?}
     */


    function splitDepsDsl(deps, sourceName) {
      return deps.map(
      /**
      * @param {?} value
      * @return {?}
      */
      function (value) {
        /** @type {?} */
        var token;
        /** @type {?} */

        var flags;

        if (Array.isArray(value)) {
          var _value2 = _slicedToArray(value, 2);

          flags = _value2[0];
          token = _value2[1];
        } else {
          flags = 0
          /* None */
          ;
          token = value;
        }

        if (token && (typeof token === 'function' || typeof token === 'object') && sourceName) {
          Object.defineProperty(token, SOURCE, {
            value: sourceName,
            configurable: true
          });
        }

        return {
          flags: flags,
          token: token,
          tokenKey: tokenKey(token)
        };
      });
    }
    /**
     * @param {?} view
     * @param {?} renderHost
     * @param {?} def
     * @return {?}
     */


    function getParentRenderElement(view, renderHost, def) {
      /** @type {?} */
      var renderParent = def.renderParent;

      if (renderParent) {
        if ((renderParent.flags & 1
        /* TypeElement */
        ) === 0 || (renderParent.flags & 33554432
        /* ComponentView */
        ) === 0 ||
        /** @type {?} */
        renderParent.element.componentRendererType &&
        /** @type {?} */

        /** @type {?} */
        renderParent.element.componentRendererType.encapsulation === ViewEncapsulation$1.Native) {
          // only children of non components, or children of components with native encapsulation should
          // be attached.
          return asElementData(view,
          /** @type {?} */
          def.renderParent.nodeIndex).renderElement;
        }
      } else {
        return renderHost;
      }
    }
    /** @type {?} */


    var DEFINITION_CACHE = new WeakMap();
    /**
     * @template D
     * @param {?} factory
     * @return {?}
     */

    function resolveDefinition(factory) {
      /** @type {?} */
      var value =
      /** @type {?} */

      /** @type {?} */
      DEFINITION_CACHE.get(factory);

      if (!value) {
        value = factory(
        /**
        * @return {?}
        */
        function () {
          return NOOP;
        });
        value.factory = factory;
        DEFINITION_CACHE.set(factory, value);
      }

      return value;
    }
    /**
     * @param {?} view
     * @return {?}
     */


    function rootRenderNodes(view) {
      /** @type {?} */
      var renderNodes = [];
      visitRootRenderNodes(view, 0
      /* Collect */
      , undefined, undefined, renderNodes);
      return renderNodes;
    }
    /** @enum {number} */


    var RenderNodeAction = {
      Collect: 0,
      AppendChild: 1,
      InsertBefore: 2,
      RemoveChild: 3
    };
    /**
     * @param {?} view
     * @param {?} action
     * @param {?} parentNode
     * @param {?} nextSibling
     * @param {?=} target
     * @return {?}
     */

    function visitRootRenderNodes(view, action, parentNode, nextSibling, target) {
      // We need to re-compute the parent node in case the nodes have been moved around manually
      if (action === 3
      /* RemoveChild */
      ) {
          parentNode = view.renderer.parentNode(renderNode(view,
          /** @type {?} */
          view.def.lastRenderRootNode));
        }

      visitSiblingRenderNodes(view, action, 0, view.def.nodes.length - 1, parentNode, nextSibling, target);
    }
    /**
     * @param {?} view
     * @param {?} action
     * @param {?} startIndex
     * @param {?} endIndex
     * @param {?} parentNode
     * @param {?} nextSibling
     * @param {?=} target
     * @return {?}
     */


    function visitSiblingRenderNodes(view, action, startIndex, endIndex, parentNode, nextSibling, target) {
      for (var i = startIndex; i <= endIndex; i++) {
        /** @type {?} */
        var nodeDef = view.def.nodes[i];

        if (nodeDef.flags & (1
        /* TypeElement */
        | 2
        /* TypeText */
        | 8
        /* TypeNgContent */
        )) {
          visitRenderNode(view, nodeDef, action, parentNode, nextSibling, target);
        } // jump to next sibling


        i += nodeDef.childCount;
      }
    }
    /**
     * @param {?} view
     * @param {?} ngContentIndex
     * @param {?} action
     * @param {?} parentNode
     * @param {?} nextSibling
     * @param {?=} target
     * @return {?}
     */


    function visitProjectedRenderNodes(view, ngContentIndex, action, parentNode, nextSibling, target) {
      /** @type {?} */
      var compView = view;

      while (compView && !isComponentView(compView)) {
        compView = compView.parent;
      }
      /** @type {?} */


      var hostView =
      /** @type {?} */
      compView.parent;
      /** @type {?} */

      var hostElDef = viewParentEl(
      /** @type {?} */
      compView);
      /** @type {?} */

      var startIndex =
      /** @type {?} */
      hostElDef.nodeIndex + 1;
      /** @type {?} */

      var endIndex =
      /** @type {?} */
      hostElDef.nodeIndex +
      /** @type {?} */
      hostElDef.childCount;

      for (var i = startIndex; i <= endIndex; i++) {
        /** @type {?} */
        var nodeDef =
        /** @type {?} */
        hostView.def.nodes[i];

        if (nodeDef.ngContentIndex === ngContentIndex) {
          visitRenderNode(
          /** @type {?} */
          hostView, nodeDef, action, parentNode, nextSibling, target);
        } // jump to next sibling


        i += nodeDef.childCount;
      }

      if (!
      /** @type {?} */
      hostView.parent) {
        // a root view

        /** @type {?} */
        var projectedNodes = view.root.projectableNodes[ngContentIndex];

        if (projectedNodes) {
          for (var _i14 = 0; _i14 < projectedNodes.length; _i14++) {
            execRenderNodeAction(view, projectedNodes[_i14], action, parentNode, nextSibling, target);
          }
        }
      }
    }
    /**
     * @param {?} view
     * @param {?} nodeDef
     * @param {?} action
     * @param {?} parentNode
     * @param {?} nextSibling
     * @param {?=} target
     * @return {?}
     */


    function visitRenderNode(view, nodeDef, action, parentNode, nextSibling, target) {
      if (nodeDef.flags & 8
      /* TypeNgContent */
      ) {
          visitProjectedRenderNodes(view,
          /** @type {?} */
          nodeDef.ngContent.index, action, parentNode, nextSibling, target);
        } else {
        /** @type {?} */
        var rn = renderNode(view, nodeDef);

        if (action === 3
        /* RemoveChild */
        && nodeDef.flags & 33554432
        /* ComponentView */
        && nodeDef.bindingFlags & 48
        /* CatSyntheticProperty */
        ) {
          // Note: we might need to do both actions.
          if (nodeDef.bindingFlags & 16
          /* SyntheticProperty */
          ) {
            execRenderNodeAction(view, rn, action, parentNode, nextSibling, target);
          }

          if (nodeDef.bindingFlags & 32
          /* SyntheticHostProperty */
          ) {
            /** @type {?} */
            var compView = asElementData(view, nodeDef.nodeIndex).componentView;
            execRenderNodeAction(compView, rn, action, parentNode, nextSibling, target);
          }
        } else {
          execRenderNodeAction(view, rn, action, parentNode, nextSibling, target);
        }

        if (nodeDef.flags & 16777216
        /* EmbeddedViews */
        ) {
            /** @type {?} */
            var embeddedViews =
            /** @type {?} */
            asElementData(view, nodeDef.nodeIndex).viewContainer._embeddedViews;

            for (var k = 0; k < embeddedViews.length; k++) {
              visitRootRenderNodes(embeddedViews[k], action, parentNode, nextSibling, target);
            }
          }

        if (nodeDef.flags & 1
        /* TypeElement */
        && !
        /** @type {?} */
        nodeDef.element.name) {
          visitSiblingRenderNodes(view, action, nodeDef.nodeIndex + 1, nodeDef.nodeIndex + nodeDef.childCount, parentNode, nextSibling, target);
        }
      }
    }
    /**
     * @param {?} view
     * @param {?} renderNode
     * @param {?} action
     * @param {?} parentNode
     * @param {?} nextSibling
     * @param {?=} target
     * @return {?}
     */


    function execRenderNodeAction(view, renderNode, action, parentNode, nextSibling, target) {
      /** @type {?} */
      var renderer = view.renderer;

      switch (action) {
        case 1
        /* AppendChild */
        :
          renderer.appendChild(parentNode, renderNode);
          break;

        case 2
        /* InsertBefore */
        :
          renderer.insertBefore(parentNode, renderNode, nextSibling);
          break;

        case 3
        /* RemoveChild */
        :
          renderer.removeChild(parentNode, renderNode);
          break;

        case 0
        /* Collect */
        :
          /** @type {?} */
          target.push(renderNode);
          break;
      }
    }
    /** @type {?} */


    var NS_PREFIX_RE = /^:([^:]+):(.+)$/;
    /**
     * @param {?} name
     * @return {?}
     */

    function splitNamespace(name) {
      if (name[0] === ':') {
        /** @type {?} */
        var match =
        /** @type {?} */
        name.match(NS_PREFIX_RE);
        return [match[1], match[2]];
      }

      return ['', name];
    }
    /**
     * @param {?} bindings
     * @return {?}
     */


    function calcBindingFlags(bindings) {
      /** @type {?} */
      var flags = 0;

      for (var i = 0; i < bindings.length; i++) {
        flags |= bindings[i].flags;
      }

      return flags;
    }
    /**
     * @param {?} valueCount
     * @param {?} constAndInterp
     * @return {?}
     */


    function interpolate(valueCount, constAndInterp) {
      /** @type {?} */
      var result = '';

      for (var i = 0; i < valueCount * 2; i = i + 2) {
        result = result + constAndInterp[i] + _toStringWithNull(constAndInterp[i + 1]);
      }

      return result + constAndInterp[valueCount * 2];
    }
    /**
     * @param {?} valueCount
     * @param {?} c0
     * @param {?} a1
     * @param {?} c1
     * @param {?=} a2
     * @param {?=} c2
     * @param {?=} a3
     * @param {?=} c3
     * @param {?=} a4
     * @param {?=} c4
     * @param {?=} a5
     * @param {?=} c5
     * @param {?=} a6
     * @param {?=} c6
     * @param {?=} a7
     * @param {?=} c7
     * @param {?=} a8
     * @param {?=} c8
     * @param {?=} a9
     * @param {?=} c9
     * @return {?}
     */


    function inlineInterpolate(valueCount, c0, a1, c1, a2, c2, a3, c3, a4, c4, a5, c5, a6, c6, a7, c7, a8, c8, a9, c9) {
      switch (valueCount) {
        case 1:
          return c0 + _toStringWithNull(a1) + c1;

        case 2:
          return c0 + _toStringWithNull(a1) + c1 + _toStringWithNull(a2) + c2;

        case 3:
          return c0 + _toStringWithNull(a1) + c1 + _toStringWithNull(a2) + c2 + _toStringWithNull(a3) + c3;

        case 4:
          return c0 + _toStringWithNull(a1) + c1 + _toStringWithNull(a2) + c2 + _toStringWithNull(a3) + c3 + _toStringWithNull(a4) + c4;

        case 5:
          return c0 + _toStringWithNull(a1) + c1 + _toStringWithNull(a2) + c2 + _toStringWithNull(a3) + c3 + _toStringWithNull(a4) + c4 + _toStringWithNull(a5) + c5;

        case 6:
          return c0 + _toStringWithNull(a1) + c1 + _toStringWithNull(a2) + c2 + _toStringWithNull(a3) + c3 + _toStringWithNull(a4) + c4 + _toStringWithNull(a5) + c5 + _toStringWithNull(a6) + c6;

        case 7:
          return c0 + _toStringWithNull(a1) + c1 + _toStringWithNull(a2) + c2 + _toStringWithNull(a3) + c3 + _toStringWithNull(a4) + c4 + _toStringWithNull(a5) + c5 + _toStringWithNull(a6) + c6 + _toStringWithNull(a7) + c7;

        case 8:
          return c0 + _toStringWithNull(a1) + c1 + _toStringWithNull(a2) + c2 + _toStringWithNull(a3) + c3 + _toStringWithNull(a4) + c4 + _toStringWithNull(a5) + c5 + _toStringWithNull(a6) + c6 + _toStringWithNull(a7) + c7 + _toStringWithNull(a8) + c8;

        case 9:
          return c0 + _toStringWithNull(a1) + c1 + _toStringWithNull(a2) + c2 + _toStringWithNull(a3) + c3 + _toStringWithNull(a4) + c4 + _toStringWithNull(a5) + c5 + _toStringWithNull(a6) + c6 + _toStringWithNull(a7) + c7 + _toStringWithNull(a8) + c8 + _toStringWithNull(a9) + c9;

        default:
          throw new Error("Does not support more than 9 expressions");
      }
    }
    /**
     * @param {?} v
     * @return {?}
     */


    function _toStringWithNull(v) {
      return v != null ? v.toString() : '';
    }
    /** @type {?} */


    var EMPTY_ARRAY$4 = [];
    /** @type {?} */

    var EMPTY_MAP = {};
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/view/ng_module.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */

    var UNDEFINED_VALUE = {};
    /** @type {?} */

    var InjectorRefTokenKey = tokenKey(Injector);
    /** @type {?} */

    var INJECTORRefTokenKey = tokenKey(INJECTOR);
    /** @type {?} */

    var NgModuleRefTokenKey = tokenKey(NgModuleRef);
    /**
     * @param {?} flags
     * @param {?} token
     * @param {?} value
     * @param {?} deps
     * @return {?}
     */

    function moduleProvideDef(flags, token, value, deps) {
      // Need to resolve forwardRefs as e.g. for `useValue` we
      // lowered the expression and then stopped evaluating it,
      // i.e. also didn't unwrap it.
      value = resolveForwardRef(value);
      /** @type {?} */

      var depDefs = splitDepsDsl(deps, stringify(token));
      return {
        // will bet set by the module definition
        index: -1,
        deps: depDefs,
        flags: flags,
        token: token,
        value: value
      };
    }
    /**
     * @param {?} providers
     * @return {?}
     */


    function moduleDef(providers) {
      /** @type {?} */
      var providersByKey = {};
      /** @type {?} */

      var modules = [];
      /** @type {?} */

      var scope = null;

      for (var i = 0; i < providers.length; i++) {
        /** @type {?} */
        var provider = providers[i];

        if (provider.token === INJECTOR_SCOPE) {
          scope = provider.value;
        }

        if (provider.flags & 1073741824
        /* TypeNgModule */
        ) {
            modules.push(provider.token);
          }

        provider.index = i;
        providersByKey[tokenKey(provider.token)] = provider;
      }

      return {
        // Will be filled later...
        factory: null,
        providersByKey: providersByKey,
        providers: providers,
        modules: modules,
        scope: scope
      };
    }
    /**
     * @param {?} data
     * @return {?}
     */


    function initNgModule(data) {
      /** @type {?} */
      var def = data._def;
      /** @type {?} */

      var providers = data._providers = newArray(def.providers.length);

      for (var i = 0; i < def.providers.length; i++) {
        /** @type {?} */
        var provDef = def.providers[i];

        if (!(provDef.flags & 4096
        /* LazyProvider */
        )) {
          // Make sure the provider has not been already initialized outside this loop.
          if (providers[i] === undefined) {
            providers[i] = _createProviderInstance(data, provDef);
          }
        }
      }
    }
    /**
     * @param {?} data
     * @param {?} depDef
     * @param {?=} notFoundValue
     * @return {?}
     */


    function resolveNgModuleDep(data, depDef) {
      var notFoundValue = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : Injector.THROW_IF_NOT_FOUND;

      /** @type {?} */
      var former = setCurrentInjector(data);

      try {
        if (depDef.flags & 8
        /* Value */
        ) {
            return depDef.token;
          }

        if (depDef.flags & 2
        /* Optional */
        ) {
            notFoundValue = null;
          }

        if (depDef.flags & 1
        /* SkipSelf */
        ) {
            return data._parent.get(depDef.token, notFoundValue);
          }
        /** @type {?} */


        var _tokenKey = depDef.tokenKey;

        switch (_tokenKey) {
          case InjectorRefTokenKey:
          case INJECTORRefTokenKey:
          case NgModuleRefTokenKey:
            return data;
        }
        /** @type {?} */


        var _providerDef = data._def.providersByKey[_tokenKey];
        /** @type {?} */

        var injectableDef;

        if (_providerDef) {
          /** @type {?} */
          var providerInstance = data._providers[_providerDef.index];

          if (providerInstance === undefined) {
            providerInstance = data._providers[_providerDef.index] = _createProviderInstance(data, _providerDef);
          }

          return providerInstance === UNDEFINED_VALUE ? undefined : providerInstance;
        } else if ((injectableDef = getInjectableDef(depDef.token)) && targetsModule(data, injectableDef)) {
          /** @type {?} */
          var index = data._providers.length;
          data._def.providers[index] = data._def.providersByKey[depDef.tokenKey] = {
            flags: 1024
            /* TypeFactoryProvider */
            | 4096
            /* LazyProvider */
            ,
            value: injectableDef.factory,
            deps: [],
            index: index,
            token: depDef.token
          };
          data._providers[index] = UNDEFINED_VALUE;
          return data._providers[index] = _createProviderInstance(data, data._def.providersByKey[depDef.tokenKey]);
        } else if (depDef.flags & 4
        /* Self */
        ) {
            return notFoundValue;
          }

        return data._parent.get(depDef.token, notFoundValue);
      } finally {
        setCurrentInjector(former);
      }
    }
    /**
     * @param {?} ngModule
     * @param {?} scope
     * @return {?}
     */


    function moduleTransitivelyPresent(ngModule, scope) {
      return ngModule._def.modules.indexOf(scope) > -1;
    }
    /**
     * @param {?} ngModule
     * @param {?} def
     * @return {?}
     */


    function targetsModule(ngModule, def) {
      /** @type {?} */
      var providedIn = def.providedIn;
      return providedIn != null && (providedIn === 'any' || providedIn === ngModule._def.scope || moduleTransitivelyPresent(ngModule, providedIn));
    }
    /**
     * @param {?} ngModule
     * @param {?} providerDef
     * @return {?}
     */


    function _createProviderInstance(ngModule, providerDef) {
      /** @type {?} */
      var injectable;

      switch (providerDef.flags & 201347067
      /* Types */
      ) {
        case 512
        /* TypeClassProvider */
        :
          injectable = _createClass(ngModule, providerDef.value, providerDef.deps);
          break;

        case 1024
        /* TypeFactoryProvider */
        :
          injectable = _callFactory(ngModule, providerDef.value, providerDef.deps);
          break;

        case 2048
        /* TypeUseExistingProvider */
        :
          injectable = resolveNgModuleDep(ngModule, providerDef.deps[0]);
          break;

        case 256
        /* TypeValueProvider */
        :
          injectable = providerDef.value;
          break;
      } // The read of `ngOnDestroy` here is slightly expensive as it's megamorphic, so it should be
      // avoided if possible. The sequence of checks here determines whether ngOnDestroy needs to be
      // checked. It might not if the `injectable` isn't an object or if NodeFlags.OnDestroy is already
      // set (ngOnDestroy was detected statically).


      if (injectable !== UNDEFINED_VALUE && injectable !== null && typeof injectable === 'object' && !(providerDef.flags & 131072
      /* OnDestroy */
      ) && typeof injectable.ngOnDestroy === 'function') {
        providerDef.flags |= 131072
        /* OnDestroy */
        ;
      }

      return injectable === undefined ? UNDEFINED_VALUE : injectable;
    }
    /**
     * @param {?} ngModule
     * @param {?} ctor
     * @param {?} deps
     * @return {?}
     */


    function _createClass(ngModule, ctor, deps) {
      /** @type {?} */
      var len = deps.length;

      switch (len) {
        case 0:
          return new ctor();

        case 1:
          return new ctor(resolveNgModuleDep(ngModule, deps[0]));

        case 2:
          return new ctor(resolveNgModuleDep(ngModule, deps[0]), resolveNgModuleDep(ngModule, deps[1]));

        case 3:
          return new ctor(resolveNgModuleDep(ngModule, deps[0]), resolveNgModuleDep(ngModule, deps[1]), resolveNgModuleDep(ngModule, deps[2]));

        default:
          /** @type {?} */
          var depValues = [];

          for (var i = 0; i < len; i++) {
            depValues[i] = resolveNgModuleDep(ngModule, deps[i]);
          }

          return _construct(ctor, depValues);
      }
    }
    /**
     * @param {?} ngModule
     * @param {?} factory
     * @param {?} deps
     * @return {?}
     */


    function _callFactory(ngModule, factory, deps) {
      /** @type {?} */
      var len = deps.length;

      switch (len) {
        case 0:
          return factory();

        case 1:
          return factory(resolveNgModuleDep(ngModule, deps[0]));

        case 2:
          return factory(resolveNgModuleDep(ngModule, deps[0]), resolveNgModuleDep(ngModule, deps[1]));

        case 3:
          return factory(resolveNgModuleDep(ngModule, deps[0]), resolveNgModuleDep(ngModule, deps[1]), resolveNgModuleDep(ngModule, deps[2]));

        default:
          /** @type {?} */
          var depValues = [];

          for (var i = 0; i < len; i++) {
            depValues[i] = resolveNgModuleDep(ngModule, deps[i]);
          }

          return factory.apply(void 0, depValues);
      }
    }
    /**
     * @param {?} ngModule
     * @param {?} lifecycles
     * @return {?}
     */


    function callNgModuleLifecycle(ngModule, lifecycles) {
      /** @type {?} */
      var def = ngModule._def;
      /** @type {?} */

      var destroyed = new Set();

      for (var i = 0; i < def.providers.length; i++) {
        /** @type {?} */
        var provDef = def.providers[i];

        if (provDef.flags & 131072
        /* OnDestroy */
        ) {
            /** @type {?} */
            var instance = ngModule._providers[i];

            if (instance && instance !== UNDEFINED_VALUE) {
              /** @type {?} */
              var onDestroy = instance.ngOnDestroy;

              if (typeof onDestroy === 'function' && !destroyed.has(instance)) {
                onDestroy.apply(instance);
                destroyed.add(instance);
              }
            }
          }
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/view/view_attach.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} parentView
     * @param {?} elementData
     * @param {?} viewIndex
     * @param {?} view
     * @return {?}
     */


    function attachEmbeddedView(parentView, elementData, viewIndex, view) {
      /** @type {?} */
      var embeddedViews =
      /** @type {?} */
      elementData.viewContainer._embeddedViews;

      if (viewIndex === null || viewIndex === undefined) {
        viewIndex = embeddedViews.length;
      }

      view.viewContainerParent = parentView;
      addToArray(embeddedViews,
      /** @type {?} */
      viewIndex, view);
      attachProjectedView(elementData, view);
      Services.dirtyParentQueries(view);
      /** @type {?} */

      var prevView =
      /** @type {?} */
      viewIndex > 0 ? embeddedViews[
      /** @type {?} */
      viewIndex - 1] : null;
      renderAttachEmbeddedView(elementData, prevView, view);
    }
    /**
     * @param {?} vcElementData
     * @param {?} view
     * @return {?}
     */


    function attachProjectedView(vcElementData, view) {
      /** @type {?} */
      var dvcElementData = declaredViewContainer(view);

      if (!dvcElementData || dvcElementData === vcElementData || view.state & 16
      /* IsProjectedView */
      ) {
          return;
        } // Note: For performance reasons, we
      // - add a view to template._projectedViews only 1x throughout its lifetime,
      //   and remove it not until the view is destroyed.
      //   (hard, as when a parent view is attached/detached we would need to attach/detach all
      //    nested projected views as well, even across component boundaries).
      // - don't track the insertion order of views in the projected views array
      //   (hard, as when the views of the same template are inserted different view containers)


      view.state |= 16
      /* IsProjectedView */
      ;
      /** @type {?} */

      var projectedViews = dvcElementData.template._projectedViews;

      if (!projectedViews) {
        projectedViews = dvcElementData.template._projectedViews = [];
      }

      projectedViews.push(view); // Note: we are changing the NodeDef here as we cannot calculate
      // the fact whether a template is used for projection during compilation.

      markNodeAsProjectedTemplate(
      /** @type {?} */
      view.parent.def,
      /** @type {?} */
      view.parentNodeDef);
    }
    /**
     * @param {?} viewDef
     * @param {?} nodeDef
     * @return {?}
     */


    function markNodeAsProjectedTemplate(viewDef, nodeDef) {
      if (nodeDef.flags & 4
      /* ProjectedTemplate */
      ) {
          return;
        }

      viewDef.nodeFlags |= 4
      /* ProjectedTemplate */
      ;
      nodeDef.flags |= 4
      /* ProjectedTemplate */
      ;
      /** @type {?} */

      var parentNodeDef = nodeDef.parent;

      while (parentNodeDef) {
        parentNodeDef.childFlags |= 4
        /* ProjectedTemplate */
        ;
        parentNodeDef = parentNodeDef.parent;
      }
    }
    /**
     * @param {?} elementData
     * @param {?=} viewIndex
     * @return {?}
     */


    function detachEmbeddedView(elementData, viewIndex) {
      /** @type {?} */
      var embeddedViews =
      /** @type {?} */
      elementData.viewContainer._embeddedViews;

      if (viewIndex == null || viewIndex >= embeddedViews.length) {
        viewIndex = embeddedViews.length - 1;
      }

      if (viewIndex < 0) {
        return null;
      }
      /** @type {?} */


      var view = embeddedViews[viewIndex];
      view.viewContainerParent = null;
      removeFromArray(embeddedViews, viewIndex); // See attachProjectedView for why we don't update projectedViews here.

      Services.dirtyParentQueries(view);
      renderDetachView$1(view);
      return view;
    }
    /**
     * @param {?} view
     * @return {?}
     */


    function detachProjectedView(view) {
      if (!(view.state & 16
      /* IsProjectedView */
      )) {
        return;
      }
      /** @type {?} */


      var dvcElementData = declaredViewContainer(view);

      if (dvcElementData) {
        /** @type {?} */
        var projectedViews = dvcElementData.template._projectedViews;

        if (projectedViews) {
          removeFromArray(projectedViews, projectedViews.indexOf(view));
          Services.dirtyParentQueries(view);
        }
      }
    }
    /**
     * @param {?} elementData
     * @param {?} oldViewIndex
     * @param {?} newViewIndex
     * @return {?}
     */


    function moveEmbeddedView(elementData, oldViewIndex, newViewIndex) {
      /** @type {?} */
      var embeddedViews =
      /** @type {?} */
      elementData.viewContainer._embeddedViews;
      /** @type {?} */

      var view = embeddedViews[oldViewIndex];
      removeFromArray(embeddedViews, oldViewIndex);

      if (newViewIndex == null) {
        newViewIndex = embeddedViews.length;
      }

      addToArray(embeddedViews, newViewIndex, view); // Note: Don't need to change projectedViews as the order in there
      // as always invalid...

      Services.dirtyParentQueries(view);
      renderDetachView$1(view);
      /** @type {?} */

      var prevView = newViewIndex > 0 ? embeddedViews[newViewIndex - 1] : null;
      renderAttachEmbeddedView(elementData, prevView, view);
      return view;
    }
    /**
     * @param {?} elementData
     * @param {?} prevView
     * @param {?} view
     * @return {?}
     */


    function renderAttachEmbeddedView(elementData, prevView, view) {
      /** @type {?} */
      var prevRenderNode = prevView ? renderNode(prevView,
      /** @type {?} */
      prevView.def.lastRenderRootNode) : elementData.renderElement;
      /** @type {?} */

      var parentNode = view.renderer.parentNode(prevRenderNode);
      /** @type {?} */

      var nextSibling = view.renderer.nextSibling(prevRenderNode); // Note: We can't check if `nextSibling` is present, as on WebWorkers it will always be!
      // However, browsers automatically do `appendChild` when there is no `nextSibling`.

      visitRootRenderNodes(view, 2
      /* InsertBefore */
      , parentNode, nextSibling, undefined);
    }
    /**
     * @param {?} view
     * @return {?}
     */


    function renderDetachView$1(view) {
      visitRootRenderNodes(view, 3
      /* RemoveChild */
      , null, null, undefined);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/view/refs.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var EMPTY_CONTEXT = {}; // Attention: this function is called as top level function.
    // Putting any logic in here will destroy closure tree shaking!

    /**
     * @param {?} selector
     * @param {?} componentType
     * @param {?} viewDefFactory
     * @param {?} inputs
     * @param {?} outputs
     * @param {?} ngContentSelectors
     * @return {?}
     */

    function createComponentFactory(selector, componentType, viewDefFactory, inputs, outputs, ngContentSelectors) {
      return new ComponentFactory_(selector, componentType, viewDefFactory, inputs, outputs, ngContentSelectors);
    }
    /**
     * @param {?} componentFactory
     * @return {?}
     */


    function getComponentViewDefinitionFactory(componentFactory) {
      return (
        /** @type {?} */
        componentFactory.viewDefFactory
      );
    }

    var ComponentFactory_ = /*#__PURE__*/function (_ComponentFactory2) {
      _inherits(ComponentFactory_, _ComponentFactory2);

      var _super37 = _createSuper(ComponentFactory_);

      /**
       * @param {?} selector
       * @param {?} componentType
       * @param {?} viewDefFactory
       * @param {?} _inputs
       * @param {?} _outputs
       * @param {?} ngContentSelectors
       */
      function ComponentFactory_(selector, componentType, viewDefFactory, _inputs, _outputs, ngContentSelectors) {
        var _this160;

        _classCallCheck(this, ComponentFactory_);

        // Attention: this ctor is called as top level function.
        // Putting any logic in here will destroy closure tree shaking!
        _this160 = _super37.call(this);
        _this160.selector = selector;
        _this160.componentType = componentType;
        _this160._inputs = _inputs;
        _this160._outputs = _outputs;
        _this160.ngContentSelectors = ngContentSelectors;
        _this160.viewDefFactory = viewDefFactory;
        return _this160;
      }
      /**
       * @return {?}
       */


      _createClass2(ComponentFactory_, [{
        key: "create",

        /**
         * Creates a new component.
         * @param {?} injector
         * @param {?=} projectableNodes
         * @param {?=} rootSelectorOrNode
         * @param {?=} ngModule
         * @return {?}
         */
        value: function create(injector, projectableNodes, rootSelectorOrNode, ngModule) {
          if (!ngModule) {
            throw new Error('ngModule should be provided');
          }
          /** @type {?} */


          var viewDef = resolveDefinition(this.viewDefFactory);
          /** @type {?} */

          var componentNodeIndex =
          /** @type {?} */

          /** @type {?} */
          viewDef.nodes[0].element.componentProvider.nodeIndex;
          /** @type {?} */

          var view = Services.createRootView(injector, projectableNodes || [], rootSelectorOrNode, viewDef, ngModule, EMPTY_CONTEXT);
          /** @type {?} */

          var component = asProviderData(view, componentNodeIndex).instance;

          if (rootSelectorOrNode) {
            view.renderer.setAttribute(asElementData(view, 0).renderElement, 'ng-version', VERSION.full);
          }

          return new ComponentRef_(view, new ViewRef_(view), component);
        }
      }, {
        key: "inputs",
        get: function get() {
          /** @type {?} */
          var inputsArr = [];
          /** @type {?} */

          var inputs =
          /** @type {?} */
          this._inputs;

          for (var propName in inputs) {
            /** @type {?} */
            var templateName = inputs[propName];
            inputsArr.push({
              propName: propName,
              templateName: templateName
            });
          }

          return inputsArr;
        }
        /**
         * @return {?}
         */

      }, {
        key: "outputs",
        get: function get() {
          /** @type {?} */
          var outputsArr = [];

          for (var propName in this._outputs) {
            /** @type {?} */
            var templateName = this._outputs[propName];
            outputsArr.push({
              propName: propName,
              templateName: templateName
            });
          }

          return outputsArr;
        }
      }]);

      return ComponentFactory_;
    }(ComponentFactory);

    if (false) {}

    var ComponentRef_ = /*#__PURE__*/function (_ComponentRef) {
      _inherits(ComponentRef_, _ComponentRef);

      var _super38 = _createSuper(ComponentRef_);

      /**
       * @param {?} _view
       * @param {?} _viewRef
       * @param {?} _component
       */
      function ComponentRef_(_view, _viewRef, _component) {
        var _this161;

        _classCallCheck(this, ComponentRef_);

        _this161 = _super38.call(this);
        _this161._view = _view;
        _this161._viewRef = _viewRef;
        _this161._component = _component;
        _this161._elDef = _this161._view.def.nodes[0];
        _this161.hostView = _viewRef;
        _this161.changeDetectorRef = _viewRef;
        _this161.instance = _component;
        return _this161;
      }
      /**
       * @return {?}
       */


      _createClass2(ComponentRef_, [{
        key: "destroy",

        /**
         * @return {?}
         */
        value: function destroy() {
          this._viewRef.destroy();
        }
        /**
         * @param {?} callback
         * @return {?}
         */

      }, {
        key: "onDestroy",
        value: function onDestroy(callback) {
          this._viewRef.onDestroy(callback);
        }
      }, {
        key: "location",
        get: function get() {
          return new ElementRef(asElementData(this._view, this._elDef.nodeIndex).renderElement);
        }
        /**
         * @return {?}
         */

      }, {
        key: "injector",
        get: function get() {
          return new Injector_(this._view, this._elDef);
        }
        /**
         * @return {?}
         */

      }, {
        key: "componentType",
        get: function get() {
          return (
            /** @type {?} */
            this._component.constructor
          );
        }
      }]);

      return ComponentRef_;
    }(ComponentRef);

    if (false) {}
    /**
     * @param {?} view
     * @param {?} elDef
     * @param {?} elData
     * @return {?}
     */


    function createViewContainerData(view, elDef, elData) {
      return new ViewContainerRef_(view, elDef, elData);
    }

    var ViewContainerRef_ = /*#__PURE__*/function () {
      /**
       * @param {?} _view
       * @param {?} _elDef
       * @param {?} _data
       */
      function ViewContainerRef_(_view, _elDef, _data) {
        _classCallCheck(this, ViewContainerRef_);

        this._view = _view;
        this._elDef = _elDef;
        this._data = _data;
        /**
         * \@internal
         */

        this._embeddedViews = [];
      }
      /**
       * @return {?}
       */


      _createClass2(ViewContainerRef_, [{
        key: "clear",

        /**
         * @return {?}
         */
        value: function clear() {
          /** @type {?} */
          var len = this._embeddedViews.length;

          for (var i = len - 1; i >= 0; i--) {
            /** @type {?} */
            var view =
            /** @type {?} */
            detachEmbeddedView(this._data, i);
            Services.destroyView(view);
          }
        }
        /**
         * @param {?} index
         * @return {?}
         */

      }, {
        key: "get",
        value: function get(index) {
          /** @type {?} */
          var view = this._embeddedViews[index];

          if (view) {
            /** @type {?} */
            var ref = new ViewRef_(view);
            ref.attachToViewContainerRef(this);
            return ref;
          }

          return null;
        }
        /**
         * @return {?}
         */

      }, {
        key: "createEmbeddedView",

        /**
         * @template C
         * @param {?} templateRef
         * @param {?=} context
         * @param {?=} index
         * @return {?}
         */
        value: function createEmbeddedView(templateRef, context, index) {
          /** @type {?} */
          var viewRef = templateRef.createEmbeddedView(context ||
          /** @type {?} */
          {});
          this.insert(viewRef, index);
          return viewRef;
        }
        /**
         * @template C
         * @param {?} componentFactory
         * @param {?=} index
         * @param {?=} injector
         * @param {?=} projectableNodes
         * @param {?=} ngModuleRef
         * @return {?}
         */

      }, {
        key: "createComponent",
        value: function createComponent(componentFactory, index, injector, projectableNodes, ngModuleRef) {
          /** @type {?} */
          var contextInjector = injector || this.parentInjector;

          if (!ngModuleRef && !(componentFactory instanceof ComponentFactoryBoundToModule)) {
            ngModuleRef = contextInjector.get(NgModuleRef);
          }
          /** @type {?} */


          var componentRef = componentFactory.create(contextInjector, projectableNodes, undefined, ngModuleRef);
          this.insert(componentRef.hostView, index);
          return componentRef;
        }
        /**
         * @param {?} viewRef
         * @param {?=} index
         * @return {?}
         */

      }, {
        key: "insert",
        value: function insert(viewRef, index) {
          if (viewRef.destroyed) {
            throw new Error('Cannot insert a destroyed View in a ViewContainer!');
          }
          /** @type {?} */


          var viewRef_ =
          /** @type {?} */
          viewRef;
          /** @type {?} */

          var viewData = viewRef_._view;
          attachEmbeddedView(this._view, this._data, index, viewData);
          viewRef_.attachToViewContainerRef(this);
          return viewRef;
        }
        /**
         * @param {?} viewRef
         * @param {?} currentIndex
         * @return {?}
         */

      }, {
        key: "move",
        value: function move(viewRef, currentIndex) {
          if (viewRef.destroyed) {
            throw new Error('Cannot move a destroyed View in a ViewContainer!');
          }
          /** @type {?} */


          var previousIndex = this._embeddedViews.indexOf(viewRef._view);

          moveEmbeddedView(this._data, previousIndex, currentIndex);
          return viewRef;
        }
        /**
         * @param {?} viewRef
         * @return {?}
         */

      }, {
        key: "indexOf",
        value: function indexOf(viewRef) {
          return this._embeddedViews.indexOf(
          /** @type {?} */
          viewRef._view);
        }
        /**
         * @param {?=} index
         * @return {?}
         */

      }, {
        key: "remove",
        value: function remove(index) {
          /** @type {?} */
          var viewData = detachEmbeddedView(this._data, index);

          if (viewData) {
            Services.destroyView(viewData);
          }
        }
        /**
         * @param {?=} index
         * @return {?}
         */

      }, {
        key: "detach",
        value: function detach(index) {
          /** @type {?} */
          var view = detachEmbeddedView(this._data, index);
          return view ? new ViewRef_(view) : null;
        }
      }, {
        key: "element",
        get: function get() {
          return new ElementRef(this._data.renderElement);
        }
        /**
         * @return {?}
         */

      }, {
        key: "injector",
        get: function get() {
          return new Injector_(this._view, this._elDef);
        }
        /**
         * @deprecated No replacement
         * @return {?}
         */

      }, {
        key: "parentInjector",
        get: function get() {
          /** @type {?} */
          var view = this._view;
          /** @type {?} */

          var elDef = this._elDef.parent;

          while (!elDef && view) {
            elDef = viewParentEl(view);
            view =
            /** @type {?} */
            view.parent;
          }

          return view ? new Injector_(view, elDef) : new Injector_(this._view, null);
        }
      }, {
        key: "length",
        get: function get() {
          return this._embeddedViews.length;
        }
      }]);

      return ViewContainerRef_;
    }();

    if (false) {}
    /**
     * @param {?} view
     * @return {?}
     */


    function createChangeDetectorRef(view) {
      return new ViewRef_(view);
    }

    var ViewRef_ = /*#__PURE__*/function () {
      /**
       * @param {?} _view
       */
      function ViewRef_(_view) {
        _classCallCheck(this, ViewRef_);

        this._view = _view;
        this._viewContainerRef = null;
        this._appRef = null;
      }
      /**
       * @return {?}
       */


      _createClass2(ViewRef_, [{
        key: "markForCheck",

        /**
         * @return {?}
         */
        value: function markForCheck() {
          markParentViewsForCheck(this._view);
        }
        /**
         * @return {?}
         */

      }, {
        key: "detach",
        value: function detach() {
          this._view.state &= ~4
          /* Attached */
          ;
        }
        /**
         * @return {?}
         */

      }, {
        key: "detectChanges",
        value: function detectChanges() {
          /** @type {?} */
          var fs = this._view.root.rendererFactory;

          if (fs.begin) {
            fs.begin();
          }

          try {
            Services.checkAndUpdateView(this._view);
          } finally {
            if (fs.end) {
              fs.end();
            }
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "checkNoChanges",
        value: function checkNoChanges() {
          Services.checkNoChangesView(this._view);
        }
        /**
         * @return {?}
         */

      }, {
        key: "reattach",
        value: function reattach() {
          this._view.state |= 4
          /* Attached */
          ;
        }
        /**
         * @param {?} callback
         * @return {?}
         */

      }, {
        key: "onDestroy",
        value: function onDestroy(callback) {
          if (!this._view.disposables) {
            this._view.disposables = [];
          }

          this._view.disposables.push(
          /** @type {?} */
          callback);
        }
        /**
         * @return {?}
         */

      }, {
        key: "destroy",
        value: function destroy() {
          if (this._appRef) {
            this._appRef.detachView(this);
          } else if (this._viewContainerRef) {
            this._viewContainerRef.detach(this._viewContainerRef.indexOf(this));
          }

          Services.destroyView(this._view);
        }
        /**
         * @return {?}
         */

      }, {
        key: "detachFromAppRef",
        value: function detachFromAppRef() {
          this._appRef = null;
          renderDetachView$1(this._view);
          Services.dirtyParentQueries(this._view);
        }
        /**
         * @param {?} appRef
         * @return {?}
         */

      }, {
        key: "attachToAppRef",
        value: function attachToAppRef(appRef) {
          if (this._viewContainerRef) {
            throw new Error('This view is already attached to a ViewContainer!');
          }

          this._appRef = appRef;
        }
        /**
         * @param {?} vcRef
         * @return {?}
         */

      }, {
        key: "attachToViewContainerRef",
        value: function attachToViewContainerRef(vcRef) {
          if (this._appRef) {
            throw new Error('This view is already attached directly to the ApplicationRef!');
          }

          this._viewContainerRef = vcRef;
        }
      }, {
        key: "rootNodes",
        get: function get() {
          return rootRenderNodes(this._view);
        }
        /**
         * @return {?}
         */

      }, {
        key: "context",
        get: function get() {
          return this._view.context;
        }
        /**
         * @return {?}
         */

      }, {
        key: "destroyed",
        get: function get() {
          return (this._view.state & 128
          /* Destroyed */
          ) !== 0;
        }
      }]);

      return ViewRef_;
    }();

    if (false) {}
    /**
     * @param {?} view
     * @param {?} def
     * @return {?}
     */


    function createTemplateData(view, def) {
      return new TemplateRef_(view, def);
    }

    var TemplateRef_ = /*#__PURE__*/function (_TemplateRef) {
      _inherits(TemplateRef_, _TemplateRef);

      var _super39 = _createSuper(TemplateRef_);

      /**
       * @param {?} _parentView
       * @param {?} _def
       */
      function TemplateRef_(_parentView, _def) {
        var _this162;

        _classCallCheck(this, TemplateRef_);

        _this162 = _super39.call(this);
        _this162._parentView = _parentView;
        _this162._def = _def;
        return _this162;
      }
      /**
       * @param {?} context
       * @return {?}
       */


      _createClass2(TemplateRef_, [{
        key: "createEmbeddedView",
        value: function createEmbeddedView(context) {
          return new ViewRef_(Services.createEmbeddedView(this._parentView, this._def,
          /** @type {?} */

          /** @type {?} */
          this._def.element.template, context));
        }
        /**
         * @return {?}
         */

      }, {
        key: "elementRef",
        get: function get() {
          return new ElementRef(asElementData(this._parentView, this._def.nodeIndex).renderElement);
        }
      }]);

      return TemplateRef_;
    }(TemplateRef);

    if (false) {}
    /**
     * @param {?} view
     * @param {?} elDef
     * @return {?}
     */


    function createInjector$1(view, elDef) {
      return new Injector_(view, elDef);
    }

    var Injector_ = /*#__PURE__*/function () {
      /**
       * @param {?} view
       * @param {?} elDef
       */
      function Injector_(view, elDef) {
        _classCallCheck(this, Injector_);

        this.view = view;
        this.elDef = elDef;
      }
      /**
       * @param {?} token
       * @param {?=} notFoundValue
       * @return {?}
       */


      _createClass2(Injector_, [{
        key: "get",
        value: function get(token) {
          var notFoundValue = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : Injector.THROW_IF_NOT_FOUND;

          /** @type {?} */
          var allowPrivateServices = this.elDef ? (this.elDef.flags & 33554432
          /* ComponentView */
          ) !== 0 : false;
          return Services.resolveDep(this.view, this.elDef, allowPrivateServices, {
            flags: 0
            /* None */
            ,
            token: token,
            tokenKey: tokenKey(token)
          }, notFoundValue);
        }
      }]);

      return Injector_;
    }();

    if (false) {}
    /**
     * @param {?} view
     * @param {?} index
     * @return {?}
     */


    function nodeValue(view, index) {
      /** @type {?} */
      var def = view.def.nodes[index];

      if (def.flags & 1
      /* TypeElement */
      ) {
          /** @type {?} */
          var elData = asElementData(view, def.nodeIndex);
          return (
            /** @type {?} */
            def.element.template ? elData.template : elData.renderElement
          );
        } else if (def.flags & 2
      /* TypeText */
      ) {
          return asTextData(view, def.nodeIndex).renderText;
        } else if (def.flags & (20224
      /* CatProvider */
      | 16
      /* TypePipe */
      )) {
        return asProviderData(view, def.nodeIndex).instance;
      }

      throw new Error("Illegal state: read nodeValue for node index ".concat(index));
    }
    /**
     * @param {?} moduleType
     * @param {?} parent
     * @param {?} bootstrapComponents
     * @param {?} def
     * @return {?}
     */


    function createNgModuleRef(moduleType, parent, bootstrapComponents, def) {
      return new NgModuleRef_(moduleType, parent, bootstrapComponents, def);
    }

    var NgModuleRef_ = /*#__PURE__*/function () {
      /**
       * @param {?} _moduleType
       * @param {?} _parent
       * @param {?} _bootstrapComponents
       * @param {?} _def
       */
      function NgModuleRef_(_moduleType, _parent, _bootstrapComponents, _def) {
        _classCallCheck(this, NgModuleRef_);

        this._moduleType = _moduleType;
        this._parent = _parent;
        this._bootstrapComponents = _bootstrapComponents;
        this._def = _def;
        this._destroyListeners = [];
        this._destroyed = false;
        this.injector = this;
        initNgModule(this);
      }
      /**
       * @param {?} token
       * @param {?=} notFoundValue
       * @param {?=} injectFlags
       * @return {?}
       */


      _createClass2(NgModuleRef_, [{
        key: "get",
        value: function get(token) {
          var notFoundValue = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : Injector.THROW_IF_NOT_FOUND;
          var injectFlags = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : InjectFlags.Default;

          /** @type {?} */
          var flags = 0
          /* None */
          ;

          if (injectFlags & InjectFlags.SkipSelf) {
            flags |= 1
            /* SkipSelf */
            ;
          } else if (injectFlags & InjectFlags.Self) {
            flags |= 4
            /* Self */
            ;
          }

          return resolveNgModuleDep(this, {
            token: token,
            tokenKey: tokenKey(token),
            flags: flags
          }, notFoundValue);
        }
        /**
         * @return {?}
         */

      }, {
        key: "destroy",

        /**
         * @return {?}
         */
        value: function destroy() {
          if (this._destroyed) {
            throw new Error("The ng module ".concat(stringify(this.instance.constructor), " has already been destroyed."));
          }

          this._destroyed = true;
          callNgModuleLifecycle(this, 131072
          /* OnDestroy */
          );

          this._destroyListeners.forEach(
          /**
          * @param {?} listener
          * @return {?}
          */
          function (listener) {
            return listener();
          });
        }
        /**
         * @param {?} callback
         * @return {?}
         */

      }, {
        key: "onDestroy",
        value: function onDestroy(callback) {
          this._destroyListeners.push(callback);
        }
      }, {
        key: "instance",
        get: function get() {
          return this.get(this._moduleType);
        }
        /**
         * @return {?}
         */

      }, {
        key: "componentFactoryResolver",
        get: function get() {
          return this.get(ComponentFactoryResolver);
        }
      }]);

      return NgModuleRef_;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/view/provider.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var Renderer2TokenKey = tokenKey(Renderer2);
    /** @type {?} */

    var ElementRefTokenKey = tokenKey(ElementRef);
    /** @type {?} */

    var ViewContainerRefTokenKey = tokenKey(ViewContainerRef);
    /** @type {?} */

    var TemplateRefTokenKey = tokenKey(TemplateRef);
    /** @type {?} */

    var ChangeDetectorRefTokenKey = tokenKey(ChangeDetectorRef);
    /** @type {?} */

    var InjectorRefTokenKey$1 = tokenKey(Injector);
    /** @type {?} */

    var INJECTORRefTokenKey$1 = tokenKey(INJECTOR);
    /**
     * @param {?} checkIndex
     * @param {?} flags
     * @param {?} matchedQueries
     * @param {?} childCount
     * @param {?} ctor
     * @param {?} deps
     * @param {?=} props
     * @param {?=} outputs
     * @return {?}
     */

    function directiveDef(checkIndex, flags, matchedQueries, childCount, ctor, deps, props, outputs) {
      /** @type {?} */
      var bindings = [];

      if (props) {
        for (var prop in props) {
          var _props$prop = _slicedToArray(props[prop], 2),
              bindingIndex = _props$prop[0],
              nonMinifiedName = _props$prop[1];

          bindings[bindingIndex] = {
            flags: 8
            /* TypeProperty */
            ,
            name: prop,
            nonMinifiedName: nonMinifiedName,
            ns: null,
            securityContext: null,
            suffix: null
          };
        }
      }
      /** @type {?} */


      var outputDefs = [];

      if (outputs) {
        for (var propName in outputs) {
          outputDefs.push({
            type: 1
            /* DirectiveOutput */
            ,
            propName: propName,
            target: null,
            eventName: outputs[propName]
          });
        }
      }

      flags |= 16384
      /* TypeDirective */
      ;
      return _def(checkIndex, flags, matchedQueries, childCount, ctor, ctor, deps, bindings, outputDefs);
    }
    /**
     * @param {?} flags
     * @param {?} ctor
     * @param {?} deps
     * @return {?}
     */


    function pipeDef(flags, ctor, deps) {
      flags |= 16
      /* TypePipe */
      ;
      return _def(-1, flags, null, 0, ctor, ctor, deps);
    }
    /**
     * @param {?} flags
     * @param {?} matchedQueries
     * @param {?} token
     * @param {?} value
     * @param {?} deps
     * @return {?}
     */


    function providerDef(flags, matchedQueries, token, value, deps) {
      return _def(-1, flags, matchedQueries, 0, token, value, deps);
    }
    /**
     * @param {?} checkIndex
     * @param {?} flags
     * @param {?} matchedQueriesDsl
     * @param {?} childCount
     * @param {?} token
     * @param {?} value
     * @param {?} deps
     * @param {?=} bindings
     * @param {?=} outputs
     * @return {?}
     */


    function _def(checkIndex, flags, matchedQueriesDsl, childCount, token, value, deps, bindings, outputs) {
      var _splitMatchedQueriesD = splitMatchedQueriesDsl(matchedQueriesDsl),
          matchedQueries = _splitMatchedQueriesD.matchedQueries,
          references = _splitMatchedQueriesD.references,
          matchedQueryIds = _splitMatchedQueriesD.matchedQueryIds;

      if (!outputs) {
        outputs = [];
      }

      if (!bindings) {
        bindings = [];
      } // Need to resolve forwardRefs as e.g. for `useValue` we
      // lowered the expression and then stopped evaluating it,
      // i.e. also didn't unwrap it.


      value = resolveForwardRef(value);
      /** @type {?} */

      var depDefs = splitDepsDsl(deps, stringify(token));
      return {
        // will bet set by the view definition
        nodeIndex: -1,
        parent: null,
        renderParent: null,
        bindingIndex: -1,
        outputIndex: -1,
        // regular values
        checkIndex: checkIndex,
        flags: flags,
        childFlags: 0,
        directChildFlags: 0,
        childMatchedQueries: 0,
        matchedQueries: matchedQueries,
        matchedQueryIds: matchedQueryIds,
        references: references,
        ngContentIndex: -1,
        childCount: childCount,
        bindings: bindings,
        bindingFlags: calcBindingFlags(bindings),
        outputs: outputs,
        element: null,
        provider: {
          token: token,
          value: value,
          deps: depDefs
        },
        text: null,
        query: null,
        ngContent: null
      };
    }
    /**
     * @param {?} view
     * @param {?} def
     * @return {?}
     */


    function createProviderInstance(view, def) {
      return _createProviderInstance$1(view, def);
    }
    /**
     * @param {?} view
     * @param {?} def
     * @return {?}
     */


    function createPipeInstance(view, def) {
      // deps are looked up from component.

      /** @type {?} */
      var compView = view;

      while (compView.parent && !isComponentView(compView)) {
        compView = compView.parent;
      } // pipes can see the private services of the component

      /** @type {?} */


      var allowPrivateServices = true; // pipes are always eager and classes!

      return createClass(
      /** @type {?} */
      compView.parent,
      /** @type {?} */
      viewParentEl(compView), allowPrivateServices,
      /** @type {?} */
      def.provider.value,
      /** @type {?} */
      def.provider.deps);
    }
    /**
     * @param {?} view
     * @param {?} def
     * @return {?}
     */


    function createDirectiveInstance(view, def) {
      // components can see other private services, other directives can't.

      /** @type {?} */
      var allowPrivateServices = (def.flags & 32768
      /* Component */
      ) > 0; // directives are always eager and classes!

      /** @type {?} */

      var instance = createClass(view,
      /** @type {?} */
      def.parent, allowPrivateServices,
      /** @type {?} */
      def.provider.value,
      /** @type {?} */
      def.provider.deps);

      if (def.outputs.length) {
        for (var i = 0; i < def.outputs.length; i++) {
          /** @type {?} */
          var output = def.outputs[i];
          /** @type {?} */

          var outputObservable = instance[
          /** @type {?} */
          output.propName];

          if (isObservable(outputObservable)) {
            /** @type {?} */
            var subscription = outputObservable.subscribe(eventHandlerClosure(view,
            /** @type {?} */
            def.parent.nodeIndex, output.eventName));

            /** @type {?} */
            view.disposables[def.outputIndex + i] = subscription.unsubscribe.bind(subscription);
          } else {
            throw new Error("@Output ".concat(output.propName, " not initialized in '").concat(instance.constructor.name, "'."));
          }
        }
      }

      return instance;
    }
    /**
     * @param {?} view
     * @param {?} index
     * @param {?} eventName
     * @return {?}
     */


    function eventHandlerClosure(view, index, eventName) {
      return (
        /**
        * @param {?} event
        * @return {?}
        */
        function (event) {
          return dispatchEvent(view, index, eventName, event);
        }
      );
    }
    /**
     * @param {?} view
     * @param {?} def
     * @param {?} v0
     * @param {?} v1
     * @param {?} v2
     * @param {?} v3
     * @param {?} v4
     * @param {?} v5
     * @param {?} v6
     * @param {?} v7
     * @param {?} v8
     * @param {?} v9
     * @return {?}
     */


    function checkAndUpdateDirectiveInline(view, def, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9) {
      /** @type {?} */
      var providerData = asProviderData(view, def.nodeIndex);
      /** @type {?} */

      var directive = providerData.instance;
      /** @type {?} */

      var changed = false;
      /** @type {?} */

      var changes =
      /** @type {?} */
      undefined;
      /** @type {?} */

      var bindLen = def.bindings.length;

      if (bindLen > 0 && checkBinding(view, def, 0, v0)) {
        changed = true;
        changes = updateProp(view, providerData, def, 0, v0, changes);
      }

      if (bindLen > 1 && checkBinding(view, def, 1, v1)) {
        changed = true;
        changes = updateProp(view, providerData, def, 1, v1, changes);
      }

      if (bindLen > 2 && checkBinding(view, def, 2, v2)) {
        changed = true;
        changes = updateProp(view, providerData, def, 2, v2, changes);
      }

      if (bindLen > 3 && checkBinding(view, def, 3, v3)) {
        changed = true;
        changes = updateProp(view, providerData, def, 3, v3, changes);
      }

      if (bindLen > 4 && checkBinding(view, def, 4, v4)) {
        changed = true;
        changes = updateProp(view, providerData, def, 4, v4, changes);
      }

      if (bindLen > 5 && checkBinding(view, def, 5, v5)) {
        changed = true;
        changes = updateProp(view, providerData, def, 5, v5, changes);
      }

      if (bindLen > 6 && checkBinding(view, def, 6, v6)) {
        changed = true;
        changes = updateProp(view, providerData, def, 6, v6, changes);
      }

      if (bindLen > 7 && checkBinding(view, def, 7, v7)) {
        changed = true;
        changes = updateProp(view, providerData, def, 7, v7, changes);
      }

      if (bindLen > 8 && checkBinding(view, def, 8, v8)) {
        changed = true;
        changes = updateProp(view, providerData, def, 8, v8, changes);
      }

      if (bindLen > 9 && checkBinding(view, def, 9, v9)) {
        changed = true;
        changes = updateProp(view, providerData, def, 9, v9, changes);
      }

      if (changes) {
        directive.ngOnChanges(changes);
      }

      if (def.flags & 65536
      /* OnInit */
      && shouldCallLifecycleInitHook(view, 256
      /* InitState_CallingOnInit */
      , def.nodeIndex)) {
        directive.ngOnInit();
      }

      if (def.flags & 262144
      /* DoCheck */
      ) {
          directive.ngDoCheck();
        }

      return changed;
    }
    /**
     * @param {?} view
     * @param {?} def
     * @param {?} values
     * @return {?}
     */


    function checkAndUpdateDirectiveDynamic(view, def, values) {
      /** @type {?} */
      var providerData = asProviderData(view, def.nodeIndex);
      /** @type {?} */

      var directive = providerData.instance;
      /** @type {?} */

      var changed = false;
      /** @type {?} */

      var changes =
      /** @type {?} */
      undefined;

      for (var i = 0; i < values.length; i++) {
        if (checkBinding(view, def, i, values[i])) {
          changed = true;
          changes = updateProp(view, providerData, def, i, values[i], changes);
        }
      }

      if (changes) {
        directive.ngOnChanges(changes);
      }

      if (def.flags & 65536
      /* OnInit */
      && shouldCallLifecycleInitHook(view, 256
      /* InitState_CallingOnInit */
      , def.nodeIndex)) {
        directive.ngOnInit();
      }

      if (def.flags & 262144
      /* DoCheck */
      ) {
          directive.ngDoCheck();
        }

      return changed;
    }
    /**
     * @param {?} view
     * @param {?} def
     * @return {?}
     */


    function _createProviderInstance$1(view, def) {
      // private services can see other private services

      /** @type {?} */
      var allowPrivateServices = (def.flags & 8192
      /* PrivateProvider */
      ) > 0;
      /** @type {?} */

      var providerDef = def.provider;

      switch (def.flags & 201347067
      /* Types */
      ) {
        case 512
        /* TypeClassProvider */
        :
          return createClass(view,
          /** @type {?} */
          def.parent, allowPrivateServices,
          /** @type {?} */
          providerDef.value,
          /** @type {?} */
          providerDef.deps);

        case 1024
        /* TypeFactoryProvider */
        :
          return callFactory(view,
          /** @type {?} */
          def.parent, allowPrivateServices,
          /** @type {?} */
          providerDef.value,
          /** @type {?} */
          providerDef.deps);

        case 2048
        /* TypeUseExistingProvider */
        :
          return resolveDep(view,
          /** @type {?} */
          def.parent, allowPrivateServices,
          /** @type {?} */
          providerDef.deps[0]);

        case 256
        /* TypeValueProvider */
        :
          return (
            /** @type {?} */
            providerDef.value
          );
      }
    }
    /**
     * @param {?} view
     * @param {?} elDef
     * @param {?} allowPrivateServices
     * @param {?} ctor
     * @param {?} deps
     * @return {?}
     */


    function createClass(view, elDef, allowPrivateServices, ctor, deps) {
      /** @type {?} */
      var len = deps.length;

      switch (len) {
        case 0:
          return new ctor();

        case 1:
          return new ctor(resolveDep(view, elDef, allowPrivateServices, deps[0]));

        case 2:
          return new ctor(resolveDep(view, elDef, allowPrivateServices, deps[0]), resolveDep(view, elDef, allowPrivateServices, deps[1]));

        case 3:
          return new ctor(resolveDep(view, elDef, allowPrivateServices, deps[0]), resolveDep(view, elDef, allowPrivateServices, deps[1]), resolveDep(view, elDef, allowPrivateServices, deps[2]));

        default:
          /** @type {?} */
          var depValues = [];

          for (var i = 0; i < len; i++) {
            depValues.push(resolveDep(view, elDef, allowPrivateServices, deps[i]));
          }

          return _construct(ctor, depValues);
      }
    }
    /**
     * @param {?} view
     * @param {?} elDef
     * @param {?} allowPrivateServices
     * @param {?} factory
     * @param {?} deps
     * @return {?}
     */


    function callFactory(view, elDef, allowPrivateServices, factory, deps) {
      /** @type {?} */
      var len = deps.length;

      switch (len) {
        case 0:
          return factory();

        case 1:
          return factory(resolveDep(view, elDef, allowPrivateServices, deps[0]));

        case 2:
          return factory(resolveDep(view, elDef, allowPrivateServices, deps[0]), resolveDep(view, elDef, allowPrivateServices, deps[1]));

        case 3:
          return factory(resolveDep(view, elDef, allowPrivateServices, deps[0]), resolveDep(view, elDef, allowPrivateServices, deps[1]), resolveDep(view, elDef, allowPrivateServices, deps[2]));

        default:
          /** @type {?} */
          var depValues = [];

          for (var i = 0; i < len; i++) {
            depValues.push(resolveDep(view, elDef, allowPrivateServices, deps[i]));
          }

          return factory.apply(void 0, depValues);
      }
    } // This default value is when checking the hierarchy for a token.
    //
    // It means both:
    // - the token is not provided by the current injector,
    // - only the element injectors should be checked (ie do not check module injectors
    //
    //          mod1
    //         /
    //       el1   mod2
    //         \  /
    //         el2
    //
    // When requesting el2.injector.get(token), we should check in the following order and return the
    // first found value:
    // - el2.injector.get(token, default)
    // - el1.injector.get(token, NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR) -> do not check the module
    // - mod2.injector.get(token, default)

    /** @type {?} */


    var NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR = {};
    /**
     * @param {?} view
     * @param {?} elDef
     * @param {?} allowPrivateServices
     * @param {?} depDef
     * @param {?=} notFoundValue
     * @return {?}
     */

    function resolveDep(view, elDef, allowPrivateServices, depDef) {
      var notFoundValue = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : Injector.THROW_IF_NOT_FOUND;

      if (depDef.flags & 8
      /* Value */
      ) {
          return depDef.token;
        }
      /** @type {?} */


      var startView = view;

      if (depDef.flags & 2
      /* Optional */
      ) {
          notFoundValue = null;
        }
      /** @type {?} */


      var tokenKey = depDef.tokenKey;

      if (tokenKey === ChangeDetectorRefTokenKey) {
        // directives on the same element as a component should be able to control the change detector
        // of that component as well.
        allowPrivateServices = !!(elDef &&
        /** @type {?} */
        elDef.element.componentView);
      }

      if (elDef && depDef.flags & 1
      /* SkipSelf */
      ) {
        allowPrivateServices = false;
        elDef =
        /** @type {?} */
        elDef.parent;
      }
      /** @type {?} */


      var searchView = view;

      while (searchView) {
        if (elDef) {
          switch (tokenKey) {
            case Renderer2TokenKey:
              {
                /** @type {?} */
                var compView = findCompView(searchView, elDef, allowPrivateServices);
                return compView.renderer;
              }

            case ElementRefTokenKey:
              return new ElementRef(asElementData(searchView, elDef.nodeIndex).renderElement);

            case ViewContainerRefTokenKey:
              return asElementData(searchView, elDef.nodeIndex).viewContainer;

            case TemplateRefTokenKey:
              {
                if (
                /** @type {?} */
                elDef.element.template) {
                  return asElementData(searchView, elDef.nodeIndex).template;
                }

                break;
              }

            case ChangeDetectorRefTokenKey:
              {
                /** @type {?} */
                var cdView = findCompView(searchView, elDef, allowPrivateServices);
                return createChangeDetectorRef(cdView);
              }

            case InjectorRefTokenKey$1:
            case INJECTORRefTokenKey$1:
              return createInjector$1(searchView, elDef);

            default:
              /** @type {?} */
              var _providerDef2 = (
              /** @type {?} */
              allowPrivateServices ?
              /** @type {?} */
              elDef.element.allProviders :
              /** @type {?} */
              elDef.element.publicProviders)[tokenKey];

              if (_providerDef2) {
                /** @type {?} */
                var providerData = asProviderData(searchView, _providerDef2.nodeIndex);

                if (!providerData) {
                  providerData = {
                    instance: _createProviderInstance$1(searchView, _providerDef2)
                  };
                  searchView.nodes[_providerDef2.nodeIndex] =
                  /** @type {?} */
                  providerData;
                }

                return providerData.instance;
              }

          }
        }

        allowPrivateServices = isComponentView(searchView);
        elDef =
        /** @type {?} */
        viewParentEl(searchView);
        searchView =
        /** @type {?} */
        searchView.parent;

        if (depDef.flags & 4
        /* Self */
        ) {
            searchView = null;
          }
      }
      /** @type {?} */


      var value = startView.root.injector.get(depDef.token, NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR);

      if (value !== NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR || notFoundValue === NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR) {
        // Return the value from the root element injector when
        // - it provides it
        //   (value !== NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR)
        // - the module injector should not be checked
        //   (notFoundValue === NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR)
        return value;
      }

      return startView.root.ngModule.injector.get(depDef.token, notFoundValue);
    }
    /**
     * @param {?} view
     * @param {?} elDef
     * @param {?} allowPrivateServices
     * @return {?}
     */


    function findCompView(view, elDef, allowPrivateServices) {
      /** @type {?} */
      var compView;

      if (allowPrivateServices) {
        compView = asElementData(view, elDef.nodeIndex).componentView;
      } else {
        compView = view;

        while (compView.parent && !isComponentView(compView)) {
          compView = compView.parent;
        }
      }

      return compView;
    }
    /**
     * @param {?} view
     * @param {?} providerData
     * @param {?} def
     * @param {?} bindingIdx
     * @param {?} value
     * @param {?} changes
     * @return {?}
     */


    function updateProp(view, providerData, def, bindingIdx, value, changes) {
      if (def.flags & 32768
      /* Component */
      ) {
          /** @type {?} */
          var compView = asElementData(view,
          /** @type {?} */
          def.parent.nodeIndex).componentView;

          if (compView.def.flags & 2
          /* OnPush */
          ) {
              compView.state |= 8
              /* ChecksEnabled */
              ;
            }
        }
      /** @type {?} */


      var binding = def.bindings[bindingIdx];
      /** @type {?} */

      var propName =
      /** @type {?} */
      binding.name; // Note: This is still safe with Closure Compiler as
      // the user passed in the property name as an object has to `providerDef`,
      // so Closure Compiler will have renamed the property correctly already.

      providerData.instance[propName] = value;

      if (def.flags & 524288
      /* OnChanges */
      ) {
          changes = changes || {};
          /** @type {?} */

          var oldValue = WrappedValue.unwrap(view.oldValues[def.bindingIndex + bindingIdx]);
          /** @type {?} */

          var _binding = def.bindings[bindingIdx];
          changes[
          /** @type {?} */
          _binding.nonMinifiedName] = new SimpleChange(oldValue, value, (view.state & 2
          /* FirstCheck */
          ) !== 0);
        }

      view.oldValues[def.bindingIndex + bindingIdx] = value;
      return changes;
    } // This function calls the ngAfterContentCheck, ngAfterContentInit,
    // ngAfterViewCheck, and ngAfterViewInit lifecycle hooks (depending on the node
    // flags in lifecycle). Unlike ngDoCheck, ngOnChanges and ngOnInit, which are
    // called during a pre-order traversal of the view tree (that is calling the
    // parent hooks before the child hooks) these events are sent in using a
    // post-order traversal of the tree (children before parents). This changes the
    // meaning of initIndex in the view state. For ngOnInit, initIndex tracks the
    // expected nodeIndex which a ngOnInit should be called. When sending
    // ngAfterContentInit and ngAfterViewInit it is the expected count of
    // ngAfterContentInit or ngAfterViewInit methods that have been called. This
    // ensure that despite being called recursively or after picking up after an
    // exception, the ngAfterContentInit or ngAfterViewInit will be called on the
    // correct nodes. Consider for example, the following (where E is an element
    // and D is a directive)
    //  Tree:       pre-order index  post-order index
    //    E1        0                6
    //      E2      1                1
    //       D3     2                0
    //      E4      3                5
    //       E5     4                4
    //        E6    5                2
    //        E7    6                3
    // As can be seen, the post-order index has an unclear relationship to the
    // pre-order index (postOrderIndex === preOrderIndex - parentCount +
    // childCount). Since number of calls to ngAfterContentInit and ngAfterViewInit
    // are stable (will be the same for the same view regardless of exceptions or
    // recursion) we just need to count them which will roughly correspond to the
    // post-order index (it skips elements and directives that do not have
    // lifecycle hooks).
    //
    // For example, if an exception is raised in the E6.onAfterViewInit() the
    // initIndex is left at 3 (by shouldCallLifecycleInitHook() which set it to
    // initIndex + 1). When checkAndUpdateView() is called again D3, E2 and E6 will
    // not have their ngAfterViewInit() called but, starting with E7, the rest of
    // the view will begin getting ngAfterViewInit() called until a check and
    // pass is complete.
    //
    // This algorthim also handles recursion. Consider if E4's ngAfterViewInit()
    // indirectly calls E1's ChangeDetectorRef.detectChanges(). The expected
    // initIndex is set to 6, the recusive checkAndUpdateView() starts walk again.
    // D3, E2, E6, E7, E5 and E4 are skipped, ngAfterViewInit() is called on E1.
    // When the recursion returns the initIndex will be 7 so E1 is skipped as it
    // has already been called in the recursively called checkAnUpdateView().

    /**
     * @param {?} view
     * @param {?} lifecycles
     * @return {?}
     */


    function callLifecycleHooksChildrenFirst(view, lifecycles) {
      if (!(view.def.nodeFlags & lifecycles)) {
        return;
      }
      /** @type {?} */


      var nodes = view.def.nodes;
      /** @type {?} */

      var initIndex = 0;

      for (var i = 0; i < nodes.length; i++) {
        /** @type {?} */
        var nodeDef = nodes[i];
        /** @type {?} */

        var parent = nodeDef.parent;

        if (!parent && nodeDef.flags & lifecycles) {
          // matching root node (e.g. a pipe)
          callProviderLifecycles(view, i, nodeDef.flags & lifecycles, initIndex++);
        }

        if ((nodeDef.childFlags & lifecycles) === 0) {
          // no child matches one of the lifecycles
          i += nodeDef.childCount;
        }

        while (parent && parent.flags & 1
        /* TypeElement */
        && i === parent.nodeIndex + parent.childCount) {
          // last child of an element
          if (parent.directChildFlags & lifecycles) {
            initIndex = callElementProvidersLifecycles(view, parent, lifecycles, initIndex);
          }

          parent = parent.parent;
        }
      }
    }
    /**
     * @param {?} view
     * @param {?} elDef
     * @param {?} lifecycles
     * @param {?} initIndex
     * @return {?}
     */


    function callElementProvidersLifecycles(view, elDef, lifecycles, initIndex) {
      for (var i = elDef.nodeIndex + 1; i <= elDef.nodeIndex + elDef.childCount; i++) {
        /** @type {?} */
        var nodeDef = view.def.nodes[i];

        if (nodeDef.flags & lifecycles) {
          callProviderLifecycles(view, i, nodeDef.flags & lifecycles, initIndex++);
        } // only visit direct children


        i += nodeDef.childCount;
      }

      return initIndex;
    }
    /**
     * @param {?} view
     * @param {?} index
     * @param {?} lifecycles
     * @param {?} initIndex
     * @return {?}
     */


    function callProviderLifecycles(view, index, lifecycles, initIndex) {
      /** @type {?} */
      var providerData = asProviderData(view, index);

      if (!providerData) {
        return;
      }
      /** @type {?} */


      var provider = providerData.instance;

      if (!provider) {
        return;
      }

      Services.setCurrentNode(view, index);

      if (lifecycles & 1048576
      /* AfterContentInit */
      && shouldCallLifecycleInitHook(view, 512
      /* InitState_CallingAfterContentInit */
      , initIndex)) {
        provider.ngAfterContentInit();
      }

      if (lifecycles & 2097152
      /* AfterContentChecked */
      ) {
          provider.ngAfterContentChecked();
        }

      if (lifecycles & 4194304
      /* AfterViewInit */
      && shouldCallLifecycleInitHook(view, 768
      /* InitState_CallingAfterViewInit */
      , initIndex)) {
        provider.ngAfterViewInit();
      }

      if (lifecycles & 8388608
      /* AfterViewChecked */
      ) {
          provider.ngAfterViewChecked();
        }

      if (lifecycles & 131072
      /* OnDestroy */
      ) {
          provider.ngOnDestroy();
        }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/component_ref.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var ComponentFactoryResolver$1 = /*#__PURE__*/function (_ComponentFactoryReso) {
      _inherits(ComponentFactoryResolver$1, _ComponentFactoryReso);

      var _super40 = _createSuper(ComponentFactoryResolver$1);

      /**
       * @param {?=} ngModule The NgModuleRef to which all resolved factories are bound.
       */
      function ComponentFactoryResolver$1(ngModule) {
        var _this163;

        _classCallCheck(this, ComponentFactoryResolver$1);

        _this163 = _super40.call(this);
        _this163.ngModule = ngModule;
        return _this163;
      }
      /**
       * @template T
       * @param {?} component
       * @return {?}
       */


      _createClass2(ComponentFactoryResolver$1, [{
        key: "resolveComponentFactory",
        value: function resolveComponentFactory(component) {
          ngDevMode && assertComponentType(component);
          /** @type {?} */

          var componentDef =
          /** @type {?} */
          getComponentDef(component);
          return new ComponentFactory$1(componentDef, this.ngModule);
        }
      }]);

      return ComponentFactoryResolver$1;
    }(ComponentFactoryResolver);

    if (false) {}
    /**
     * @param {?} map
     * @return {?}
     */


    function toRefArray(map) {
      /** @type {?} */
      var array = [];

      for (var nonMinified in map) {
        if (map.hasOwnProperty(nonMinified)) {
          /** @type {?} */
          var minified = map[nonMinified];
          array.push({
            propName: minified,
            templateName: nonMinified
          });
        }
      }

      return array;
    }
    /**
     * @param {?} elementName
     * @return {?}
     */


    function getNamespace$1(elementName) {
      /** @type {?} */
      var name = elementName.toLowerCase();
      return name === 'svg' ? SVG_NAMESPACE : name === 'math' ? MATH_ML_NAMESPACE : null;
    }
    /**
     * A change detection scheduler token for {\@link RootContext}. This token is the default value used
     * for the default `RootContext` found in the {\@link ROOT_CONTEXT} token.
     * @type {?}
     */


    var SCHEDULER = new InjectionToken('SCHEDULER_TOKEN', {
      providedIn: 'root',
      factory:
      /**
      * @return {?}
      */
      function factory() {
        return defaultScheduler;
      }
    });
    /**
     * @param {?} rootViewInjector
     * @param {?} moduleInjector
     * @return {?}
     */

    function createChainedInjector(rootViewInjector, moduleInjector) {
      return {
        get:
        /**
        * @template T
        * @param {?} token
        * @param {?=} notFoundValue
        * @param {?=} flags
        * @return {?}
        */
        function get(token, notFoundValue, flags) {
          /** @type {?} */
          var value = rootViewInjector.get(token,
          /** @type {?} */
          NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR, flags);

          if (value !== NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR || notFoundValue === NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR) {
            // Return the value from the root element injector when
            // - it provides it
            //   (value !== NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR)
            // - the module injector should not be checked
            //   (notFoundValue === NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR)
            return value;
          }

          return moduleInjector.get(token, notFoundValue, flags);
        }
      };
    }
    /**
     * Render3 implementation of {\@link viewEngine_ComponentFactory}.
     * @template T
     */


    var ComponentFactory$1 = /*#__PURE__*/function (_ComponentFactory3) {
      _inherits(ComponentFactory$1, _ComponentFactory3);

      var _super41 = _createSuper(ComponentFactory$1);

      /**
       * @param {?} componentDef The component definition.
       * @param {?=} ngModule The NgModuleRef to which the factory is bound.
       */
      function ComponentFactory$1(componentDef, ngModule) {
        var _this164;

        _classCallCheck(this, ComponentFactory$1);

        _this164 = _super41.call(this);
        _this164.componentDef = componentDef;
        _this164.ngModule = ngModule;
        _this164.componentType = componentDef.type;
        _this164.selector = stringifyCSSSelectorList(componentDef.selectors);
        _this164.ngContentSelectors = componentDef.ngContentSelectors ? componentDef.ngContentSelectors : [];
        _this164.isBoundToModule = !!ngModule;
        return _this164;
      }
      /**
       * @return {?}
       */


      _createClass2(ComponentFactory$1, [{
        key: "create",

        /**
         * @param {?} injector
         * @param {?=} projectableNodes
         * @param {?=} rootSelectorOrNode
         * @param {?=} ngModule
         * @return {?}
         */
        value: function create(injector, projectableNodes, rootSelectorOrNode, ngModule) {
          ngModule = ngModule || this.ngModule;
          /** @type {?} */

          var rootViewInjector = ngModule ? createChainedInjector(injector, ngModule.injector) : injector;
          /** @type {?} */

          var rendererFactory =
          /** @type {?} */
          rootViewInjector.get(RendererFactory2, domRendererFactory3);
          /** @type {?} */

          var sanitizer = rootViewInjector.get(Sanitizer, null);
          /** @type {?} */

          var hostRenderer = rendererFactory.createRenderer(null, this.componentDef); // Determine a tag name used for creating host elements when this component is created
          // dynamically. Default to 'div' if this component did not specify any tag name in its selector.

          /** @type {?} */

          var elementName =
          /** @type {?} */
          this.componentDef.selectors[0][0] || 'div';
          /** @type {?} */

          var hostRNode = rootSelectorOrNode ? locateHostElement(hostRenderer, rootSelectorOrNode, this.componentDef.encapsulation) : elementCreate(elementName, rendererFactory.createRenderer(null, this.componentDef), getNamespace$1(elementName));
          /** @type {?} */

          var rootFlags = this.componentDef.onPush ? 64
          /* Dirty */
          | 512
          /* IsRoot */
          : 16
          /* CheckAlways */
          | 512
          /* IsRoot */
          ; // Check whether this Component needs to be isolated from other components, i.e. whether it
          // should be placed into its own (empty) root context or existing root context should be used.
          // Note: this is internal-only convention and might change in the future, so it should not be
          // relied upon externally.

          /** @type {?} */

          var isIsolated = typeof rootSelectorOrNode === 'string' && /^#root-ng-internal-isolated-\d+/.test(rootSelectorOrNode);
          /** @type {?} */

          var rootContext = createRootContext(); // Create the root view. Uses empty TView and ContentTemplate.

          /** @type {?} */

          var rootTView = createTView(0
          /* Root */
          , -1, null, 1, 0, null, null, null, null, null);
          /** @type {?} */

          var rootLView = createLView(null, rootTView, rootContext, rootFlags, null, null, rendererFactory, hostRenderer, sanitizer, rootViewInjector); // rootView is the parent when bootstrapping
          // TODO(misko): it looks like we are entering view here but we don't really need to as
          // `renderView` does that. However as the code is written it is needed because
          // `createRootComponentView` and `createRootComponent` both read global state. Fixing those
          // issues would allow us to drop this.

          enterView(rootLView, null);
          /** @type {?} */

          var component;
          /** @type {?} */

          var tElementNode;

          try {
            /** @type {?} */
            var componentView = createRootComponentView(hostRNode, this.componentDef, rootLView, rendererFactory, hostRenderer);

            if (hostRNode) {
              if (rootSelectorOrNode) {
                setUpAttributes(hostRenderer, hostRNode, ['ng-version', VERSION.full]);
              } else {
                // If host element is created as a part of this function call (i.e. `rootSelectorOrNode`
                // is not defined), also apply attributes and classes extracted from component selector.
                // Extract attributes and classes from the first selector only to match VE behavior.
                var _extractAttrsAndClass = extractAttrsAndClassesFromSelector(this.componentDef.selectors[0]),
                    attrs = _extractAttrsAndClass.attrs,
                    classes = _extractAttrsAndClass.classes;

                if (attrs) {
                  setUpAttributes(hostRenderer, hostRNode, attrs);
                }

                if (classes && classes.length > 0) {
                  writeDirectClass(hostRenderer, hostRNode, classes.join(' '));
                }
              }
            }

            tElementNode =
            /** @type {?} */
            getTNode(rootLView[TVIEW], 0);

            if (projectableNodes) {
              // projectable nodes can be passed as array of arrays or an array of iterables (ngUpgrade
              // case). Here we do normalize passed data structure to be an array of arrays to avoid
              // complex checks down the line.
              tElementNode.projection = projectableNodes.map(
              /**
              * @param {?} nodesforSlot
              * @return {?}
              */
              function (nodesforSlot) {
                return Array.from(nodesforSlot);
              });
            } // TODO: should LifecycleHooksFeature and other host features be generated by the compiler and
            // executed here?
            // Angular 5 reference: https://stackblitz.com/edit/lifecycle-hooks-vcref


            component = createRootComponent(componentView, this.componentDef, rootLView, rootContext, [LifecycleHooksFeature]);
            renderView(rootTView, rootLView, null);
          } finally {
            leaveView();
          }
          /** @type {?} */


          var componentRef = new ComponentRef$1(this.componentType, component, createElementRef(ElementRef, tElementNode, rootLView), rootLView, tElementNode);

          if (!rootSelectorOrNode || isIsolated) {
            // The host element of the internal or isolated root view is attached to the component's host
            // view node.

            /** @type {?} */
            componentRef.hostView._tViewNode.child = tElementNode;
          }

          return componentRef;
        }
      }, {
        key: "inputs",
        get: function get() {
          return toRefArray(this.componentDef.inputs);
        }
        /**
         * @return {?}
         */

      }, {
        key: "outputs",
        get: function get() {
          return toRefArray(this.componentDef.outputs);
        }
      }]);

      return ComponentFactory$1;
    }(ComponentFactory);

    if (false) {}
    /** @type {?} */


    var componentFactoryResolver = new ComponentFactoryResolver$1();
    /**
     * Creates a ComponentFactoryResolver and stores it on the injector. Or, if the
     * ComponentFactoryResolver
     * already exists, retrieves the existing ComponentFactoryResolver.
     *
     * @return {?} The ComponentFactoryResolver instance to use
     */

    function injectComponentFactoryResolver() {
      return componentFactoryResolver;
    }
    /**
     * Represents an instance of a Component created via a {\@link ComponentFactory}.
     *
     * `ComponentRef` provides access to the Component Instance as well other objects related to this
     * Component Instance and allows you to destroy the Component Instance via the {\@link #destroy}
     * method.
     *
     * @template T
     */


    var ComponentRef$1 = /*#__PURE__*/function (_ComponentRef2) {
      _inherits(ComponentRef$1, _ComponentRef2);

      var _super42 = _createSuper(ComponentRef$1);

      /**
       * @param {?} componentType
       * @param {?} instance
       * @param {?} location
       * @param {?} _rootLView
       * @param {?} _tNode
       */
      function ComponentRef$1(componentType, instance, location, _rootLView, _tNode) {
        var _this165;

        _classCallCheck(this, ComponentRef$1);

        _this165 = _super42.call(this);
        _this165.location = location;
        _this165._rootLView = _rootLView;
        _this165._tNode = _tNode;
        _this165.destroyCbs = [];
        _this165.instance = instance;
        _this165.hostView = _this165.changeDetectorRef = new RootViewRef(_rootLView);
        _this165.hostView._tViewNode = assignTViewNodeToLView(_rootLView[TVIEW], null, -1, _rootLView);
        _this165.componentType = componentType;
        return _this165;
      }
      /**
       * @return {?}
       */


      _createClass2(ComponentRef$1, [{
        key: "destroy",

        /**
         * @return {?}
         */
        value: function destroy() {
          if (this.destroyCbs) {
            this.destroyCbs.forEach(
            /**
            * @param {?} fn
            * @return {?}
            */
            function (fn) {
              return fn();
            });
            this.destroyCbs = null;
            !this.hostView.destroyed && this.hostView.destroy();
          }
        }
        /**
         * @param {?} callback
         * @return {?}
         */

      }, {
        key: "onDestroy",
        value: function onDestroy(callback) {
          if (this.destroyCbs) {
            this.destroyCbs.push(callback);
          }
        }
      }, {
        key: "injector",
        get: function get() {
          return new NodeInjector(this._tNode, this._rootLView);
        }
      }]);

      return ComponentRef$1;
    }(ComponentRef);

    if (false) {}
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * NOTE: changes to the `ngI18nClosureMode` name must be synced with `compiler-cli/src/tooling.ts`.
     */


    if (typeof ngI18nClosureMode === 'undefined') {
      // These property accesses can be ignored because ngI18nClosureMode will be set to false
      // when optimizing code and the whole if statement will be dropped.
      // Make sure to refer to ngI18nClosureMode as ['ngI18nClosureMode'] for closure.
      // NOTE: we need to have it in IIFE so that the tree-shaker is happy.
      (function () {
        // tslint:disable-next-line:no-toplevel-property-access
        _global['ngI18nClosureMode'] = // TODO(FW-1250): validate that this actually, you know, works.
        // tslint:disable-next-line:no-toplevel-property-access
        typeof goog !== 'undefined' && typeof goog.getMsg === 'function';
      })();
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/i18n/locale_en.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */
    // THIS CODE IS GENERATED - DO NOT MODIFY
    // See angular/tools/gulp-tasks/cldr/extract.js

    /** @type {?} */


    var u = undefined;
    /**
     * @param {?} n
     * @return {?}
     */

    function plural(n) {
      /** @type {?} */
      var i = Math.floor(Math.abs(n));
      /** @type {?} */

      var v = n.toString().replace(/^[^.]*\.?/, '').length;
      if (i === 1 && v === 0) return 1;
      return 5;
    }

    var localeEn = ['en', [['a', 'p'], ['AM', 'PM'], u], [['AM', 'PM'], u, u], [['S', 'M', 'T', 'W', 'T', 'F', 'S'], ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'], ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'], ['Su', 'Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa']], u, [['J', 'F', 'M', 'A', 'M', 'J', 'J', 'A', 'S', 'O', 'N', 'D'], ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'], ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December']], u, [['B', 'A'], ['BC', 'AD'], ['Before Christ', 'Anno Domini']], 0, [6, 0], ['M/d/yy', 'MMM d, y', 'MMMM d, y', 'EEEE, MMMM d, y'], ['h:mm a', 'h:mm:ss a', 'h:mm:ss a z', 'h:mm:ss a zzzz'], ['{1}, {0}', u, '{1} \'at\' {0}', u], ['.', ',', ';', '%', '+', '-', 'E', '×', '‰', '∞', 'NaN', ':'], ['#,##0.###', '#,##0%', '¤#,##0.00', '#E0'], 'USD', '$', 'US Dollar', {}, 'ltr', plural];
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/i18n/locale_data_api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * This const is used to store the locale data registered with `registerLocaleData`
     * @type {?}
     */

    var LOCALE_DATA = {};
    /**
     * Register locale data to be used internally by Angular. See the
     * ["I18n guide"](guide/i18n#i18n-pipes) to know how to import additional locale data.
     *
     * The signature `registerLocaleData(data: any, extraData?: any)` is deprecated since v5.1
     * @param {?} data
     * @param {?=} localeId
     * @param {?=} extraData
     * @return {?}
     */

    function registerLocaleData(data, localeId, extraData) {
      if (typeof localeId !== 'string') {
        extraData = localeId;
        localeId = data[LocaleDataIndex.LocaleId];
      }

      localeId = localeId.toLowerCase().replace(/_/g, '-');
      LOCALE_DATA[localeId] = data;

      if (extraData) {
        LOCALE_DATA[localeId][LocaleDataIndex.ExtraData] = extraData;
      }
    }
    /**
     * Finds the locale data for a given locale.
     *
     * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     * @param {?} locale The locale code.
     * @return {?} The locale data.
     */


    function findLocaleData(locale) {
      /** @type {?} */
      var normalizedLocale = normalizeLocale(locale);
      /** @type {?} */

      var match = getLocaleData(normalizedLocale);

      if (match) {
        return match;
      } // let's try to find a parent locale

      /** @type {?} */


      var parentLocale = normalizedLocale.split('-')[0];
      match = getLocaleData(parentLocale);

      if (match) {
        return match;
      }

      if (parentLocale === 'en') {
        return localeEn;
      }

      throw new Error("Missing locale data for the locale \"".concat(locale, "\"."));
    }
    /**
     * Retrieves the default currency code for the given locale.
     *
     * The default is defined as the first currency which is still in use.
     *
     * @param {?} locale The code of the locale whose currency code we want.
     * @return {?} The code of the default currency for the given locale.
     *
     */


    function getLocaleCurrencyCode(locale) {
      /** @type {?} */
      var data = findLocaleData(locale);
      return data[LocaleDataIndex.CurrencyCode] || null;
    }
    /**
     * Retrieves the plural function used by ICU expressions to determine the plural case to use
     * for a given locale.
     * @see `NgPlural` / [Internationalization (i18n) Guide](https://angular.io/guide/i18n)
     * @param {?} locale A locale code for the locale format rules to use.
     * @return {?} The plural function for the locale.
     */


    function getLocalePluralCase(locale) {
      /** @type {?} */
      var data = findLocaleData(locale);
      return data[LocaleDataIndex.PluralCase];
    }
    /**
     * Helper function to get the given `normalizedLocale` from `LOCALE_DATA`
     * or from the global `ng.common.locale`.
     * @param {?} normalizedLocale
     * @return {?}
     */


    function getLocaleData(normalizedLocale) {
      if (!(normalizedLocale in LOCALE_DATA)) {
        LOCALE_DATA[normalizedLocale] = _global.ng && _global.ng.common && _global.ng.common.locales && _global.ng.common.locales[normalizedLocale];
      }

      return LOCALE_DATA[normalizedLocale];
    }
    /**
     * Helper function to remove all the locale data from `LOCALE_DATA`.
     * @return {?}
     */


    function unregisterAllLocaleData() {
      LOCALE_DATA = {};
    }
    /** @enum {number} */


    var LocaleDataIndex = {
      LocaleId: 0,
      DayPeriodsFormat: 1,
      DayPeriodsStandalone: 2,
      DaysFormat: 3,
      DaysStandalone: 4,
      MonthsFormat: 5,
      MonthsStandalone: 6,
      Eras: 7,
      FirstDayOfWeek: 8,
      WeekendRange: 9,
      DateFormat: 10,
      TimeFormat: 11,
      DateTimeFormat: 12,
      NumberSymbols: 13,
      NumberFormats: 14,
      CurrencyCode: 15,
      CurrencySymbol: 16,
      CurrencyName: 17,
      Currencies: 18,
      Directionality: 19,
      PluralCase: 20,
      ExtraData: 21
    };
    LocaleDataIndex[LocaleDataIndex.LocaleId] = 'LocaleId';
    LocaleDataIndex[LocaleDataIndex.DayPeriodsFormat] = 'DayPeriodsFormat';
    LocaleDataIndex[LocaleDataIndex.DayPeriodsStandalone] = 'DayPeriodsStandalone';
    LocaleDataIndex[LocaleDataIndex.DaysFormat] = 'DaysFormat';
    LocaleDataIndex[LocaleDataIndex.DaysStandalone] = 'DaysStandalone';
    LocaleDataIndex[LocaleDataIndex.MonthsFormat] = 'MonthsFormat';
    LocaleDataIndex[LocaleDataIndex.MonthsStandalone] = 'MonthsStandalone';
    LocaleDataIndex[LocaleDataIndex.Eras] = 'Eras';
    LocaleDataIndex[LocaleDataIndex.FirstDayOfWeek] = 'FirstDayOfWeek';
    LocaleDataIndex[LocaleDataIndex.WeekendRange] = 'WeekendRange';
    LocaleDataIndex[LocaleDataIndex.DateFormat] = 'DateFormat';
    LocaleDataIndex[LocaleDataIndex.TimeFormat] = 'TimeFormat';
    LocaleDataIndex[LocaleDataIndex.DateTimeFormat] = 'DateTimeFormat';
    LocaleDataIndex[LocaleDataIndex.NumberSymbols] = 'NumberSymbols';
    LocaleDataIndex[LocaleDataIndex.NumberFormats] = 'NumberFormats';
    LocaleDataIndex[LocaleDataIndex.CurrencyCode] = 'CurrencyCode';
    LocaleDataIndex[LocaleDataIndex.CurrencySymbol] = 'CurrencySymbol';
    LocaleDataIndex[LocaleDataIndex.CurrencyName] = 'CurrencyName';
    LocaleDataIndex[LocaleDataIndex.Currencies] = 'Currencies';
    LocaleDataIndex[LocaleDataIndex.Directionality] = 'Directionality';
    LocaleDataIndex[LocaleDataIndex.PluralCase] = 'PluralCase';
    LocaleDataIndex[LocaleDataIndex.ExtraData] = 'ExtraData';
    /** @enum {number} */

    var ExtraLocaleDataIndex = {
      ExtraDayPeriodFormats: 0,
      ExtraDayPeriodStandalone: 1,
      ExtraDayPeriodsRules: 2
    };
    /** @enum {number} */

    var CurrencyIndex = {
      Symbol: 0,
      SymbolNarrow: 1,
      NbOfDigits: 2
    };
    /**
     * Returns the canonical form of a locale name - lowercase with `_` replaced with `-`.
     * @param {?} locale
     * @return {?}
     */

    function normalizeLocale(locale) {
      return locale.toLowerCase().replace(/_/g, '-');
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/i18n/localization.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Returns the plural case based on the locale
     * @param {?} value
     * @param {?} locale
     * @return {?}
     */


    function getPluralCase(value, locale) {
      /** @type {?} */
      var plural = getLocalePluralCase(locale)(value);

      switch (plural) {
        case 0:
          return 'zero';

        case 1:
          return 'one';

        case 2:
          return 'two';

        case 3:
          return 'few';

        case 4:
          return 'many';

        default:
          return 'other';
      }
    }
    /**
     * The locale id that the application is using by default (for translations and ICU expressions).
     * @type {?}
     */


    var DEFAULT_LOCALE_ID = 'en-US';
    /**
     * USD currency code that the application uses by default for CurrencyPipe when no
     * DEFAULT_CURRENCY_CODE is provided.
     * @type {?}
     */

    var USD_CURRENCY_CODE = 'USD';
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/i18n.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */

    var MARKER = "\uFFFD";
    /** @type {?} */

    var ICU_BLOCK_REGEXP = /^\s*(�\d+:?\d*�)\s*,\s*(select|plural)\s*,/;
    /** @type {?} */

    var SUBTEMPLATE_REGEXP = /�\/?\*(\d+:\d+)�/gi;
    /** @type {?} */

    var PH_REGEXP = /�(\/?[#*!]\d+):?\d*�/gi;
    /** @type {?} */

    var BINDING_REGEXP = /�(\d+):?\d*�/gi;
    /** @type {?} */

    var ICU_REGEXP = /({\s*�\d+:?\d*�\s*,\s*\S{6}\s*,[\s\S]*})/gi;
    /** @enum {string} */

    var TagType = {
      ELEMENT: "#",
      TEMPLATE: "*",
      PROJECTION: "!"
    }; // i18nPostprocess consts

    /** @type {?} */

    var ROOT_TEMPLATE_ID = 0;
    /** @type {?} */

    var PP_MULTI_VALUE_PLACEHOLDERS_REGEXP = /\[(�.+?�?)\]/;
    /** @type {?} */

    var PP_PLACEHOLDERS_REGEXP = /\[(�.+?�?)\]|(�\/?\*\d+:\d+�)/g;
    /** @type {?} */

    var PP_ICU_VARS_REGEXP = /({\s*)(VAR_(PLURAL|SELECT)(_\d+)?)(\s*,)/g;
    /** @type {?} */

    var PP_ICU_PLACEHOLDERS_REGEXP = /{([A-Z0-9_]+)}/g;
    /** @type {?} */

    var PP_ICUS_REGEXP = /�I18N_EXP_(ICU(_\d+)?)�/g;
    /** @type {?} */

    var PP_CLOSE_TEMPLATE_REGEXP = /\/\*/;
    /** @type {?} */

    var PP_TEMPLATE_ID_REGEXP = /\d+\:(\d+)/;
    /**
     * @record
     */

    function IcuExpression() {}

    if (false) {}
    /**
     * @record
     */


    function IcuCase() {}

    if (false) {}
    /**
     * Breaks pattern into strings and top level {...} blocks.
     * Can be used to break a message into text and ICU expressions, or to break an ICU expression into
     * keys and cases.
     * Original code from closure library, modified for Angular.
     *
     * @param {?} pattern (sub)Pattern to be broken.
     *
     * @return {?}
     */


    function extractParts(pattern) {
      if (!pattern) {
        return [];
      }
      /** @type {?} */


      var prevPos = 0;
      /** @type {?} */

      var braceStack = [];
      /** @type {?} */

      var results = [];
      /** @type {?} */

      var braces = /[{}]/g; // lastIndex doesn't get set to 0 so we have to.

      braces.lastIndex = 0;
      /** @type {?} */

      var match;

      while (match = braces.exec(pattern)) {
        /** @type {?} */
        var pos = match.index;

        if (match[0] == '}') {
          braceStack.pop();

          if (braceStack.length == 0) {
            // End of the block.

            /** @type {?} */
            var block = pattern.substring(prevPos, pos);

            if (ICU_BLOCK_REGEXP.test(block)) {
              results.push(parseICUBlock(block));
            } else {
              results.push(block);
            }

            prevPos = pos + 1;
          }
        } else {
          if (braceStack.length == 0) {
            /** @type {?} */
            var _substring = pattern.substring(prevPos, pos);

            results.push(_substring);
            prevPos = pos + 1;
          }

          braceStack.push('{');
        }
      }
      /** @type {?} */


      var substring = pattern.substring(prevPos);
      results.push(substring);
      return results;
    }
    /**
     * Parses text containing an ICU expression and produces a JSON object for it.
     * Original code from closure library, modified for Angular.
     *
     * @param {?} pattern Text containing an ICU expression that needs to be parsed.
     *
     * @return {?}
     */


    function parseICUBlock(pattern) {
      /** @type {?} */
      var cases = [];
      /** @type {?} */

      var values = [];
      /** @type {?} */

      var icuType = 1
      /* plural */
      ;
      /** @type {?} */

      var mainBinding = 0;
      pattern = pattern.replace(ICU_BLOCK_REGEXP,
      /**
      * @param {?} str
      * @param {?} binding
      * @param {?} type
      * @return {?}
      */
      function (str, binding, type) {
        if (type === 'select') {
          icuType = 0
          /* select */
          ;
        } else {
          icuType = 1
          /* plural */
          ;
        }

        mainBinding = parseInt(binding.substr(1), 10);
        return '';
      });
      /** @type {?} */

      var parts =
      /** @type {?} */
      extractParts(pattern); // Looking for (key block)+ sequence. One of the keys has to be "other".

      for (var pos = 0; pos < parts.length;) {
        /** @type {?} */
        var key = parts[pos++].trim();

        if (icuType === 1
        /* plural */
        ) {
            // Key can be "=x", we just want "x"
            key = key.replace(/\s*(?:=)?(\w+)\s*/, '$1');
          }

        if (key.length) {
          cases.push(key);
        }
        /** @type {?} */


        var blocks =
        /** @type {?} */
        extractParts(parts[pos++]);

        if (cases.length > values.length) {
          values.push(blocks);
        }
      } // TODO(ocombe): support ICU expressions in attributes, see #21615


      return {
        type: icuType,
        mainBinding: mainBinding,
        cases: cases,
        values: values
      };
    }
    /**
     * Removes everything inside the sub-templates of a message.
     * @param {?} message
     * @return {?}
     */


    function removeInnerTemplateTranslation(message) {
      /** @type {?} */
      var match;
      /** @type {?} */

      var res = '';
      /** @type {?} */

      var index = 0;
      /** @type {?} */

      var inTemplate = false;
      /** @type {?} */

      var tagMatched;

      while ((match = SUBTEMPLATE_REGEXP.exec(message)) !== null) {
        if (!inTemplate) {
          res += message.substring(index, match.index + match[0].length);
          tagMatched = match[1];
          inTemplate = true;
        } else {
          if (match[0] === "".concat(MARKER, "/*").concat(tagMatched).concat(MARKER)) {
            index = match.index;
            inTemplate = false;
          }
        }
      }

      ngDevMode && assertEqual(inTemplate, false, "Tag mismatch: unable to find the end of the sub-template in the translation \"".concat(message, "\""));
      res += message.substr(index);
      return res;
    }
    /**
     * Extracts a part of a message and removes the rest.
     *
     * This method is used for extracting a part of the message associated with a template. A translated
     * message can span multiple templates.
     *
     * Example:
     * ```
     * <div i18n>Translate <span *ngIf>me</span>!</div>
     * ```
     *
     * @param {?} message The message to crop
     * @param {?=} subTemplateIndex Index of the sub-template to extract. If undefined it returns the
     * external template and removes all sub-templates.
     * @return {?}
     */


    function getTranslationForTemplate(message, subTemplateIndex) {
      if (isRootTemplateMessage(subTemplateIndex)) {
        // We want the root template message, ignore all sub-templates
        return removeInnerTemplateTranslation(message);
      } else {
        // We want a specific sub-template

        /** @type {?} */
        var start = message.indexOf(":".concat(subTemplateIndex).concat(MARKER)) + 2 + subTemplateIndex.toString().length;
        /** @type {?} */

        var end = message.search(new RegExp("".concat(MARKER, "\\/\\*\\d+:").concat(subTemplateIndex).concat(MARKER)));
        return removeInnerTemplateTranslation(message.substring(start, end));
      }
    }
    /**
     * Generate the OpCodes to update the bindings of a string.
     *
     * @param {?} str The string containing the bindings.
     * @param {?} destinationNode Index of the destination node which will receive the binding.
     * @param {?=} attrName Name of the attribute, if the string belongs to an attribute.
     * @param {?=} sanitizeFn Sanitization function used to sanitize the string after update, if necessary.
     * @return {?}
     */


    function generateBindingUpdateOpCodes(str, destinationNode, attrName) {
      var sanitizeFn = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : null;

      /** @type {?} */
      var updateOpCodes = [null, null]; // Alloc space for mask and size

      /** @type {?} */

      var textParts = str.split(BINDING_REGEXP);
      /** @type {?} */

      var mask = 0;

      for (var j = 0; j < textParts.length; j++) {
        /** @type {?} */
        var textValue = textParts[j];

        if (j & 1) {
          // Odd indexes are bindings

          /** @type {?} */
          var bindingIndex = parseInt(textValue, 10);
          updateOpCodes.push(-1 - bindingIndex);
          mask = mask | toMaskBit(bindingIndex);
        } else if (textValue !== '') {
          // Even indexes are text
          updateOpCodes.push(textValue);
        }
      }

      updateOpCodes.push(destinationNode << 2
      /* SHIFT_REF */
      | (attrName ? 1
      /* Attr */
      : 0
      /* Text */
      ));

      if (attrName) {
        updateOpCodes.push(attrName, sanitizeFn);
      }

      updateOpCodes[0] = mask;
      updateOpCodes[1] = updateOpCodes.length - 2;
      return updateOpCodes;
    }
    /**
     * @param {?} icuExpression
     * @param {?=} mask
     * @return {?}
     */


    function getBindingMask(icuExpression) {
      var mask = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
      mask = mask | toMaskBit(icuExpression.mainBinding);
      /** @type {?} */

      var match;

      for (var i = 0; i < icuExpression.values.length; i++) {
        /** @type {?} */
        var valueArr = icuExpression.values[i];

        for (var j = 0; j < valueArr.length; j++) {
          /** @type {?} */
          var value = valueArr[j];

          if (typeof value === 'string') {
            while (match = BINDING_REGEXP.exec(value)) {
              mask = mask | toMaskBit(parseInt(match[1], 10));
            }
          } else {
            mask = getBindingMask(
            /** @type {?} */
            value, mask);
          }
        }
      }

      return mask;
    }
    /** @type {?} */


    var i18nIndexStack = [];
    /** @type {?} */

    var i18nIndexStackPointer = -1;
    /**
     * Convert binding index to mask bit.
     *
     * Each index represents a single bit on the bit-mask. Because bit-mask only has 32 bits, we make
     * the 32nd bit share all masks for all bindings higher than 32. Since it is extremely rare to have
     * more than 32 bindings this will be hit very rarely. The downside of hitting this corner case is
     * that we will execute binding code more often than necessary. (penalty of performance)
     * @param {?} bindingIndex
     * @return {?}
     */

    function toMaskBit(bindingIndex) {
      return 1 << Math.min(bindingIndex, 31);
    }
    /** @type {?} */


    var parentIndexStack = [];
    /**
     * Marks a block of text as translatable.
     *
     * The instructions `i18nStart` and `i18nEnd` mark the translation block in the template.
     * The translation `message` is the value which is locale specific. The translation string may
     * contain placeholders which associate inner elements and sub-templates within the translation.
     *
     * The translation `message` placeholders are:
     * - `�{index}(:{block})�`: *Binding Placeholder*: Marks a location where an expression will be
     *   interpolated into. The placeholder `index` points to the expression binding index. An optional
     *   `block` that matches the sub-template in which it was declared.
     * - `�#{index}(:{block})�`/`�/#{index}(:{block})�`: *Element Placeholder*:  Marks the beginning
     *   and end of DOM element that were embedded in the original translation block. The placeholder
     *   `index` points to the element index in the template instructions set. An optional `block` that
     *   matches the sub-template in which it was declared.
     * - `�!{index}(:{block})�`/`�/!{index}(:{block})�`: *Projection Placeholder*:  Marks the
     *   beginning and end of <ng-content> that was embedded in the original translation block.
     *   The placeholder `index` points to the element index in the template instructions set.
     *   An optional `block` that matches the sub-template in which it was declared.
     * - `�*{index}:{block}�`/`�/*{index}:{block}�`: *Sub-template Placeholder*: Sub-templates must be
     *   split up and translated separately in each angular template function. The `index` points to the
     *   `template` instruction index. A `block` that matches the sub-template in which it was declared.
     *
     * \@codeGenApi
     * @param {?} index A unique index of the translation in the static block.
     * @param {?} message The translation message.
     * @param {?=} subTemplateIndex Optional sub-template index in the `message`.
     *
     * @return {?}
     */

    function ɵɵi18nStart(index, message, subTemplateIndex) {
      /** @type {?} */
      var tView = getTView();
      ngDevMode && assertDefined(tView, "tView should be defined");
      i18nIndexStack[++i18nIndexStackPointer] = index; // We need to delay projections until `i18nEnd`

      setDelayProjection(true);

      if (tView.firstCreatePass && tView.data[index + HEADER_OFFSET] === null) {
        i18nStartFirstPass(getLView(), tView, index, message, subTemplateIndex);
      }
    } // Count for the number of vars that will be allocated for each i18n block.
    // It is global because this is used in multiple functions that include loops and recursive calls.
    // This is reset to 0 when `i18nStartFirstPass` is called.

    /** @type {?} */


    var i18nVarsCount;
    /**
     * @param {?} startIndex
     * @return {?}
     */

    function allocNodeIndex(startIndex) {
      return startIndex + i18nVarsCount++;
    }
    /**
     * See `i18nStart` above.
     * @param {?} lView
     * @param {?} tView
     * @param {?} index
     * @param {?} message
     * @param {?=} subTemplateIndex
     * @return {?}
     */


    function i18nStartFirstPass(lView, tView, index, message, subTemplateIndex) {
      /** @type {?} */
      var startIndex = tView.blueprint.length - HEADER_OFFSET;
      i18nVarsCount = 0;
      /** @type {?} */

      var previousOrParentTNode = getPreviousOrParentTNode();
      /** @type {?} */

      var parentTNode = getIsParent() ? previousOrParentTNode : previousOrParentTNode && previousOrParentTNode.parent;
      /** @type {?} */

      var parentIndex = parentTNode && parentTNode !== lView[T_HOST] ? parentTNode.index - HEADER_OFFSET : index;
      /** @type {?} */

      var parentIndexPointer = 0;
      parentIndexStack[parentIndexPointer] = parentIndex;
      /** @type {?} */

      var createOpCodes = []; // If the previous node wasn't the direct parent then we have a translation without top level
      // element and we need to keep a reference of the previous element if there is one. We should also
      // keep track whether an element was a parent node or not, so that the logic that consumes
      // the generated `I18nMutateOpCode`s can leverage this information to properly set TNode state
      // (whether it's a parent or sibling).

      if (index > 0 && previousOrParentTNode !== parentTNode) {
        /** @type {?} */
        var previousTNodeIndex = previousOrParentTNode.index - HEADER_OFFSET; // If current TNode is a sibling node, encode it using a negative index. This information is
        // required when the `Select` action is processed (see the `readCreateOpCodes` function).

        if (!getIsParent()) {
          previousTNodeIndex = ~previousTNodeIndex;
        } // Create an OpCode to select the previous TNode


        createOpCodes.push(previousTNodeIndex << 3
        /* SHIFT_REF */
        | 0
        /* Select */
        );
      }
      /** @type {?} */


      var updateOpCodes = [];
      /** @type {?} */

      var icuExpressions = [];

      if (message === '' && isRootTemplateMessage(subTemplateIndex)) {
        // If top level translation is an empty string, do not invoke additional processing
        // and just create op codes for empty text node instead.
        createOpCodes.push(message, allocNodeIndex(startIndex), parentIndex << 17
        /* SHIFT_PARENT */
        | 1
        /* AppendChild */
        );
      } else {
        /** @type {?} */
        var templateTranslation = getTranslationForTemplate(message, subTemplateIndex);
        /** @type {?} */

        var msgParts = replaceNgsp(templateTranslation).split(PH_REGEXP);

        for (var i = 0; i < msgParts.length; i++) {
          /** @type {?} */
          var value = msgParts[i];

          if (i & 1) {
            // Odd indexes are placeholders (elements and sub-templates)
            if (value.charAt(0) === '/') {
              // It is a closing tag
              if (value.charAt(1) === "#"
              /* ELEMENT */
              ) {
                  /** @type {?} */
                  var phIndex = parseInt(value.substr(2), 10);
                  parentIndex = parentIndexStack[--parentIndexPointer];
                  createOpCodes.push(phIndex << 3
                  /* SHIFT_REF */
                  | 5
                  /* ElementEnd */
                  );
                }
            } else {
              /** @type {?} */
              var _phIndex = parseInt(value.substr(1), 10);
              /** @type {?} */


              var isElement = value.charAt(0) === "#"
              /* ELEMENT */
              ; // The value represents a placeholder that we move to the designated index.
              // Note: positive indicies indicate that a TNode with a given index should also be marked
              // as parent while executing `Select` instruction.

              createOpCodes.push((isElement ? _phIndex : ~_phIndex) << 3
              /* SHIFT_REF */
              | 0
              /* Select */
              , parentIndex << 17
              /* SHIFT_PARENT */
              | 1
              /* AppendChild */
              );

              if (isElement) {
                parentIndexStack[++parentIndexPointer] = parentIndex = _phIndex;
              }
            }
          } else {
            // Even indexes are text (including bindings & ICU expressions)

            /** @type {?} */
            var parts = extractParts(value);

            for (var j = 0; j < parts.length; j++) {
              if (j & 1) {
                // Odd indexes are ICU expressions

                /** @type {?} */
                var icuExpression =
                /** @type {?} */
                parts[j]; // Verify that ICU expression has the right shape. Translations might contain invalid
                // constructions (while original messages were correct), so ICU parsing at runtime may
                // not succeed (thus `icuExpression` remains a string).

                if (typeof icuExpression !== 'object') {
                  throw new Error("Unable to parse ICU expression in \"".concat(templateTranslation, "\" message."));
                } // Create the comment node that will anchor the ICU expression

                /** @type {?} */


                var icuNodeIndex = allocNodeIndex(startIndex);
                createOpCodes.push(COMMENT_MARKER, ngDevMode ? "ICU ".concat(icuNodeIndex) : '', icuNodeIndex, parentIndex << 17
                /* SHIFT_PARENT */
                | 1
                /* AppendChild */
                ); // Update codes for the ICU expression

                /** @type {?} */

                var mask = getBindingMask(icuExpression);
                icuStart(icuExpressions, icuExpression, icuNodeIndex, icuNodeIndex); // Since this is recursive, the last TIcu that was pushed is the one we want

                /** @type {?} */

                var tIcuIndex = icuExpressions.length - 1;
                updateOpCodes.push(toMaskBit(icuExpression.mainBinding), // mask of the main binding
                3, // skip 3 opCodes if not changed
                -1 - icuExpression.mainBinding, icuNodeIndex << 2
                /* SHIFT_REF */
                | 2
                /* IcuSwitch */
                , tIcuIndex, mask, // mask of all the bindings of this ICU expression
                2, // skip 2 opCodes if not changed
                icuNodeIndex << 2
                /* SHIFT_REF */
                | 3
                /* IcuUpdate */
                , tIcuIndex);
              } else if (parts[j] !== '') {
                /** @type {?} */
                var text =
                /** @type {?} */
                parts[j]; // Even indexes are text (including bindings)

                /** @type {?} */

                var hasBinding = text.match(BINDING_REGEXP); // Create text nodes

                /** @type {?} */

                var textNodeIndex = allocNodeIndex(startIndex);
                createOpCodes.push( // If there is a binding, the value will be set during update
                hasBinding ? '' : text, textNodeIndex, parentIndex << 17
                /* SHIFT_PARENT */
                | 1
                /* AppendChild */
                );

                if (hasBinding) {
                  addAllToArray(generateBindingUpdateOpCodes(text, textNodeIndex), updateOpCodes);
                }
              }
            }
          }
        }
      }

      if (i18nVarsCount > 0) {
        allocExpando(tView, lView, i18nVarsCount);
      }

      ngDevMode && attachI18nOpCodesDebug(createOpCodes, updateOpCodes, icuExpressions.length ? icuExpressions : null, lView); // NOTE: local var needed to properly assert the type of `TI18n`.

      /** @type {?} */

      var tI18n = {
        vars: i18nVarsCount,
        create: createOpCodes,
        update: updateOpCodes,
        icus: icuExpressions.length ? icuExpressions : null
      };
      tView.data[index + HEADER_OFFSET] = tI18n;
    }
    /**
     * @param {?} tView
     * @param {?} tNode
     * @param {?} parentTNode
     * @param {?} previousTNode
     * @param {?} lView
     * @return {?}
     */


    function appendI18nNode(tView, tNode, parentTNode, previousTNode, lView) {
      ngDevMode && ngDevMode.rendererMoveNode++;
      /** @type {?} */

      var nextNode = tNode.next;

      if (!previousTNode) {
        previousTNode = parentTNode;
      } // Re-organize node tree to put this node in the correct position.


      if (previousTNode === parentTNode && tNode !== parentTNode.child) {
        tNode.next = parentTNode.child;
        parentTNode.child = tNode;
      } else if (previousTNode !== parentTNode && tNode !== previousTNode.next) {
        tNode.next = previousTNode.next;
        previousTNode.next = tNode;
      } else {
        tNode.next = null;
      }

      if (parentTNode !== lView[T_HOST]) {
        tNode.parent =
        /** @type {?} */
        parentTNode;
      } // If tNode was moved around, we might need to fix a broken link.

      /** @type {?} */


      var cursor = tNode.next;

      while (cursor) {
        if (cursor.next === tNode) {
          cursor.next = nextNode;
        }

        cursor = cursor.next;
      } // If the placeholder to append is a projection, we need to move the projected nodes instead


      if (tNode.type === 1
      /* Projection */
      ) {
          applyProjection(tView, lView,
          /** @type {?} */
          tNode);
          return tNode;
        }

      appendChild(tView, lView, getNativeByTNode(tNode, lView), tNode);
      /** @type {?} */

      var slotValue = lView[tNode.index];

      if (tNode.type !== 0
      /* Container */
      && isLContainer(slotValue)) {
        // Nodes that inject ViewContainerRef also have a comment node that should be moved
        appendChild(tView, lView, slotValue[NATIVE], tNode);
      }

      return tNode;
    }
    /**
     * @param {?} subTemplateIndex
     * @return {?}
     */


    function isRootTemplateMessage(subTemplateIndex) {
      return subTemplateIndex === undefined;
    }
    /**
     * Handles message string post-processing for internationalization.
     *
     * Handles message string post-processing by transforming it from intermediate
     * format (that might contain some markers that we need to replace) to the final
     * form, consumable by i18nStart instruction. Post processing steps include:
     *
     * 1. Resolve all multi-value cases (like [�*1:1��#2:1�|�#4:1�|�5�])
     * 2. Replace all ICU vars (like "VAR_PLURAL")
     * 3. Replace all placeholders used inside ICUs in a form of {PLACEHOLDER}
     * 4. Replace all ICU references with corresponding values (like �ICU_EXP_ICU_1�)
     *    in case multiple ICUs have the same placeholder name
     *
     * \@codeGenApi
     * @param {?} message Raw translation string for post processing
     * @param {?=} replacements Set of replacements that should be applied
     *
     * @return {?} Transformed string that can be consumed by i18nStart instruction
     *
     */


    function ɵɵi18nPostprocess(message) {
      var replacements = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};

      /**
       * Step 1: resolve all multi-value placeholders like [�#5�|�*1:1��#2:1�|�#4:1�]
       *
       * Note: due to the way we process nested templates (BFS), multi-value placeholders are typically
       * grouped by templates, for example: [�#5�|�#6�|�#1:1�|�#3:2�] where �#5� and �#6� belong to root
       * template, �#1:1� belong to nested template with index 1 and �#1:2� - nested template with index
       * 3. However in real templates the order might be different: i.e. �#1:1� and/or �#3:2� may go in
       * front of �#6�. The post processing step restores the right order by keeping track of the
       * template id stack and looks for placeholders that belong to the currently active template.
       * @type {?}
       */
      var result = message;

      if (PP_MULTI_VALUE_PLACEHOLDERS_REGEXP.test(message)) {
        /** @type {?} */
        var matches = {};
        /** @type {?} */

        var templateIdsStack = [ROOT_TEMPLATE_ID];
        result = result.replace(PP_PLACEHOLDERS_REGEXP,
        /**
        * @param {?} m
        * @param {?} phs
        * @param {?} tmpl
        * @return {?}
        */
        function (m, phs, tmpl) {
          /** @type {?} */
          var content = phs || tmpl;
          /** @type {?} */

          var placeholders = matches[content] || [];

          if (!placeholders.length) {
            content.split('|').forEach(
            /**
            * @param {?} placeholder
            * @return {?}
            */
            function (placeholder) {
              /** @type {?} */
              var match = placeholder.match(PP_TEMPLATE_ID_REGEXP);
              /** @type {?} */

              var templateId = match ? parseInt(match[1], 10) : ROOT_TEMPLATE_ID;
              /** @type {?} */

              var isCloseTemplateTag = PP_CLOSE_TEMPLATE_REGEXP.test(placeholder);
              placeholders.push([templateId, isCloseTemplateTag, placeholder]);
            });
            matches[content] = placeholders;
          }

          if (!placeholders.length) {
            throw new Error("i18n postprocess: unmatched placeholder - ".concat(content));
          }
          /** @type {?} */


          var currentTemplateId = templateIdsStack[templateIdsStack.length - 1];
          /** @type {?} */

          var idx = 0; // find placeholder index that matches current template id

          for (var i = 0; i < placeholders.length; i++) {
            if (placeholders[i][0] === currentTemplateId) {
              idx = i;
              break;
            }
          } // update template id stack based on the current tag extracted


          var _placeholders$idx = _slicedToArray(placeholders[idx], 3),
              templateId = _placeholders$idx[0],
              isCloseTemplateTag = _placeholders$idx[1],
              placeholder = _placeholders$idx[2];

          if (isCloseTemplateTag) {
            templateIdsStack.pop();
          } else if (currentTemplateId !== templateId) {
            templateIdsStack.push(templateId);
          } // remove processed tag from the list


          placeholders.splice(idx, 1);
          return placeholder;
        });
      } // return current result if no replacements specified


      if (!Object.keys(replacements).length) {
        return result;
      }
      /**
       * Step 2: replace all ICU vars (like "VAR_PLURAL")
       */


      result = result.replace(PP_ICU_VARS_REGEXP,
      /**
      * @param {?} match
      * @param {?} start
      * @param {?} key
      * @param {?} _type
      * @param {?} _idx
      * @param {?} end
      * @return {?}
      */
      function (match, start, key, _type, _idx, end) {
        return replacements.hasOwnProperty(key) ? "".concat(start).concat(replacements[key]).concat(end) : match;
      });
      /**
       * Step 3: replace all placeholders used inside ICUs in a form of {PLACEHOLDER}
       */

      result = result.replace(PP_ICU_PLACEHOLDERS_REGEXP,
      /**
      * @param {?} match
      * @param {?} key
      * @return {?}
      */
      function (match, key) {
        return replacements.hasOwnProperty(key) ?
        /** @type {?} */
        replacements[key] : match;
      });
      /**
       * Step 4: replace all ICU references with corresponding values (like �ICU_EXP_ICU_1�) in case
       * multiple ICUs have the same placeholder name
       */

      result = result.replace(PP_ICUS_REGEXP,
      /**
      * @param {?} match
      * @param {?} key
      * @return {?}
      */
      function (match, key) {
        if (replacements.hasOwnProperty(key)) {
          /** @type {?} */
          var list =
          /** @type {?} */
          replacements[key];

          if (!list.length) {
            throw new Error("i18n postprocess: unmatched ICU - ".concat(match, " with key: ").concat(key));
          }

          return (
            /** @type {?} */
            list.shift()
          );
        }

        return match;
      });
      return result;
    }
    /**
     * Translates a translation block marked by `i18nStart` and `i18nEnd`. It inserts the text/ICU nodes
     * into the render tree, moves the placeholder nodes and removes the deleted nodes.
     *
     * \@codeGenApi
     * @return {?}
     */


    function ɵɵi18nEnd() {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var tView = getTView();
      ngDevMode && assertDefined(tView, "tView should be defined");
      i18nEndFirstPass(tView, lView); // Stop delaying projections

      setDelayProjection(false);
    }
    /**
     * See `i18nEnd` above.
     * @param {?} tView
     * @param {?} lView
     * @return {?}
     */


    function i18nEndFirstPass(tView, lView) {
      ngDevMode && assertEqual(getBindingIndex(), tView.bindingStartIndex, 'i18nEnd should be called before any binding');
      /** @type {?} */

      var rootIndex = i18nIndexStack[i18nIndexStackPointer--];
      /** @type {?} */

      var tI18n =
      /** @type {?} */
      tView.data[rootIndex + HEADER_OFFSET];
      ngDevMode && assertDefined(tI18n, "You should call i18nStart before i18nEnd"); // Find the last node that was added before `i18nEnd`

      /** @type {?} */

      var lastCreatedNode = getPreviousOrParentTNode(); // Read the instructions to insert/move/remove DOM elements

      /** @type {?} */

      var visitedNodes = readCreateOpCodes(rootIndex, tI18n.create, tView, lView); // Remove deleted nodes

      /** @type {?} */

      var index = rootIndex + 1;

      while (index <= lastCreatedNode.index - HEADER_OFFSET) {
        if (visitedNodes.indexOf(index) === -1) {
          removeNode(tView, lView, index,
          /* markAsDetached */
          true);
        } // Check if an element has any local refs and skip them

        /** @type {?} */


        var tNode = getTNode(tView, index);

        if (tNode && (tNode.type === 0
        /* Container */
        || tNode.type === 3
        /* Element */
        || tNode.type === 4
        /* ElementContainer */
        ) && tNode.localNames !== null) {
          // Divide by 2 to get the number of local refs,
          // since they are stored as an array that also includes directive indexes,
          // i.e. ["localRef", directiveIndex, ...]
          index += tNode.localNames.length >> 1;
        }

        index++;
      }
    }
    /**
     * Creates and stores the dynamic TNode, and unhooks it from the tree for now.
     * @param {?} tView
     * @param {?} lView
     * @param {?} index
     * @param {?} type
     * @param {?} native
     * @param {?} name
     * @return {?}
     */


    function createDynamicNodeAtIndex(tView, lView, index, type, _native16, name) {
      /** @type {?} */
      var previousOrParentTNode = getPreviousOrParentTNode();
      ngDevMode && assertDataInRange(lView, index + HEADER_OFFSET);
      lView[index + HEADER_OFFSET] = _native16;
      /** @type {?} */

      var tNode = getOrCreateTNode(tView, lView[T_HOST], index,
      /** @type {?} */
      type, name, null); // We are creating a dynamic node, the previous tNode might not be pointing at this node.
      // We will link ourselves into the tree later with `appendI18nNode`.

      if (previousOrParentTNode && previousOrParentTNode.next === tNode) {
        previousOrParentTNode.next = null;
      }

      return tNode;
    }
    /**
     * @param {?} index
     * @param {?} createOpCodes
     * @param {?} tView
     * @param {?} lView
     * @return {?}
     */


    function readCreateOpCodes(index, createOpCodes, tView, lView) {
      /** @type {?} */
      var renderer = lView[RENDERER];
      /** @type {?} */

      var currentTNode = null;
      /** @type {?} */

      var previousTNode = null;
      /** @type {?} */

      var visitedNodes = [];

      for (var i = 0; i < createOpCodes.length; i++) {
        /** @type {?} */
        var opCode = createOpCodes[i];

        if (typeof opCode == 'string') {
          /** @type {?} */
          var textRNode = createTextNode(opCode, renderer);
          /** @type {?} */

          var textNodeIndex =
          /** @type {?} */
          createOpCodes[++i];
          ngDevMode && ngDevMode.rendererCreateTextNode++;
          previousTNode = currentTNode;
          currentTNode = createDynamicNodeAtIndex(tView, lView, textNodeIndex, 3
          /* Element */
          , textRNode, null);
          visitedNodes.push(textNodeIndex);
          setIsNotParent();
        } else if (typeof opCode == 'number') {
          switch (opCode & 7
          /* MASK_OPCODE */
          ) {
            case 1
            /* AppendChild */
            :
              /** @type {?} */
              var destinationNodeIndex = opCode >>> 17
              /* SHIFT_PARENT */
              ;
              /** @type {?} */

              var destinationTNode = void 0;

              if (destinationNodeIndex === index) {
                // If the destination node is `i18nStart`, we don't have a
                // top-level node and we should use the host node instead
                destinationTNode =
                /** @type {?} */
                lView[T_HOST];
              } else {
                destinationTNode = getTNode(tView, destinationNodeIndex);
              }

              ngDevMode && assertDefined(
              /** @type {?} */
              currentTNode, "You need to create or select a node before you can insert it into the DOM");
              previousTNode = appendI18nNode(tView,
              /** @type {?} */
              currentTNode, destinationTNode, previousTNode, lView);
              break;

            case 0
            /* Select */
            :
              // Negative indicies indicate that a given TNode is a sibling node, not a parent node
              // (see `i18nStartFirstPass` for additional information).

              /** @type {?} */
              var isParent = opCode >= 0;
              /** @type {?} */

              var nodeIndex = (isParent ? opCode : ~opCode) >>> 3
              /* SHIFT_REF */
              ;
              visitedNodes.push(nodeIndex);
              previousTNode = currentTNode;
              currentTNode = getTNode(tView, nodeIndex);

              if (currentTNode) {
                setPreviousOrParentTNode(currentTNode, isParent);
              }

              break;

            case 5
            /* ElementEnd */
            :
              /** @type {?} */
              var elementIndex = opCode >>> 3
              /* SHIFT_REF */
              ;
              previousTNode = currentTNode = getTNode(tView, elementIndex);
              setPreviousOrParentTNode(currentTNode, false);
              break;

            case 4
            /* Attr */
            :
              /** @type {?} */
              var elementNodeIndex = opCode >>> 3
              /* SHIFT_REF */
              ;
              /** @type {?} */

              var attrName =
              /** @type {?} */
              createOpCodes[++i];
              /** @type {?} */

              var attrValue =
              /** @type {?} */
              createOpCodes[++i]; // This code is used for ICU expressions only, since we don't support
              // directives/components in ICUs, we don't need to worry about inputs here

              elementAttributeInternal(getTNode(tView, elementNodeIndex), lView, attrName, attrValue, null, null);
              break;

            default:
              throw new Error("Unable to determine the type of mutate operation for \"".concat(opCode, "\""));
          }
        } else {
          switch (opCode) {
            case COMMENT_MARKER:
              /** @type {?} */
              var commentValue =
              /** @type {?} */
              createOpCodes[++i];
              /** @type {?} */

              var commentNodeIndex =
              /** @type {?} */
              createOpCodes[++i];
              ngDevMode && assertEqual(typeof commentValue, 'string', "Expected \"".concat(commentValue, "\" to be a comment node value"));
              /** @type {?} */

              var commentRNode = renderer.createComment(commentValue);
              ngDevMode && ngDevMode.rendererCreateComment++;
              previousTNode = currentTNode;
              currentTNode = createDynamicNodeAtIndex(tView, lView, commentNodeIndex, 5
              /* IcuContainer */
              , commentRNode, null);
              visitedNodes.push(commentNodeIndex);
              attachPatchData(commentRNode, lView);

              /** @type {?} */
              currentTNode.activeCaseIndex = null; // We will add the case nodes later, during the update phase

              setIsNotParent();
              break;

            case ELEMENT_MARKER:
              /** @type {?} */
              var tagNameValue =
              /** @type {?} */
              createOpCodes[++i];
              /** @type {?} */

              var _elementNodeIndex =
              /** @type {?} */
              createOpCodes[++i];
              ngDevMode && assertEqual(typeof tagNameValue, 'string', "Expected \"".concat(tagNameValue, "\" to be an element node tag name"));
              /** @type {?} */

              var elementRNode = renderer.createElement(tagNameValue);
              ngDevMode && ngDevMode.rendererCreateElement++;
              previousTNode = currentTNode;
              currentTNode = createDynamicNodeAtIndex(tView, lView, _elementNodeIndex, 3
              /* Element */
              , elementRNode, tagNameValue);
              visitedNodes.push(_elementNodeIndex);
              break;

            default:
              throw new Error("Unable to determine the type of mutate operation for \"".concat(opCode, "\""));
          }
        }
      }

      setIsNotParent();
      return visitedNodes;
    }
    /**
     * @param {?} updateOpCodes
     * @param {?} icus
     * @param {?} bindingsStartIndex
     * @param {?} changeMask
     * @param {?} tView
     * @param {?} lView
     * @param {?=} bypassCheckBit
     * @return {?}
     */


    function readUpdateOpCodes(updateOpCodes, icus, bindingsStartIndex, changeMask, tView, lView) {
      var bypassCheckBit = arguments.length > 6 && arguments[6] !== undefined ? arguments[6] : false;

      /** @type {?} */
      var caseCreated = false;

      for (var i = 0; i < updateOpCodes.length; i++) {
        // bit code to check if we should apply the next update

        /** @type {?} */
        var checkBit =
        /** @type {?} */
        updateOpCodes[i]; // Number of opCodes to skip until next set of update codes

        /** @type {?} */

        var skipCodes =
        /** @type {?} */
        updateOpCodes[++i];

        if (bypassCheckBit || checkBit & changeMask) {
          // The value has been updated since last checked

          /** @type {?} */
          var value = '';

          for (var j = i + 1; j <= i + skipCodes; j++) {
            /** @type {?} */
            var opCode = updateOpCodes[j];

            if (typeof opCode == 'string') {
              value += opCode;
            } else if (typeof opCode == 'number') {
              if (opCode < 0) {
                // It's a binding index whose value is negative
                value += renderStringify(lView[bindingsStartIndex - opCode]);
              } else {
                /** @type {?} */
                var nodeIndex = opCode >>> 2
                /* SHIFT_REF */
                ;
                /** @type {?} */

                var tIcuIndex = void 0;
                /** @type {?} */

                var tIcu = void 0;
                /** @type {?} */

                var icuTNode = void 0;

                switch (opCode & 3
                /* MASK_OPCODE */
                ) {
                  case 1
                  /* Attr */
                  :
                    /** @type {?} */
                    var propName =
                    /** @type {?} */
                    updateOpCodes[++j];
                    /** @type {?} */

                    var sanitizeFn =
                    /** @type {?} */
                    updateOpCodes[++j];
                    elementPropertyInternal(tView, getTNode(tView, nodeIndex), lView, propName, value, lView[RENDERER], sanitizeFn, false);
                    break;

                  case 0
                  /* Text */
                  :
                    textBindingInternal(lView, nodeIndex, value);
                    break;

                  case 2
                  /* IcuSwitch */
                  :
                    tIcuIndex =
                    /** @type {?} */
                    updateOpCodes[++j];
                    tIcu =
                    /** @type {?} */
                    icus[tIcuIndex];
                    icuTNode =
                    /** @type {?} */
                    getTNode(tView, nodeIndex); // If there is an active case, delete the old nodes

                    if (icuTNode.activeCaseIndex !== null) {
                      /** @type {?} */
                      var removeCodes = tIcu.remove[icuTNode.activeCaseIndex];

                      for (var k = 0; k < removeCodes.length; k++) {
                        /** @type {?} */
                        var removeOpCode =
                        /** @type {?} */
                        removeCodes[k];

                        switch (removeOpCode & 7
                        /* MASK_OPCODE */
                        ) {
                          case 3
                          /* Remove */
                          :
                            /** @type {?} */
                            var _nodeIndex = removeOpCode >>> 3
                            /* SHIFT_REF */
                            ; // Remove DOM element, but do *not* mark TNode as detached, since we are
                            // just switching ICU cases (while keeping the same TNode), so a DOM element
                            // representing a new ICU case will be re-created.


                            removeNode(tView, lView, _nodeIndex,
                            /* markAsDetached */
                            false);
                            break;

                          case 6
                          /* RemoveNestedIcu */
                          :
                            /** @type {?} */
                            var nestedIcuNodeIndex =
                            /** @type {?} */
                            removeCodes[k + 1] >>> 3
                            /* SHIFT_REF */
                            ;
                            /** @type {?} */

                            var nestedIcuTNode =
                            /** @type {?} */
                            getTNode(tView, nestedIcuNodeIndex);
                            /** @type {?} */

                            var activeIndex = nestedIcuTNode.activeCaseIndex;

                            if (activeIndex !== null) {
                              /** @type {?} */
                              var nestedIcuTIndex = removeOpCode >>> 3
                              /* SHIFT_REF */
                              ;
                              /** @type {?} */

                              var nestedTIcu =
                              /** @type {?} */
                              icus[nestedIcuTIndex];
                              addAllToArray(nestedTIcu.remove[activeIndex], removeCodes);
                            }

                            break;
                        }
                      }
                    } // Update the active caseIndex

                    /** @type {?} */


                    var caseIndex = getCaseIndex(tIcu, value);
                    icuTNode.activeCaseIndex = caseIndex !== -1 ? caseIndex : null;

                    if (caseIndex > -1) {
                      // Add the nodes for the new case
                      readCreateOpCodes(-1, tIcu.create[caseIndex], tView, lView);
                      caseCreated = true;
                    }

                    break;

                  case 3
                  /* IcuUpdate */
                  :
                    tIcuIndex =
                    /** @type {?} */
                    updateOpCodes[++j];
                    tIcu =
                    /** @type {?} */
                    icus[tIcuIndex];
                    icuTNode =
                    /** @type {?} */
                    getTNode(tView, nodeIndex);

                    if (icuTNode.activeCaseIndex !== null) {
                      readUpdateOpCodes(tIcu.update[icuTNode.activeCaseIndex], icus, bindingsStartIndex, changeMask, tView, lView, caseCreated);
                    }

                    break;
                }
              }
            }
          }
        }

        i += skipCodes;
      }
    }
    /**
     * @param {?} tView
     * @param {?} lView
     * @param {?} index
     * @param {?} markAsDetached
     * @return {?}
     */


    function removeNode(tView, lView, index, markAsDetached) {
      /** @type {?} */
      var removedPhTNode = getTNode(tView, index);
      /** @type {?} */

      var removedPhRNode = getNativeByIndex(index, lView);

      if (removedPhRNode) {
        nativeRemoveNode(lView[RENDERER], removedPhRNode);
      }
      /** @type {?} */


      var slotValue =
      /** @type {?} */
      load(lView, index);

      if (isLContainer(slotValue)) {
        /** @type {?} */
        var lContainer =
        /** @type {?} */
        slotValue;

        if (removedPhTNode.type !== 0
        /* Container */
        ) {
            nativeRemoveNode(lView[RENDERER], lContainer[NATIVE]);
          }
      }

      if (markAsDetached) {
        // Define this node as detached to avoid projecting it later
        removedPhTNode.flags |= 64
        /* isDetached */
        ;
      }

      ngDevMode && ngDevMode.rendererRemoveNode++;
    }
    /**
     *
     * Use this instruction to create a translation block that doesn't contain any placeholder.
     * It calls both {\@link i18nStart} and {\@link i18nEnd} in one instruction.
     *
     * The translation `message` is the value which is locale specific. The translation string may
     * contain placeholders which associate inner elements and sub-templates within the translation.
     *
     * The translation `message` placeholders are:
     * - `�{index}(:{block})�`: *Binding Placeholder*: Marks a location where an expression will be
     *   interpolated into. The placeholder `index` points to the expression binding index. An optional
     *   `block` that matches the sub-template in which it was declared.
     * - `�#{index}(:{block})�`/`�/#{index}(:{block})�`: *Element Placeholder*:  Marks the beginning
     *   and end of DOM element that were embedded in the original translation block. The placeholder
     *   `index` points to the element index in the template instructions set. An optional `block` that
     *   matches the sub-template in which it was declared.
     * - `�*{index}:{block}�`/`�/*{index}:{block}�`: *Sub-template Placeholder*: Sub-templates must be
     *   split up and translated separately in each angular template function. The `index` points to the
     *   `template` instruction index. A `block` that matches the sub-template in which it was declared.
     *
     * \@codeGenApi
     * @param {?} index A unique index of the translation in the static block.
     * @param {?} message The translation message.
     * @param {?=} subTemplateIndex Optional sub-template index in the `message`.
     *
     * @return {?}
     */


    function ɵɵi18n(index, message, subTemplateIndex) {
      ɵɵi18nStart(index, message, subTemplateIndex);
      ɵɵi18nEnd();
    }
    /**
     * Marks a list of attributes as translatable.
     *
     * \@codeGenApi
     * @param {?} index A unique index in the static block
     * @param {?} values
     *
     * @return {?}
     */


    function ɵɵi18nAttributes(index, values) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var tView = getTView();
      ngDevMode && assertDefined(tView, "tView should be defined");
      i18nAttributesFirstPass(lView, tView, index, values);
    }
    /**
     * See `i18nAttributes` above.
     * @param {?} lView
     * @param {?} tView
     * @param {?} index
     * @param {?} values
     * @return {?}
     */


    function i18nAttributesFirstPass(lView, tView, index, values) {
      /** @type {?} */
      var previousElement = getPreviousOrParentTNode();
      /** @type {?} */

      var previousElementIndex = previousElement.index - HEADER_OFFSET;
      /** @type {?} */

      var updateOpCodes = [];

      for (var i = 0; i < values.length; i += 2) {
        /** @type {?} */
        var attrName = values[i];
        /** @type {?} */

        var message = values[i + 1];
        /** @type {?} */

        var parts = message.split(ICU_REGEXP);

        for (var j = 0; j < parts.length; j++) {
          /** @type {?} */
          var value = parts[j];

          if (j & 1) {
            // Odd indexes are ICU expressions
            // TODO(ocombe): support ICU expressions in attributes
            throw new Error('ICU expressions are not yet supported in attributes');
          } else if (value !== '') {
            // Even indexes are text (including bindings)

            /** @type {?} */
            var hasBinding = !!value.match(BINDING_REGEXP);

            if (hasBinding) {
              if (tView.firstCreatePass && tView.data[index + HEADER_OFFSET] === null) {
                addAllToArray(generateBindingUpdateOpCodes(value, previousElementIndex, attrName), updateOpCodes);
              }
            } else {
              /** @type {?} */
              var tNode = getTNode(tView, previousElementIndex); // Set attributes for Elements only, for other types (like ElementContainer),
              // only set inputs below

              if (tNode.type === 3
              /* Element */
              ) {
                  elementAttributeInternal(tNode, lView, attrName, value, null, null);
                } // Check if that attribute is a directive input

              /** @type {?} */


              var dataValue = tNode.inputs !== null && tNode.inputs[attrName];

              if (dataValue) {
                setInputsForProperty(tView, lView, dataValue, attrName, value);

                if (ngDevMode) {
                  /** @type {?} */
                  var element =
                  /** @type {?} */
                  getNativeByIndex(previousElementIndex, lView);
                  setNgReflectProperties(lView, element, tNode.type, dataValue, value);
                }
              }
            }
          }
        }
      }

      if (tView.firstCreatePass && tView.data[index + HEADER_OFFSET] === null) {
        tView.data[index + HEADER_OFFSET] = updateOpCodes;
      }
    }
    /** @type {?} */


    var changeMask = 0;
    /** @type {?} */

    var shiftsCounter = 0;
    /**
     * Stores the values of the bindings during each update cycle in order to determine if we need to
     * update the translated nodes.
     *
     * \@codeGenApi
     * @template T
     * @param {?} value The binding's value
     * @return {?} This function returns itself so that it may be chained
     * (e.g. `i18nExp(ctx.name)(ctx.title)`)
     *
     */

    function ɵɵi18nExp(value) {
      /** @type {?} */
      var lView = getLView();

      if (bindingUpdated(lView, nextBindingIndex(), value)) {
        changeMask = changeMask | 1 << shiftsCounter;
      }

      shiftsCounter++;
      return ɵɵi18nExp;
    }
    /**
     * Updates a translation block or an i18n attribute when the bindings have changed.
     *
     * \@codeGenApi
     * @param {?} index Index of either {\@link i18nStart} (translation block) or {\@link i18nAttributes}
     * (i18n attribute) on which it should update the content.
     *
     * @return {?}
     */


    function ɵɵi18nApply(index) {
      if (shiftsCounter) {
        /** @type {?} */
        var tView = getTView();
        ngDevMode && assertDefined(tView, "tView should be defined");
        /** @type {?} */

        var tI18n = tView.data[index + HEADER_OFFSET];
        /** @type {?} */

        var updateOpCodes;
        /** @type {?} */

        var icus = null;

        if (Array.isArray(tI18n)) {
          updateOpCodes =
          /** @type {?} */
          tI18n;
        } else {
          updateOpCodes =
          /** @type {?} */
          tI18n.update;
          icus =
          /** @type {?} */
          tI18n.icus;
        }
        /** @type {?} */


        var bindingsStartIndex = getBindingIndex() - shiftsCounter - 1;
        /** @type {?} */

        var lView = getLView();
        readUpdateOpCodes(updateOpCodes, icus, bindingsStartIndex, changeMask, tView, lView); // Reset changeMask & maskBit to default for the next update cycle

        changeMask = 0;
        shiftsCounter = 0;
      }
    }
    /**
     * Returns the index of the current case of an ICU expression depending on the main binding value
     *
     * @param {?} icuExpression
     * @param {?} bindingValue The value of the main binding used by this ICU expression
     * @return {?}
     */


    function getCaseIndex(icuExpression, bindingValue) {
      /** @type {?} */
      var index = icuExpression.cases.indexOf(bindingValue);

      if (index === -1) {
        switch (icuExpression.type) {
          case 1
          /* plural */
          :
            {
              /** @type {?} */
              var resolvedCase = getPluralCase(bindingValue, getLocaleId());
              index = icuExpression.cases.indexOf(resolvedCase);

              if (index === -1 && resolvedCase !== 'other') {
                index = icuExpression.cases.indexOf('other');
              }

              break;
            }

          case 0
          /* select */
          :
            {
              index = icuExpression.cases.indexOf('other');
              break;
            }
        }
      }

      return index;
    }
    /**
     * Generate the OpCodes for ICU expressions.
     *
     * @param {?} tIcus
     * @param {?} icuExpression
     * @param {?} startIndex
     * @param {?} expandoStartIndex
     * @return {?}
     */


    function icuStart(tIcus, icuExpression, startIndex, expandoStartIndex) {
      /** @type {?} */
      var createCodes = [];
      /** @type {?} */

      var removeCodes = [];
      /** @type {?} */

      var updateCodes = [];
      /** @type {?} */

      var vars = [];
      /** @type {?} */

      var childIcus = [];

      for (var i = 0; i < icuExpression.values.length; i++) {
        // Each value is an array of strings & other ICU expressions

        /** @type {?} */
        var valueArr = icuExpression.values[i];
        /** @type {?} */

        var nestedIcus = [];

        for (var j = 0; j < valueArr.length; j++) {
          /** @type {?} */
          var value = valueArr[j];

          if (typeof value !== 'string') {
            // It is an nested ICU expression

            /** @type {?} */
            var icuIndex = nestedIcus.push(
            /** @type {?} */
            value) - 1; // Replace nested ICU expression by a comment node

            valueArr[j] = "<!--\uFFFD".concat(icuIndex, "\uFFFD-->");
          }
        }
        /** @type {?} */


        var icuCase = parseIcuCase(valueArr.join(''), startIndex, nestedIcus, tIcus, expandoStartIndex);
        createCodes.push(icuCase.create);
        removeCodes.push(icuCase.remove);
        updateCodes.push(icuCase.update);
        vars.push(icuCase.vars);
        childIcus.push(icuCase.childIcus);
      }
      /** @type {?} */


      var tIcu = {
        type: icuExpression.type,
        vars: vars,
        childIcus: childIcus,
        cases: icuExpression.cases,
        create: createCodes,
        remove: removeCodes,
        update: updateCodes
      };
      tIcus.push(tIcu); // Adding the maximum possible of vars needed (based on the cases with the most vars)

      i18nVarsCount += Math.max.apply(Math, vars);
    }
    /**
     * Transforms a string template into an HTML template and a list of instructions used to update
     * attributes or nodes that contain bindings.
     *
     * @param {?} unsafeHtml The string to parse
     * @param {?} parentIndex
     * @param {?} nestedIcus
     * @param {?} tIcus
     * @param {?} expandoStartIndex
     * @return {?}
     */


    function parseIcuCase(unsafeHtml, parentIndex, nestedIcus, tIcus, expandoStartIndex) {
      /** @type {?} */
      var inertBodyHelper = new InertBodyHelper(getDocument());
      /** @type {?} */

      var inertBodyElement = inertBodyHelper.getInertBodyElement(unsafeHtml);

      if (!inertBodyElement) {
        throw new Error('Unable to generate inert body element');
      }
      /** @type {?} */


      var wrapper =
      /** @type {?} */
      getTemplateContent(
      /** @type {?} */
      inertBodyElement) || inertBodyElement;
      /** @type {?} */

      var opCodes = {
        vars: 0,
        childIcus: [],
        create: [],
        remove: [],
        update: []
      };
      parseNodes(wrapper.firstChild, opCodes, parentIndex, nestedIcus, tIcus, expandoStartIndex);
      return opCodes;
    }
    /** @type {?} */


    var NESTED_ICU = /�(\d+)�/;
    /**
     * Parses a node, its children and its siblings, and generates the mutate & update OpCodes.
     *
     * @param {?} currentNode The first node to parse
     * @param {?} icuCase The data for the ICU expression case that contains those nodes
     * @param {?} parentIndex Index of the current node's parent
     * @param {?} nestedIcus Data for the nested ICU expressions that this case contains
     * @param {?} tIcus Data for all ICU expressions of the current message
     * @param {?} expandoStartIndex Expando start index for the current ICU expression
     * @return {?}
     */

    function parseNodes(currentNode, icuCase, parentIndex, nestedIcus, tIcus, expandoStartIndex) {
      if (currentNode) {
        /** @type {?} */
        var nestedIcusToCreate = [];

        while (currentNode) {
          /** @type {?} */
          var nextNode = currentNode.nextSibling;
          /** @type {?} */

          var newIndex = expandoStartIndex + ++icuCase.vars;

          switch (currentNode.nodeType) {
            case Node.ELEMENT_NODE:
              /** @type {?} */
              var element =
              /** @type {?} */
              currentNode;
              /** @type {?} */

              var tagName = element.tagName.toLowerCase();

              if (!VALID_ELEMENTS.hasOwnProperty(tagName)) {
                // This isn't a valid element, we won't create an element for it
                icuCase.vars--;
              } else {
                icuCase.create.push(ELEMENT_MARKER, tagName, newIndex, parentIndex << 17
                /* SHIFT_PARENT */
                | 1
                /* AppendChild */
                );
                /** @type {?} */

                var elAttrs = element.attributes;

                for (var i = 0; i < elAttrs.length; i++) {
                  /** @type {?} */
                  var attr =
                  /** @type {?} */
                  elAttrs.item(i);
                  /** @type {?} */

                  var lowerAttrName = attr.name.toLowerCase();
                  /** @type {?} */

                  var _hasBinding = !!attr.value.match(BINDING_REGEXP); // we assume the input string is safe, unless it's using a binding


                  if (_hasBinding) {
                    if (VALID_ATTRS.hasOwnProperty(lowerAttrName)) {
                      if (URI_ATTRS[lowerAttrName]) {
                        addAllToArray(generateBindingUpdateOpCodes(attr.value, newIndex, attr.name, _sanitizeUrl), icuCase.update);
                      } else if (SRCSET_ATTRS[lowerAttrName]) {
                        addAllToArray(generateBindingUpdateOpCodes(attr.value, newIndex, attr.name, sanitizeSrcset), icuCase.update);
                      } else {
                        addAllToArray(generateBindingUpdateOpCodes(attr.value, newIndex, attr.name), icuCase.update);
                      }
                    } else {
                      ngDevMode && console.warn("WARNING: ignoring unsafe attribute value ".concat(lowerAttrName, " on element ").concat(tagName, " (see http://g.co/ng/security#xss)"));
                    }
                  } else {
                    icuCase.create.push(newIndex << 3
                    /* SHIFT_REF */
                    | 4
                    /* Attr */
                    , attr.name, attr.value);
                  }
                } // Parse the children of this node (if any)


                parseNodes(currentNode.firstChild, icuCase, newIndex, nestedIcus, tIcus, expandoStartIndex); // Remove the parent node after the children

                icuCase.remove.push(newIndex << 3
                /* SHIFT_REF */
                | 3
                /* Remove */
                );
              }

              break;

            case Node.TEXT_NODE:
              /** @type {?} */
              var value = currentNode.textContent || '';
              /** @type {?} */

              var hasBinding = value.match(BINDING_REGEXP);
              icuCase.create.push(hasBinding ? '' : value, newIndex, parentIndex << 17
              /* SHIFT_PARENT */
              | 1
              /* AppendChild */
              );
              icuCase.remove.push(newIndex << 3
              /* SHIFT_REF */
              | 3
              /* Remove */
              );

              if (hasBinding) {
                addAllToArray(generateBindingUpdateOpCodes(value, newIndex), icuCase.update);
              }

              break;

            case Node.COMMENT_NODE:
              // Check if the comment node is a placeholder for a nested ICU

              /** @type {?} */
              var match = NESTED_ICU.exec(currentNode.textContent || '');

              if (match) {
                /** @type {?} */
                var nestedIcuIndex = parseInt(match[1], 10);
                /** @type {?} */

                var newLocal = ngDevMode ? "nested ICU ".concat(nestedIcuIndex) : ''; // Create the comment node that will anchor the ICU expression

                icuCase.create.push(COMMENT_MARKER, newLocal, newIndex, parentIndex << 17
                /* SHIFT_PARENT */
                | 1
                /* AppendChild */
                );
                /** @type {?} */

                var nestedIcu = nestedIcus[nestedIcuIndex];
                nestedIcusToCreate.push([nestedIcu, newIndex]);
              } else {
                // We do not handle any other type of comment
                icuCase.vars--;
              }

              break;

            default:
              // We do not handle any other type of element
              icuCase.vars--;
          }

          currentNode =
          /** @type {?} */
          nextNode;
        }

        for (var _i15 = 0; _i15 < nestedIcusToCreate.length; _i15++) {
          /** @type {?} */
          var _nestedIcu = nestedIcusToCreate[_i15][0];
          /** @type {?} */

          var nestedIcuNodeIndex = nestedIcusToCreate[_i15][1];
          icuStart(tIcus, _nestedIcu, nestedIcuNodeIndex, expandoStartIndex + icuCase.vars); // Since this is recursive, the last TIcu that was pushed is the one we want

          /** @type {?} */

          var nestTIcuIndex = tIcus.length - 1;
          icuCase.vars += Math.max.apply(Math, _toConsumableArray(tIcus[nestTIcuIndex].vars));
          icuCase.childIcus.push(nestTIcuIndex);
          /** @type {?} */

          var mask = getBindingMask(_nestedIcu);
          icuCase.update.push(toMaskBit(_nestedIcu.mainBinding), // mask of the main binding
          3, // skip 3 opCodes if not changed
          -1 - _nestedIcu.mainBinding, nestedIcuNodeIndex << 2
          /* SHIFT_REF */
          | 2
          /* IcuSwitch */
          , nestTIcuIndex, mask, // mask of all the bindings of this ICU expression
          2, // skip 2 opCodes if not changed
          nestedIcuNodeIndex << 2
          /* SHIFT_REF */
          | 3
          /* IcuUpdate */
          , nestTIcuIndex);
          icuCase.remove.push(nestTIcuIndex << 3
          /* SHIFT_REF */
          | 6
          /* RemoveNestedIcu */
          , nestedIcuNodeIndex << 3
          /* SHIFT_REF */
          | 3
          /* Remove */
          );
        }
      }
    }
    /**
     * Angular Dart introduced &ngsp; as a placeholder for non-removable space, see:
     * https://github.com/dart-lang/angular/blob/0bb611387d29d65b5af7f9d2515ab571fd3fbee4/_tests/test/compiler/preserve_whitespace_test.dart#L25-L32
     * In Angular Dart &ngsp; is converted to the 0xE500 PUA (Private Use Areas) unicode character
     * and later on replaced by a space. We are re-implementing the same idea here, since translations
     * might contain this special character.
     * @type {?}
     */


    var NGSP_UNICODE_REGEXP = /\uE500/g;
    /**
     * @param {?} value
     * @return {?}
     */

    function replaceNgsp(value) {
      return value.replace(NGSP_UNICODE_REGEXP, ' ');
    }
    /**
     * The locale id that the application is currently using (for translations and ICU expressions).
     * This is the ivy version of `LOCALE_ID` that was defined as an injection token for the view engine
     * but is now defined as a global value.
     * @type {?}
     */


    var LOCALE_ID = DEFAULT_LOCALE_ID;
    /**
     * Sets the locale id that will be used for translations and ICU expressions.
     * This is the ivy version of `LOCALE_ID` that was defined as an injection token for the view engine
     * but is now defined as a global value.
     *
     * @param {?} localeId
     * @return {?}
     */

    function setLocaleId(localeId) {
      assertDefined(localeId, "Expected localeId to be defined");

      if (typeof localeId === 'string') {
        LOCALE_ID = localeId.toLowerCase().replace(/_/g, '-');
      }
    }
    /**
     * Gets the locale id that will be used for translations and ICU expressions.
     * This is the ivy version of `LOCALE_ID` that was defined as an injection token for the view engine
     * but is now defined as a global value.
     * @return {?}
     */


    function getLocaleId() {
      return LOCALE_ID;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/metadata.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @record
     */


    function TypeWithMetadata() {}

    if (false) {}
    /**
     * Adds decorator, constructor, and property metadata to a given type via static metadata fields
     * on the type.
     *
     * These metadata fields can later be read with Angular's `ReflectionCapabilities` API.
     *
     * Calls to `setClassMetadata` can be marked as pure, resulting in the metadata assignments being
     * tree-shaken away during production builds.
     * @param {?} type
     * @param {?} decorators
     * @param {?} ctorParameters
     * @param {?} propDecorators
     * @return {?}
     */


    function setClassMetadata(type, decorators, ctorParameters, propDecorators) {
      return (
        /** @type {?} */
        noSideEffects(
        /**
        * @return {?}
        */
        function () {
          /** @type {?} */
          var clazz =
          /** @type {?} */
          type; // We determine whether a class has its own metadata by taking the metadata from the
          // parent constructor and checking whether it's the same as the subclass metadata below.
          // We can't use `hasOwnProperty` here because it doesn't work correctly in IE10 for
          // static fields that are defined by TS. See
          // https://github.com/angular/angular/pull/28439#issuecomment-459349218.

          /** @type {?} */

          var parentPrototype = clazz.prototype ? Object.getPrototypeOf(clazz.prototype) : null;
          /** @type {?} */

          var parentConstructor = parentPrototype && parentPrototype.constructor;

          if (decorators !== null) {
            if (clazz.decorators !== undefined && (!parentConstructor || parentConstructor.decorators !== clazz.decorators)) {
              var _clazz$decorators;

              (_clazz$decorators = clazz.decorators).push.apply(_clazz$decorators, _toConsumableArray(decorators));
            } else {
              clazz.decorators = decorators;
            }
          }

          if (ctorParameters !== null) {
            // Rather than merging, clobber the existing parameters. If other projects exist which
            // use tsickle-style annotations and reflect over them in the same way, this could
            // cause issues, but that is vanishingly unlikely.
            clazz.ctorParameters = ctorParameters;
          }

          if (propDecorators !== null) {
            // The property decorator objects are merged as it is possible different fields have
            // different decorator types. Decorators on individual fields are not merged, as it's
            // also incredibly unlikely that a field will be decorated both with an Angular
            // decorator and a non-Angular decorator that's also been downleveled.
            if (clazz.propDecorators !== undefined && (!parentConstructor || parentConstructor.propDecorators !== clazz.propDecorators)) {
              clazz.propDecorators = Object.assign(Object.assign({}, clazz.propDecorators), propDecorators);
            } else {
              clazz.propDecorators = propDecorators;
            }
          }
        })
      );
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/linker/ng_module_factory_registration.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Map of module-id to the corresponding NgModule.
     * - In pre Ivy we track NgModuleFactory,
     * - In post Ivy we track the NgModuleType
     * @type {?}
     */


    var modules = new Map();
    /**
     * Registers a loaded module. Should only be called from generated NgModuleFactory code.
     * \@publicApi
     * @param {?} id
     * @param {?} factory
     * @return {?}
     */

    function registerModuleFactory(id, factory) {
      /** @type {?} */
      var existing =
      /** @type {?} */
      modules.get(id);
      assertSameOrNotExisting(id, existing && existing.moduleType, factory.moduleType);
      modules.set(id, factory);
    }
    /**
     * @param {?} id
     * @param {?} type
     * @param {?} incoming
     * @return {?}
     */


    function assertSameOrNotExisting(id, type, incoming) {
      if (type && type !== incoming) {
        throw new Error("Duplicate module registered for ".concat(id, " - ").concat(stringify(type), " vs ").concat(stringify(type.name)));
      }
    }
    /**
     * @param {?} ngModuleType
     * @return {?}
     */


    function registerNgModuleType(ngModuleType) {
      if (ngModuleType.ɵmod.id !== null) {
        /** @type {?} */
        var id = ngModuleType.ɵmod.id;
        /** @type {?} */

        var existing =
        /** @type {?} */
        modules.get(id);
        assertSameOrNotExisting(id, existing, ngModuleType);
        modules.set(id, ngModuleType);
      }
      /** @type {?} */


      var imports = ngModuleType.ɵmod.imports;

      if (imports instanceof Function) {
        imports = imports();
      }

      if (imports) {
        imports.forEach(
        /**
        * @param {?} i
        * @return {?}
        */
        function (i) {
          return registerNgModuleType(
          /** @type {?} */
          i);
        });
      }
    }
    /**
     * @return {?}
     */


    function clearModulesForTest() {
      modules.clear();
    }
    /**
     * @param {?} id
     * @return {?}
     */


    function getRegisteredNgModuleType(id) {
      return modules.get(id) || autoRegisterModuleById[id];
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/ng_module_ref.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @record
     * @template T
     */


    function NgModuleType() {}

    if (false) {}
    /**
     * @template T
     */


    var NgModuleRef$1 = /*#__PURE__*/function (_NgModuleRef) {
      _inherits(NgModuleRef$1, _NgModuleRef);

      var _super43 = _createSuper(NgModuleRef$1);

      /**
       * @param {?} ngModuleType
       * @param {?} _parent
       */
      function NgModuleRef$1(ngModuleType, _parent) {
        var _this166;

        _classCallCheck(this, NgModuleRef$1);

        _this166 = _super43.call(this);
        _this166._parent = _parent; // tslint:disable-next-line:require-internal-with-underscore

        _this166._bootstrapComponents = [];
        _this166.injector = _assertThisInitialized(_this166);
        _this166.destroyCbs = []; // When bootstrapping a module we have a dependency graph that looks like this:
        // ApplicationRef -> ComponentFactoryResolver -> NgModuleRef. The problem is that if the
        // module being resolved tries to inject the ComponentFactoryResolver, it'll create a
        // circular dependency which will result in a runtime error, because the injector doesn't
        // exist yet. We work around the issue by creating the ComponentFactoryResolver ourselves
        // and providing it, rather than letting the injector resolve it.

        _this166.componentFactoryResolver = new ComponentFactoryResolver$1(_assertThisInitialized(_this166));
        /** @type {?} */

        var ngModuleDef = getNgModuleDef(ngModuleType);
        ngDevMode && assertDefined(ngModuleDef, "NgModule '".concat(stringify(ngModuleType), "' is not a subtype of 'NgModuleType'."));
        /** @type {?} */

        var ngLocaleIdDef = getNgLocaleIdDef(ngModuleType);
        ngLocaleIdDef && setLocaleId(ngLocaleIdDef);
        _this166._bootstrapComponents = maybeUnwrapFn(
        /** @type {?} */
        ngModuleDef.bootstrap);
        _this166._r3Injector =
        /** @type {?} */
        createInjectorWithoutInjectorInstances(ngModuleType, _parent, [{
          provide: NgModuleRef,
          useValue: _assertThisInitialized(_this166)
        }, {
          provide: ComponentFactoryResolver,
          useValue: _this166.componentFactoryResolver
        }], stringify(ngModuleType)); // We need to resolve the injector types separately from the injector creation, because
        // the module might be trying to use this ref in its contructor for DI which will cause a
        // circular error that will eventually error out, because the injector isn't created yet.

        _this166._r3Injector._resolveInjectorDefTypes();

        _this166.instance = _this166.get(ngModuleType);
        return _this166;
      }
      /**
       * @param {?} token
       * @param {?=} notFoundValue
       * @param {?=} injectFlags
       * @return {?}
       */


      _createClass2(NgModuleRef$1, [{
        key: "get",
        value: function get(token) {
          var notFoundValue = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : Injector.THROW_IF_NOT_FOUND;
          var injectFlags = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : InjectFlags.Default;

          if (token === Injector || token === NgModuleRef || token === INJECTOR) {
            return this;
          }

          return this._r3Injector.get(token, notFoundValue, injectFlags);
        }
        /**
         * @return {?}
         */

      }, {
        key: "destroy",
        value: function destroy() {
          ngDevMode && assertDefined(this.destroyCbs, 'NgModule already destroyed');
          /** @type {?} */

          var injector = this._r3Injector;
          !injector.destroyed && injector.destroy();

          /** @type {?} */
          this.destroyCbs.forEach(
          /**
          * @param {?} fn
          * @return {?}
          */
          function (fn) {
            return fn();
          });
          this.destroyCbs = null;
        }
        /**
         * @param {?} callback
         * @return {?}
         */

      }, {
        key: "onDestroy",
        value: function onDestroy(callback) {
          ngDevMode && assertDefined(this.destroyCbs, 'NgModule already destroyed');

          /** @type {?} */
          this.destroyCbs.push(callback);
        }
      }]);

      return NgModuleRef$1;
    }(NgModuleRef);

    if (false) {}
    /**
     * @template T
     */


    var NgModuleFactory$1 = /*#__PURE__*/function (_NgModuleFactory) {
      _inherits(NgModuleFactory$1, _NgModuleFactory);

      var _super44 = _createSuper(NgModuleFactory$1);

      /**
       * @param {?} moduleType
       */
      function NgModuleFactory$1(moduleType) {
        var _this167;

        _classCallCheck(this, NgModuleFactory$1);

        _this167 = _super44.call(this);
        _this167.moduleType = moduleType;
        /** @type {?} */

        var ngModuleDef = getNgModuleDef(moduleType);

        if (ngModuleDef !== null) {
          // Register the NgModule with Angular's module registry. The location (and hence timing) of
          // this call is critical to ensure this works correctly (modules get registered when expected)
          // without bloating bundles (modules are registered when otherwise not referenced).
          //
          // In View Engine, registration occurs in the .ngfactory.js file as a side effect. This has
          // several practical consequences:
          //
          // - If an .ngfactory file is not imported from, the module won't be registered (and can be
          //   tree shaken).
          // - If an .ngfactory file is imported from, the module will be registered even if an instance
          //   is not actually created (via `create` below).
          // - Since an .ngfactory file in View Engine references the .ngfactory files of the NgModule's
          //   imports,
          //
          // In Ivy, things are a bit different. .ngfactory files still exist for compatibility, but are
          // not a required API to use - there are other ways to obtain an NgModuleFactory for a given
          // NgModule. Thus, relying on a side effect in the .ngfactory file is not sufficient. Instead,
          // the side effect of registration is added here, in the constructor of NgModuleFactory,
          // ensuring no matter how a factory is created, the module is registered correctly.
          //
          // An alternative would be to include the registration side effect inline following the actual
          // NgModule definition. This also has the correct timing, but breaks tree-shaking - modules
          // will be registered and retained even if they're otherwise never referenced.
          registerNgModuleType(
          /** @type {?} */
          moduleType);
        }

        return _this167;
      }
      /**
       * @param {?} parentInjector
       * @return {?}
       */


      _createClass2(NgModuleFactory$1, [{
        key: "create",
        value: function create(parentInjector) {
          return new NgModuleRef$1(this.moduleType, parentInjector);
        }
      }]);

      return NgModuleFactory$1;
    }(NgModuleFactory);

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/pure_function.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Bindings for pure functions are stored after regular bindings.
     *
     * |-------decls------|---------vars---------|                 |----- hostVars (dir1) ------|
     * ------------------------------------------------------------------------------------------
     * | nodes/refs/pipes | bindings | fn slots  | injector | dir1 | host bindings | host slots |
     * ------------------------------------------------------------------------------------------
     *                    ^                      ^
     *      TView.bindingStartIndex      TView.expandoStartIndex
     *
     * Pure function instructions are given an offset from the binding root. Adding the offset to the
     * binding root gives the first index where the bindings are stored. In component views, the binding
     * root is the bindingStartIndex. In host bindings, the binding root is the expandoStartIndex +
     * any directive instances + any hostVars in directives evaluated before it.
     *
     * See VIEW_DATA.md for more information about host binding resolution.
     */

    /**
     * If the value hasn't been saved, calls the pure function to store and return the
     * value. If it has been saved, returns the saved value.
     *
     * \@codeGenApi
     * @template T
     * @param {?} slotOffset the offset from binding root to the reserved slot
     * @param {?} pureFn Function that returns a value
     * @param {?=} thisArg Optional calling context of pureFn
     * @return {?} value
     *
     */


    function ɵɵpureFunction0(slotOffset, pureFn, thisArg) {
      /** @type {?} */
      var bindingIndex = getBindingRoot() + slotOffset;
      /** @type {?} */

      var lView = getLView();
      return lView[bindingIndex] === NO_CHANGE ? updateBinding(lView, bindingIndex, thisArg ? pureFn.call(thisArg) : pureFn()) : getBinding(lView, bindingIndex);
    }
    /**
     * If the value of the provided exp has changed, calls the pure function to return
     * an updated value. Or if the value has not changed, returns cached value.
     *
     * \@codeGenApi
     * @param {?} slotOffset the offset from binding root to the reserved slot
     * @param {?} pureFn Function that returns an updated value
     * @param {?} exp Updated expression value
     * @param {?=} thisArg Optional calling context of pureFn
     * @return {?} Updated or cached value
     *
     */


    function ɵɵpureFunction1(slotOffset, pureFn, exp, thisArg) {
      return pureFunction1Internal(getLView(), getBindingRoot(), slotOffset, pureFn, exp, thisArg);
    }
    /**
     * If the value of any provided exp has changed, calls the pure function to return
     * an updated value. Or if no values have changed, returns cached value.
     *
     * \@codeGenApi
     * @param {?} slotOffset the offset from binding root to the reserved slot
     * @param {?} pureFn
     * @param {?} exp1
     * @param {?} exp2
     * @param {?=} thisArg Optional calling context of pureFn
     * @return {?} Updated or cached value
     *
     */


    function ɵɵpureFunction2(slotOffset, pureFn, exp1, exp2, thisArg) {
      return pureFunction2Internal(getLView(), getBindingRoot(), slotOffset, pureFn, exp1, exp2, thisArg);
    }
    /**
     * If the value of any provided exp has changed, calls the pure function to return
     * an updated value. Or if no values have changed, returns cached value.
     *
     * \@codeGenApi
     * @param {?} slotOffset the offset from binding root to the reserved slot
     * @param {?} pureFn
     * @param {?} exp1
     * @param {?} exp2
     * @param {?} exp3
     * @param {?=} thisArg Optional calling context of pureFn
     * @return {?} Updated or cached value
     *
     */


    function ɵɵpureFunction3(slotOffset, pureFn, exp1, exp2, exp3, thisArg) {
      return pureFunction3Internal(getLView(), getBindingRoot(), slotOffset, pureFn, exp1, exp2, exp3, thisArg);
    }
    /**
     * If the value of any provided exp has changed, calls the pure function to return
     * an updated value. Or if no values have changed, returns cached value.
     *
     * \@codeGenApi
     * @param {?} slotOffset the offset from binding root to the reserved slot
     * @param {?} pureFn
     * @param {?} exp1
     * @param {?} exp2
     * @param {?} exp3
     * @param {?} exp4
     * @param {?=} thisArg Optional calling context of pureFn
     * @return {?} Updated or cached value
     *
     */


    function ɵɵpureFunction4(slotOffset, pureFn, exp1, exp2, exp3, exp4, thisArg) {
      return pureFunction4Internal(getLView(), getBindingRoot(), slotOffset, pureFn, exp1, exp2, exp3, exp4, thisArg);
    }
    /**
     * If the value of any provided exp has changed, calls the pure function to return
     * an updated value. Or if no values have changed, returns cached value.
     *
     * \@codeGenApi
     * @param {?} slotOffset the offset from binding root to the reserved slot
     * @param {?} pureFn
     * @param {?} exp1
     * @param {?} exp2
     * @param {?} exp3
     * @param {?} exp4
     * @param {?} exp5
     * @param {?=} thisArg Optional calling context of pureFn
     * @return {?} Updated or cached value
     *
     */


    function ɵɵpureFunction5(slotOffset, pureFn, exp1, exp2, exp3, exp4, exp5, thisArg) {
      /** @type {?} */
      var bindingIndex = getBindingRoot() + slotOffset;
      /** @type {?} */

      var lView = getLView();
      /** @type {?} */

      var different = bindingUpdated4(lView, bindingIndex, exp1, exp2, exp3, exp4);
      return bindingUpdated(lView, bindingIndex + 4, exp5) || different ? updateBinding(lView, bindingIndex + 5, thisArg ? pureFn.call(thisArg, exp1, exp2, exp3, exp4, exp5) : pureFn(exp1, exp2, exp3, exp4, exp5)) : getBinding(lView, bindingIndex + 5);
    }
    /**
     * If the value of any provided exp has changed, calls the pure function to return
     * an updated value. Or if no values have changed, returns cached value.
     *
     * \@codeGenApi
     * @param {?} slotOffset the offset from binding root to the reserved slot
     * @param {?} pureFn
     * @param {?} exp1
     * @param {?} exp2
     * @param {?} exp3
     * @param {?} exp4
     * @param {?} exp5
     * @param {?} exp6
     * @param {?=} thisArg Optional calling context of pureFn
     * @return {?} Updated or cached value
     *
     */


    function ɵɵpureFunction6(slotOffset, pureFn, exp1, exp2, exp3, exp4, exp5, exp6, thisArg) {
      /** @type {?} */
      var bindingIndex = getBindingRoot() + slotOffset;
      /** @type {?} */

      var lView = getLView();
      /** @type {?} */

      var different = bindingUpdated4(lView, bindingIndex, exp1, exp2, exp3, exp4);
      return bindingUpdated2(lView, bindingIndex + 4, exp5, exp6) || different ? updateBinding(lView, bindingIndex + 6, thisArg ? pureFn.call(thisArg, exp1, exp2, exp3, exp4, exp5, exp6) : pureFn(exp1, exp2, exp3, exp4, exp5, exp6)) : getBinding(lView, bindingIndex + 6);
    }
    /**
     * If the value of any provided exp has changed, calls the pure function to return
     * an updated value. Or if no values have changed, returns cached value.
     *
     * \@codeGenApi
     * @param {?} slotOffset the offset from binding root to the reserved slot
     * @param {?} pureFn
     * @param {?} exp1
     * @param {?} exp2
     * @param {?} exp3
     * @param {?} exp4
     * @param {?} exp5
     * @param {?} exp6
     * @param {?} exp7
     * @param {?=} thisArg Optional calling context of pureFn
     * @return {?} Updated or cached value
     *
     */


    function ɵɵpureFunction7(slotOffset, pureFn, exp1, exp2, exp3, exp4, exp5, exp6, exp7, thisArg) {
      /** @type {?} */
      var bindingIndex = getBindingRoot() + slotOffset;
      /** @type {?} */

      var lView = getLView();
      /** @type {?} */

      var different = bindingUpdated4(lView, bindingIndex, exp1, exp2, exp3, exp4);
      return bindingUpdated3(lView, bindingIndex + 4, exp5, exp6, exp7) || different ? updateBinding(lView, bindingIndex + 7, thisArg ? pureFn.call(thisArg, exp1, exp2, exp3, exp4, exp5, exp6, exp7) : pureFn(exp1, exp2, exp3, exp4, exp5, exp6, exp7)) : getBinding(lView, bindingIndex + 7);
    }
    /**
     * If the value of any provided exp has changed, calls the pure function to return
     * an updated value. Or if no values have changed, returns cached value.
     *
     * \@codeGenApi
     * @param {?} slotOffset the offset from binding root to the reserved slot
     * @param {?} pureFn
     * @param {?} exp1
     * @param {?} exp2
     * @param {?} exp3
     * @param {?} exp4
     * @param {?} exp5
     * @param {?} exp6
     * @param {?} exp7
     * @param {?} exp8
     * @param {?=} thisArg Optional calling context of pureFn
     * @return {?} Updated or cached value
     *
     */


    function ɵɵpureFunction8(slotOffset, pureFn, exp1, exp2, exp3, exp4, exp5, exp6, exp7, exp8, thisArg) {
      /** @type {?} */
      var bindingIndex = getBindingRoot() + slotOffset;
      /** @type {?} */

      var lView = getLView();
      /** @type {?} */

      var different = bindingUpdated4(lView, bindingIndex, exp1, exp2, exp3, exp4);
      return bindingUpdated4(lView, bindingIndex + 4, exp5, exp6, exp7, exp8) || different ? updateBinding(lView, bindingIndex + 8, thisArg ? pureFn.call(thisArg, exp1, exp2, exp3, exp4, exp5, exp6, exp7, exp8) : pureFn(exp1, exp2, exp3, exp4, exp5, exp6, exp7, exp8)) : getBinding(lView, bindingIndex + 8);
    }
    /**
     * pureFunction instruction that can support any number of bindings.
     *
     * If the value of any provided exp has changed, calls the pure function to return
     * an updated value. Or if no values have changed, returns cached value.
     *
     * \@codeGenApi
     * @param {?} slotOffset the offset from binding root to the reserved slot
     * @param {?} pureFn A pure function that takes binding values and builds an object or array
     * containing those values.
     * @param {?} exps An array of binding values
     * @param {?=} thisArg Optional calling context of pureFn
     * @return {?} Updated or cached value
     *
     */


    function ɵɵpureFunctionV(slotOffset, pureFn, exps, thisArg) {
      return pureFunctionVInternal(getLView(), getBindingRoot(), slotOffset, pureFn, exps, thisArg);
    }
    /**
     * Results of a pure function invocation are stored in LView in a dedicated slot that is initialized
     * to NO_CHANGE. In rare situations a pure pipe might throw an exception on the very first
     * invocation and not produce any valid results. In this case LView would keep holding the NO_CHANGE
     * value. The NO_CHANGE is not something that we can use in expressions / bindings thus we convert
     * it to `undefined`.
     * @param {?} lView
     * @param {?} returnValueIndex
     * @return {?}
     */


    function getPureFunctionReturnValue(lView, returnValueIndex) {
      ngDevMode && assertDataInRange(lView, returnValueIndex);
      /** @type {?} */

      var lastReturnValue = lView[returnValueIndex];
      return lastReturnValue === NO_CHANGE ? undefined : lastReturnValue;
    }
    /**
     * If the value of the provided exp has changed, calls the pure function to return
     * an updated value. Or if the value has not changed, returns cached value.
     *
     * @param {?} lView LView in which the function is being executed.
     * @param {?} bindingRoot Binding root index.
     * @param {?} slotOffset the offset from binding root to the reserved slot
     * @param {?} pureFn Function that returns an updated value
     * @param {?} exp Updated expression value
     * @param {?=} thisArg Optional calling context of pureFn
     * @return {?} Updated or cached value
     */


    function pureFunction1Internal(lView, bindingRoot, slotOffset, pureFn, exp, thisArg) {
      /** @type {?} */
      var bindingIndex = bindingRoot + slotOffset;
      return bindingUpdated(lView, bindingIndex, exp) ? updateBinding(lView, bindingIndex + 1, thisArg ? pureFn.call(thisArg, exp) : pureFn(exp)) : getPureFunctionReturnValue(lView, bindingIndex + 1);
    }
    /**
     * If the value of any provided exp has changed, calls the pure function to return
     * an updated value. Or if no values have changed, returns cached value.
     *
     * @param {?} lView LView in which the function is being executed.
     * @param {?} bindingRoot Binding root index.
     * @param {?} slotOffset the offset from binding root to the reserved slot
     * @param {?} pureFn
     * @param {?} exp1
     * @param {?} exp2
     * @param {?=} thisArg Optional calling context of pureFn
     * @return {?} Updated or cached value
     */


    function pureFunction2Internal(lView, bindingRoot, slotOffset, pureFn, exp1, exp2, thisArg) {
      /** @type {?} */
      var bindingIndex = bindingRoot + slotOffset;
      return bindingUpdated2(lView, bindingIndex, exp1, exp2) ? updateBinding(lView, bindingIndex + 2, thisArg ? pureFn.call(thisArg, exp1, exp2) : pureFn(exp1, exp2)) : getPureFunctionReturnValue(lView, bindingIndex + 2);
    }
    /**
     * If the value of any provided exp has changed, calls the pure function to return
     * an updated value. Or if no values have changed, returns cached value.
     *
     * @param {?} lView LView in which the function is being executed.
     * @param {?} bindingRoot Binding root index.
     * @param {?} slotOffset the offset from binding root to the reserved slot
     * @param {?} pureFn
     * @param {?} exp1
     * @param {?} exp2
     * @param {?} exp3
     * @param {?=} thisArg Optional calling context of pureFn
     * @return {?} Updated or cached value
     */


    function pureFunction3Internal(lView, bindingRoot, slotOffset, pureFn, exp1, exp2, exp3, thisArg) {
      /** @type {?} */
      var bindingIndex = bindingRoot + slotOffset;
      return bindingUpdated3(lView, bindingIndex, exp1, exp2, exp3) ? updateBinding(lView, bindingIndex + 3, thisArg ? pureFn.call(thisArg, exp1, exp2, exp3) : pureFn(exp1, exp2, exp3)) : getPureFunctionReturnValue(lView, bindingIndex + 3);
    }
    /**
     * If the value of any provided exp has changed, calls the pure function to return
     * an updated value. Or if no values have changed, returns cached value.
     *
     * @param {?} lView LView in which the function is being executed.
     * @param {?} bindingRoot Binding root index.
     * @param {?} slotOffset the offset from binding root to the reserved slot
     * @param {?} pureFn
     * @param {?} exp1
     * @param {?} exp2
     * @param {?} exp3
     * @param {?} exp4
     * @param {?=} thisArg Optional calling context of pureFn
     * @return {?} Updated or cached value
     *
     */


    function pureFunction4Internal(lView, bindingRoot, slotOffset, pureFn, exp1, exp2, exp3, exp4, thisArg) {
      /** @type {?} */
      var bindingIndex = bindingRoot + slotOffset;
      return bindingUpdated4(lView, bindingIndex, exp1, exp2, exp3, exp4) ? updateBinding(lView, bindingIndex + 4, thisArg ? pureFn.call(thisArg, exp1, exp2, exp3, exp4) : pureFn(exp1, exp2, exp3, exp4)) : getPureFunctionReturnValue(lView, bindingIndex + 4);
    }
    /**
     * pureFunction instruction that can support any number of bindings.
     *
     * If the value of any provided exp has changed, calls the pure function to return
     * an updated value. Or if no values have changed, returns cached value.
     *
     * @param {?} lView LView in which the function is being executed.
     * @param {?} bindingRoot Binding root index.
     * @param {?} slotOffset the offset from binding root to the reserved slot
     * @param {?} pureFn A pure function that takes binding values and builds an object or array
     * containing those values.
     * @param {?} exps An array of binding values
     * @param {?=} thisArg Optional calling context of pureFn
     * @return {?} Updated or cached value
     */


    function pureFunctionVInternal(lView, bindingRoot, slotOffset, pureFn, exps, thisArg) {
      /** @type {?} */
      var bindingIndex = bindingRoot + slotOffset;
      /** @type {?} */

      var different = false;

      for (var i = 0; i < exps.length; i++) {
        bindingUpdated(lView, bindingIndex++, exps[i]) && (different = true);
      }

      return different ? updateBinding(lView, bindingIndex, pureFn.apply(thisArg, exps)) : getPureFunctionReturnValue(lView, bindingIndex);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/pipe.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Create a pipe.
     *
     * \@codeGenApi
     * @param {?} index Pipe index where the pipe will be stored.
     * @param {?} pipeName The name of the pipe
     * @return {?} T the instance of the pipe.
     *
     */


    function ɵɵpipe(index, pipeName) {
      /** @type {?} */
      var tView = getTView();
      /** @type {?} */

      var pipeDef;
      /** @type {?} */

      var adjustedIndex = index + HEADER_OFFSET;

      if (tView.firstCreatePass) {
        pipeDef = getPipeDef$1(pipeName, tView.pipeRegistry);
        tView.data[adjustedIndex] = pipeDef;

        if (pipeDef.onDestroy) {
          (tView.destroyHooks || (tView.destroyHooks = [])).push(adjustedIndex, pipeDef.onDestroy);
        }
      } else {
        pipeDef =
        /** @type {?} */
        tView.data[adjustedIndex];
      }
      /** @type {?} */


      var pipeFactory = pipeDef.factory || (pipeDef.factory = getFactoryDef(pipeDef.type, true));
      /** @type {?} */

      var previousInjectImplementation = setInjectImplementation(ɵɵdirectiveInject); // DI for pipes is supposed to behave like directives when placed on a component
      // host node, which means that we have to disable access to `viewProviders`.

      /** @type {?} */

      var previousIncludeViewProviders = setIncludeViewProviders(false);
      /** @type {?} */

      var pipeInstance = pipeFactory();
      setIncludeViewProviders(previousIncludeViewProviders);
      setInjectImplementation(previousInjectImplementation);
      store(tView, getLView(), index, pipeInstance);
      return pipeInstance;
    }
    /**
     * Searches the pipe registry for a pipe with the given name. If one is found,
     * returns the pipe. Otherwise, an error is thrown because the pipe cannot be resolved.
     *
     * @param {?} name Name of pipe to resolve
     * @param {?} registry Full list of available pipes
     * @return {?} Matching PipeDef
     */


    function getPipeDef$1(name, registry) {
      if (registry) {
        for (var i = registry.length - 1; i >= 0; i--) {
          /** @type {?} */
          var _pipeDef = registry[i];

          if (name === _pipeDef.name) {
            return _pipeDef;
          }
        }
      }

      throw new Error("The pipe '".concat(name, "' could not be found!"));
    }
    /**
     * Invokes a pipe with 1 arguments.
     *
     * This instruction acts as a guard to {\@link PipeTransform#transform} invoking
     * the pipe only when an input to the pipe changes.
     *
     * \@codeGenApi
     * @param {?} index Pipe index where the pipe was stored on creation.
     * @param {?} slotOffset the offset in the reserved slot space
     * @param {?} v1 1st argument to {\@link PipeTransform#transform}.
     *
     * @return {?}
     */


    function ɵɵpipeBind1(index, slotOffset, v1) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var pipeInstance = load(lView, index);
      return unwrapValue$1(lView, isPure(lView, index) ? pureFunction1Internal(lView, getBindingRoot(), slotOffset, pipeInstance.transform, v1, pipeInstance) : pipeInstance.transform(v1));
    }
    /**
     * Invokes a pipe with 2 arguments.
     *
     * This instruction acts as a guard to {\@link PipeTransform#transform} invoking
     * the pipe only when an input to the pipe changes.
     *
     * \@codeGenApi
     * @param {?} index Pipe index where the pipe was stored on creation.
     * @param {?} slotOffset the offset in the reserved slot space
     * @param {?} v1 1st argument to {\@link PipeTransform#transform}.
     * @param {?} v2 2nd argument to {\@link PipeTransform#transform}.
     *
     * @return {?}
     */


    function ɵɵpipeBind2(index, slotOffset, v1, v2) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var pipeInstance = load(lView, index);
      return unwrapValue$1(lView, isPure(lView, index) ? pureFunction2Internal(lView, getBindingRoot(), slotOffset, pipeInstance.transform, v1, v2, pipeInstance) : pipeInstance.transform(v1, v2));
    }
    /**
     * Invokes a pipe with 3 arguments.
     *
     * This instruction acts as a guard to {\@link PipeTransform#transform} invoking
     * the pipe only when an input to the pipe changes.
     *
     * \@codeGenApi
     * @param {?} index Pipe index where the pipe was stored on creation.
     * @param {?} slotOffset the offset in the reserved slot space
     * @param {?} v1 1st argument to {\@link PipeTransform#transform}.
     * @param {?} v2 2nd argument to {\@link PipeTransform#transform}.
     * @param {?} v3 4rd argument to {\@link PipeTransform#transform}.
     *
     * @return {?}
     */


    function ɵɵpipeBind3(index, slotOffset, v1, v2, v3) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var pipeInstance = load(lView, index);
      return unwrapValue$1(lView, isPure(lView, index) ? pureFunction3Internal(lView, getBindingRoot(), slotOffset, pipeInstance.transform, v1, v2, v3, pipeInstance) : pipeInstance.transform(v1, v2, v3));
    }
    /**
     * Invokes a pipe with 4 arguments.
     *
     * This instruction acts as a guard to {\@link PipeTransform#transform} invoking
     * the pipe only when an input to the pipe changes.
     *
     * \@codeGenApi
     * @param {?} index Pipe index where the pipe was stored on creation.
     * @param {?} slotOffset the offset in the reserved slot space
     * @param {?} v1 1st argument to {\@link PipeTransform#transform}.
     * @param {?} v2 2nd argument to {\@link PipeTransform#transform}.
     * @param {?} v3 3rd argument to {\@link PipeTransform#transform}.
     * @param {?} v4 4th argument to {\@link PipeTransform#transform}.
     *
     * @return {?}
     */


    function ɵɵpipeBind4(index, slotOffset, v1, v2, v3, v4) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var pipeInstance = load(lView, index);
      return unwrapValue$1(lView, isPure(lView, index) ? pureFunction4Internal(lView, getBindingRoot(), slotOffset, pipeInstance.transform, v1, v2, v3, v4, pipeInstance) : pipeInstance.transform(v1, v2, v3, v4));
    }
    /**
     * Invokes a pipe with variable number of arguments.
     *
     * This instruction acts as a guard to {\@link PipeTransform#transform} invoking
     * the pipe only when an input to the pipe changes.
     *
     * \@codeGenApi
     * @param {?} index Pipe index where the pipe was stored on creation.
     * @param {?} slotOffset the offset in the reserved slot space
     * @param {?} values Array of arguments to pass to {\@link PipeTransform#transform} method.
     *
     * @return {?}
     */


    function ɵɵpipeBindV(index, slotOffset, values) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var pipeInstance = load(lView, index);
      return unwrapValue$1(lView, isPure(lView, index) ? pureFunctionVInternal(lView, getBindingRoot(), slotOffset, pipeInstance.transform, values, pipeInstance) : pipeInstance.transform.apply(pipeInstance, values));
    }
    /**
     * @param {?} lView
     * @param {?} index
     * @return {?}
     */


    function isPure(lView, index) {
      return (
        /** @type {?} */
        lView[TVIEW].data[index + HEADER_OFFSET].pure
      );
    }
    /**
     * Unwrap the output of a pipe transformation.
     * In order to trick change detection into considering that the new value is always different from
     * the old one, the old value is overwritten by NO_CHANGE.
     *
     * @param {?} lView
     * @param {?} newValue the pipe transformation output.
     * @return {?}
     */


    function unwrapValue$1(lView, newValue) {
      if (WrappedValue.isWrapped(newValue)) {
        newValue = WrappedValue.unwrap(newValue); // The NO_CHANGE value needs to be written at the index where the impacted binding value is
        // stored

        /** @type {?} */

        var bindingToInvalidateIdx = getBindingIndex();
        lView[bindingToInvalidateIdx] = NO_CHANGE;
      }

      return newValue;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/event_emitter.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Use in components with the `\@Output` directive to emit custom events
     * synchronously or asynchronously, and register handlers for those events
     * by subscribing to an instance.
     *
     * \@usageNotes
     *
     * Extends
     * [RxJS `Subject`](https://rxjs.dev/api/index/class/Subject)
     * for Angular by adding the `emit()` method.
     *
     * In the following example, a component defines two output properties
     * that create event emitters. When the title is clicked, the emitter
     * emits an open or close event to toggle the current visibility state.
     *
     * ```html
     * \@Component({
     *   selector: 'zippy',
     *   template: `
     *   <div class="zippy">
     *     <div (click)="toggle()">Toggle</div>
     *     <div [hidden]="!visible">
     *       <ng-content></ng-content>
     *     </div>
     *  </div>`})
     * export class Zippy {
     *   visible: boolean = true;
     * \@Output() open: EventEmitter<any> = new EventEmitter();
     * \@Output() close: EventEmitter<any> = new EventEmitter();
     *
     *   toggle() {
     *     this.visible = !this.visible;
     *     if (this.visible) {
     *       this.open.emit(null);
     *     } else {
     *       this.close.emit(null);
     *     }
     *   }
     * }
     * ```
     *
     * Access the event object with the `$event` argument passed to the output event
     * handler:
     *
     * ```html
     * <zippy (open)="onOpen($event)" (close)="onClose($event)"></zippy>
     * ```
     *
     * @see [Observables in Angular](guide/observables-in-angular)
     * \@publicApi
     * @template T
     */


    var EventEmitter = /*#__PURE__*/function (_rxjs__WEBPACK_IMPORT) {
      _inherits(EventEmitter, _rxjs__WEBPACK_IMPORT);

      var _super45 = _createSuper(EventEmitter);

      // tslint:disable-line

      /**
       * Creates an instance of this class that can
       * deliver events synchronously or asynchronously.
       *
       * @param {?=} isAsync When true, deliver events asynchronously.
       *
       */
      function EventEmitter() {
        var _this168;

        var isAsync = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;

        _classCallCheck(this, EventEmitter);

        _this168 = _super45.call(this);
        _this168.__isAsync = isAsync;
        return _this168;
      }
      /**
       * Emits an event containing a given value.
       * @param {?=} value The value to emit.
       * @return {?}
       */


      _createClass2(EventEmitter, [{
        key: "emit",
        value: function emit(value) {
          _get(_getPrototypeOf(EventEmitter.prototype), "next", this).call(this, value);
        }
        /**
         * Registers handlers for events emitted by this instance.
         * @param {?=} generatorOrNext When supplied, a custom handler for emitted events.
         * @param {?=} error When supplied, a custom handler for an error notification
         * from this emitter.
         * @param {?=} complete When supplied, a custom handler for a completion
         * notification from this emitter.
         * @return {?}
         */

      }, {
        key: "subscribe",
        value: function subscribe(generatorOrNext, error, complete) {
          /** @type {?} */
          var schedulerFn;
          /** @type {?} */

          var errorFn =
          /**
          * @param {?} err
          * @return {?}
          */
          function errorFn(err) {
            return null;
          };
          /** @type {?} */


          var completeFn =
          /**
          * @return {?}
          */
          function completeFn() {
            return null;
          };

          if (generatorOrNext && typeof generatorOrNext === 'object') {
            schedulerFn = this.__isAsync ?
            /**
            * @param {?} value
            * @return {?}
            */
            function (value) {
              setTimeout(
              /**
              * @return {?}
              */
              function () {
                return generatorOrNext.next(value);
              });
            } :
            /**
            * @param {?} value
            * @return {?}
            */
            function (value) {
              generatorOrNext.next(value);
            };

            if (generatorOrNext.error) {
              errorFn = this.__isAsync ?
              /**
              * @param {?} err
              * @return {?}
              */
              function (err) {
                setTimeout(
                /**
                * @return {?}
                */
                function () {
                  return generatorOrNext.error(err);
                });
              } :
              /**
              * @param {?} err
              * @return {?}
              */
              function (err) {
                generatorOrNext.error(err);
              };
            }

            if (generatorOrNext.complete) {
              completeFn = this.__isAsync ?
              /**
              * @return {?}
              */
              function () {
                setTimeout(
                /**
                * @return {?}
                */
                function () {
                  return generatorOrNext.complete();
                });
              } :
              /**
              * @return {?}
              */
              function () {
                generatorOrNext.complete();
              };
            }
          } else {
            schedulerFn = this.__isAsync ?
            /**
            * @param {?} value
            * @return {?}
            */
            function (value) {
              setTimeout(
              /**
              * @return {?}
              */
              function () {
                return generatorOrNext(value);
              });
            } :
            /**
            * @param {?} value
            * @return {?}
            */
            function (value) {
              generatorOrNext(value);
            };

            if (error) {
              errorFn = this.__isAsync ?
              /**
              * @param {?} err
              * @return {?}
              */
              function (err) {
                setTimeout(
                /**
                * @return {?}
                */
                function () {
                  return error(err);
                });
              } :
              /**
              * @param {?} err
              * @return {?}
              */
              function (err) {
                error(err);
              };
            }

            if (complete) {
              completeFn = this.__isAsync ?
              /**
              * @return {?}
              */
              function () {
                setTimeout(
                /**
                * @return {?}
                */
                function () {
                  return complete();
                });
              } :
              /**
              * @return {?}
              */
              function () {
                complete();
              };
            }
          }
          /** @type {?} */


          var sink = _get(_getPrototypeOf(EventEmitter.prototype), "subscribe", this).call(this, schedulerFn, errorFn, completeFn);

          if (generatorOrNext instanceof rxjs__WEBPACK_IMPORTED_MODULE_0__["Subscription"]) {
            generatorOrNext.add(sink);
          }

          return sink;
        }
      }]);

      return EventEmitter;
    }(rxjs__WEBPACK_IMPORTED_MODULE_0__["Subject"]);

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/linker/query_list.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @template T
     * @this {?}
     * @return {?}
     */


    function symbolIterator() {
      return (
        /** @type {?} */

        /** @type {?} */

        /** @type {?} */
        this._results[getSymbolIterator()]()
      );
    }
    /**
     * An unmodifiable list of items that Angular keeps up to date when the state
     * of the application changes.
     *
     * The type of object that {\@link ViewChildren}, {\@link ContentChildren}, and {\@link QueryList}
     * provide.
     *
     * Implements an iterable interface, therefore it can be used in both ES6
     * javascript `for (var i of items)` loops as well as in Angular templates with
     * `*ngFor="let i of myList"`.
     *
     * Changes can be observed by subscribing to the changes `Observable`.
     *
     * NOTE: In the future this class will implement an `Observable` interface.
     *
     * \@usageNotes
     * ### Example
     * ```typescript
     * \@Component({...})
     * class Container {
     * \@ViewChildren(Item) items:QueryList<Item>;
     * }
     * ```
     *
     * \@publicApi
     * @template T
     */


    var QueryList = /*#__PURE__*/function () {
      function QueryList() {
        _classCallCheck(this, QueryList);

        this.dirty = true;
        this._results = [];
        this.changes = new EventEmitter();
        this.length = 0; // This function should be declared on the prototype, but doing so there will cause the class
        // declaration to have side-effects and become not tree-shakable. For this reason we do it in
        // the constructor.
        // [getSymbolIterator()](): Iterator<T> { ... }

        /** @type {?} */

        var symbol = getSymbolIterator();
        /** @type {?} */

        var proto =
        /** @type {?} */
        QueryList.prototype;
        if (!proto[symbol]) proto[symbol] = symbolIterator;
      }
      /**
       * See
       * [Array.map](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/map)
       * @template U
       * @param {?} fn
       * @return {?}
       */


      _createClass2(QueryList, [{
        key: "map",
        value: function map(fn) {
          return this._results.map(fn);
        }
        /**
         * See
         * [Array.filter](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/filter)
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "filter",
        value: function filter(fn) {
          return this._results.filter(fn);
        }
        /**
         * See
         * [Array.find](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/find)
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "find",
        value: function find(fn) {
          return this._results.find(fn);
        }
        /**
         * See
         * [Array.reduce](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/reduce)
         * @template U
         * @param {?} fn
         * @param {?} init
         * @return {?}
         */

      }, {
        key: "reduce",
        value: function reduce(fn, init) {
          return this._results.reduce(fn, init);
        }
        /**
         * See
         * [Array.forEach](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/forEach)
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "forEach",
        value: function forEach(fn) {
          this._results.forEach(fn);
        }
        /**
         * See
         * [Array.some](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/some)
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "some",
        value: function some(fn) {
          return this._results.some(fn);
        }
        /**
         * Returns a copy of the internal results list as an Array.
         * @return {?}
         */

      }, {
        key: "toArray",
        value: function toArray() {
          return this._results.slice();
        }
        /**
         * @return {?}
         */

      }, {
        key: "toString",
        value: function toString() {
          return this._results.toString();
        }
        /**
         * Updates the stored data of the query list, and resets the `dirty` flag to `false`, so that
         * on change detection, it will not notify of changes to the queries, unless a new change
         * occurs.
         *
         * @param {?} resultsTree The query results to store
         * @return {?}
         */

      }, {
        key: "reset",
        value: function reset(resultsTree) {
          this._results = flatten(resultsTree);

          /** @type {?} */
          this.dirty = false;

          /** @type {?} */
          this.length = this._results.length;

          /** @type {?} */
          this.last = this._results[this.length - 1];

          /** @type {?} */
          this.first = this._results[0];
        }
        /**
         * Triggers a change event by emitting on the `changes` {\@link EventEmitter}.
         * @return {?}
         */

      }, {
        key: "notifyOnChanges",
        value: function notifyOnChanges() {
          /** @type {?} */
          this.changes.emit(this);
        }
        /**
         * internal
         * @return {?}
         */

      }, {
        key: "setDirty",
        value: function setDirty() {
          /** @type {?} */
          this.dirty = true;
        }
        /**
         * internal
         * @return {?}
         */

      }, {
        key: "destroy",
        value: function destroy() {
          /** @type {?} */
          this.changes.complete();

          /** @type {?} */
          this.changes.unsubscribe();
        }
      }]);

      return QueryList;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/interfaces/definition.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** @enum {number} */


    var RenderFlags = {
      /* Whether to run the creation block (e.g. create elements and directives) */
      Create: 1,

      /* Whether to run the update block (e.g. refresh bindings) */
      Update: 2
    };
    /**
     * A subclass of `Type` which has a static `ɵcmp`:`ComponentDef` field making it
     * consumable for rendering.
     * @record
     * @template T
     */

    function ComponentType() {}

    if (false) {}
    /**
     * A subclass of `Type` which has a static `ɵdir`:`DirectiveDef` field making it
     * consumable for rendering.
     * @record
     * @template T
     */


    function DirectiveType() {}

    if (false) {}
    /**
     * A subclass of `Type` which has a static `ɵpipe`:`PipeDef` field making it
     * consumable for rendering.
     * @record
     * @template T
     */


    function PipeType() {}

    if (false) {}
    /**
     * Runtime link information for Directives.
     *
     * This is an internal data structure used by the render to link
     * directives into templates.
     *
     * NOTE: Always use `defineDirective` function to create this object,
     * never create the object directly since the shape of this object
     * can change between versions.
     *
     * @param Selector type metadata specifying the selector of the directive or component
     *
     * See: {\@link defineDirective}
     * @record
     * @template T
     */


    function DirectiveDef() {}

    if (false) {}
    /**
     * Runtime link information for Components.
     *
     * This is an internal data structure used by the render to link
     * components into templates.
     *
     * NOTE: Always use `defineComponent` function to create this object,
     * never create the object directly since the shape of this object
     * can change between versions.
     *
     * See: {\@link defineComponent}
     * @record
     * @template T
     */


    function ComponentDef() {}

    if (false) {}
    /**
     * Runtime link information for Pipes.
     *
     * This is an internal data structure used by the renderer to link
     * pipes into templates.
     *
     * NOTE: Always use `definePipe` function to create this object,
     * never create the object directly since the shape of this object
     * can change between versions.
     *
     * See: {\@link definePipe}
     * @record
     * @template T
     */


    function PipeDef() {}

    if (false) {}
    /**
     * @record
     */


    function DirectiveDefFeature() {}

    if (false) {}
    /**
     * @record
     */


    function ComponentDefFeature() {}

    if (false) {} // Note: This hack is necessary so we don't erroneously get a circular dependency
    // failure based on types.

    /** @type {?} */


    var unusedValueExportToPlacateAjd$7 = 1;
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/interfaces/query.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * An object representing query metadata extracted from query annotations.
     * @record
     */

    function TQueryMetadata() {}

    if (false) {}
    /**
     * TQuery objects represent all the query-related data that remain the same from one view instance
     * to another and can be determined on the very first template pass. Most notably TQuery holds all
     * the matches for a given view.
     * @record
     */


    function TQuery() {}

    if (false) {}
    /**
     * TQueries represent a collection of individual TQuery objects tracked in a given view. Most of the
     * methods on this interface are simple proxy methods to the corresponding functionality on TQuery.
     * @record
     */


    function TQueries() {}

    if (false) {}
    /**
     * An interface that represents query-related information specific to a view instance. Most notably
     * it contains:
     * - materialized query matches;
     * - a pointer to a QueryList where materialized query results should be reported.
     * @record
     * @template T
     */


    function LQuery() {}

    if (false) {}
    /**
     * lQueries represent a collection of individual LQuery objects tracked in a given view.
     * @record
     */


    function LQueries() {}

    if (false) {} // Note: This hack is necessary so we don't erroneously get a circular dependency
    // failure based on types.

    /** @type {?} */


    var unusedValueExportToPlacateAjd$8 = 1;
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/query.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */

    var unusedValueToPlacateAjd$2 = unusedValueExportToPlacateAjd$7 + unusedValueExportToPlacateAjd$3 + unusedValueExportToPlacateAjd$4 + unusedValueExportToPlacateAjd$8;
    /**
     * @template T
     */

    var LQuery_ = /*#__PURE__*/function () {
      /**
       * @param {?} queryList
       */
      function LQuery_(queryList) {
        _classCallCheck(this, LQuery_);

        this.queryList = queryList;
        this.matches = null;
      }
      /**
       * @return {?}
       */


      _createClass2(LQuery_, [{
        key: "clone",
        value: function clone() {
          return new LQuery_(this.queryList);
        }
        /**
         * @return {?}
         */

      }, {
        key: "setDirty",
        value: function setDirty() {
          this.queryList.setDirty();
        }
      }]);

      return LQuery_;
    }();

    if (false) {}

    var LQueries_ = /*#__PURE__*/function () {
      /**
       * @param {?=} queries
       */
      function LQueries_() {
        var queries = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];

        _classCallCheck(this, LQueries_);

        this.queries = queries;
      }
      /**
       * @param {?} tView
       * @return {?}
       */


      _createClass2(LQueries_, [{
        key: "createEmbeddedView",
        value: function createEmbeddedView(tView) {
          /** @type {?} */
          var tQueries = tView.queries;

          if (tQueries !== null) {
            /** @type {?} */
            var noOfInheritedQueries = tView.contentQueries !== null ? tView.contentQueries[0] : tQueries.length;
            /** @type {?} */

            var viewLQueries = []; // An embedded view has queries propagated from a declaration view at the beginning of the
            // TQueries collection and up until a first content query declared in the embedded view. Only
            // propagated LQueries are created at this point (LQuery corresponding to declared content
            // queries will be instantiated from the content query instructions for each directive).

            for (var i = 0; i < noOfInheritedQueries; i++) {
              /** @type {?} */
              var tQuery = tQueries.getByIndex(i);
              /** @type {?} */

              var parentLQuery = this.queries[tQuery.indexInDeclarationView];
              viewLQueries.push(parentLQuery.clone());
            }

            return new LQueries_(viewLQueries);
          }

          return null;
        }
        /**
         * @param {?} tView
         * @return {?}
         */

      }, {
        key: "insertView",
        value: function insertView(tView) {
          this.dirtyQueriesWithMatches(tView);
        }
        /**
         * @param {?} tView
         * @return {?}
         */

      }, {
        key: "detachView",
        value: function detachView(tView) {
          this.dirtyQueriesWithMatches(tView);
        }
        /**
         * @private
         * @param {?} tView
         * @return {?}
         */

      }, {
        key: "dirtyQueriesWithMatches",
        value: function dirtyQueriesWithMatches(tView) {
          for (var i = 0; i < this.queries.length; i++) {
            if (getTQuery(tView, i).matches !== null) {
              this.queries[i].setDirty();
            }
          }
        }
      }]);

      return LQueries_;
    }();

    if (false) {}

    var TQueryMetadata_ =
    /**
     * @param {?} predicate
     * @param {?} descendants
     * @param {?} isStatic
     * @param {?=} read
     */
    function TQueryMetadata_(predicate, descendants, isStatic) {
      var read = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : null;

      _classCallCheck(this, TQueryMetadata_);

      this.predicate = predicate;
      this.descendants = descendants;
      this.isStatic = isStatic;
      this.read = read;
    };

    if (false) {}

    var TQueries_ = /*#__PURE__*/function () {
      /**
       * @param {?=} queries
       */
      function TQueries_() {
        var queries = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];

        _classCallCheck(this, TQueries_);

        this.queries = queries;
      }
      /**
       * @param {?} tView
       * @param {?} tNode
       * @return {?}
       */


      _createClass2(TQueries_, [{
        key: "elementStart",
        value: function elementStart(tView, tNode) {
          ngDevMode && assertFirstCreatePass(tView, 'Queries should collect results on the first template pass only');

          for (var i = 0; i < this.queries.length; i++) {
            this.queries[i].elementStart(tView, tNode);
          }
        }
        /**
         * @param {?} tNode
         * @return {?}
         */

      }, {
        key: "elementEnd",
        value: function elementEnd(tNode) {
          for (var i = 0; i < this.queries.length; i++) {
            this.queries[i].elementEnd(tNode);
          }
        }
        /**
         * @param {?} tNode
         * @return {?}
         */

      }, {
        key: "embeddedTView",
        value: function embeddedTView(tNode) {
          /** @type {?} */
          var queriesForTemplateRef = null;

          for (var i = 0; i < this.length; i++) {
            /** @type {?} */
            var childQueryIndex = queriesForTemplateRef !== null ? queriesForTemplateRef.length : 0;
            /** @type {?} */

            var tqueryClone = this.getByIndex(i).embeddedTView(tNode, childQueryIndex);

            if (tqueryClone) {
              tqueryClone.indexInDeclarationView = i;

              if (queriesForTemplateRef !== null) {
                queriesForTemplateRef.push(tqueryClone);
              } else {
                queriesForTemplateRef = [tqueryClone];
              }
            }
          }

          return queriesForTemplateRef !== null ? new TQueries_(queriesForTemplateRef) : null;
        }
        /**
         * @param {?} tView
         * @param {?} tNode
         * @return {?}
         */

      }, {
        key: "template",
        value: function template(tView, tNode) {
          ngDevMode && assertFirstCreatePass(tView, 'Queries should collect results on the first template pass only');

          for (var i = 0; i < this.queries.length; i++) {
            this.queries[i].template(tView, tNode);
          }
        }
        /**
         * @param {?} index
         * @return {?}
         */

      }, {
        key: "getByIndex",
        value: function getByIndex(index) {
          ngDevMode && assertDataInRange(this.queries, index);
          return this.queries[index];
        }
        /**
         * @return {?}
         */

      }, {
        key: "track",

        /**
         * @param {?} tquery
         * @return {?}
         */
        value: function track(tquery) {
          this.queries.push(tquery);
        }
      }, {
        key: "length",
        get: function get() {
          return this.queries.length;
        }
      }]);

      return TQueries_;
    }();

    if (false) {}

    var TQuery_ = /*#__PURE__*/function () {
      /**
       * @param {?} metadata
       * @param {?=} nodeIndex
       */
      function TQuery_(metadata) {
        var nodeIndex = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : -1;

        _classCallCheck(this, TQuery_);

        this.metadata = metadata;
        this.matches = null;
        this.indexInDeclarationView = -1;
        this.crossesNgTemplate = false;
        /**
         * A flag indicating if a given query still applies to nodes it is crossing. We use this flag
         * (alongside with _declarationNodeIndex) to know when to stop applying content queries to
         * elements in a template.
         */

        this._appliesToNextNode = true;
        this._declarationNodeIndex = nodeIndex;
      }
      /**
       * @param {?} tView
       * @param {?} tNode
       * @return {?}
       */


      _createClass2(TQuery_, [{
        key: "elementStart",
        value: function elementStart(tView, tNode) {
          if (this.isApplyingToNode(tNode)) {
            this.matchTNode(tView, tNode);
          }
        }
        /**
         * @param {?} tNode
         * @return {?}
         */

      }, {
        key: "elementEnd",
        value: function elementEnd(tNode) {
          if (this._declarationNodeIndex === tNode.index) {
            this._appliesToNextNode = false;
          }
        }
        /**
         * @param {?} tView
         * @param {?} tNode
         * @return {?}
         */

      }, {
        key: "template",
        value: function template(tView, tNode) {
          this.elementStart(tView, tNode);
        }
        /**
         * @param {?} tNode
         * @param {?} childQueryIndex
         * @return {?}
         */

      }, {
        key: "embeddedTView",
        value: function embeddedTView(tNode, childQueryIndex) {
          if (this.isApplyingToNode(tNode)) {
            this.crossesNgTemplate = true; // A marker indicating a `<ng-template>` element (a placeholder for query results from
            // embedded views created based on this `<ng-template>`).

            this.addMatch(-tNode.index, childQueryIndex);
            return new TQuery_(this.metadata);
          }

          return null;
        }
        /**
         * @private
         * @param {?} tNode
         * @return {?}
         */

      }, {
        key: "isApplyingToNode",
        value: function isApplyingToNode(tNode) {
          if (this._appliesToNextNode && this.metadata.descendants === false) {
            /** @type {?} */
            var declarationNodeIdx = this._declarationNodeIndex;
            /** @type {?} */

            var parent = tNode.parent; // Determine if a given TNode is a "direct" child of a node on which a content query was
            // declared (only direct children of query's host node can match with the descendants: false
            // option). There are 3 main use-case / conditions to consider here:
            // - <needs-target><i #target></i></needs-target>: here <i #target> parent node is a query
            // host node;
            // - <needs-target><ng-template [ngIf]="true"><i #target></i></ng-template></needs-target>:
            // here <i #target> parent node is null;
            // - <needs-target><ng-container><i #target></i></ng-container></needs-target>: here we need
            // to go past `<ng-container>` to determine <i #target> parent node (but we shouldn't traverse
            // up past the query's host node!).

            while (parent !== null && parent.type === 4
            /* ElementContainer */
            && parent.index !== declarationNodeIdx) {
              parent = parent.parent;
            }

            return declarationNodeIdx === (parent !== null ? parent.index : -1);
          }

          return this._appliesToNextNode;
        }
        /**
         * @private
         * @param {?} tView
         * @param {?} tNode
         * @return {?}
         */

      }, {
        key: "matchTNode",
        value: function matchTNode(tView, tNode) {
          if (Array.isArray(this.metadata.predicate)) {
            /** @type {?} */
            var localNames = this.metadata.predicate;

            for (var i = 0; i < localNames.length; i++) {
              this.matchTNodeWithReadOption(tView, tNode, getIdxOfMatchingSelector(tNode, localNames[i]));
            }
          } else {
            /** @type {?} */
            var typePredicate =
            /** @type {?} */
            this.metadata.predicate;

            if (typePredicate === TemplateRef) {
              if (tNode.type === 0
              /* Container */
              ) {
                  this.matchTNodeWithReadOption(tView, tNode, -1);
                }
            } else {
              this.matchTNodeWithReadOption(tView, tNode, locateDirectiveOrProvider(tNode, tView, typePredicate, false, false));
            }
          }
        }
        /**
         * @private
         * @param {?} tView
         * @param {?} tNode
         * @param {?} nodeMatchIdx
         * @return {?}
         */

      }, {
        key: "matchTNodeWithReadOption",
        value: function matchTNodeWithReadOption(tView, tNode, nodeMatchIdx) {
          if (nodeMatchIdx !== null) {
            /** @type {?} */
            var read = this.metadata.read;

            if (read !== null) {
              if (read === ElementRef || read === ViewContainerRef || read === TemplateRef && tNode.type === 0
              /* Container */
              ) {
                  this.addMatch(tNode.index, -2);
                } else {
                /** @type {?} */
                var directiveOrProviderIdx = locateDirectiveOrProvider(tNode, tView, read, false, false);

                if (directiveOrProviderIdx !== null) {
                  this.addMatch(tNode.index, directiveOrProviderIdx);
                }
              }
            } else {
              this.addMatch(tNode.index, nodeMatchIdx);
            }
          }
        }
        /**
         * @private
         * @param {?} tNodeIdx
         * @param {?} matchIdx
         * @return {?}
         */

      }, {
        key: "addMatch",
        value: function addMatch(tNodeIdx, matchIdx) {
          if (this.matches === null) {
            this.matches = [tNodeIdx, matchIdx];
          } else {
            this.matches.push(tNodeIdx, matchIdx);
          }
        }
      }]);

      return TQuery_;
    }();

    if (false) {}
    /**
     * Iterates over local names for a given node and returns directive index
     * (or -1 if a local name points to an element).
     *
     * @param {?} tNode static data of a node to check
     * @param {?} selector selector to match
     * @return {?} directive index, -1 or null if a selector didn't match any of the local names
     */


    function getIdxOfMatchingSelector(tNode, selector) {
      /** @type {?} */
      var localNames = tNode.localNames;

      if (localNames !== null) {
        for (var i = 0; i < localNames.length; i += 2) {
          if (localNames[i] === selector) {
            return (
              /** @type {?} */
              localNames[i + 1]
            );
          }
        }
      }

      return null;
    }
    /**
     * @param {?} tNode
     * @param {?} currentView
     * @return {?}
     */


    function createResultByTNodeType(tNode, currentView) {
      if (tNode.type === 3
      /* Element */
      || tNode.type === 4
      /* ElementContainer */
      ) {
          return createElementRef(ElementRef, tNode, currentView);
        } else if (tNode.type === 0
      /* Container */
      ) {
          return createTemplateRef(TemplateRef, ElementRef, tNode, currentView);
        }

      return null;
    }
    /**
     * @param {?} lView
     * @param {?} tNode
     * @param {?} matchingIdx
     * @param {?} read
     * @return {?}
     */


    function createResultForNode(lView, tNode, matchingIdx, read) {
      if (matchingIdx === -1) {
        // if read token and / or strategy is not specified, detect it using appropriate tNode type
        return createResultByTNodeType(tNode, lView);
      } else if (matchingIdx === -2) {
        // read a special token from a node injector
        return createSpecialToken(lView, tNode, read);
      } else {
        // read a token
        return getNodeInjectable(lView, lView[TVIEW], matchingIdx,
        /** @type {?} */
        tNode);
      }
    }
    /**
     * @param {?} lView
     * @param {?} tNode
     * @param {?} read
     * @return {?}
     */


    function createSpecialToken(lView, tNode, read) {
      if (read === ElementRef) {
        return createElementRef(ElementRef, tNode, lView);
      } else if (read === TemplateRef) {
        return createTemplateRef(TemplateRef, ElementRef, tNode, lView);
      } else if (read === ViewContainerRef) {
        ngDevMode && assertNodeOfPossibleTypes(tNode, 3
        /* Element */
        , 0
        /* Container */
        , 4
        /* ElementContainer */
        );
        return createContainerRef(ViewContainerRef, ElementRef,
        /** @type {?} */
        tNode, lView);
      } else {
        ngDevMode && throwError("Special token to read should be one of ElementRef, TemplateRef or ViewContainerRef but got ".concat(stringify(read), "."));
      }
    }
    /**
     * A helper function that creates query results for a given view. This function is meant to do the
     * processing once and only once for a given view instance (a set of results for a given view
     * doesn't change).
     * @template T
     * @param {?} tView
     * @param {?} lView
     * @param {?} tQuery
     * @param {?} queryIndex
     * @return {?}
     */


    function materializeViewResults(tView, lView, tQuery, queryIndex) {
      /** @type {?} */
      var lQuery =
      /** @type {?} */

      /** @type {?} */
      lView[QUERIES].queries[queryIndex];

      if (lQuery.matches === null) {
        /** @type {?} */
        var tViewData = tView.data;
        /** @type {?} */

        var tQueryMatches =
        /** @type {?} */
        tQuery.matches;
        /** @type {?} */

        var result = [];

        for (var i = 0; i < tQueryMatches.length; i += 2) {
          /** @type {?} */
          var matchedNodeIdx = tQueryMatches[i];

          if (matchedNodeIdx < 0) {
            // we at the <ng-template> marker which might have results in views created based on this
            // <ng-template> - those results will be in separate views though, so here we just leave
            // null as a placeholder
            result.push(null);
          } else {
            ngDevMode && assertDataInRange(tViewData, matchedNodeIdx);
            /** @type {?} */

            var tNode =
            /** @type {?} */
            tViewData[matchedNodeIdx];
            result.push(createResultForNode(lView, tNode, tQueryMatches[i + 1], tQuery.metadata.read));
          }
        }

        lQuery.matches = result;
      }

      return lQuery.matches;
    }
    /**
     * A helper function that collects (already materialized) query results from a tree of views,
     * starting with a provided LView.
     * @template T
     * @param {?} tView
     * @param {?} lView
     * @param {?} queryIndex
     * @param {?} result
     * @return {?}
     */


    function collectQueryResults(tView, lView, queryIndex, result) {
      /** @type {?} */
      var tQuery =
      /** @type {?} */
      tView.queries.getByIndex(queryIndex);
      /** @type {?} */

      var tQueryMatches = tQuery.matches;

      if (tQueryMatches !== null) {
        /** @type {?} */
        var lViewResults = materializeViewResults(tView, lView, tQuery, queryIndex);

        for (var i = 0; i < tQueryMatches.length; i += 2) {
          /** @type {?} */
          var tNodeIdx = tQueryMatches[i];

          if (tNodeIdx > 0) {
            result.push(
            /** @type {?} */
            lViewResults[i / 2]);
          } else {
            /** @type {?} */
            var childQueryIndex = tQueryMatches[i + 1];
            /** @type {?} */

            var declarationLContainer =
            /** @type {?} */
            lView[-tNodeIdx];
            ngDevMode && assertLContainer(declarationLContainer); // collect matches for views inserted in this container

            for (var _i16 = CONTAINER_HEADER_OFFSET; _i16 < declarationLContainer.length; _i16++) {
              /** @type {?} */
              var embeddedLView = declarationLContainer[_i16];

              if (embeddedLView[DECLARATION_LCONTAINER] === embeddedLView[PARENT]) {
                collectQueryResults(embeddedLView[TVIEW], embeddedLView, childQueryIndex, result);
              }
            } // collect matches for views created from this declaration container and inserted into
            // different containers


            if (declarationLContainer[MOVED_VIEWS] !== null) {
              /** @type {?} */
              var embeddedLViews =
              /** @type {?} */
              declarationLContainer[MOVED_VIEWS];

              for (var _i17 = 0; _i17 < embeddedLViews.length; _i17++) {
                /** @type {?} */
                var _embeddedLView = embeddedLViews[_i17];
                collectQueryResults(_embeddedLView[TVIEW], _embeddedLView, childQueryIndex, result);
              }
            }
          }
        }
      }

      return result;
    }
    /**
     * Refreshes a query by combining matches from all active views and removing matches from deleted
     * views.
     *
     * \@codeGenApi
     * @param {?} queryList
     * @return {?} `true` if a query got dirty during change detection or if this is a static query
     * resolving in creation mode, `false` otherwise.
     *
     */


    function ɵɵqueryRefresh(queryList) {
      /** @type {?} */
      var lView = getLView();
      /** @type {?} */

      var tView = getTView();
      /** @type {?} */

      var queryIndex = getCurrentQueryIndex();
      setCurrentQueryIndex(queryIndex + 1);
      /** @type {?} */

      var tQuery = getTQuery(tView, queryIndex);

      if (queryList.dirty && isCreationMode(lView) === tQuery.metadata.isStatic) {
        if (tQuery.matches === null) {
          queryList.reset([]);
        } else {
          /** @type {?} */
          var result = tQuery.crossesNgTemplate ? collectQueryResults(tView, lView, queryIndex, []) : materializeViewResults(tView, lView, tQuery, queryIndex);
          queryList.reset(result);
          queryList.notifyOnChanges();
        }

        return true;
      }

      return false;
    }
    /**
     * Creates new QueryList for a static view query.
     *
     * \@codeGenApi
     * @template T
     * @param {?} predicate The type for which the query will search
     * @param {?} descend Whether or not to descend into children
     * @param {?=} read What to save in the query
     *
     * @return {?}
     */


    function ɵɵstaticViewQuery(predicate, descend, read) {
      viewQueryInternal(getTView(), getLView(), predicate, descend, read, true);
    }
    /**
     * Creates new QueryList, stores the reference in LView and returns QueryList.
     *
     * \@codeGenApi
     * @template T
     * @param {?} predicate The type for which the query will search
     * @param {?} descend Whether or not to descend into children
     * @param {?=} read What to save in the query
     *
     * @return {?}
     */


    function ɵɵviewQuery(predicate, descend, read) {
      viewQueryInternal(getTView(), getLView(), predicate, descend, read, false);
    }
    /**
     * @template T
     * @param {?} tView
     * @param {?} lView
     * @param {?} predicate
     * @param {?} descend
     * @param {?} read
     * @param {?} isStatic
     * @return {?}
     */


    function viewQueryInternal(tView, lView, predicate, descend, read, isStatic) {
      if (tView.firstCreatePass) {
        createTQuery(tView, new TQueryMetadata_(predicate, descend, isStatic, read), -1);

        if (isStatic) {
          tView.staticViewQueries = true;
        }
      }

      createLQuery(tView, lView);
    }
    /**
     * Registers a QueryList, associated with a content query, for later refresh (part of a view
     * refresh).
     *
     * \@codeGenApi
     * @template T
     * @param {?} directiveIndex Current directive index
     * @param {?} predicate The type for which the query will search
     * @param {?} descend Whether or not to descend into children
     * @param {?=} read What to save in the query
     * @return {?} QueryList<T>
     *
     */


    function ɵɵcontentQuery(directiveIndex, predicate, descend, read) {
      contentQueryInternal(getTView(), getLView(), predicate, descend, read, false, getPreviousOrParentTNode(), directiveIndex);
    }
    /**
     * Registers a QueryList, associated with a static content query, for later refresh
     * (part of a view refresh).
     *
     * \@codeGenApi
     * @template T
     * @param {?} directiveIndex Current directive index
     * @param {?} predicate The type for which the query will search
     * @param {?} descend Whether or not to descend into children
     * @param {?=} read What to save in the query
     * @return {?} QueryList<T>
     *
     */


    function ɵɵstaticContentQuery(directiveIndex, predicate, descend, read) {
      contentQueryInternal(getTView(), getLView(), predicate, descend, read, true, getPreviousOrParentTNode(), directiveIndex);
    }
    /**
     * @template T
     * @param {?} tView
     * @param {?} lView
     * @param {?} predicate
     * @param {?} descend
     * @param {?} read
     * @param {?} isStatic
     * @param {?} tNode
     * @param {?} directiveIndex
     * @return {?}
     */


    function contentQueryInternal(tView, lView, predicate, descend, read, isStatic, tNode, directiveIndex) {
      if (tView.firstCreatePass) {
        createTQuery(tView, new TQueryMetadata_(predicate, descend, isStatic, read), tNode.index);
        saveContentQueryAndDirectiveIndex(tView, directiveIndex);

        if (isStatic) {
          tView.staticContentQueries = true;
        }
      }

      createLQuery(tView, lView);
    }
    /**
     * Loads a QueryList corresponding to the current view or content query.
     *
     * \@codeGenApi
     * @template T
     * @return {?}
     */


    function ɵɵloadQuery() {
      return loadQueryInternal(getLView(), getCurrentQueryIndex());
    }
    /**
     * @template T
     * @param {?} lView
     * @param {?} queryIndex
     * @return {?}
     */


    function loadQueryInternal(lView, queryIndex) {
      ngDevMode && assertDefined(lView[QUERIES], 'LQueries should be defined when trying to load a query');
      ngDevMode && assertDataInRange(
      /** @type {?} */
      lView[QUERIES].queries, queryIndex);
      return (
        /** @type {?} */
        lView[QUERIES].queries[queryIndex].queryList
      );
    }
    /**
     * @template T
     * @param {?} tView
     * @param {?} lView
     * @return {?}
     */


    function createLQuery(tView, lView) {
      /** @type {?} */
      var queryList = new QueryList();
      storeCleanupWithContext(tView, lView, queryList, queryList.destroy);
      if (lView[QUERIES] === null) lView[QUERIES] = new LQueries_();

      /** @type {?} */
      lView[QUERIES].queries.push(new LQuery_(queryList));
    }
    /**
     * @param {?} tView
     * @param {?} metadata
     * @param {?} nodeIndex
     * @return {?}
     */


    function createTQuery(tView, metadata, nodeIndex) {
      if (tView.queries === null) tView.queries = new TQueries_();
      tView.queries.track(new TQuery_(metadata, nodeIndex));
    }
    /**
     * @param {?} tView
     * @param {?} directiveIndex
     * @return {?}
     */


    function saveContentQueryAndDirectiveIndex(tView, directiveIndex) {
      /** @type {?} */
      var tViewContentQueries = tView.contentQueries || (tView.contentQueries = []);
      /** @type {?} */

      var lastSavedDirectiveIndex = tView.contentQueries.length ? tViewContentQueries[tViewContentQueries.length - 1] : -1;

      if (directiveIndex !== lastSavedDirectiveIndex) {
        tViewContentQueries.push(
        /** @type {?} */
        tView.queries.length - 1, directiveIndex);
      }
    }
    /**
     * @param {?} tView
     * @param {?} index
     * @return {?}
     */


    function getTQuery(tView, index) {
      ngDevMode && assertDefined(tView.queries, 'TQueries must be defined to retrieve a TQuery');
      return (
        /** @type {?} */
        tView.queries.getByIndex(index)
      );
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/view_engine_compatibility_prebound.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Retrieves `TemplateRef` instance from `Injector` when a local reference is placed on the
     * `<ng-template>` element.
     *
     * \@codeGenApi
     * @param {?} tNode
     * @param {?} currentView
     * @return {?}
     */


    function ɵɵtemplateRefExtractor(tNode, currentView) {
      return createTemplateRef(TemplateRef, ElementRef, tNode, currentView);
    }
    /**
     * Returns the appropriate `ChangeDetectorRef` for a pipe.
     *
     * \@codeGenApi
     * @param {?=} flags
     * @return {?}
     */


    function ɵɵinjectPipeChangeDetectorRef() {
      var flags = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : InjectFlags.Default;

      /** @type {?} */
      var value = injectChangeDetectorRef(true);

      if (value == null && !(flags & InjectFlags.Optional)) {
        throw new Error("No provider for ChangeDetectorRef!");
      } else {
        return value;
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/jit/environment.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var ɵ0$d =
    /**
    * @return {?}
    */
    function ɵ0$d() {
      return {
        'ɵɵattribute': ɵɵattribute,
        'ɵɵattributeInterpolate1': ɵɵattributeInterpolate1,
        'ɵɵattributeInterpolate2': ɵɵattributeInterpolate2,
        'ɵɵattributeInterpolate3': ɵɵattributeInterpolate3,
        'ɵɵattributeInterpolate4': ɵɵattributeInterpolate4,
        'ɵɵattributeInterpolate5': ɵɵattributeInterpolate5,
        'ɵɵattributeInterpolate6': ɵɵattributeInterpolate6,
        'ɵɵattributeInterpolate7': ɵɵattributeInterpolate7,
        'ɵɵattributeInterpolate8': ɵɵattributeInterpolate8,
        'ɵɵattributeInterpolateV': ɵɵattributeInterpolateV,
        'ɵɵdefineComponent': ɵɵdefineComponent,
        'ɵɵdefineDirective': ɵɵdefineDirective,
        'ɵɵdefineInjectable': ɵɵdefineInjectable,
        'ɵɵdefineInjector': ɵɵdefineInjector,
        'ɵɵdefineNgModule': ɵɵdefineNgModule,
        'ɵɵdefinePipe': ɵɵdefinePipe,
        'ɵɵdirectiveInject': ɵɵdirectiveInject,
        'ɵɵgetFactoryOf': ɵɵgetFactoryOf,
        'ɵɵgetInheritedFactory': ɵɵgetInheritedFactory,
        'ɵɵinject': ɵɵinject,
        'ɵɵinjectAttribute': ɵɵinjectAttribute,
        'ɵɵinvalidFactory': ɵɵinvalidFactory,
        'ɵɵinvalidFactoryDep': ɵɵinvalidFactoryDep,
        'ɵɵinjectPipeChangeDetectorRef': ɵɵinjectPipeChangeDetectorRef,
        'ɵɵtemplateRefExtractor': ɵɵtemplateRefExtractor,
        'ɵɵNgOnChangesFeature': ɵɵNgOnChangesFeature,
        'ɵɵProvidersFeature': ɵɵProvidersFeature,
        'ɵɵCopyDefinitionFeature': ɵɵCopyDefinitionFeature,
        'ɵɵInheritDefinitionFeature': ɵɵInheritDefinitionFeature,
        'ɵɵcontainer': ɵɵcontainer,
        'ɵɵnextContext': ɵɵnextContext,
        'ɵɵcontainerRefreshStart': ɵɵcontainerRefreshStart,
        'ɵɵcontainerRefreshEnd': ɵɵcontainerRefreshEnd,
        'ɵɵnamespaceHTML': ɵɵnamespaceHTML,
        'ɵɵnamespaceMathML': ɵɵnamespaceMathML,
        'ɵɵnamespaceSVG': ɵɵnamespaceSVG,
        'ɵɵenableBindings': ɵɵenableBindings,
        'ɵɵdisableBindings': ɵɵdisableBindings,
        'ɵɵelementStart': ɵɵelementStart,
        'ɵɵelementEnd': ɵɵelementEnd,
        'ɵɵelement': ɵɵelement,
        'ɵɵelementContainerStart': ɵɵelementContainerStart,
        'ɵɵelementContainerEnd': ɵɵelementContainerEnd,
        'ɵɵelementContainer': ɵɵelementContainer,
        'ɵɵpureFunction0': ɵɵpureFunction0,
        'ɵɵpureFunction1': ɵɵpureFunction1,
        'ɵɵpureFunction2': ɵɵpureFunction2,
        'ɵɵpureFunction3': ɵɵpureFunction3,
        'ɵɵpureFunction4': ɵɵpureFunction4,
        'ɵɵpureFunction5': ɵɵpureFunction5,
        'ɵɵpureFunction6': ɵɵpureFunction6,
        'ɵɵpureFunction7': ɵɵpureFunction7,
        'ɵɵpureFunction8': ɵɵpureFunction8,
        'ɵɵpureFunctionV': ɵɵpureFunctionV,
        'ɵɵgetCurrentView': ɵɵgetCurrentView,
        'ɵɵrestoreView': ɵɵrestoreView,
        'ɵɵlistener': ɵɵlistener,
        'ɵɵprojection': ɵɵprojection,
        'ɵɵupdateSyntheticHostBinding': ɵɵupdateSyntheticHostBinding,
        'ɵɵcomponentHostSyntheticListener': ɵɵcomponentHostSyntheticListener,
        'ɵɵpipeBind1': ɵɵpipeBind1,
        'ɵɵpipeBind2': ɵɵpipeBind2,
        'ɵɵpipeBind3': ɵɵpipeBind3,
        'ɵɵpipeBind4': ɵɵpipeBind4,
        'ɵɵpipeBindV': ɵɵpipeBindV,
        'ɵɵprojectionDef': ɵɵprojectionDef,
        'ɵɵhostProperty': ɵɵhostProperty,
        'ɵɵproperty': ɵɵproperty,
        'ɵɵpropertyInterpolate': ɵɵpropertyInterpolate,
        'ɵɵpropertyInterpolate1': ɵɵpropertyInterpolate1,
        'ɵɵpropertyInterpolate2': ɵɵpropertyInterpolate2,
        'ɵɵpropertyInterpolate3': ɵɵpropertyInterpolate3,
        'ɵɵpropertyInterpolate4': ɵɵpropertyInterpolate4,
        'ɵɵpropertyInterpolate5': ɵɵpropertyInterpolate5,
        'ɵɵpropertyInterpolate6': ɵɵpropertyInterpolate6,
        'ɵɵpropertyInterpolate7': ɵɵpropertyInterpolate7,
        'ɵɵpropertyInterpolate8': ɵɵpropertyInterpolate8,
        'ɵɵpropertyInterpolateV': ɵɵpropertyInterpolateV,
        'ɵɵpipe': ɵɵpipe,
        'ɵɵqueryRefresh': ɵɵqueryRefresh,
        'ɵɵviewQuery': ɵɵviewQuery,
        'ɵɵstaticViewQuery': ɵɵstaticViewQuery,
        'ɵɵstaticContentQuery': ɵɵstaticContentQuery,
        'ɵɵloadQuery': ɵɵloadQuery,
        'ɵɵcontentQuery': ɵɵcontentQuery,
        'ɵɵreference': ɵɵreference,
        'ɵɵclassMap': ɵɵclassMap,
        'ɵɵclassMapInterpolate1': ɵɵclassMapInterpolate1,
        'ɵɵclassMapInterpolate2': ɵɵclassMapInterpolate2,
        'ɵɵclassMapInterpolate3': ɵɵclassMapInterpolate3,
        'ɵɵclassMapInterpolate4': ɵɵclassMapInterpolate4,
        'ɵɵclassMapInterpolate5': ɵɵclassMapInterpolate5,
        'ɵɵclassMapInterpolate6': ɵɵclassMapInterpolate6,
        'ɵɵclassMapInterpolate7': ɵɵclassMapInterpolate7,
        'ɵɵclassMapInterpolate8': ɵɵclassMapInterpolate8,
        'ɵɵclassMapInterpolateV': ɵɵclassMapInterpolateV,
        'ɵɵstyleMap': ɵɵstyleMap,
        'ɵɵstyleMapInterpolate1': ɵɵstyleMapInterpolate1,
        'ɵɵstyleMapInterpolate2': ɵɵstyleMapInterpolate2,
        'ɵɵstyleMapInterpolate3': ɵɵstyleMapInterpolate3,
        'ɵɵstyleMapInterpolate4': ɵɵstyleMapInterpolate4,
        'ɵɵstyleMapInterpolate5': ɵɵstyleMapInterpolate5,
        'ɵɵstyleMapInterpolate6': ɵɵstyleMapInterpolate6,
        'ɵɵstyleMapInterpolate7': ɵɵstyleMapInterpolate7,
        'ɵɵstyleMapInterpolate8': ɵɵstyleMapInterpolate8,
        'ɵɵstyleMapInterpolateV': ɵɵstyleMapInterpolateV,
        'ɵɵstyleProp': ɵɵstyleProp,
        'ɵɵstylePropInterpolate1': ɵɵstylePropInterpolate1,
        'ɵɵstylePropInterpolate2': ɵɵstylePropInterpolate2,
        'ɵɵstylePropInterpolate3': ɵɵstylePropInterpolate3,
        'ɵɵstylePropInterpolate4': ɵɵstylePropInterpolate4,
        'ɵɵstylePropInterpolate5': ɵɵstylePropInterpolate5,
        'ɵɵstylePropInterpolate6': ɵɵstylePropInterpolate6,
        'ɵɵstylePropInterpolate7': ɵɵstylePropInterpolate7,
        'ɵɵstylePropInterpolate8': ɵɵstylePropInterpolate8,
        'ɵɵstylePropInterpolateV': ɵɵstylePropInterpolateV,
        'ɵɵstyleSanitizer': ɵɵstyleSanitizer,
        'ɵɵclassProp': ɵɵclassProp,
        'ɵɵselect': ɵɵselect,
        'ɵɵadvance': ɵɵadvance,
        'ɵɵtemplate': ɵɵtemplate,
        'ɵɵtext': ɵɵtext,
        'ɵɵtextInterpolate': ɵɵtextInterpolate,
        'ɵɵtextInterpolate1': ɵɵtextInterpolate1,
        'ɵɵtextInterpolate2': ɵɵtextInterpolate2,
        'ɵɵtextInterpolate3': ɵɵtextInterpolate3,
        'ɵɵtextInterpolate4': ɵɵtextInterpolate4,
        'ɵɵtextInterpolate5': ɵɵtextInterpolate5,
        'ɵɵtextInterpolate6': ɵɵtextInterpolate6,
        'ɵɵtextInterpolate7': ɵɵtextInterpolate7,
        'ɵɵtextInterpolate8': ɵɵtextInterpolate8,
        'ɵɵtextInterpolateV': ɵɵtextInterpolateV,
        'ɵɵembeddedViewStart': ɵɵembeddedViewStart,
        'ɵɵembeddedViewEnd': ɵɵembeddedViewEnd,
        'ɵɵi18n': ɵɵi18n,
        'ɵɵi18nAttributes': ɵɵi18nAttributes,
        'ɵɵi18nExp': ɵɵi18nExp,
        'ɵɵi18nStart': ɵɵi18nStart,
        'ɵɵi18nEnd': ɵɵi18nEnd,
        'ɵɵi18nApply': ɵɵi18nApply,
        'ɵɵi18nPostprocess': ɵɵi18nPostprocess,
        'ɵɵresolveWindow': ɵɵresolveWindow,
        'ɵɵresolveDocument': ɵɵresolveDocument,
        'ɵɵresolveBody': ɵɵresolveBody,
        'ɵɵsetComponentScope': ɵɵsetComponentScope,
        'ɵɵsetNgModuleScope': ɵɵsetNgModuleScope,
        'ɵɵsanitizeHtml': ɵɵsanitizeHtml,
        'ɵɵsanitizeStyle': ɵɵsanitizeStyle,
        'ɵɵdefaultStyleSanitizer': ɵɵdefaultStyleSanitizer,
        'ɵɵsanitizeResourceUrl': ɵɵsanitizeResourceUrl,
        'ɵɵsanitizeScript': ɵɵsanitizeScript,
        'ɵɵsanitizeUrl': ɵɵsanitizeUrl,
        'ɵɵsanitizeUrlOrResourceUrl': ɵɵsanitizeUrlOrResourceUrl
      };
    };
    /**
     * A mapping of the \@angular/core API surface used in generated expressions to the actual symbols.
     *
     * This should be kept up to date with the public exports of \@angular/core.
     * @type {?}
     */


    var angularCoreEnv = ɵ0$d();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/jit/jit_options.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @record
     */

    function JitCompilerOptions() {}

    if (false) {}
    /** @type {?} */


    var jitOptions = null;
    /**
     * @param {?} options
     * @return {?}
     */

    function setJitOptions(options) {
      if (jitOptions !== null) {
        if (options.defaultEncapsulation !== jitOptions.defaultEncapsulation) {
          ngDevMode && console.error('Provided value for `defaultEncapsulation` can not be changed once it has been set.');
          return;
        }

        if (options.preserveWhitespaces !== jitOptions.preserveWhitespaces) {
          ngDevMode && console.error('Provided value for `preserveWhitespaces` can not be changed once it has been set.');
          return;
        }
      }

      jitOptions = options;
    }
    /**
     * @return {?}
     */


    function getJitOptions() {
      return jitOptions;
    }
    /**
     * @return {?}
     */


    function resetJitOptions() {
      jitOptions = null;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/jit/module.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var EMPTY_ARRAY$5 = [];
    /**
     * @record
     */

    function ModuleQueueItem() {}

    if (false) {}
    /** @type {?} */


    var moduleQueue = [];
    /**
     * Enqueues moduleDef to be checked later to see if scope can be set on its
     * component declarations.
     * @param {?} moduleType
     * @param {?} ngModule
     * @return {?}
     */

    function enqueueModuleForDelayedScoping(moduleType, ngModule) {
      moduleQueue.push({
        moduleType: moduleType,
        ngModule: ngModule
      });
    }
    /** @type {?} */


    var flushingModuleQueue = false;
    /**
     * Loops over queued module definitions, if a given module definition has all of its
     * declarations resolved, it dequeues that module definition and sets the scope on
     * its declarations.
     * @return {?}
     */

    function flushModuleScopingQueueAsMuchAsPossible() {
      if (!flushingModuleQueue) {
        flushingModuleQueue = true;

        try {
          for (var i = moduleQueue.length - 1; i >= 0; i--) {
            var _moduleQueue$i = moduleQueue[i],
                moduleType = _moduleQueue$i.moduleType,
                ngModule = _moduleQueue$i.ngModule;

            if (ngModule.declarations && ngModule.declarations.every(isResolvedDeclaration)) {
              // dequeue
              moduleQueue.splice(i, 1);
              setScopeOnDeclaredComponents(moduleType, ngModule);
            }
          }
        } finally {
          flushingModuleQueue = false;
        }
      }
    }
    /**
     * Returns truthy if a declaration has resolved. If the declaration happens to be
     * an array of declarations, it will recurse to check each declaration in that array
     * (which may also be arrays).
     * @param {?} declaration
     * @return {?}
     */


    function isResolvedDeclaration(declaration) {
      if (Array.isArray(declaration)) {
        return declaration.every(isResolvedDeclaration);
      }

      return !!resolveForwardRef(declaration);
    }
    /**
     * Compiles a module in JIT mode.
     *
     * This function automatically gets called when a class has a `\@NgModule` decorator.
     * @param {?} moduleType
     * @param {?=} ngModule
     * @return {?}
     */


    function compileNgModule(moduleType) {
      var ngModule = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
      compileNgModuleDefs(
      /** @type {?} */
      moduleType, ngModule); // Because we don't know if all declarations have resolved yet at the moment the
      // NgModule decorator is executing, we're enqueueing the setting of module scope
      // on its declarations to be run at a later time when all declarations for the module,
      // including forward refs, have resolved.

      enqueueModuleForDelayedScoping(moduleType, ngModule);
    }
    /**
     * Compiles and adds the `ɵmod` and `ɵinj` properties to the module class.
     *
     * It's possible to compile a module via this API which will allow duplicate declarations in its
     * root.
     * @param {?} moduleType
     * @param {?} ngModule
     * @param {?=} allowDuplicateDeclarationsInRoot
     * @return {?}
     */


    function compileNgModuleDefs(moduleType, ngModule) {
      var allowDuplicateDeclarationsInRoot = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
      ngDevMode && assertDefined(moduleType, 'Required value moduleType');
      ngDevMode && assertDefined(ngModule, 'Required value ngModule');
      /** @type {?} */

      var declarations = flatten(ngModule.declarations || EMPTY_ARRAY$5);
      /** @type {?} */

      var ngModuleDef = null;
      Object.defineProperty(moduleType, NG_MOD_DEF, {
        configurable: true,
        get:
        /**
        * @return {?}
        */
        function get() {
          if (ngModuleDef === null) {
            if (ngDevMode && ngModule.imports && ngModule.imports.indexOf(moduleType) > -1) {
              // We need to assert this immediately, because allowing it to continue will cause it to
              // go into an infinite loop before we've reached the point where we throw all the errors.
              throw new Error("'".concat(stringifyForError(moduleType), "' module can't import itself"));
            }

            ngModuleDef = getCompilerFacade().compileNgModule(angularCoreEnv, "ng:///".concat(moduleType.name, "/\u0275mod.js"), {
              type: moduleType,
              bootstrap: flatten(ngModule.bootstrap || EMPTY_ARRAY$5).map(resolveForwardRef),
              declarations: declarations.map(resolveForwardRef),
              imports: flatten(ngModule.imports || EMPTY_ARRAY$5).map(resolveForwardRef).map(expandModuleWithProviders),
              exports: flatten(ngModule.exports || EMPTY_ARRAY$5).map(resolveForwardRef).map(expandModuleWithProviders),
              schemas: ngModule.schemas ? flatten(ngModule.schemas) : null,
              id: ngModule.id || null
            }); // Set `schemas` on ngModuleDef to an empty array in JIT mode to indicate that runtime
            // should verify that there are no unknown elements in a template. In AOT mode, that check
            // happens at compile time and `schemas` information is not present on Component and Module
            // defs after compilation (so the check doesn't happen the second time at runtime).

            if (!ngModuleDef.schemas) {
              ngModuleDef.schemas = [];
            }
          }

          return ngModuleDef;
        }
      });
      /** @type {?} */

      var ngInjectorDef = null;
      Object.defineProperty(moduleType, NG_INJ_DEF, {
        get:
        /**
        * @return {?}
        */
        function get() {
          if (ngInjectorDef === null) {
            ngDevMode && verifySemanticsOfNgModuleDef(
            /** @type {?} */

            /** @type {?} */
            moduleType, allowDuplicateDeclarationsInRoot);
            /** @type {?} */

            var meta = {
              name: moduleType.name,
              type: moduleType,
              deps: reflectDependencies(moduleType),
              providers: ngModule.providers || EMPTY_ARRAY$5,
              imports: [(ngModule.imports || EMPTY_ARRAY$5).map(resolveForwardRef), (ngModule.exports || EMPTY_ARRAY$5).map(resolveForwardRef)]
            };
            ngInjectorDef = getCompilerFacade().compileInjector(angularCoreEnv, "ng:///".concat(moduleType.name, "/\u0275inj.js"), meta);
          }

          return ngInjectorDef;
        },
        // Make the property configurable in dev mode to allow overriding in tests
        configurable: !!ngDevMode
      });
    }
    /**
     * @param {?} moduleType
     * @param {?} allowDuplicateDeclarationsInRoot
     * @param {?=} importingModule
     * @return {?}
     */


    function verifySemanticsOfNgModuleDef(moduleType, allowDuplicateDeclarationsInRoot, importingModule) {
      if (verifiedNgModule.get(moduleType)) return;
      verifiedNgModule.set(moduleType, true);
      moduleType = resolveForwardRef(moduleType);
      /** @type {?} */

      var ngModuleDef;

      if (importingModule) {
        ngModuleDef =
        /** @type {?} */
        getNgModuleDef(moduleType);

        if (!ngModuleDef) {
          throw new Error("Unexpected value '".concat(moduleType.name, "' imported by the module '").concat(importingModule.name, "'. Please add an @NgModule annotation."));
        }
      } else {
        ngModuleDef = getNgModuleDef(moduleType, true);
      }
      /** @type {?} */


      var errors = [];
      /** @type {?} */

      var declarations = maybeUnwrapFn(ngModuleDef.declarations);
      /** @type {?} */

      var imports = maybeUnwrapFn(ngModuleDef.imports);
      flatten(imports).map(unwrapModuleWithProvidersImports).forEach(
      /**
      * @param {?} mod
      * @return {?}
      */
      function (mod) {
        verifySemanticsOfNgModuleImport(mod, moduleType);
        verifySemanticsOfNgModuleDef(mod, false, moduleType);
      });
      /** @type {?} */

      var exports = maybeUnwrapFn(ngModuleDef.exports);
      declarations.forEach(verifyDeclarationsHaveDefinitions);
      declarations.forEach(verifyDirectivesHaveSelector);
      /** @type {?} */

      var combinedDeclarations = [].concat(_toConsumableArray(declarations.map(resolveForwardRef)), _toConsumableArray(flatten(imports.map(computeCombinedExports)).map(resolveForwardRef)));
      exports.forEach(verifyExportsAreDeclaredOrReExported);
      declarations.forEach(
      /**
      * @param {?} decl
      * @return {?}
      */
      function (decl) {
        return verifyDeclarationIsUnique(decl, allowDuplicateDeclarationsInRoot);
      });
      declarations.forEach(verifyComponentEntryComponentsIsPartOfNgModule);
      /** @type {?} */

      var ngModule = getAnnotation(moduleType, 'NgModule');

      if (ngModule) {
        ngModule.imports && flatten(ngModule.imports).map(unwrapModuleWithProvidersImports).forEach(
        /**
        * @param {?} mod
        * @return {?}
        */
        function (mod) {
          verifySemanticsOfNgModuleImport(mod, moduleType);
          verifySemanticsOfNgModuleDef(mod, false, moduleType);
        });
        ngModule.bootstrap && deepForEach(ngModule.bootstrap, verifyCorrectBootstrapType);
        ngModule.bootstrap && deepForEach(ngModule.bootstrap, verifyComponentIsPartOfNgModule);
        ngModule.entryComponents && deepForEach(ngModule.entryComponents, verifyComponentIsPartOfNgModule);
      } // Throw Error if any errors were detected.


      if (errors.length) {
        throw new Error(errors.join('\n'));
      } ////////////////////////////////////////////////////////////////////////////////////////////////

      /**
       * @param {?} type
       * @return {?}
       */


      function verifyDeclarationsHaveDefinitions(type) {
        type = resolveForwardRef(type);
        /** @type {?} */

        var def = getComponentDef(type) || getDirectiveDef(type) || getPipeDef(type);

        if (!def) {
          errors.push("Unexpected value '".concat(stringifyForError(type), "' declared by the module '").concat(stringifyForError(moduleType), "'. Please add a @Pipe/@Directive/@Component annotation."));
        }
      }
      /**
       * @param {?} type
       * @return {?}
       */


      function verifyDirectivesHaveSelector(type) {
        type = resolveForwardRef(type);
        /** @type {?} */

        var def = getDirectiveDef(type);

        if (!getComponentDef(type) && def && def.selectors.length == 0) {
          errors.push("Directive ".concat(stringifyForError(type), " has no selector, please add it!"));
        }
      }
      /**
       * @param {?} type
       * @return {?}
       */


      function verifyExportsAreDeclaredOrReExported(type) {
        type = resolveForwardRef(type);
        /** @type {?} */

        var kind = getComponentDef(type) && 'component' || getDirectiveDef(type) && 'directive' || getPipeDef(type) && 'pipe';

        if (kind) {
          // only checked if we are declared as Component, Directive, or Pipe
          // Modules don't need to be declared or imported.
          if (combinedDeclarations.lastIndexOf(type) === -1) {
            // We are exporting something which we don't explicitly declare or import.
            errors.push("Can't export ".concat(kind, " ").concat(stringifyForError(type), " from ").concat(stringifyForError(moduleType), " as it was neither declared nor imported!"));
          }
        }
      }
      /**
       * @param {?} type
       * @param {?} suppressErrors
       * @return {?}
       */


      function verifyDeclarationIsUnique(type, suppressErrors) {
        type = resolveForwardRef(type);
        /** @type {?} */

        var existingModule = ownerNgModule.get(type);

        if (existingModule && existingModule !== moduleType) {
          if (!suppressErrors) {
            /** @type {?} */
            var _modules = [existingModule, moduleType].map(stringifyForError).sort();

            errors.push("Type ".concat(stringifyForError(type), " is part of the declarations of 2 modules: ").concat(_modules[0], " and ").concat(_modules[1], "! ") + "Please consider moving ".concat(stringifyForError(type), " to a higher module that imports ").concat(_modules[0], " and ").concat(_modules[1], ". ") + "You can also create a new NgModule that exports and includes ".concat(stringifyForError(type), " then import that NgModule in ").concat(_modules[0], " and ").concat(_modules[1], "."));
          }
        } else {
          // Mark type as having owner.
          ownerNgModule.set(type, moduleType);
        }
      }
      /**
       * @param {?} type
       * @return {?}
       */


      function verifyComponentIsPartOfNgModule(type) {
        type = resolveForwardRef(type);
        /** @type {?} */

        var existingModule = ownerNgModule.get(type);

        if (!existingModule) {
          errors.push("Component ".concat(stringifyForError(type), " is not part of any NgModule or the module has not been imported into your module."));
        }
      }
      /**
       * @param {?} type
       * @return {?}
       */


      function verifyCorrectBootstrapType(type) {
        type = resolveForwardRef(type);

        if (!getComponentDef(type)) {
          errors.push("".concat(stringifyForError(type), " cannot be used as an entry component."));
        }
      }
      /**
       * @param {?} type
       * @return {?}
       */


      function verifyComponentEntryComponentsIsPartOfNgModule(type) {
        type = resolveForwardRef(type);

        if (getComponentDef(type)) {
          // We know we are component

          /** @type {?} */
          var component = getAnnotation(type, 'Component');

          if (component && component.entryComponents) {
            deepForEach(component.entryComponents, verifyComponentIsPartOfNgModule);
          }
        }
      }
      /**
       * @param {?} type
       * @param {?} importingModule
       * @return {?}
       */


      function verifySemanticsOfNgModuleImport(type, importingModule) {
        type = resolveForwardRef(type);

        if (getComponentDef(type) || getDirectiveDef(type)) {
          throw new Error("Unexpected directive '".concat(type.name, "' imported by the module '").concat(importingModule.name, "'. Please add an @NgModule annotation."));
        }

        if (getPipeDef(type)) {
          throw new Error("Unexpected pipe '".concat(type.name, "' imported by the module '").concat(importingModule.name, "'. Please add an @NgModule annotation."));
        }
      }
    }
    /**
     * @param {?} typeOrWithProviders
     * @return {?}
     */


    function unwrapModuleWithProvidersImports(typeOrWithProviders) {
      typeOrWithProviders = resolveForwardRef(typeOrWithProviders);
      return (
        /** @type {?} */
        typeOrWithProviders.ngModule || typeOrWithProviders
      );
    }
    /**
     * @template T
     * @param {?} type
     * @param {?} name
     * @return {?}
     */


    function getAnnotation(type, name) {
      /** @type {?} */
      var annotation = null;
      collect(type.__annotations__);
      collect(type.decorators);
      return annotation;
      /**
       * @param {?} annotations
       * @return {?}
       */

      function collect(annotations) {
        if (annotations) {
          annotations.forEach(readAnnotation);
        }
      }
      /**
       * @param {?} decorator
       * @return {?}
       */


      function readAnnotation(decorator) {
        if (!annotation) {
          /** @type {?} */
          var proto = Object.getPrototypeOf(decorator);

          if (proto.ngMetadataName == name) {
            annotation =
            /** @type {?} */
            decorator;
          } else if (decorator.type) {
            /** @type {?} */
            var _proto = Object.getPrototypeOf(decorator.type);

            if (_proto.ngMetadataName == name) {
              annotation = decorator.args[0];
            }
          }
        }
      }
    }
    /**
     * Keep track of compiled components. This is needed because in tests we often want to compile the
     * same component with more than one NgModule. This would cause an error unless we reset which
     * NgModule the component belongs to. We keep the list of compiled components here so that the
     * TestBed can reset it later.
     * @type {?}
     */


    var ownerNgModule = new Map();
    /** @type {?} */

    var verifiedNgModule = new Map();
    /**
     * @return {?}
     */

    function resetCompiledComponents() {
      ownerNgModule = new Map();
      verifiedNgModule = new Map();
      moduleQueue.length = 0;
    }
    /**
     * Computes the combined declarations of explicit declarations, as well as declarations inherited by
     * traversing the exports of imported modules.
     * @param {?} type
     * @return {?}
     */


    function computeCombinedExports(type) {
      type = resolveForwardRef(type);
      /** @type {?} */

      var ngModuleDef = getNgModuleDef(type, true);
      return _toConsumableArray(flatten(maybeUnwrapFn(ngModuleDef.exports).map(
      /**
      * @param {?} type
      * @return {?}
      */
      function (type) {
        /** @type {?} */
        var ngModuleDef = getNgModuleDef(type);

        if (ngModuleDef) {
          verifySemanticsOfNgModuleDef(
          /** @type {?} */

          /** @type {?} */
          type, false);
          return computeCombinedExports(type);
        } else {
          return type;
        }
      })));
    }
    /**
     * Some declared components may be compiled asynchronously, and thus may not have their
     * ɵcmp set yet. If this is the case, then a reference to the module is written into
     * the `ngSelectorScope` property of the declared type.
     * @param {?} moduleType
     * @param {?} ngModule
     * @return {?}
     */


    function setScopeOnDeclaredComponents(moduleType, ngModule) {
      /** @type {?} */
      var declarations = flatten(ngModule.declarations || EMPTY_ARRAY$5);
      /** @type {?} */

      var transitiveScopes = transitiveScopesFor(moduleType);
      declarations.forEach(
      /**
      * @param {?} declaration
      * @return {?}
      */
      function (declaration) {
        if (declaration.hasOwnProperty(NG_COMP_DEF)) {
          // A `ɵcmp` field exists - go ahead and patch the component directly.

          /** @type {?} */
          var component =
          /** @type {?} */
          declaration;
          /** @type {?} */

          var componentDef =
          /** @type {?} */
          getComponentDef(component);
          patchComponentDefWithScope(componentDef, transitiveScopes);
        } else if (!declaration.hasOwnProperty(NG_DIR_DEF) && !declaration.hasOwnProperty(NG_PIPE_DEF)) {
          // Set `ngSelectorScope` for future reference when the component compilation finishes.

          /** @type {?} */
          declaration.ngSelectorScope = moduleType;
        }
      });
    }
    /**
     * Patch the definition of a component with directives and pipes from the compilation scope of
     * a given module.
     * @template C
     * @param {?} componentDef
     * @param {?} transitiveScopes
     * @return {?}
     */


    function patchComponentDefWithScope(componentDef, transitiveScopes) {
      componentDef.directiveDefs =
      /**
      * @return {?}
      */
      function () {
        return Array.from(transitiveScopes.compilation.directives).map(
        /**
        * @param {?} dir
        * @return {?}
        */
        function (dir) {
          return dir.hasOwnProperty(NG_COMP_DEF) ?
          /** @type {?} */
          getComponentDef(dir) :
          /** @type {?} */
          getDirectiveDef(dir);
        }).filter(
        /**
        * @param {?} def
        * @return {?}
        */
        function (def) {
          return !!def;
        });
      };

      componentDef.pipeDefs =
      /**
      * @return {?}
      */
      function () {
        return Array.from(transitiveScopes.compilation.pipes).map(
        /**
        * @param {?} pipe
        * @return {?}
        */
        function (pipe) {
          return (
            /** @type {?} */
            getPipeDef(pipe)
          );
        });
      };

      componentDef.schemas = transitiveScopes.schemas; // Since we avoid Components/Directives/Pipes recompiling in case there are no overrides, we
      // may face a problem where previously compiled defs available to a given Component/Directive
      // are cached in TView and may become stale (in case any of these defs gets recompiled). In
      // order to avoid this problem, we force fresh TView to be created.

      componentDef.tView = null;
    }
    /**
     * Compute the pair of transitive scopes (compilation scope and exported scope) for a given module.
     *
     * This operation is memoized and the result is cached on the module's definition. This function can
     * be called on modules with components that have not fully compiled yet, but the result should not
     * be used until they have.
     *
     * @template T
     * @param {?} moduleType module that transitive scope should be calculated for.
     * @return {?}
     */


    function transitiveScopesFor(moduleType) {
      if (!isNgModule(moduleType)) {
        throw new Error("".concat(moduleType.name, " does not have a module def (\u0275mod property)"));
      }
      /** @type {?} */


      var def =
      /** @type {?} */
      getNgModuleDef(moduleType);

      if (def.transitiveCompileScopes !== null) {
        return def.transitiveCompileScopes;
      }
      /** @type {?} */


      var scopes = {
        schemas: def.schemas || null,
        compilation: {
          directives: new Set(),
          pipes: new Set()
        },
        exported: {
          directives: new Set(),
          pipes: new Set()
        }
      };
      maybeUnwrapFn(def.imports).forEach(
      /**
      * @template I
      * @param {?} imported
      * @return {?}
      */
      function (imported) {
        /** @type {?} */
        var importedType =
        /** @type {?} */
        imported;

        if (!isNgModule(importedType)) {
          throw new Error("Importing ".concat(importedType.name, " which does not have a \u0275mod property"));
        } // When this module imports another, the imported module's exported directives and pipes are
        // added to the compilation scope of this module.

        /** @type {?} */


        var importedScope = transitiveScopesFor(importedType);
        importedScope.exported.directives.forEach(
        /**
        * @param {?} entry
        * @return {?}
        */
        function (entry) {
          return scopes.compilation.directives.add(entry);
        });
        importedScope.exported.pipes.forEach(
        /**
        * @param {?} entry
        * @return {?}
        */
        function (entry) {
          return scopes.compilation.pipes.add(entry);
        });
      });
      maybeUnwrapFn(def.declarations).forEach(
      /**
      * @param {?} declared
      * @return {?}
      */
      function (declared) {
        /** @type {?} */
        var declaredWithDefs =
        /** @type {?} */
        declared;

        if (getPipeDef(declaredWithDefs)) {
          scopes.compilation.pipes.add(declared);
        } else {
          // Either declared has a ɵcmp or ɵdir, or it's a component which hasn't
          // had its template compiled yet. In either case, it gets added to the compilation's
          // directives.
          scopes.compilation.directives.add(declared);
        }
      });
      maybeUnwrapFn(def.exports).forEach(
      /**
      * @template E
      * @param {?} exported
      * @return {?}
      */
      function (exported) {
        /** @type {?} */
        var exportedType =
        /** @type {?} */
        exported; // Either the type is a module, a pipe, or a component/directive (which may not have a
        // ɵcmp as it might be compiled asynchronously).

        if (isNgModule(exportedType)) {
          // When this module exports another, the exported module's exported directives and pipes are
          // added to both the compilation and exported scopes of this module.

          /** @type {?} */
          var exportedScope = transitiveScopesFor(exportedType);
          exportedScope.exported.directives.forEach(
          /**
          * @param {?} entry
          * @return {?}
          */
          function (entry) {
            scopes.compilation.directives.add(entry);
            scopes.exported.directives.add(entry);
          });
          exportedScope.exported.pipes.forEach(
          /**
          * @param {?} entry
          * @return {?}
          */
          function (entry) {
            scopes.compilation.pipes.add(entry);
            scopes.exported.pipes.add(entry);
          });
        } else if (getPipeDef(exportedType)) {
          scopes.exported.pipes.add(exportedType);
        } else {
          scopes.exported.directives.add(exportedType);
        }
      });
      def.transitiveCompileScopes = scopes;
      return scopes;
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function expandModuleWithProviders(value) {
      if (isModuleWithProviders(value)) {
        return value.ngModule;
      }

      return value;
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function isModuleWithProviders(value) {
      return (
        /** @type {?} */
        value.ngModule !== undefined
      );
    }
    /**
     * @template T
     * @param {?} value
     * @return {?}
     */


    function isNgModule(value) {
      return !!getNgModuleDef(value);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/jit/directive.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Compile an Angular component according to its decorator metadata, and patch the resulting
     * component def (ɵcmp) onto the component type.
     *
     * Compilation may be asynchronous (due to the need to resolve URLs for the component template or
     * other resources, for example). In the event that compilation is not immediate, `compileComponent`
     * will enqueue resource resolution into a global queue and will fail to return the `ɵcmp`
     * until the global queue has been resolved with a call to `resolveComponentResources`.
     * @param {?} type
     * @param {?} metadata
     * @return {?}
     */


    function compileComponent(type, metadata) {
      // Initialize ngDevMode. This must be the first statement in compileComponent.
      // See the `initNgDevMode` docstring for more information.
      (typeof ngDevMode === 'undefined' || ngDevMode) && initNgDevMode();
      /** @type {?} */

      var ngComponentDef = null; // Metadata may have resources which need to be resolved.

      maybeQueueResolutionOfComponentResources(type, metadata); // Note that we're using the same function as `Directive`, because that's only subset of metadata
      // that we need to create the ngFactoryDef. We're avoiding using the component metadata
      // because we'd have to resolve the asynchronous templates.

      addDirectiveFactoryDef(type, metadata);
      Object.defineProperty(type, NG_COMP_DEF, {
        get:
        /**
        * @return {?}
        */
        function get() {
          if (ngComponentDef === null) {
            /** @type {?} */
            var compiler = getCompilerFacade();

            if (componentNeedsResolution(metadata)) {
              /** @type {?} */
              var error = ["Component '".concat(type.name, "' is not resolved:")];

              if (metadata.templateUrl) {
                error.push(" - templateUrl: ".concat(metadata.templateUrl));
              }

              if (metadata.styleUrls && metadata.styleUrls.length) {
                error.push(" - styleUrls: ".concat(JSON.stringify(metadata.styleUrls)));
              }

              error.push("Did you run and wait for 'resolveComponentResources()'?");
              throw new Error(error.join('\n'));
            } // This const was called `jitOptions` previously but had to be renamed to `options` because
            // of a bug with Terser that caused optimized JIT builds to throw a `ReferenceError`.
            // This bug was investigated in https://github.com/angular/angular-cli/issues/17264.
            // We should not rename it back until https://github.com/terser/terser/issues/615 is fixed.

            /** @type {?} */


            var options = getJitOptions();
            /** @type {?} */

            var preserveWhitespaces = metadata.preserveWhitespaces;

            if (preserveWhitespaces === undefined) {
              if (options !== null && options.preserveWhitespaces !== undefined) {
                preserveWhitespaces = options.preserveWhitespaces;
              } else {
                preserveWhitespaces = false;
              }
            }
            /** @type {?} */


            var encapsulation = metadata.encapsulation;

            if (encapsulation === undefined) {
              if (options !== null && options.defaultEncapsulation !== undefined) {
                encapsulation = options.defaultEncapsulation;
              } else {
                encapsulation = ViewEncapsulation$1.Emulated;
              }
            }
            /** @type {?} */


            var templateUrl = metadata.templateUrl || "ng:///".concat(type.name, "/template.html");
            /** @type {?} */

            var meta = Object.assign(Object.assign({}, directiveMetadata(type, metadata)), {
              typeSourceSpan: compiler.createParseSourceSpan('Component', type.name, templateUrl),
              template: metadata.template || '',
              preserveWhitespaces: preserveWhitespaces,
              styles: metadata.styles || EMPTY_ARRAY,
              animations: metadata.animations,
              directives: [],
              changeDetection: metadata.changeDetection,
              pipes: new Map(),
              encapsulation: encapsulation,
              interpolation: metadata.interpolation,
              viewProviders: metadata.viewProviders || null
            });

            if (meta.usesInheritance) {
              addDirectiveDefToUndecoratedParents(type);
            }

            ngComponentDef = compiler.compileComponent(angularCoreEnv, templateUrl, meta); // When NgModule decorator executed, we enqueued the module definition such that
            // it would only dequeue and add itself as module scope to all of its declarations,
            // but only if  if all of its declarations had resolved. This call runs the check
            // to see if any modules that are in the queue can be dequeued and add scope to
            // their declarations.

            flushModuleScopingQueueAsMuchAsPossible(); // If component compilation is async, then the @NgModule annotation which declares the
            // component may execute and set an ngSelectorScope property on the component type. This
            // allows the component to patch itself with directiveDefs from the module after it
            // finishes compiling.

            if (hasSelectorScope(type)) {
              /** @type {?} */
              var scopes = transitiveScopesFor(type.ngSelectorScope);
              patchComponentDefWithScope(ngComponentDef, scopes);
            }
          }

          return ngComponentDef;
        },
        // Make the property configurable in dev mode to allow overriding in tests
        configurable: !!ngDevMode
      });
    }
    /**
     * @template T
     * @param {?} component
     * @return {?}
     */


    function hasSelectorScope(component) {
      return (
        /** @type {?} */
        component.ngSelectorScope !== undefined
      );
    }
    /**
     * Compile an Angular directive according to its decorator metadata, and patch the resulting
     * directive def onto the component type.
     *
     * In the event that compilation is not immediate, `compileDirective` will return a `Promise` which
     * will resolve when compilation completes and the directive becomes usable.
     * @param {?} type
     * @param {?} directive
     * @return {?}
     */


    function compileDirective(type, directive) {
      /** @type {?} */
      var ngDirectiveDef = null;
      addDirectiveFactoryDef(type, directive || {});
      Object.defineProperty(type, NG_DIR_DEF, {
        get:
        /**
        * @return {?}
        */
        function get() {
          if (ngDirectiveDef === null) {
            // `directive` can be null in the case of abstract directives as a base class
            // that use `@Directive()` with no selector. In that case, pass empty object to the
            // `directiveMetadata` function instead of null.

            /** @type {?} */
            var meta = getDirectiveMetadata(type, directive || {});
            ngDirectiveDef = getCompilerFacade().compileDirective(angularCoreEnv, meta.sourceMapUrl, meta.metadata);
          }

          return ngDirectiveDef;
        },
        // Make the property configurable in dev mode to allow overriding in tests
        configurable: !!ngDevMode
      });
    }
    /**
     * @param {?} type
     * @param {?} metadata
     * @return {?}
     */


    function getDirectiveMetadata(type, metadata) {
      /** @type {?} */
      var name = type && type.name;
      /** @type {?} */

      var sourceMapUrl = "ng:///".concat(name, "/\u0275dir.js");
      /** @type {?} */

      var compiler = getCompilerFacade();
      /** @type {?} */

      var facade = directiveMetadata(
      /** @type {?} */
      type, metadata);
      facade.typeSourceSpan = compiler.createParseSourceSpan('Directive', name, sourceMapUrl);

      if (facade.usesInheritance) {
        addDirectiveDefToUndecoratedParents(type);
      }

      return {
        metadata: facade,
        sourceMapUrl: sourceMapUrl
      };
    }
    /**
     * @param {?} type
     * @param {?} metadata
     * @return {?}
     */


    function addDirectiveFactoryDef(type, metadata) {
      /** @type {?} */
      var ngFactoryDef = null;
      Object.defineProperty(type, NG_FACTORY_DEF, {
        get:
        /**
        * @return {?}
        */
        function get() {
          if (ngFactoryDef === null) {
            /** @type {?} */
            var meta = getDirectiveMetadata(type, metadata);
            /** @type {?} */

            var compiler = getCompilerFacade();
            ngFactoryDef = compiler.compileFactory(angularCoreEnv, "ng:///".concat(type.name, "/\u0275fac.js"), Object.assign(Object.assign({}, meta.metadata), {
              injectFn: 'directiveInject',
              target: compiler.R3FactoryTarget.Directive
            }));
          }

          return ngFactoryDef;
        },
        // Make the property configurable in dev mode to allow overriding in tests
        configurable: !!ngDevMode
      });
    }
    /**
     * @param {?} type
     * @return {?}
     */


    function extendsDirectlyFromObject(type) {
      return Object.getPrototypeOf(type.prototype) === Object.prototype;
    }
    /**
     * Extract the `R3DirectiveMetadata` for a particular directive (either a `Directive` or a
     * `Component`).
     * @param {?} type
     * @param {?} metadata
     * @return {?}
     */


    function directiveMetadata(type, metadata) {
      // Reflect inputs and outputs.

      /** @type {?} */
      var reflect = getReflect();
      /** @type {?} */

      var propMetadata = reflect.ownPropMetadata(type);
      return {
        name: type.name,
        type: type,
        typeArgumentCount: 0,
        selector: metadata.selector !== undefined ? metadata.selector : null,
        deps: reflectDependencies(type),
        host: metadata.host || EMPTY_OBJ,
        propMetadata: propMetadata,
        inputs: metadata.inputs || EMPTY_ARRAY,
        outputs: metadata.outputs || EMPTY_ARRAY,
        queries: extractQueriesMetadata(type, propMetadata, isContentQuery),
        lifecycle: {
          usesOnChanges: reflect.hasLifecycleHook(type, 'ngOnChanges')
        },
        typeSourceSpan:
        /** @type {?} */
        null,
        usesInheritance: !extendsDirectlyFromObject(type),
        exportAs: extractExportAs(metadata.exportAs),
        providers: metadata.providers || null,
        viewQueries: extractQueriesMetadata(type, propMetadata, isViewQuery)
      };
    }
    /**
     * Adds a directive definition to all parent classes of a type that don't have an Angular decorator.
     * @param {?} type
     * @return {?}
     */


    function addDirectiveDefToUndecoratedParents(type) {
      /** @type {?} */
      var objPrototype = Object.prototype;
      /** @type {?} */

      var parent = Object.getPrototypeOf(type.prototype).constructor; // Go up the prototype until we hit `Object`.

      while (parent && parent !== objPrototype) {
        // Since inheritance works if the class was annotated already, we only need to add
        // the def if there are no annotations and the def hasn't been created already.
        if (!getDirectiveDef(parent) && !getComponentDef(parent) && shouldAddAbstractDirective(parent)) {
          compileDirective(parent, null);
        }

        parent = Object.getPrototypeOf(parent);
      }
    }
    /**
     * @param {?} selector
     * @return {?}
     */


    function convertToR3QueryPredicate(selector) {
      return typeof selector === 'string' ? splitByComma(selector) : resolveForwardRef(selector);
    }
    /**
     * @param {?} propertyName
     * @param {?} ann
     * @return {?}
     */


    function convertToR3QueryMetadata(propertyName, ann) {
      return {
        propertyName: propertyName,
        predicate: convertToR3QueryPredicate(ann.selector),
        descendants: ann.descendants,
        first: ann.first,
        read: ann.read ? ann.read : null,
        "static": !!ann["static"]
      };
    }
    /**
     * @param {?} type
     * @param {?} propMetadata
     * @param {?} isQueryAnn
     * @return {?}
     */


    function extractQueriesMetadata(type, propMetadata, isQueryAnn) {
      /** @type {?} */
      var queriesMeta = [];

      var _loop4 = function _loop4(field) {
        if (propMetadata.hasOwnProperty(field)) {
          /** @type {?} */
          var annotations = propMetadata[field];
          annotations.forEach(
          /**
          * @param {?} ann
          * @return {?}
          */
          function (ann) {
            if (isQueryAnn(ann)) {
              if (!ann.selector) {
                throw new Error("Can't construct a query for the property \"".concat(field, "\" of ") + "\"".concat(stringifyForError(type), "\" since the query selector wasn't defined."));
              }

              if (annotations.some(isInputAnnotation)) {
                throw new Error("Cannot combine @Input decorators with query decorators");
              }

              queriesMeta.push(convertToR3QueryMetadata(field, ann));
            }
          });
        }
      };

      for (var field in propMetadata) {
        _loop4(field);
      }

      return queriesMeta;
    }
    /**
     * @param {?} exportAs
     * @return {?}
     */


    function extractExportAs(exportAs) {
      return exportAs === undefined ? null : splitByComma(exportAs);
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function isContentQuery(value) {
      /** @type {?} */
      var name = value.ngMetadataName;
      return name === 'ContentChild' || name === 'ContentChildren';
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function isViewQuery(value) {
      /** @type {?} */
      var name = value.ngMetadataName;
      return name === 'ViewChild' || name === 'ViewChildren';
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function isInputAnnotation(value) {
      return value.ngMetadataName === 'Input';
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function splitByComma(value) {
      return value.split(',').map(
      /**
      * @param {?} piece
      * @return {?}
      */
      function (piece) {
        return piece.trim();
      });
    }
    /** @type {?} */


    var LIFECYCLE_HOOKS = ['ngOnChanges', 'ngOnInit', 'ngOnDestroy', 'ngDoCheck', 'ngAfterViewInit', 'ngAfterViewChecked', 'ngAfterContentInit', 'ngAfterContentChecked'];
    /**
     * @param {?} type
     * @return {?}
     */

    function shouldAddAbstractDirective(type) {
      /** @type {?} */
      var reflect = getReflect();

      if (LIFECYCLE_HOOKS.some(
      /**
      * @param {?} hookName
      * @return {?}
      */
      function (hookName) {
        return reflect.hasLifecycleHook(type, hookName);
      })) {
        return true;
      }
      /** @type {?} */


      var propMetadata = reflect.propMetadata(type);

      for (var field in propMetadata) {
        /** @type {?} */
        var annotations = propMetadata[field];

        for (var i = 0; i < annotations.length; i++) {
          /** @type {?} */
          var current = annotations[i];
          /** @type {?} */

          var metadataName = current.ngMetadataName;

          if (isInputAnnotation(current) || isContentQuery(current) || isViewQuery(current) || metadataName === 'Output' || metadataName === 'HostBinding' || metadataName === 'HostListener') {
            return true;
          }
        }
      }

      return false;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render3/jit/pipe.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} type
     * @param {?} meta
     * @return {?}
     */


    function compilePipe(type, meta) {
      /** @type {?} */
      var ngPipeDef = null;
      /** @type {?} */

      var ngFactoryDef = null;
      Object.defineProperty(type, NG_FACTORY_DEF, {
        get:
        /**
        * @return {?}
        */
        function get() {
          if (ngFactoryDef === null) {
            /** @type {?} */
            var metadata = getPipeMetadata(type, meta);
            /** @type {?} */

            var compiler = getCompilerFacade();
            ngFactoryDef = compiler.compileFactory(angularCoreEnv, "ng:///".concat(metadata.name, "/\u0275fac.js"), Object.assign(Object.assign({}, metadata), {
              injectFn: 'directiveInject',
              target: compiler.R3FactoryTarget.Pipe
            }));
          }

          return ngFactoryDef;
        },
        // Make the property configurable in dev mode to allow overriding in tests
        configurable: !!ngDevMode
      });
      Object.defineProperty(type, NG_PIPE_DEF, {
        get:
        /**
        * @return {?}
        */
        function get() {
          if (ngPipeDef === null) {
            /** @type {?} */
            var metadata = getPipeMetadata(type, meta);
            ngPipeDef = getCompilerFacade().compilePipe(angularCoreEnv, "ng:///".concat(metadata.name, "/\u0275pipe.js"), metadata);
          }

          return ngPipeDef;
        },
        // Make the property configurable in dev mode to allow overriding in tests
        configurable: !!ngDevMode
      });
    }
    /**
     * @param {?} type
     * @param {?} meta
     * @return {?}
     */


    function getPipeMetadata(type, meta) {
      return {
        type: type,
        typeArgumentCount: 0,
        name: type.name,
        deps: reflectDependencies(type),
        pipeName: meta.name,
        pure: meta.pure !== undefined ? meta.pure : true
      };
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/metadata/directives.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Type of the Directive decorator / constructor function.
     * \@publicApi
     * @record
     */


    function DirectiveDecorator() {} // WARNING: interface has both a type and a value, skipping emit


    var ɵ0$e =
    /**
    * @param {?=} dir
    * @return {?}
    */
    function ɵ0$e() {
      var dir = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
      return dir;
    },
        ɵ1$3 =
    /**
    * @param {?} type
    * @param {?} meta
    * @return {?}
    */
    function ɵ1$3(type, meta) {
      return SWITCH_COMPILE_DIRECTIVE(type, meta);
    };
    /**
     * Type of the Directive metadata.
     *
     * \@publicApi
     * @type {?}
     */


    var Directive = makeDecorator('Directive', ɵ0$e, undefined, undefined, ɵ1$3);
    /**
     * Component decorator interface
     *
     * \@publicApi
     * @record
     */

    function ComponentDecorator() {} // WARNING: interface has both a type and a value, skipping emit


    var ɵ2$1 =
    /**
    * @param {?=} c
    * @return {?}
    */
    function ɵ2$1() {
      var c = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
      return Object.assign({
        changeDetection: ChangeDetectionStrategy.Default
      }, c);
    },
        ɵ3$1 =
    /**
    * @param {?} type
    * @param {?} meta
    * @return {?}
    */
    function ɵ3$1(type, meta) {
      return SWITCH_COMPILE_COMPONENT(type, meta);
    };
    /**
     * Component decorator and metadata.
     *
     * \@Annotation
     * \@publicApi
     * @type {?}
     */


    var Component = makeDecorator('Component', ɵ2$1, Directive, undefined, ɵ3$1);
    /**
     * Type of the Pipe decorator / constructor function.
     *
     * \@publicApi
     * @record
     */

    function PipeDecorator() {} // WARNING: interface has both a type and a value, skipping emit


    var ɵ4 =
    /**
    * @param {?} p
    * @return {?}
    */
    function ɵ4(p) {
      return Object.assign({
        pure: true
      }, p);
    },
        ɵ5 =
    /**
    * @param {?} type
    * @param {?} meta
    * @return {?}
    */
    function ɵ5(type, meta) {
      return SWITCH_COMPILE_PIPE(type, meta);
    };
    /**
     * \@Annotation
     * \@publicApi
     * @type {?}
     */


    var Pipe = makeDecorator('Pipe', ɵ4, undefined, undefined, ɵ5);
    /**
     * \@publicApi
     * @record
     */

    function InputDecorator() {} // WARNING: interface has both a type and a value, skipping emit


    var ɵ6 =
    /**
    * @param {?=} bindingPropertyName
    * @return {?}
    */
    function ɵ6(bindingPropertyName) {
      return {
        bindingPropertyName: bindingPropertyName
      };
    };
    /**
     * \@Annotation
     * \@publicApi
     * @type {?}
     */


    var Input = makePropDecorator('Input', ɵ6);
    /**
     * Type of the Output decorator / constructor function.
     *
     * \@publicApi
     * @record
     */

    function OutputDecorator() {} // WARNING: interface has both a type and a value, skipping emit


    var ɵ7 =
    /**
    * @param {?=} bindingPropertyName
    * @return {?}
    */
    function ɵ7(bindingPropertyName) {
      return {
        bindingPropertyName: bindingPropertyName
      };
    };
    /**
     * \@Annotation
     * \@publicApi
     * @type {?}
     */


    var Output = makePropDecorator('Output', ɵ7);
    /**
     * Type of the HostBinding decorator / constructor function.
     *
     * \@publicApi
     * @record
     */

    function HostBindingDecorator() {} // WARNING: interface has both a type and a value, skipping emit


    var ɵ8 =
    /**
    * @param {?=} hostPropertyName
    * @return {?}
    */
    function ɵ8(hostPropertyName) {
      return {
        hostPropertyName: hostPropertyName
      };
    };
    /**
     * \@Annotation
     * \@publicApi
     * @type {?}
     */


    var HostBinding = makePropDecorator('HostBinding', ɵ8);
    /**
     * Type of the HostListener decorator / constructor function.
     *
     * \@publicApi
     * @record
     */

    function HostListenerDecorator() {} // WARNING: interface has both a type and a value, skipping emit


    var ɵ9 =
    /**
    * @param {?=} eventName
    * @param {?=} args
    * @return {?}
    */
    function ɵ9(eventName, args) {
      return {
        eventName: eventName,
        args: args
      };
    };
    /**
     * Decorator that binds a DOM event to a host listener and supplies configuration metadata.
     * Angular invokes the supplied handler method when the host element emits the specified event,
     * and updates the bound element with the result.
     *
     * If the handler method returns false, applies `preventDefault` on the bound element.
     *
     * \@usageNotes
     *
     * The following example declares a directive
     * that attaches a click listener to a button and counts clicks.
     *
     * ```ts
     * \@Directive({selector: 'button[counting]'})
     * class CountClicks {
     *   numberOfClicks = 0;
     *
     * \@HostListener('click', ['$event.target'])
     *   onClick(btn) {
     *     console.log('button', btn, 'number of clicks:', this.numberOfClicks++);
     *  }
     * }
     *
     * \@Component({
     *   selector: 'app',
     *   template: '<button counting>Increment</button>',
     * })
     * class App {}
     *
     * ```
     *
     * The following example registers another DOM event handler that listens for key-press events.
     * ``` ts
     * import { HostListener, Component } from "\@angular/core";
     *
     * \@Component({
     *   selector: 'app',
     *   template: `<h1>Hello, you have pressed keys {{counter}} number of times!</h1> Press any key to
     * increment the counter.
     *   <button (click)="resetCounter()">Reset Counter</button>`
     * })
     * class AppComponent {
     *   counter = 0;
     * \@HostListener('window:keydown', ['$event'])
     *   handleKeyDown(event: KeyboardEvent) {
     *     this.counter++;
     *   }
     *   resetCounter() {
     *     this.counter = 0;
     *   }
     * }
     * ```
     *
     * \@Annotation
     * \@publicApi
     * @type {?}
     */


    var HostListener = makePropDecorator('HostListener', ɵ9);
    /** @type {?} */

    var SWITCH_COMPILE_COMPONENT__POST_R3__ = compileComponent;
    /** @type {?} */

    var SWITCH_COMPILE_DIRECTIVE__POST_R3__ = compileDirective;
    /** @type {?} */

    var SWITCH_COMPILE_PIPE__POST_R3__ = compilePipe;
    /** @type {?} */

    var SWITCH_COMPILE_COMPONENT__PRE_R3__ = noop;
    /** @type {?} */

    var SWITCH_COMPILE_DIRECTIVE__PRE_R3__ = noop;
    /** @type {?} */

    var SWITCH_COMPILE_PIPE__PRE_R3__ = noop;
    /** @type {?} */

    var SWITCH_COMPILE_COMPONENT = SWITCH_COMPILE_COMPONENT__POST_R3__;
    /** @type {?} */

    var SWITCH_COMPILE_DIRECTIVE = SWITCH_COMPILE_DIRECTIVE__POST_R3__;
    /** @type {?} */

    var SWITCH_COMPILE_PIPE = SWITCH_COMPILE_PIPE__POST_R3__;
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/metadata/ng_module.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Represents the expansion of an `NgModule` into its scopes.
     *
     * A scope is a set of directives and pipes that are visible in a particular context. Each
     * `NgModule` has two scopes. The `compilation` scope is the set of directives and pipes that will
     * be recognized in the templates of components declared by the module. The `exported` scope is the
     * set of directives and pipes exported by a module (that is, module B's exported scope gets added
     * to module A's compilation scope when module A imports B).
     * @record
     */

    function NgModuleTransitiveScopes() {}

    if (false) {}
    /**
     * Runtime link information for NgModules.
     *
     * This is the internal data structure used by the runtime to assemble components, directives,
     * pipes, and injectors.
     *
     * NOTE: Always use `ɵɵdefineNgModule` function to create this object,
     * never create the object directly since the shape of this object
     * can change between versions.
     * @record
     * @template T
     */


    function NgModuleDef() {}

    if (false) {}
    /**
     * A wrapper around an NgModule that associates it with the providers.
     *
     * @param T the module type. In Ivy applications, this must be explicitly
     * provided.
     *
     * Note that using ModuleWithProviders without a generic type is deprecated.
     * The generic will become required in a future version of Angular.
     *
     * \@publicApi
     * @record
     * @template T
     */


    function ModuleWithProviders() {}

    if (false) {}
    /**
     * Type of the NgModule decorator / constructor function.
     *
     * \@publicApi
     * @record
     */


    function NgModuleDecorator() {} // WARNING: interface has both a type and a value, skipping emit


    var ɵ0$f =
    /**
    * @param {?} ngModule
    * @return {?}
    */
    function ɵ0$f(ngModule) {
      return ngModule;
    },
        ɵ1$4 =
    /**
    * Decorator that marks the following class as an NgModule, and supplies
    * configuration metadata for it.
    *
    * * The `declarations` and `entryComponents` options configure the compiler
    * with information about what belongs to the NgModule.
    * * The `providers` options configures the NgModule's injector to provide
    * dependencies the NgModule members.
    * * The `imports` and `exports` options bring in members from other modules, and make
    * this module's members available to others.
    * @param {?} type
    * @param {?} meta
    * @return {?}
    */
    function ɵ1$4(type, meta) {
      return SWITCH_COMPILE_NGMODULE(type, meta);
    };
    /**
     * \@Annotation
     * \@publicApi
     * @type {?}
     */


    var NgModule = makeDecorator('NgModule', ɵ0$f, undefined, undefined, ɵ1$4);
    /**
     * \@description
     * Hook for manual bootstrapping of the application instead of using bootstrap array in \@NgModule
     * annotation.
     *
     * Reference to the current application is provided as a parameter.
     *
     * See ["Bootstrapping"](guide/bootstrapping) and ["Entry components"](guide/entry-components).
     *
     * \@usageNotes
     * ```typescript
     * class AppModule implements DoBootstrap {
     *   ngDoBootstrap(appRef: ApplicationRef) {
     *     appRef.bootstrap(AppComponent); // Or some other component
     *   }
     * }
     * ```
     *
     * \@publicApi
     * @record
     */

    function DoBootstrap() {}

    if (false) {}
    /**
     * @param {?} moduleType
     * @param {?=} metadata
     * @return {?}
     */


    function preR3NgModuleCompile(moduleType, metadata) {
      /** @type {?} */
      var imports = metadata && metadata.imports || [];

      if (metadata && metadata.exports) {
        imports = [].concat(_toConsumableArray(imports), [metadata.exports]);
      }

      /** @type {?} */
      moduleType.ɵinj = ɵɵdefineInjector({
        factory: convertInjectableProviderToFactory(moduleType, {
          useClass: moduleType
        }),
        providers: metadata && metadata.providers,
        imports: imports
      });
    }
    /** @type {?} */


    var SWITCH_COMPILE_NGMODULE__POST_R3__ = compileNgModule;
    /** @type {?} */

    var SWITCH_COMPILE_NGMODULE__PRE_R3__ = preR3NgModuleCompile;
    /** @type {?} */

    var SWITCH_COMPILE_NGMODULE = SWITCH_COMPILE_NGMODULE__POST_R3__;
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/metadata.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/application_init.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * An injection token that allows you to provide one or more initialization functions.
     * These function are injected at application startup and executed during
     * app initialization. If any of these functions returns a Promise, initialization
     * does not complete until the Promise is resolved.
     *
     * You can, for example, create a factory function that loads language data
     * or an external configuration, and provide that function to the `APP_INITIALIZER` token.
     * That way, the function is executed during the application bootstrap process,
     * and the needed data is available on startup.
     *
     * \@publicApi
     * @type {?}
     */

    var APP_INITIALIZER = new InjectionToken('Application Initializer');
    /**
     * A class that reflects the state of running {\@link APP_INITIALIZER}s.
     *
     * \@publicApi
     */

    var ApplicationInitStatus = /*#__PURE__*/function () {
      /**
       * @param {?} appInits
       */
      function ApplicationInitStatus(appInits) {
        var _this169 = this;

        _classCallCheck(this, ApplicationInitStatus);

        this.appInits = appInits;
        this.initialized = false;
        this.done = false;
        this.donePromise = new Promise(
        /**
        * @param {?} res
        * @param {?} rej
        * @return {?}
        */
        function (res, rej) {
          _this169.resolve = res;
          _this169.reject = rej;
        });
      }
      /**
       * \@internal
       * @return {?}
       */


      _createClass2(ApplicationInitStatus, [{
        key: "runInitializers",
        value: function runInitializers() {
          var _this170 = this;

          if (this.initialized) {
            return;
          }
          /** @type {?} */


          var asyncInitPromises = [];
          /** @type {?} */

          var complete =
          /**
          * @return {?}
          */
          function complete() {
            /** @type {?} */
            _this170.done = true;

            _this170.resolve();
          };

          if (this.appInits) {
            for (var i = 0; i < this.appInits.length; i++) {
              /** @type {?} */
              var initResult = this.appInits[i]();

              if (isPromise(initResult)) {
                asyncInitPromises.push(initResult);
              }
            }
          }

          Promise.all(asyncInitPromises).then(
          /**
          * @return {?}
          */
          function () {
            complete();
          })["catch"](
          /**
          * @param {?} e
          * @return {?}
          */
          function (e) {
            _this170.reject(e);
          });

          if (asyncInitPromises.length === 0) {
            complete();
          }

          this.initialized = true;
        }
      }]);

      return ApplicationInitStatus;
    }();

    ApplicationInitStatus.ɵfac = function ApplicationInitStatus_Factory(t) {
      return new (t || ApplicationInitStatus)(ɵɵinject(APP_INITIALIZER, 8));
    };

    ApplicationInitStatus.ɵprov = ɵɵdefineInjectable({
      token: ApplicationInitStatus,
      factory: ApplicationInitStatus.ɵfac
    });
    /** @nocollapse */

    ApplicationInitStatus.ctorParameters = function () {
      return [{
        type: Array,
        decorators: [{
          type: Inject,
          args: [APP_INITIALIZER]
        }, {
          type: Optional
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      setClassMetadata(ApplicationInitStatus, [{
        type: Injectable
      }], function () {
        return [{
          type: Array,
          decorators: [{
            type: Inject,
            args: [APP_INITIALIZER]
          }, {
            type: Optional
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/application_tokens.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * A DI Token representing a unique string id assigned to the application by Angular and used
     * primarily for prefixing application attributes and CSS styles when
     * {\@link ViewEncapsulation#Emulated ViewEncapsulation.Emulated} is being used.
     *
     * If you need to avoid randomly generated value to be used as an application id, you can provide
     * a custom value via a DI provider <!-- TODO: provider --> configuring the root {\@link Injector}
     * using this token.
     * \@publicApi
     * @type {?}
     */


    var APP_ID = new InjectionToken('AppId');
    /**
     * @return {?}
     */

    function _appIdRandomProviderFactory() {
      return "".concat(_randomChar()).concat(_randomChar()).concat(_randomChar());
    }
    /**
     * Providers that will generate a random APP_ID_TOKEN.
     * \@publicApi
     * @type {?}
     */


    var APP_ID_RANDOM_PROVIDER = {
      provide: APP_ID,
      useFactory: _appIdRandomProviderFactory,
      deps:
      /** @type {?} */
      []
    };
    /**
     * @return {?}
     */

    function _randomChar() {
      return String.fromCharCode(97 + Math.floor(Math.random() * 25));
    }
    /**
     * A function that will be executed when a platform is initialized.
     * \@publicApi
     * @type {?}
     */


    var PLATFORM_INITIALIZER = new InjectionToken('Platform Initializer');
    /**
     * A token that indicates an opaque platform id.
     * \@publicApi
     * @type {?}
     */

    var PLATFORM_ID = new InjectionToken('Platform ID');
    /**
     * All callbacks provided via this token will be called for every component that is bootstrapped.
     * Signature of the callback:
     *
     * `(componentRef: ComponentRef) => void`.
     *
     * \@publicApi
     * @type {?}
     */

    var APP_BOOTSTRAP_LISTENER = new InjectionToken('appBootstrapListener');
    /**
     * A token which indicates the root directory of the application
     * \@publicApi
     * @type {?}
     */

    var PACKAGE_ROOT_URL = new InjectionToken('Application Packages Root URL');
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/console.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    var Console = /*#__PURE__*/function () {
      function Console() {
        _classCallCheck(this, Console);
      }

      _createClass2(Console, [{
        key: "log",

        /**
         * @param {?} message
         * @return {?}
         */
        value: function log(message) {
          // tslint:disable-next-line:no-console
          console.log(message);
        } // Note: for reporting errors use `DOM.logError()` as it is platform specific

        /**
         * @param {?} message
         * @return {?}
         */

      }, {
        key: "warn",
        value: function warn(message) {
          // tslint:disable-next-line:no-console
          console.warn(message);
        }
      }]);

      return Console;
    }();

    Console.ɵfac = function Console_Factory(t) {
      return new (t || Console)();
    };

    Console.ɵprov = ɵɵdefineInjectable({
      token: Console,
      factory: Console.ɵfac
    });
    /*@__PURE__*/

    (function () {
      setClassMetadata(Console, [{
        type: Injectable
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/i18n/tokens.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Provide this token to set the locale of your application.
     * It is used for i18n extraction, by i18n pipes (DatePipe, I18nPluralPipe, CurrencyPipe,
     * DecimalPipe and PercentPipe) and by ICU expressions.
     *
     * See the [i18n guide](guide/i18n#setting-up-locale) for more information.
     *
     * \@usageNotes
     * ### Example
     *
     * ```typescript
     * import { LOCALE_ID } from '\@angular/core';
     * import { platformBrowserDynamic } from '\@angular/platform-browser-dynamic';
     * import { AppModule } from './app/app.module';
     *
     * platformBrowserDynamic().bootstrapModule(AppModule, {
     *   providers: [{provide: LOCALE_ID, useValue: 'en-US' }]
     * });
     * ```
     *
     * \@publicApi
     * @type {?}
     */


    var LOCALE_ID$1 = new InjectionToken('LocaleId');
    /**
     * Provide this token to set the default currency code your application uses for
     * CurrencyPipe when there is no currency code passed into it. This is only used by
     * CurrencyPipe and has no relation to locale currency. Defaults to USD if not configured.
     *
     * See the [i18n guide](guide/i18n#setting-up-locale) for more information.
     *
     * <div class="alert is-helpful">
     *
     * **Deprecation notice:**
     *
     * The default currency code is currently always `USD` but this is deprecated from v9.
     *
     * **In v10 the default currency code will be taken from the current locale.**
     *
     * If you need the previous behavior then set it by creating a `DEFAULT_CURRENCY_CODE` provider in
     * your application `NgModule`:
     *
     * ```ts
     * {provide: DEFAULT_CURRENCY_CODE, useValue: 'USD'}
     * ```
     *
     * </div>
     *
     * \@usageNotes
     * ### Example
     *
     * ```typescript
     * import { platformBrowserDynamic } from '\@angular/platform-browser-dynamic';
     * import { AppModule } from './app/app.module';
     *
     * platformBrowserDynamic().bootstrapModule(AppModule, {
     *   providers: [{provide: DEFAULT_CURRENCY_CODE, useValue: 'EUR' }]
     * });
     * ```
     *
     * \@publicApi
     * @type {?}
     */

    var DEFAULT_CURRENCY_CODE = new InjectionToken('DefaultCurrencyCode');
    /**
     * Use this token at bootstrap to provide the content of your translation file (`xtb`,
     * `xlf` or `xlf2`) when you want to translate your application in another language.
     *
     * See the [i18n guide](guide/i18n#merge) for more information.
     *
     * \@usageNotes
     * ### Example
     *
     * ```typescript
     * import { TRANSLATIONS } from '\@angular/core';
     * import { platformBrowserDynamic } from '\@angular/platform-browser-dynamic';
     * import { AppModule } from './app/app.module';
     *
     * // content of your translation file
     * const translations = '....';
     *
     * platformBrowserDynamic().bootstrapModule(AppModule, {
     *   providers: [{provide: TRANSLATIONS, useValue: translations }]
     * });
     * ```
     *
     * \@publicApi
     * @type {?}
     */

    var TRANSLATIONS = new InjectionToken('Translations');
    /**
     * Provide this token at bootstrap to set the format of your {\@link TRANSLATIONS}: `xtb`,
     * `xlf` or `xlf2`.
     *
     * See the [i18n guide](guide/i18n#merge) for more information.
     *
     * \@usageNotes
     * ### Example
     *
     * ```typescript
     * import { TRANSLATIONS_FORMAT } from '\@angular/core';
     * import { platformBrowserDynamic } from '\@angular/platform-browser-dynamic';
     * import { AppModule } from './app/app.module';
     *
     * platformBrowserDynamic().bootstrapModule(AppModule, {
     *   providers: [{provide: TRANSLATIONS_FORMAT, useValue: 'xlf' }]
     * });
     * ```
     *
     * \@publicApi
     * @type {?}
     */

    var TRANSLATIONS_FORMAT = new InjectionToken('TranslationsFormat');
    /** @enum {number} */

    var MissingTranslationStrategy = {
      Error: 0,
      Warning: 1,
      Ignore: 2
    };
    MissingTranslationStrategy[MissingTranslationStrategy.Error] = 'Error';
    MissingTranslationStrategy[MissingTranslationStrategy.Warning] = 'Warning';
    MissingTranslationStrategy[MissingTranslationStrategy.Ignore] = 'Ignore';
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/ivy_switch.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** @type {?} */

    var SWITCH_IVY_ENABLED__POST_R3__ = true;
    /** @type {?} */

    var SWITCH_IVY_ENABLED__PRE_R3__ = false;
    /** @type {?} */

    var ivyEnabled = SWITCH_IVY_ENABLED__POST_R3__;
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/linker/compiler.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Combination of NgModuleFactory and ComponentFactorys.
     *
     * \@publicApi
     * @template T
     */

    var ModuleWithComponentFactories =
    /**
     * @param {?} ngModuleFactory
     * @param {?} componentFactories
     */
    function ModuleWithComponentFactories(ngModuleFactory, componentFactories) {
      _classCallCheck(this, ModuleWithComponentFactories);

      this.ngModuleFactory = ngModuleFactory;
      this.componentFactories = componentFactories;
    };

    if (false) {}
    /**
     * @return {?}
     */


    function _throwError() {
      throw new Error("Runtime compiler is not loaded");
    }
    /** @type {?} */


    var Compiler_compileModuleSync__PRE_R3__ =
    /** @type {?} */
    _throwError;
    /** @type {?} */

    var Compiler_compileModuleSync__POST_R3__ =
    /**
    * @template T
    * @param {?} moduleType
    * @return {?}
    */
    function Compiler_compileModuleSync__POST_R3__(moduleType) {
      return new NgModuleFactory$1(moduleType);
    };
    /** @type {?} */


    var Compiler_compileModuleSync = Compiler_compileModuleSync__POST_R3__;
    /** @type {?} */

    var Compiler_compileModuleAsync__PRE_R3__ =
    /** @type {?} */
    _throwError;
    /** @type {?} */

    var Compiler_compileModuleAsync__POST_R3__ =
    /**
    * @template T
    * @param {?} moduleType
    * @return {?}
    */
    function Compiler_compileModuleAsync__POST_R3__(moduleType) {
      return Promise.resolve(Compiler_compileModuleSync__POST_R3__(moduleType));
    };
    /** @type {?} */


    var Compiler_compileModuleAsync = Compiler_compileModuleAsync__POST_R3__;
    /** @type {?} */

    var Compiler_compileModuleAndAllComponentsSync__PRE_R3__ =
    /** @type {?} */
    _throwError;
    /** @type {?} */

    var Compiler_compileModuleAndAllComponentsSync__POST_R3__ =
    /**
    * @template T
    * @param {?} moduleType
    * @return {?}
    */
    function Compiler_compileModuleAndAllComponentsSync__POST_R3__(moduleType) {
      /** @type {?} */
      var ngModuleFactory = Compiler_compileModuleSync__POST_R3__(moduleType);
      /** @type {?} */

      var moduleDef =
      /** @type {?} */
      getNgModuleDef(moduleType);
      /** @type {?} */

      var componentFactories = maybeUnwrapFn(moduleDef.declarations).reduce(
      /**
      * @param {?} factories
      * @param {?} declaration
      * @return {?}
      */
      function (factories, declaration) {
        /** @type {?} */
        var componentDef = getComponentDef(declaration);
        componentDef && factories.push(new ComponentFactory$1(componentDef));
        return factories;
      },
      /** @type {?} */
      []);
      return new ModuleWithComponentFactories(ngModuleFactory, componentFactories);
    };
    /** @type {?} */


    var Compiler_compileModuleAndAllComponentsSync = Compiler_compileModuleAndAllComponentsSync__POST_R3__;
    /** @type {?} */

    var Compiler_compileModuleAndAllComponentsAsync__PRE_R3__ =
    /** @type {?} */
    _throwError;
    /** @type {?} */

    var Compiler_compileModuleAndAllComponentsAsync__POST_R3__ =
    /**
    * @template T
    * @param {?} moduleType
    * @return {?}
    */
    function Compiler_compileModuleAndAllComponentsAsync__POST_R3__(moduleType) {
      return Promise.resolve(Compiler_compileModuleAndAllComponentsSync__POST_R3__(moduleType));
    };
    /** @type {?} */


    var Compiler_compileModuleAndAllComponentsAsync = Compiler_compileModuleAndAllComponentsAsync__POST_R3__;
    /**
     * Low-level service for running the angular compiler during runtime
     * to create {\@link ComponentFactory}s, which
     * can later be used to create and render a Component instance.
     *
     * Each `\@NgModule` provides an own `Compiler` to its injector,
     * that will use the directives/pipes of the ng module for compilation
     * of components.
     *
     * \@publicApi
     */

    var Compiler = /*#__PURE__*/function () {
      function Compiler() {
        _classCallCheck(this, Compiler);

        /**
         * Compiles the given NgModule and all of its components. All templates of the components listed
         * in `entryComponents` have to be inlined.
         */
        this.compileModuleSync = Compiler_compileModuleSync;
        /**
         * Compiles the given NgModule and all of its components
         */

        this.compileModuleAsync = Compiler_compileModuleAsync;
        /**
         * Same as {\@link #compileModuleSync} but also creates ComponentFactories for all components.
         */

        this.compileModuleAndAllComponentsSync = Compiler_compileModuleAndAllComponentsSync;
        /**
         * Same as {\@link #compileModuleAsync} but also creates ComponentFactories for all components.
         */

        this.compileModuleAndAllComponentsAsync = Compiler_compileModuleAndAllComponentsAsync;
      }
      /**
       * Clears all caches.
       * @return {?}
       */


      _createClass2(Compiler, [{
        key: "clearCache",
        value: function clearCache() {}
        /**
         * Clears the cache for the given component/ngModule.
         * @param {?} type
         * @return {?}
         */

      }, {
        key: "clearCacheFor",
        value: function clearCacheFor(type) {}
        /**
         * Returns the id for a given NgModule, if one is defined and known to the compiler.
         * @param {?} moduleType
         * @return {?}
         */

      }, {
        key: "getModuleId",
        value: function getModuleId(moduleType) {
          return undefined;
        }
      }]);

      return Compiler;
    }();

    Compiler.ɵfac = function Compiler_Factory(t) {
      return new (t || Compiler)();
    };

    Compiler.ɵprov = ɵɵdefineInjectable({
      token: Compiler,
      factory: Compiler.ɵfac
    });
    /*@__PURE__*/

    (function () {
      setClassMetadata(Compiler, [{
        type: Injectable
      }], function () {
        return [];
      }, null);
    })();

    if (false) {}
    /**
     * Token to provide CompilerOptions in the platform injector.
     *
     * \@publicApi
     * @type {?}
     */


    var COMPILER_OPTIONS = new InjectionToken('compilerOptions');
    /**
     * A factory for creating a Compiler
     *
     * \@publicApi
     * @abstract
     */

    var CompilerFactory = function CompilerFactory() {
      _classCallCheck(this, CompilerFactory);
    };

    if (false) {}
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */


    var promise = function () {
      return Promise.resolve(0);
    }();

    function scheduleMicroTask(fn) {
      if (typeof Zone === 'undefined') {
        // use promise to schedule microTask instead of use Zone
        promise.then(function () {
          fn && fn.apply(null, null);
        });
      } else {
        Zone.current.scheduleMicroTask('scheduleMicrotask', fn);
      }
    }
    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */


    function getNativeRequestAnimationFrame() {
      var nativeRequestAnimationFrame = _global['requestAnimationFrame'];
      var nativeCancelAnimationFrame = _global['cancelAnimationFrame'];

      if (typeof Zone !== 'undefined' && nativeRequestAnimationFrame && nativeCancelAnimationFrame) {
        // use unpatched version of requestAnimationFrame(native delegate) if possible
        // to avoid another Change detection
        var unpatchedRequestAnimationFrame = nativeRequestAnimationFrame[Zone.__symbol__('OriginalDelegate')];

        if (unpatchedRequestAnimationFrame) {
          nativeRequestAnimationFrame = unpatchedRequestAnimationFrame;
        }

        var unpatchedCancelAnimationFrame = nativeCancelAnimationFrame[Zone.__symbol__('OriginalDelegate')];

        if (unpatchedCancelAnimationFrame) {
          nativeCancelAnimationFrame = unpatchedCancelAnimationFrame;
        }
      }

      return {
        nativeRequestAnimationFrame: nativeRequestAnimationFrame,
        nativeCancelAnimationFrame: nativeCancelAnimationFrame
      };
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/zone/ng_zone.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * An injectable service for executing work inside or outside of the Angular zone.
     *
     * The most common use of this service is to optimize performance when starting a work consisting of
     * one or more asynchronous tasks that don't require UI updates or error handling to be handled by
     * Angular. Such tasks can be kicked off via {\@link #runOutsideAngular} and if needed, these tasks
     * can reenter the Angular zone via {\@link #run}.
     *
     * <!-- TODO: add/fix links to:
     *   - docs explaining zones and the use of zones in Angular and change-detection
     *   - link to runOutsideAngular/run (throughout this file!)
     *   -->
     *
     * \@usageNotes
     * ### Example
     *
     * ```
     * import {Component, NgZone} from '\@angular/core';
     * import {NgIf} from '\@angular/common';
     *
     * \@Component({
     *   selector: 'ng-zone-demo',
     *   template: `
     *     <h2>Demo: NgZone</h2>
     *
     *     <p>Progress: {{progress}}%</p>
     *     <p *ngIf="progress >= 100">Done processing {{label}} of Angular zone!</p>
     *
     *     <button (click)="processWithinAngularZone()">Process within Angular zone</button>
     *     <button (click)="processOutsideOfAngularZone()">Process outside of Angular zone</button>
     *   `,
     * })
     * export class NgZoneDemo {
     *   progress: number = 0;
     *   label: string;
     *
     *   constructor(private _ngZone: NgZone) {}
     *
     *   // Loop inside the Angular zone
     *   // so the UI DOES refresh after each setTimeout cycle
     *   processWithinAngularZone() {
     *     this.label = 'inside';
     *     this.progress = 0;
     *     this._increaseProgress(() => console.log('Inside Done!'));
     *   }
     *
     *   // Loop outside of the Angular zone
     *   // so the UI DOES NOT refresh after each setTimeout cycle
     *   processOutsideOfAngularZone() {
     *     this.label = 'outside';
     *     this.progress = 0;
     *     this._ngZone.runOutsideAngular(() => {
     *       this._increaseProgress(() => {
     *         // reenter the Angular zone and display done
     *         this._ngZone.run(() => { console.log('Outside Done!'); });
     *       });
     *     });
     *   }
     *
     *   _increaseProgress(doneCallback: () => void) {
     *     this.progress += 1;
     *     console.log(`Current progress: ${this.progress}%`);
     *
     *     if (this.progress < 100) {
     *       window.setTimeout(() => this._increaseProgress(doneCallback), 10);
     *     } else {
     *       doneCallback();
     *     }
     *   }
     * }
     * ```
     *
     * \@publicApi
     */


    var NgZone = /*#__PURE__*/function () {
      /**
       * @param {?} __0
       */
      function NgZone(_ref10) {
        var _ref10$enableLongStac = _ref10.enableLongStackTrace,
            enableLongStackTrace = _ref10$enableLongStac === void 0 ? false : _ref10$enableLongStac,
            _ref10$shouldCoalesce = _ref10.shouldCoalesceEventChangeDetection,
            shouldCoalesceEventChangeDetection = _ref10$shouldCoalesce === void 0 ? false : _ref10$shouldCoalesce;

        _classCallCheck(this, NgZone);

        this.hasPendingMacrotasks = false;
        this.hasPendingMicrotasks = false;
        /**
         * Whether there are no outstanding microtasks or macrotasks.
         */

        this.isStable = true;
        /**
         * Notifies when code enters Angular Zone. This gets fired first on VM Turn.
         */

        this.onUnstable = new EventEmitter(false);
        /**
         * Notifies when there is no more microtasks enqueued in the current VM Turn.
         * This is a hint for Angular to do change detection, which may enqueue more microtasks.
         * For this reason this event can fire multiple times per VM Turn.
         */

        this.onMicrotaskEmpty = new EventEmitter(false);
        /**
         * Notifies when the last `onMicrotaskEmpty` has run and there are no more microtasks, which
         * implies we are about to relinquish VM turn.
         * This event gets called just once.
         */

        this.onStable = new EventEmitter(false);
        /**
         * Notifies that an error has been delivered.
         */

        this.onError = new EventEmitter(false);

        if (typeof Zone == 'undefined') {
          throw new Error("In this configuration Angular requires Zone.js");
        }

        Zone.assertZonePatched();
        /** @type {?} */

        var self =
        /** @type {?} */

        /** @type {?} */
        this;
        self._nesting = 0;
        self._outer = self._inner = Zone.current;

        if (
        /** @type {?} */
        Zone['wtfZoneSpec']) {
          self._inner = self._inner.fork(
          /** @type {?} */
          Zone['wtfZoneSpec']);
        }

        if (
        /** @type {?} */
        Zone['TaskTrackingZoneSpec']) {
          self._inner = self._inner.fork(new
          /** @type {?} */

          /** @type {?} */
          Zone['TaskTrackingZoneSpec']());
        }

        if (enableLongStackTrace &&
        /** @type {?} */
        Zone['longStackTraceZoneSpec']) {
          self._inner = self._inner.fork(
          /** @type {?} */
          Zone['longStackTraceZoneSpec']);
        }

        self.shouldCoalesceEventChangeDetection = shouldCoalesceEventChangeDetection;
        self.lastRequestAnimationFrameId = -1;
        self.nativeRequestAnimationFrame = getNativeRequestAnimationFrame().nativeRequestAnimationFrame;
        forkInnerZoneWithAngularBehavior(self);
      }
      /**
       * @return {?}
       */


      _createClass2(NgZone, [{
        key: "run",

        /**
         * Executes the `fn` function synchronously within the Angular zone and returns value returned by
         * the function.
         *
         * Running functions via `run` allows you to reenter Angular zone from a task that was executed
         * outside of the Angular zone (typically started via {\@link #runOutsideAngular}).
         *
         * Any future tasks or microtasks scheduled from within this function will continue executing from
         * within the Angular zone.
         *
         * If a synchronous error happens it will be rethrown and not reported via `onError`.
         * @template T
         * @param {?} fn
         * @param {?=} applyThis
         * @param {?=} applyArgs
         * @return {?}
         */
        value: function run(fn, applyThis, applyArgs) {
          return (
            /** @type {?} */

            /** @type {?} */

            /** @type {?} */
            this._inner.run(fn, applyThis, applyArgs)
          );
        }
        /**
         * Executes the `fn` function synchronously within the Angular zone as a task and returns value
         * returned by the function.
         *
         * Running functions via `run` allows you to reenter Angular zone from a task that was executed
         * outside of the Angular zone (typically started via {\@link #runOutsideAngular}).
         *
         * Any future tasks or microtasks scheduled from within this function will continue executing from
         * within the Angular zone.
         *
         * If a synchronous error happens it will be rethrown and not reported via `onError`.
         * @template T
         * @param {?} fn
         * @param {?=} applyThis
         * @param {?=} applyArgs
         * @param {?=} name
         * @return {?}
         */

      }, {
        key: "runTask",
        value: function runTask(fn, applyThis, applyArgs, name) {
          /** @type {?} */
          var zone =
          /** @type {?} */

          /** @type {?} */
          this._inner;
          /** @type {?} */

          var task = zone.scheduleEventTask('NgZoneEvent: ' + name, fn, EMPTY_PAYLOAD, noop$1, noop$1);

          try {
            return (
              /** @type {?} */
              zone.runTask(task, applyThis, applyArgs)
            );
          } finally {
            zone.cancelTask(task);
          }
        }
        /**
         * Same as `run`, except that synchronous errors are caught and forwarded via `onError` and not
         * rethrown.
         * @template T
         * @param {?} fn
         * @param {?=} applyThis
         * @param {?=} applyArgs
         * @return {?}
         */

      }, {
        key: "runGuarded",
        value: function runGuarded(fn, applyThis, applyArgs) {
          return (
            /** @type {?} */

            /** @type {?} */

            /** @type {?} */
            this._inner.runGuarded(fn, applyThis, applyArgs)
          );
        }
        /**
         * Executes the `fn` function synchronously in Angular's parent zone and returns value returned by
         * the function.
         *
         * Running functions via {\@link #runOutsideAngular} allows you to escape Angular's zone and do
         * work that
         * doesn't trigger Angular change-detection or is subject to Angular's error handling.
         *
         * Any future tasks or microtasks scheduled from within this function will continue executing from
         * outside of the Angular zone.
         *
         * Use {\@link #run} to reenter the Angular zone and do work that updates the application model.
         * @template T
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "runOutsideAngular",
        value: function runOutsideAngular(fn) {
          return (
            /** @type {?} */

            /** @type {?} */

            /** @type {?} */
            this._outer.run(fn)
          );
        }
      }], [{
        key: "isInAngularZone",
        value: function isInAngularZone() {
          return Zone.current.get('isAngularZone') === true;
        }
        /**
         * @return {?}
         */

      }, {
        key: "assertInAngularZone",
        value: function assertInAngularZone() {
          if (!NgZone.isInAngularZone()) {
            throw new Error('Expected to be in Angular Zone, but it is not!');
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "assertNotInAngularZone",
        value: function assertNotInAngularZone() {
          if (NgZone.isInAngularZone()) {
            throw new Error('Expected to not be in Angular Zone, but it is!');
          }
        }
      }]);

      return NgZone;
    }();

    if (false) {}
    /**
     * @return {?}
     */


    function noop$1() {}
    /** @type {?} */


    var EMPTY_PAYLOAD = {};
    /**
     * @record
     */

    function NgZonePrivate() {}

    if (false) {}
    /**
     * @param {?} zone
     * @return {?}
     */


    function checkStable(zone) {
      if (zone._nesting == 0 && !zone.hasPendingMicrotasks && !zone.isStable) {
        try {
          zone._nesting++;
          zone.onMicrotaskEmpty.emit(null);
        } finally {
          zone._nesting--;

          if (!zone.hasPendingMicrotasks) {
            try {
              zone.runOutsideAngular(
              /**
              * @return {?}
              */
              function () {
                return zone.onStable.emit(null);
              });
            } finally {
              zone.isStable = true;
            }
          }
        }
      }
    }
    /**
     * @param {?} zone
     * @return {?}
     */


    function delayChangeDetectionForEvents(zone) {
      if (zone.lastRequestAnimationFrameId !== -1) {
        return;
      }

      zone.lastRequestAnimationFrameId = zone.nativeRequestAnimationFrame.call(_global,
      /**
      * @return {?}
      */
      function () {
        zone.lastRequestAnimationFrameId = -1;
        updateMicroTaskStatus(zone);
        checkStable(zone);
      });
      updateMicroTaskStatus(zone);
    }
    /**
     * @param {?} zone
     * @return {?}
     */


    function forkInnerZoneWithAngularBehavior(zone) {
      /** @type {?} */
      var delayChangeDetectionForEventsDelegate =
      /**
      * @return {?}
      */
      function delayChangeDetectionForEventsDelegate() {
        delayChangeDetectionForEvents(zone);
      };
      /** @type {?} */


      var maybeDelayChangeDetection = !!zone.shouldCoalesceEventChangeDetection && zone.nativeRequestAnimationFrame && delayChangeDetectionForEventsDelegate;
      zone._inner = zone._inner.fork({
        name: 'angular',
        properties:
        /** @type {?} */
        {
          'isAngularZone': true,
          'maybeDelayChangeDetection': maybeDelayChangeDetection
        },
        onInvokeTask:
        /**
        * @param {?} delegate
        * @param {?} current
        * @param {?} target
        * @param {?} task
        * @param {?} applyThis
        * @param {?} applyArgs
        * @return {?}
        */
        function onInvokeTask(delegate, current, target, task, applyThis, applyArgs) {
          try {
            onEnter(zone);
            return delegate.invokeTask(target, task, applyThis, applyArgs);
          } finally {
            if (maybeDelayChangeDetection && task.type === 'eventTask') {
              maybeDelayChangeDetection();
            }

            onLeave(zone);
          }
        },
        onInvoke:
        /**
        * @param {?} delegate
        * @param {?} current
        * @param {?} target
        * @param {?} callback
        * @param {?} applyThis
        * @param {?=} applyArgs
        * @param {?=} source
        * @return {?}
        */
        function onInvoke(delegate, current, target, callback, applyThis, applyArgs, source) {
          try {
            onEnter(zone);
            return delegate.invoke(target, callback, applyThis, applyArgs, source);
          } finally {
            onLeave(zone);
          }
        },
        onHasTask:
        /**
        * @param {?} delegate
        * @param {?} current
        * @param {?} target
        * @param {?} hasTaskState
        * @return {?}
        */
        function onHasTask(delegate, current, target, hasTaskState) {
          delegate.hasTask(target, hasTaskState);

          if (current === target) {
            // We are only interested in hasTask events which originate from our zone
            // (A child hasTask event is not interesting to us)
            if (hasTaskState.change == 'microTask') {
              zone._hasPendingMicrotasks = hasTaskState.microTask;
              updateMicroTaskStatus(zone);
              checkStable(zone);
            } else if (hasTaskState.change == 'macroTask') {
              zone.hasPendingMacrotasks = hasTaskState.macroTask;
            }
          }
        },
        onHandleError:
        /**
        * @param {?} delegate
        * @param {?} current
        * @param {?} target
        * @param {?} error
        * @return {?}
        */
        function onHandleError(delegate, current, target, error) {
          delegate.handleError(target, error);
          zone.runOutsideAngular(
          /**
          * @return {?}
          */
          function () {
            return zone.onError.emit(error);
          });
          return false;
        }
      });
    }
    /**
     * @param {?} zone
     * @return {?}
     */


    function updateMicroTaskStatus(zone) {
      if (zone._hasPendingMicrotasks || zone.shouldCoalesceEventChangeDetection && zone.lastRequestAnimationFrameId !== -1) {
        zone.hasPendingMicrotasks = true;
      } else {
        zone.hasPendingMicrotasks = false;
      }
    }
    /**
     * @param {?} zone
     * @return {?}
     */


    function onEnter(zone) {
      zone._nesting++;

      if (zone.isStable) {
        zone.isStable = false;
        zone.onUnstable.emit(null);
      }
    }
    /**
     * @param {?} zone
     * @return {?}
     */


    function onLeave(zone) {
      zone._nesting--;
      checkStable(zone);
    }
    /**
     * Provides a noop implementation of `NgZone` which does nothing. This zone requires explicit calls
     * to framework to perform rendering.
     */


    var NoopNgZone = /*#__PURE__*/function () {
      function NoopNgZone() {
        _classCallCheck(this, NoopNgZone);

        this.hasPendingMicrotasks = false;
        this.hasPendingMacrotasks = false;
        this.isStable = true;
        this.onUnstable = new EventEmitter();
        this.onMicrotaskEmpty = new EventEmitter();
        this.onStable = new EventEmitter();
        this.onError = new EventEmitter();
      }
      /**
       * @param {?} fn
       * @param {?=} applyThis
       * @param {?=} applyArgs
       * @return {?}
       */


      _createClass2(NoopNgZone, [{
        key: "run",
        value: function run(fn, applyThis, applyArgs) {
          return fn.apply(applyThis, applyArgs);
        }
        /**
         * @param {?} fn
         * @param {?=} applyThis
         * @param {?=} applyArgs
         * @return {?}
         */

      }, {
        key: "runGuarded",
        value: function runGuarded(fn, applyThis, applyArgs) {
          return fn.apply(applyThis, applyArgs);
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "runOutsideAngular",
        value: function runOutsideAngular(fn) {
          return fn();
        }
        /**
         * @param {?} fn
         * @param {?=} applyThis
         * @param {?=} applyArgs
         * @param {?=} name
         * @return {?}
         */

      }, {
        key: "runTask",
        value: function runTask(fn, applyThis, applyArgs, name) {
          return fn.apply(applyThis, applyArgs);
        }
      }]);

      return NoopNgZone;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/testability/testability.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @record
     */


    function PendingMacrotask() {}

    if (false) {}
    /**
     * @record
     */


    function TaskData() {}

    if (false) {}
    /**
     * @record
     */


    function WaitCallback() {}

    if (false) {}
    /**
     * The Testability service provides testing hooks that can be accessed from
     * the browser and by services such as Protractor. Each bootstrapped Angular
     * application on the page will have an instance of Testability.
     * \@publicApi
     */


    var Testability = /*#__PURE__*/function () {
      /**
       * @param {?} _ngZone
       */
      function Testability(_ngZone) {
        var _this171 = this;

        _classCallCheck(this, Testability);

        this._ngZone = _ngZone;
        this._pendingCount = 0;
        this._isZoneStable = true;
        /**
         * Whether any work was done since the last 'whenStable' callback. This is
         * useful to detect if this could have potentially destabilized another
         * component while it is stabilizing.
         * \@internal
         */

        this._didWork = false;
        this._callbacks = [];
        this.taskTrackingZone = null;

        this._watchAngularEvents();

        _ngZone.run(
        /**
        * @return {?}
        */
        function () {
          _this171.taskTrackingZone = typeof Zone == 'undefined' ? null : Zone.current.get('TaskTrackingZone');
        });
      }
      /**
       * @private
       * @return {?}
       */


      _createClass2(Testability, [{
        key: "_watchAngularEvents",
        value: function _watchAngularEvents() {
          var _this172 = this;

          this._ngZone.onUnstable.subscribe({
            next:
            /**
            * @return {?}
            */
            function next() {
              _this172._didWork = true;
              _this172._isZoneStable = false;
            }
          });

          this._ngZone.runOutsideAngular(
          /**
          * @return {?}
          */
          function () {
            _this172._ngZone.onStable.subscribe({
              next:
              /**
              * @return {?}
              */
              function next() {
                NgZone.assertNotInAngularZone();
                scheduleMicroTask(
                /**
                * @return {?}
                */
                function () {
                  _this172._isZoneStable = true;

                  _this172._runCallbacksIfReady();
                });
              }
            });
          });
        }
        /**
         * Increases the number of pending request
         * @deprecated pending requests are now tracked with zones.
         * @return {?}
         */

      }, {
        key: "increasePendingRequestCount",
        value: function increasePendingRequestCount() {
          this._pendingCount += 1;
          this._didWork = true;
          return this._pendingCount;
        }
        /**
         * Decreases the number of pending request
         * @deprecated pending requests are now tracked with zones
         * @return {?}
         */

      }, {
        key: "decreasePendingRequestCount",
        value: function decreasePendingRequestCount() {
          this._pendingCount -= 1;

          if (this._pendingCount < 0) {
            throw new Error('pending async requests below zero');
          }

          this._runCallbacksIfReady();

          return this._pendingCount;
        }
        /**
         * Whether an associated application is stable
         * @return {?}
         */

      }, {
        key: "isStable",
        value: function isStable() {
          return this._isZoneStable && this._pendingCount === 0 && !this._ngZone.hasPendingMacrotasks;
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_runCallbacksIfReady",
        value: function _runCallbacksIfReady() {
          var _this173 = this;

          if (this.isStable()) {
            // Schedules the call backs in a new frame so that it is always async.
            scheduleMicroTask(
            /**
            * @return {?}
            */
            function () {
              while (_this173._callbacks.length !== 0) {
                /** @type {?} */
                var cb =
                /** @type {?} */
                _this173._callbacks.pop();

                clearTimeout(cb.timeoutId);
                cb.doneCb(_this173._didWork);
              }

              _this173._didWork = false;
            });
          } else {
            // Still not stable, send updates.

            /** @type {?} */
            var pending = this.getPendingTasks();
            this._callbacks = this._callbacks.filter(
            /**
            * @param {?} cb
            * @return {?}
            */
            function (cb) {
              if (cb.updateCb && cb.updateCb(pending)) {
                clearTimeout(cb.timeoutId);
                return false;
              }

              return true;
            });
            this._didWork = true;
          }
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "getPendingTasks",
        value: function getPendingTasks() {
          if (!this.taskTrackingZone) {
            return [];
          } // Copy the tasks data so that we don't leak tasks.


          return this.taskTrackingZone.macroTasks.map(
          /**
          * @param {?} t
          * @return {?}
          */
          function (t) {
            return {
              source: t.source,
              // From TaskTrackingZone:
              // https://github.com/angular/zone.js/blob/master/lib/zone-spec/task-tracking.ts#L40
              creationLocation:
              /** @type {?} */

              /** @type {?} */
              t.creationLocation,
              data: t.data
            };
          });
        }
        /**
         * @private
         * @param {?} cb
         * @param {?=} timeout
         * @param {?=} updateCb
         * @return {?}
         */

      }, {
        key: "addCallback",
        value: function addCallback(cb, timeout, updateCb) {
          var _this174 = this;

          /** @type {?} */
          var timeoutId = -1;

          if (timeout && timeout > 0) {
            timeoutId = setTimeout(
            /**
            * @return {?}
            */
            function () {
              _this174._callbacks = _this174._callbacks.filter(
              /**
              * @param {?} cb
              * @return {?}
              */
              function (cb) {
                return cb.timeoutId !== timeoutId;
              });
              cb(_this174._didWork, _this174.getPendingTasks());
            }, timeout);
          }

          this._callbacks.push(
          /** @type {?} */
          {
            doneCb: cb,
            timeoutId: timeoutId,
            updateCb: updateCb
          });
        }
        /**
         * Wait for the application to be stable with a timeout. If the timeout is reached before that
         * happens, the callback receives a list of the macro tasks that were pending, otherwise null.
         *
         * @param {?} doneCb The callback to invoke when Angular is stable or the timeout expires
         *    whichever comes first.
         * @param {?=} timeout Optional. The maximum time to wait for Angular to become stable. If not
         *    specified, whenStable() will wait forever.
         * @param {?=} updateCb Optional. If specified, this callback will be invoked whenever the set of
         *    pending macrotasks changes. If this callback returns true doneCb will not be invoked
         *    and no further updates will be issued.
         * @return {?}
         */

      }, {
        key: "whenStable",
        value: function whenStable(doneCb, timeout, updateCb) {
          if (updateCb && !this.taskTrackingZone) {
            throw new Error('Task tracking zone is required when passing an update callback to ' + 'whenStable(). Is "zone.js/dist/task-tracking.js" loaded?');
          } // These arguments are 'Function' above to keep the public API simple.


          this.addCallback(
          /** @type {?} */
          doneCb, timeout,
          /** @type {?} */
          updateCb);

          this._runCallbacksIfReady();
        }
        /**
         * Get the number of pending requests
         * @deprecated pending requests are now tracked with zones
         * @return {?}
         */

      }, {
        key: "getPendingRequestCount",
        value: function getPendingRequestCount() {
          return this._pendingCount;
        }
        /**
         * Find providers by name
         * @param {?} using The root element to search from
         * @param {?} provider The name of binding variable
         * @param {?} exactMatch Whether using exactMatch
         * @return {?}
         */

      }, {
        key: "findProviders",
        value: function findProviders(using, provider, exactMatch) {
          // TODO(juliemr): implement.
          return [];
        }
      }]);

      return Testability;
    }();

    Testability.ɵfac = function Testability_Factory(t) {
      return new (t || Testability)(ɵɵinject(NgZone));
    };

    Testability.ɵprov = ɵɵdefineInjectable({
      token: Testability,
      factory: Testability.ɵfac
    });
    /** @nocollapse */

    Testability.ctorParameters = function () {
      return [{
        type: NgZone
      }];
    };
    /*@__PURE__*/


    (function () {
      setClassMetadata(Testability, [{
        type: Injectable
      }], function () {
        return [{
          type: NgZone
        }];
      }, null);
    })();

    if (false) {}
    /**
     * A global registry of {\@link Testability} instances for specific elements.
     * \@publicApi
     */


    var TestabilityRegistry = /*#__PURE__*/function () {
      function TestabilityRegistry() {
        _classCallCheck(this, TestabilityRegistry);

        /**
         * \@internal
         */
        this._applications = new Map();

        _testabilityGetter.addToWindow(this);
      }
      /**
       * Registers an application with a testability hook so that it can be tracked
       * @param {?} token token of application, root element
       * @param {?} testability Testability hook
       * @return {?}
       */


      _createClass2(TestabilityRegistry, [{
        key: "registerApplication",
        value: function registerApplication(token, testability) {
          this._applications.set(token, testability);
        }
        /**
         * Unregisters an application.
         * @param {?} token token of application, root element
         * @return {?}
         */

      }, {
        key: "unregisterApplication",
        value: function unregisterApplication(token) {
          this._applications["delete"](token);
        }
        /**
         * Unregisters all applications
         * @return {?}
         */

      }, {
        key: "unregisterAllApplications",
        value: function unregisterAllApplications() {
          this._applications.clear();
        }
        /**
         * Get a testability hook associated with the application
         * @param {?} elem root element
         * @return {?}
         */

      }, {
        key: "getTestability",
        value: function getTestability(elem) {
          return this._applications.get(elem) || null;
        }
        /**
         * Get all registered testabilities
         * @return {?}
         */

      }, {
        key: "getAllTestabilities",
        value: function getAllTestabilities() {
          return Array.from(this._applications.values());
        }
        /**
         * Get all registered applications(root elements)
         * @return {?}
         */

      }, {
        key: "getAllRootElements",
        value: function getAllRootElements() {
          return Array.from(this._applications.keys());
        }
        /**
         * Find testability of a node in the Tree
         * @param {?} elem node
         * @param {?=} findInAncestors whether finding testability in ancestors if testability was not found in
         * current node
         * @return {?}
         */

      }, {
        key: "findTestabilityInTree",
        value: function findTestabilityInTree(elem) {
          var findInAncestors = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
          return _testabilityGetter.findTestabilityInTree(this, elem, findInAncestors);
        }
      }]);

      return TestabilityRegistry;
    }();

    TestabilityRegistry.ɵfac = function TestabilityRegistry_Factory(t) {
      return new (t || TestabilityRegistry)();
    };

    TestabilityRegistry.ɵprov = ɵɵdefineInjectable({
      token: TestabilityRegistry,
      factory: TestabilityRegistry.ɵfac
    });
    /** @nocollapse */

    TestabilityRegistry.ctorParameters = function () {
      return [];
    };
    /*@__PURE__*/


    (function () {
      setClassMetadata(TestabilityRegistry, [{
        type: Injectable
      }], function () {
        return [];
      }, null);
    })();

    if (false) {}
    /**
     * Adapter interface for retrieving the `Testability` service associated for a
     * particular context.
     *
     * \@publicApi
     * @record
     */


    function GetTestability() {}

    if (false) {}

    var _NoopGetTestability = /*#__PURE__*/function () {
      function _NoopGetTestability() {
        _classCallCheck(this, _NoopGetTestability);
      }

      _createClass2(_NoopGetTestability, [{
        key: "addToWindow",

        /**
         * @param {?} registry
         * @return {?}
         */
        value: function addToWindow(registry) {}
        /**
         * @param {?} registry
         * @param {?} elem
         * @param {?} findInAncestors
         * @return {?}
         */

      }, {
        key: "findTestabilityInTree",
        value: function findTestabilityInTree(registry, elem, findInAncestors) {
          return null;
        }
      }]);

      return _NoopGetTestability;
    }();
    /**
     * Set the {\@link GetTestability} implementation used by the Angular testing framework.
     * \@publicApi
     * @param {?} getter
     * @return {?}
     */


    function setTestabilityGetter(getter) {
      _testabilityGetter = getter;
    }
    /** @type {?} */


    var _testabilityGetter = new _NoopGetTestability();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/application_ref.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var _platform;
    /** @type {?} */


    var compileNgModuleFactory = compileNgModuleFactory__POST_R3__;
    /**
     * @template M
     * @param {?} injector
     * @param {?} options
     * @param {?} moduleType
     * @return {?}
     */

    function compileNgModuleFactory__PRE_R3__(injector, options, moduleType) {
      /** @type {?} */
      var compilerFactory = injector.get(CompilerFactory);
      /** @type {?} */

      var compiler = compilerFactory.createCompiler([options]);
      return compiler.compileModuleAsync(moduleType);
    }
    /**
     * @template M
     * @param {?} injector
     * @param {?} options
     * @param {?} moduleType
     * @return {?}
     */


    function compileNgModuleFactory__POST_R3__(injector, options, moduleType) {
      ngDevMode && assertNgModuleType(moduleType);
      /** @type {?} */

      var compilerOptions = injector.get(COMPILER_OPTIONS, []).concat(options);

      if (typeof ngJitMode === 'undefined' || ngJitMode) {
        // Configure the compiler to use the provided options. This call may fail when multiple modules
        // are bootstrapped with incompatible options, as a component can only be compiled according to
        // a single set of options.
        setJitOptions({
          defaultEncapsulation: _lastDefined(compilerOptions.map(
          /**
          * @param {?} options
          * @return {?}
          */
          function (options) {
            return options.defaultEncapsulation;
          })),
          preserveWhitespaces: _lastDefined(compilerOptions.map(
          /**
          * @param {?} options
          * @return {?}
          */
          function (options) {
            return options.preserveWhitespaces;
          }))
        });
      }
      /** @type {?} */


      var moduleFactory = new NgModuleFactory$1(moduleType);

      if (isComponentResourceResolutionQueueEmpty()) {
        return Promise.resolve(moduleFactory);
      }
      /** @type {?} */


      var compilerProviders = _mergeArrays(compilerOptions.map(
      /**
      * @param {?} o
      * @return {?}
      */
      function (o) {
        return (
          /** @type {?} */
          o.providers
        );
      })); // In case there are no compiler providers, we just return the module factory as
      // there won't be any resource loader. This can happen with Ivy, because AOT compiled
      // modules can be still passed through "bootstrapModule". In that case we shouldn't
      // unnecessarily require the JIT compiler.


      if (compilerProviders.length === 0) {
        return Promise.resolve(moduleFactory);
      }
      /** @type {?} */


      var compiler = getCompilerFacade();
      /** @type {?} */

      var compilerInjector = Injector.create({
        providers: compilerProviders
      });
      /** @type {?} */

      var resourceLoader = compilerInjector.get(compiler.ResourceLoader); // The resource loader can also return a string while the "resolveComponentResources"
      // always expects a promise. Therefore we need to wrap the returned value in a promise.

      return resolveComponentResources(
      /**
      * @param {?} url
      * @return {?}
      */
      function (url) {
        return Promise.resolve(resourceLoader.get(url));
      }).then(
      /**
      * @return {?}
      */
      function () {
        return moduleFactory;
      });
    } // the `window.ng` global utilities are only available in non-VE versions of
    // Angular. The function switch below will make sure that the code is not
    // included into Angular when PRE mode is active.

    /**
     * @return {?}
     */


    function publishDefaultGlobalUtils__PRE_R3__() {}
    /**
     * @return {?}
     */


    function publishDefaultGlobalUtils__POST_R3__() {
      ngDevMode && publishDefaultGlobalUtils();
    }
    /** @type {?} */


    var publishDefaultGlobalUtils$1 = publishDefaultGlobalUtils__POST_R3__;
    /** @type {?} */

    var isBoundToModule = isBoundToModule__POST_R3__;
    /**
     * @template C
     * @param {?} cf
     * @return {?}
     */

    function isBoundToModule__PRE_R3__(cf) {
      return cf instanceof ComponentFactoryBoundToModule;
    }
    /**
     * @template C
     * @param {?} cf
     * @return {?}
     */


    function isBoundToModule__POST_R3__(cf) {
      return (
        /** @type {?} */
        cf.isBoundToModule
      );
    }
    /** @type {?} */


    var ALLOW_MULTIPLE_PLATFORMS = new InjectionToken('AllowMultipleToken');
    /**
     * A token for third-party components that can register themselves with NgProbe.
     *
     * \@publicApi
     */

    var NgProbeToken =
    /**
     * @param {?} name
     * @param {?} token
     */
    function NgProbeToken(name, token) {
      _classCallCheck(this, NgProbeToken);

      this.name = name;
      this.token = token;
    };

    if (false) {}
    /**
     * Creates a platform.
     * Platforms have to be eagerly created via this function.
     *
     * \@publicApi
     * @param {?} injector
     * @return {?}
     */


    function createPlatform(injector) {
      if (_platform && !_platform.destroyed && !_platform.injector.get(ALLOW_MULTIPLE_PLATFORMS, false)) {
        throw new Error('There can be only one platform. Destroy the previous one to create a new one.');
      }

      publishDefaultGlobalUtils$1();
      _platform = injector.get(PlatformRef);
      /** @type {?} */

      var inits = injector.get(PLATFORM_INITIALIZER, null);
      if (inits) inits.forEach(
      /**
      * @param {?} init
      * @return {?}
      */
      function (init) {
        return init();
      });
      return _platform;
    }
    /**
     * Creates a factory for a platform
     *
     * \@publicApi
     * @param {?} parentPlatformFactory
     * @param {?} name
     * @param {?=} providers
     * @return {?}
     */


    function createPlatformFactory(parentPlatformFactory, name) {
      var providers = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : [];

      /** @type {?} */
      var desc = "Platform: ".concat(name);
      /** @type {?} */

      var marker = new InjectionToken(desc);
      return (
        /**
        * @param {?=} extraProviders
        * @return {?}
        */
        function () {
          var extraProviders = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];

          /** @type {?} */
          var platform = getPlatform();

          if (!platform || platform.injector.get(ALLOW_MULTIPLE_PLATFORMS, false)) {
            if (parentPlatformFactory) {
              parentPlatformFactory(providers.concat(extraProviders).concat({
                provide: marker,
                useValue: true
              }));
            } else {
              /** @type {?} */
              var injectedProviders = providers.concat(extraProviders).concat({
                provide: marker,
                useValue: true
              }, {
                provide: INJECTOR_SCOPE,
                useValue: 'platform'
              });
              createPlatform(Injector.create({
                providers: injectedProviders,
                name: desc
              }));
            }
          }

          return assertPlatform(marker);
        }
      );
    }
    /**
     * Checks that there currently is a platform which contains the given token as a provider.
     *
     * \@publicApi
     * @param {?} requiredToken
     * @return {?}
     */


    function assertPlatform(requiredToken) {
      /** @type {?} */
      var platform = getPlatform();

      if (!platform) {
        throw new Error('No platform exists!');
      }

      if (!platform.injector.get(requiredToken, null)) {
        throw new Error('A platform with a different configuration has been created. Please destroy it first.');
      }

      return platform;
    }
    /**
     * Destroy the existing platform.
     *
     * \@publicApi
     * @return {?}
     */


    function destroyPlatform() {
      if (_platform && !_platform.destroyed) {
        _platform.destroy();
      }
    }
    /**
     * Returns the current platform.
     *
     * \@publicApi
     * @return {?}
     */


    function getPlatform() {
      return _platform && !_platform.destroyed ? _platform : null;
    }
    /**
     * Provides additional options to the bootstraping process.
     *
     *
     * @record
     */


    function BootstrapOptions() {}

    if (false) {}
    /**
     * The Angular platform is the entry point for Angular on a web page. Each page
     * has exactly one platform, and services (such as reflection) which are common
     * to every Angular application running on the page are bound in its scope.
     *
     * A page's platform is initialized implicitly when a platform is created via a platform factory
     * (e.g. {\@link platformBrowser}), or explicitly by calling the {\@link createPlatform} function.
     *
     * \@publicApi
     */


    var PlatformRef = /*#__PURE__*/function () {
      /**
       * \@internal
       * @param {?} _injector
       */
      function PlatformRef(_injector) {
        _classCallCheck(this, PlatformRef);

        this._injector = _injector;
        this._modules = [];
        this._destroyListeners = [];
        this._destroyed = false;
      }
      /**
       * Creates an instance of an `\@NgModule` for the given platform
       * for offline compilation.
       *
       * \@usageNotes
       * ### Simple Example
       *
       * ```typescript
       * my_module.ts:
       *
       * \@NgModule({
       *   imports: [BrowserModule]
       * })
       * class MyModule {}
       *
       * main.ts:
       * import {MyModuleNgFactory} from './my_module.ngfactory';
       * import {platformBrowser} from '\@angular/platform-browser';
       *
       * let moduleRef = platformBrowser().bootstrapModuleFactory(MyModuleNgFactory);
       * ```
       * @template M
       * @param {?} moduleFactory
       * @param {?=} options
       * @return {?}
       */


      _createClass2(PlatformRef, [{
        key: "bootstrapModuleFactory",
        value: function bootstrapModuleFactory(moduleFactory, options) {
          var _this175 = this;

          // Note: We need to create the NgZone _before_ we instantiate the module,
          // as instantiating the module creates some providers eagerly.
          // So we create a mini parent injector that just contains the new NgZone and
          // pass that as parent to the NgModuleFactory.

          /** @type {?} */
          var ngZoneOption = options ? options.ngZone : undefined;
          /** @type {?} */

          var ngZoneEventCoalescing = options && options.ngZoneEventCoalescing || false;
          /** @type {?} */

          var ngZone = getNgZone(ngZoneOption, ngZoneEventCoalescing);
          /** @type {?} */

          var providers = [{
            provide: NgZone,
            useValue: ngZone
          }]; // Attention: Don't use ApplicationRef.run here,
          // as we want to be sure that all possible constructor calls are inside `ngZone.run`!

          return ngZone.run(
          /**
          * @return {?}
          */
          function () {
            /** @type {?} */
            var ngZoneInjector = Injector.create({
              providers: providers,
              parent: _this175.injector,
              name: moduleFactory.moduleType.name
            });
            /** @type {?} */

            var moduleRef =
            /** @type {?} */
            moduleFactory.create(ngZoneInjector);
            /** @type {?} */

            var exceptionHandler = moduleRef.injector.get(ErrorHandler, null);

            if (!exceptionHandler) {
              throw new Error('No ErrorHandler. Is platform module (BrowserModule) included?');
            }

            moduleRef.onDestroy(
            /**
            * @return {?}
            */
            function () {
              return remove(_this175._modules, moduleRef);
            });

            /** @type {?} */
            ngZone.runOutsideAngular(
            /**
            * @return {?}
            */
            function () {
              return (
                /** @type {?} */
                ngZone.onError.subscribe({
                  next:
                  /**
                  * @param {?} error
                  * @return {?}
                  */
                  function next(error) {
                    exceptionHandler.handleError(error);
                  }
                })
              );
            });
            return _callAndReportToErrorHandler(exceptionHandler,
            /** @type {?} */
            ngZone,
            /**
            * @return {?}
            */
            function () {
              /** @type {?} */
              var initStatus = moduleRef.injector.get(ApplicationInitStatus);
              initStatus.runInitializers();
              return initStatus.donePromise.then(
              /**
              * @return {?}
              */
              function () {
                if (ivyEnabled) {
                  // If the `LOCALE_ID` provider is defined at bootstrap then we set the value for ivy

                  /** @type {?} */
                  var localeId = moduleRef.injector.get(LOCALE_ID$1, DEFAULT_LOCALE_ID);
                  setLocaleId(localeId || DEFAULT_LOCALE_ID);
                }

                _this175._moduleDoBootstrap(moduleRef);

                return moduleRef;
              });
            });
          });
        }
        /**
         * Creates an instance of an `\@NgModule` for a given platform using the given runtime compiler.
         *
         * \@usageNotes
         * ### Simple Example
         *
         * ```typescript
         * \@NgModule({
         *   imports: [BrowserModule]
         * })
         * class MyModule {}
         *
         * let moduleRef = platformBrowser().bootstrapModule(MyModule);
         * ```
         *
         * @template M
         * @param {?} moduleType
         * @param {?=} compilerOptions
         * @return {?}
         */

      }, {
        key: "bootstrapModule",
        value: function bootstrapModule(moduleType) {
          var _this176 = this;

          var compilerOptions = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];

          /** @type {?} */
          var options = optionsReducer({}, compilerOptions);
          return compileNgModuleFactory(this.injector, options, moduleType).then(
          /**
          * @param {?} moduleFactory
          * @return {?}
          */
          function (moduleFactory) {
            return _this176.bootstrapModuleFactory(moduleFactory, options);
          });
        }
        /**
         * @private
         * @param {?} moduleRef
         * @return {?}
         */

      }, {
        key: "_moduleDoBootstrap",
        value: function _moduleDoBootstrap(moduleRef) {
          /** @type {?} */
          var appRef =
          /** @type {?} */
          moduleRef.injector.get(ApplicationRef);

          if (moduleRef._bootstrapComponents.length > 0) {
            moduleRef._bootstrapComponents.forEach(
            /**
            * @param {?} f
            * @return {?}
            */
            function (f) {
              return appRef.bootstrap(f);
            });
          } else if (moduleRef.instance.ngDoBootstrap) {
            moduleRef.instance.ngDoBootstrap(appRef);
          } else {
            throw new Error("The module ".concat(stringify(moduleRef.instance.constructor), " was bootstrapped, but it does not declare \"@NgModule.bootstrap\" components nor a \"ngDoBootstrap\" method. ") + "Please define one of these.");
          }

          this._modules.push(moduleRef);
        }
        /**
         * Register a listener to be called when the platform is disposed.
         * @param {?} callback
         * @return {?}
         */

      }, {
        key: "onDestroy",
        value: function onDestroy(callback) {
          this._destroyListeners.push(callback);
        }
        /**
         * Retrieve the platform {\@link Injector}, which is the parent injector for
         * every Angular application on the page and provides singleton providers.
         * @return {?}
         */

      }, {
        key: "destroy",

        /**
         * Destroy the Angular platform and all Angular applications on the page.
         * @return {?}
         */
        value: function destroy() {
          if (this._destroyed) {
            throw new Error('The platform has already been destroyed!');
          }

          this._modules.slice().forEach(
          /**
          * @param {?} module
          * @return {?}
          */
          function (module) {
            return module.destroy();
          });

          this._destroyListeners.forEach(
          /**
          * @param {?} listener
          * @return {?}
          */
          function (listener) {
            return listener();
          });

          this._destroyed = true;
        }
        /**
         * @return {?}
         */

      }, {
        key: "injector",
        get: function get() {
          return this._injector;
        }
      }, {
        key: "destroyed",
        get: function get() {
          return this._destroyed;
        }
      }]);

      return PlatformRef;
    }();

    PlatformRef.ɵfac = function PlatformRef_Factory(t) {
      return new (t || PlatformRef)(ɵɵinject(Injector));
    };

    PlatformRef.ɵprov = ɵɵdefineInjectable({
      token: PlatformRef,
      factory: PlatformRef.ɵfac
    });
    /** @nocollapse */

    PlatformRef.ctorParameters = function () {
      return [{
        type: Injector
      }];
    };
    /*@__PURE__*/


    (function () {
      setClassMetadata(PlatformRef, [{
        type: Injectable
      }], function () {
        return [{
          type: Injector
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @param {?} ngZoneOption
     * @param {?} ngZoneEventCoalescing
     * @return {?}
     */


    function getNgZone(ngZoneOption, ngZoneEventCoalescing) {
      /** @type {?} */
      var ngZone;

      if (ngZoneOption === 'noop') {
        ngZone = new NoopNgZone();
      } else {
        ngZone = (ngZoneOption === 'zone.js' ? undefined : ngZoneOption) || new NgZone({
          enableLongStackTrace: isDevMode(),
          shouldCoalesceEventChangeDetection: ngZoneEventCoalescing
        });
      }

      return ngZone;
    }
    /**
     * @param {?} errorHandler
     * @param {?} ngZone
     * @param {?} callback
     * @return {?}
     */


    function _callAndReportToErrorHandler(errorHandler, ngZone, callback) {
      try {
        /** @type {?} */
        var result = callback();

        if (isPromise(result)) {
          return result["catch"](
          /**
          * @param {?} e
          * @return {?}
          */
          function (e) {
            ngZone.runOutsideAngular(
            /**
            * @return {?}
            */
            function () {
              return errorHandler.handleError(e);
            }); // rethrow as the exception handler might not do it

            throw e;
          });
        }

        return result;
      } catch (e) {
        ngZone.runOutsideAngular(
        /**
        * @return {?}
        */
        function () {
          return errorHandler.handleError(e);
        }); // rethrow as the exception handler might not do it

        throw e;
      }
    }
    /**
     * @template T
     * @param {?} dst
     * @param {?} objs
     * @return {?}
     */


    function optionsReducer(dst, objs) {
      if (Array.isArray(objs)) {
        dst = objs.reduce(optionsReducer, dst);
      } else {
        dst = Object.assign(Object.assign({}, dst),
        /** @type {?} */
        objs);
      }

      return dst;
    }
    /**
     * A reference to an Angular application running on a page.
     *
     * \@usageNotes
     *
     * {\@a is-stable-examples}
     * ### isStable examples and caveats
     *
     * Note two important points about `isStable`, demonstrated in the examples below:
     * - the application will never be stable if you start any kind
     * of recurrent asynchronous task when the application starts
     * (for example for a polling process, started with a `setInterval`, a `setTimeout`
     * or using RxJS operators like `interval`);
     * - the `isStable` Observable runs outside of the Angular zone.
     *
     * Let's imagine that you start a recurrent task
     * (here incrementing a counter, using RxJS `interval`),
     * and at the same time subscribe to `isStable`.
     *
     * ```
     * constructor(appRef: ApplicationRef) {
     *   appRef.isStable.pipe(
     *      filter(stable => stable)
     *   ).subscribe(() => console.log('App is stable now');
     *   interval(1000).subscribe(counter => console.log(counter));
     * }
     * ```
     * In this example, `isStable` will never emit `true`,
     * and the trace "App is stable now" will never get logged.
     *
     * If you want to execute something when the app is stable,
     * you have to wait for the application to be stable
     * before starting your polling process.
     *
     * ```
     * constructor(appRef: ApplicationRef) {
     *   appRef.isStable.pipe(
     *     first(stable => stable),
     *     tap(stable => console.log('App is stable now')),
     *     switchMap(() => interval(1000))
     *   ).subscribe(counter => console.log(counter));
     * }
     * ```
     * In this example, the trace "App is stable now" will be logged
     * and then the counter starts incrementing every second.
     *
     * Note also that this Observable runs outside of the Angular zone,
     * which means that the code in the subscription
     * to this Observable will not trigger the change detection.
     *
     * Let's imagine that instead of logging the counter value,
     * you update a field of your component
     * and display it in its template.
     *
     * ```
     * constructor(appRef: ApplicationRef) {
     *   appRef.isStable.pipe(
     *     first(stable => stable),
     *     switchMap(() => interval(1000))
     *   ).subscribe(counter => this.value = counter);
     * }
     * ```
     * As the `isStable` Observable runs outside the zone,
     * the `value` field will be updated properly,
     * but the template will not be refreshed!
     *
     * You'll have to manually trigger the change detection to update the template.
     *
     * ```
     * constructor(appRef: ApplicationRef, cd: ChangeDetectorRef) {
     *   appRef.isStable.pipe(
     *     first(stable => stable),
     *     switchMap(() => interval(1000))
     *   ).subscribe(counter => {
     *     this.value = counter;
     *     cd.detectChanges();
     *   });
     * }
     * ```
     *
     * Or make the subscription callback run inside the zone.
     *
     * ```
     * constructor(appRef: ApplicationRef, zone: NgZone) {
     *   appRef.isStable.pipe(
     *     first(stable => stable),
     *     switchMap(() => interval(1000))
     *   ).subscribe(counter => zone.run(() => this.value = counter));
     * }
     * ```
     *
     * \@publicApi
     */


    var ApplicationRef = /*#__PURE__*/function () {
      /**
       * \@internal
       * @param {?} _zone
       * @param {?} _console
       * @param {?} _injector
       * @param {?} _exceptionHandler
       * @param {?} _componentFactoryResolver
       * @param {?} _initStatus
       */
      function ApplicationRef(_zone, _console, _injector, _exceptionHandler, _componentFactoryResolver, _initStatus) {
        var _this177 = this;

        _classCallCheck(this, ApplicationRef);

        this._zone = _zone;
        this._console = _console;
        this._injector = _injector;
        this._exceptionHandler = _exceptionHandler;
        this._componentFactoryResolver = _componentFactoryResolver;
        this._initStatus = _initStatus;
        /**
         * \@internal
         */

        this._bootstrapListeners = [];
        this._views = [];
        this._runningTick = false;
        this._enforceNoNewChanges = false;
        this._stable = true;
        /**
         * Get a list of component types registered to this application.
         * This list is populated even before the component is created.
         */

        this.componentTypes = [];
        /**
         * Get a list of components registered to this application.
         */

        this.components = [];
        this._enforceNoNewChanges = isDevMode();

        this._zone.onMicrotaskEmpty.subscribe({
          next:
          /**
          * @return {?}
          */
          function next() {
            _this177._zone.run(
            /**
            * @return {?}
            */
            function () {
              _this177.tick();
            });
          }
        });
        /** @type {?} */


        var isCurrentlyStable = new rxjs__WEBPACK_IMPORTED_MODULE_0__["Observable"](
        /**
        * @param {?} observer
        * @return {?}
        */
        function (observer) {
          _this177._stable = _this177._zone.isStable && !_this177._zone.hasPendingMacrotasks && !_this177._zone.hasPendingMicrotasks;

          _this177._zone.runOutsideAngular(
          /**
          * @return {?}
          */
          function () {
            observer.next(_this177._stable);
            observer.complete();
          });
        });
        /** @type {?} */

        var isStable = new rxjs__WEBPACK_IMPORTED_MODULE_0__["Observable"](
        /**
        * @param {?} observer
        * @return {?}
        */
        function (observer) {
          // Create the subscription to onStable outside the Angular Zone so that
          // the callback is run outside the Angular Zone.

          /** @type {?} */
          var stableSub;

          _this177._zone.runOutsideAngular(
          /**
          * @return {?}
          */
          function () {
            stableSub = _this177._zone.onStable.subscribe(
            /**
            * @return {?}
            */
            function () {
              NgZone.assertNotInAngularZone(); // Check whether there are no pending macro/micro tasks in the next tick
              // to allow for NgZone to update the state.

              scheduleMicroTask(
              /**
              * @return {?}
              */
              function () {
                if (!_this177._stable && !_this177._zone.hasPendingMacrotasks && !_this177._zone.hasPendingMicrotasks) {
                  _this177._stable = true;
                  observer.next(true);
                }
              });
            });
          });
          /** @type {?} */


          var unstableSub = _this177._zone.onUnstable.subscribe(
          /**
          * @return {?}
          */
          function () {
            NgZone.assertInAngularZone();

            if (_this177._stable) {
              _this177._stable = false;

              _this177._zone.runOutsideAngular(
              /**
              * @return {?}
              */
              function () {
                observer.next(false);
              });
            }
          });

          return (
            /**
            * @return {?}
            */
            function () {
              stableSub.unsubscribe();
              unstableSub.unsubscribe();
            }
          );
        });

        /** @type {?} */
        this.isStable = Object(rxjs__WEBPACK_IMPORTED_MODULE_0__["merge"])(isCurrentlyStable, isStable.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_1__["share"])()));
      }
      /**
       * Bootstrap a new component at the root level of the application.
       *
       * \@usageNotes
       * ### Bootstrap process
       *
       * When bootstrapping a new root component into an application, Angular mounts the
       * specified application component onto DOM elements identified by the componentType's
       * selector and kicks off automatic change detection to finish initializing the component.
       *
       * Optionally, a component can be mounted onto a DOM element that does not match the
       * componentType's selector.
       *
       * ### Example
       * {\@example core/ts/platform/platform.ts region='longform'}
       * @template C
       * @param {?} componentOrFactory
       * @param {?=} rootSelectorOrNode
       * @return {?}
       */


      _createClass2(ApplicationRef, [{
        key: "bootstrap",
        value: function bootstrap(componentOrFactory, rootSelectorOrNode) {
          var _this178 = this;

          if (!this._initStatus.done) {
            throw new Error('Cannot bootstrap as there are still asynchronous initializers running. Bootstrap components in the `ngDoBootstrap` method of the root module.');
          }
          /** @type {?} */


          var componentFactory;

          if (componentOrFactory instanceof ComponentFactory) {
            componentFactory = componentOrFactory;
          } else {
            componentFactory =
            /** @type {?} */
            this._componentFactoryResolver.resolveComponentFactory(componentOrFactory);
          }

          this.componentTypes.push(componentFactory.componentType); // Create a factory associated with the current module if it's not bound to some other

          /** @type {?} */

          var ngModule = isBoundToModule(componentFactory) ? undefined : this._injector.get(NgModuleRef);
          /** @type {?} */

          var selectorOrNode = rootSelectorOrNode || componentFactory.selector;
          /** @type {?} */

          var compRef = componentFactory.create(Injector.NULL, [], selectorOrNode, ngModule);
          compRef.onDestroy(
          /**
          * @return {?}
          */
          function () {
            _this178._unloadComponent(compRef);
          });
          /** @type {?} */

          var testability = compRef.injector.get(Testability, null);

          if (testability) {
            compRef.injector.get(TestabilityRegistry).registerApplication(compRef.location.nativeElement, testability);
          }

          this._loadComponent(compRef);

          if (isDevMode()) {
            this._console.log("Angular is running in the development mode. Call enableProdMode() to enable the production mode.");
          }

          return compRef;
        }
        /**
         * Invoke this method to explicitly process change detection and its side-effects.
         *
         * In development mode, `tick()` also performs a second change detection cycle to ensure that no
         * further changes are detected. If additional changes are picked up during this second cycle,
         * bindings in the app have side-effects that cannot be resolved in a single change detection
         * pass.
         * In this case, Angular throws an error, since an Angular application can only have one change
         * detection pass during which all change detection must complete.
         * @return {?}
         */

      }, {
        key: "tick",
        value: function tick() {
          var _this179 = this;

          if (this._runningTick) {
            throw new Error('ApplicationRef.tick is called recursively');
          }

          try {
            this._runningTick = true;

            var _iterator12 = _createForOfIteratorHelper(this._views),
                _step12;

            try {
              for (_iterator12.s(); !(_step12 = _iterator12.n()).done;) {
                var _view4 = _step12.value;

                _view4.detectChanges();
              }
            } catch (err) {
              _iterator12.e(err);
            } finally {
              _iterator12.f();
            }

            if (this._enforceNoNewChanges) {
              var _iterator13 = _createForOfIteratorHelper(this._views),
                  _step13;

              try {
                for (_iterator13.s(); !(_step13 = _iterator13.n()).done;) {
                  var view = _step13.value;
                  view.checkNoChanges();
                }
              } catch (err) {
                _iterator13.e(err);
              } finally {
                _iterator13.f();
              }
            }
          } catch (e) {
            // Attention: Don't rethrow as it could cancel subscriptions to Observables!
            this._zone.runOutsideAngular(
            /**
            * @return {?}
            */
            function () {
              return _this179._exceptionHandler.handleError(e);
            });
          } finally {
            this._runningTick = false;
          }
        }
        /**
         * Attaches a view so that it will be dirty checked.
         * The view will be automatically detached when it is destroyed.
         * This will throw if the view is already attached to a ViewContainer.
         * @param {?} viewRef
         * @return {?}
         */

      }, {
        key: "attachView",
        value: function attachView(viewRef) {
          /** @type {?} */
          var view =
          /** @type {?} */
          viewRef;

          this._views.push(view);

          view.attachToAppRef(this);
        }
        /**
         * Detaches a view from dirty checking again.
         * @param {?} viewRef
         * @return {?}
         */

      }, {
        key: "detachView",
        value: function detachView(viewRef) {
          /** @type {?} */
          var view =
          /** @type {?} */
          viewRef;
          remove(this._views, view);
          view.detachFromAppRef();
        }
        /**
         * @private
         * @param {?} componentRef
         * @return {?}
         */

      }, {
        key: "_loadComponent",
        value: function _loadComponent(componentRef) {
          this.attachView(componentRef.hostView);
          this.tick();
          this.components.push(componentRef); // Get the listeners lazily to prevent DI cycles.

          /** @type {?} */

          var listeners = this._injector.get(APP_BOOTSTRAP_LISTENER, []).concat(this._bootstrapListeners);

          listeners.forEach(
          /**
          * @param {?} listener
          * @return {?}
          */
          function (listener) {
            return listener(componentRef);
          });
        }
        /**
         * @private
         * @param {?} componentRef
         * @return {?}
         */

      }, {
        key: "_unloadComponent",
        value: function _unloadComponent(componentRef) {
          this.detachView(componentRef.hostView);
          remove(this.components, componentRef);
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          // TODO(alxhub): Dispose of the NgZone.
          this._views.slice().forEach(
          /**
          * @param {?} view
          * @return {?}
          */
          function (view) {
            return view.destroy();
          });
        }
        /**
         * Returns the number of attached views.
         * @return {?}
         */

      }, {
        key: "viewCount",
        get: function get() {
          return this._views.length;
        }
      }]);

      return ApplicationRef;
    }();

    ApplicationRef.ɵfac = function ApplicationRef_Factory(t) {
      return new (t || ApplicationRef)(ɵɵinject(NgZone), ɵɵinject(Console), ɵɵinject(Injector), ɵɵinject(ErrorHandler), ɵɵinject(ComponentFactoryResolver), ɵɵinject(ApplicationInitStatus));
    };

    ApplicationRef.ɵprov = ɵɵdefineInjectable({
      token: ApplicationRef,
      factory: ApplicationRef.ɵfac
    });
    /** @nocollapse */

    ApplicationRef.ctorParameters = function () {
      return [{
        type: NgZone
      }, {
        type: Console
      }, {
        type: Injector
      }, {
        type: ErrorHandler
      }, {
        type: ComponentFactoryResolver
      }, {
        type: ApplicationInitStatus
      }];
    };
    /*@__PURE__*/


    (function () {
      setClassMetadata(ApplicationRef, [{
        type: Injectable
      }], function () {
        return [{
          type: NgZone
        }, {
          type: Console
        }, {
          type: Injector
        }, {
          type: ErrorHandler
        }, {
          type: ComponentFactoryResolver
        }, {
          type: ApplicationInitStatus
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @template T
     * @param {?} list
     * @param {?} el
     * @return {?}
     */


    function remove(list, el) {
      /** @type {?} */
      var index = list.indexOf(el);

      if (index > -1) {
        list.splice(index, 1);
      }
    }
    /**
     * @template T
     * @param {?} args
     * @return {?}
     */


    function _lastDefined(args) {
      for (var i = args.length - 1; i >= 0; i--) {
        if (args[i] !== undefined) {
          return args[i];
        }
      }

      return undefined;
    }
    /**
     * @param {?} parts
     * @return {?}
     */


    function _mergeArrays(parts) {
      /** @type {?} */
      var result = [];
      parts.forEach(
      /**
      * @param {?} part
      * @return {?}
      */
      function (part) {
        return part && result.push.apply(result, _toConsumableArray(part));
      });
      return result;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/zone.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/render.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/linker/ng_module_factory_loader.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Used to load ng module factories.
     *
     * \@publicApi
     * @deprecated the `string` form of `loadChildren` is deprecated, and `NgModuleFactoryLoader` is
     * part of its implementation. See `LoadChildren` for more details.
     * @abstract
     */


    var NgModuleFactoryLoader = function NgModuleFactoryLoader() {
      _classCallCheck(this, NgModuleFactoryLoader);
    };

    if (false) {}
    /**
     * @param {?} id
     * @return {?}
     */


    function getModuleFactory__PRE_R3__(id) {
      /** @type {?} */
      var factory =
      /** @type {?} */
      getRegisteredNgModuleType(id);
      if (!factory) throw noModuleError(id);
      return factory;
    }
    /**
     * @param {?} id
     * @return {?}
     */


    function getModuleFactory__POST_R3__(id) {
      /** @type {?} */
      var type =
      /** @type {?} */
      getRegisteredNgModuleType(id);
      if (!type) throw noModuleError(id);
      return new NgModuleFactory$1(type);
    }
    /**
     * Returns the NgModuleFactory with the given id, if it exists and has been loaded.
     * Factories for modules that do not specify an `id` cannot be retrieved. Throws if the module
     * cannot be found.
     * \@publicApi
     * @type {?}
     */


    var getModuleFactory = getModuleFactory__POST_R3__;
    /**
     * @param {?} id
     * @return {?}
     */

    function noModuleError(id) {
      return new Error("No module with ID ".concat(id, " loaded"));
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/linker/system_js_ng_module_factory_loader.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var _SEPARATOR = '#';
    /** @type {?} */

    var FACTORY_CLASS_SUFFIX = 'NgFactory';
    /**
     * Configuration for SystemJsNgModuleLoader.
     * token.
     *
     * \@publicApi
     * @deprecated the `string` form of `loadChildren` is deprecated, and `SystemJsNgModuleLoaderConfig`
     * is part of its implementation. See `LoadChildren` for more details.
     * @abstract
     */

    var SystemJsNgModuleLoaderConfig = function SystemJsNgModuleLoaderConfig() {
      _classCallCheck(this, SystemJsNgModuleLoaderConfig);
    };

    if (false) {}
    /** @type {?} */


    var DEFAULT_CONFIG = {
      factoryPathPrefix: '',
      factoryPathSuffix: '.ngfactory'
    };
    /**
     * NgModuleFactoryLoader that uses SystemJS to load NgModuleFactory
     * \@publicApi
     * @deprecated the `string` form of `loadChildren` is deprecated, and `SystemJsNgModuleLoader` is
     * part of its implementation. See `LoadChildren` for more details.
     */

    var SystemJsNgModuleLoader = /*#__PURE__*/function () {
      /**
       * @param {?} _compiler
       * @param {?=} config
       */
      function SystemJsNgModuleLoader(_compiler, config) {
        _classCallCheck(this, SystemJsNgModuleLoader);

        this._compiler = _compiler;
        this._config = config || DEFAULT_CONFIG;
      }
      /**
       * @param {?} path
       * @return {?}
       */


      _createClass2(SystemJsNgModuleLoader, [{
        key: "load",
        value: function load(path) {
          /** @type {?} */
          var legacyOfflineMode = !ivyEnabled && this._compiler instanceof Compiler;
          return legacyOfflineMode ? this.loadFactory(path) : this.loadAndCompile(path);
        }
        /**
         * @private
         * @param {?} path
         * @return {?}
         */

      }, {
        key: "loadAndCompile",
        value: function loadAndCompile(path) {
          var _this180 = this;

          var _path$split = path.split(_SEPARATOR),
              _path$split2 = _slicedToArray(_path$split, 2),
              module = _path$split2[0],
              exportName = _path$split2[1];

          if (exportName === undefined) {
            exportName = 'default';
          }

          return __webpack_require__("./$$_lazy_route_resource lazy recursive")(module).then(
          /**
          * @param {?} module
          * @return {?}
          */
          function (module) {
            return module[exportName];
          }).then(
          /**
          * @param {?} type
          * @return {?}
          */
          function (type) {
            return checkNotEmpty(type, module, exportName);
          }).then(
          /**
          * @param {?} type
          * @return {?}
          */
          function (type) {
            return _this180._compiler.compileModuleAsync(type);
          });
        }
        /**
         * @private
         * @param {?} path
         * @return {?}
         */

      }, {
        key: "loadFactory",
        value: function loadFactory(path) {
          var _path$split3 = path.split(_SEPARATOR),
              _path$split4 = _slicedToArray(_path$split3, 2),
              module = _path$split4[0],
              exportName = _path$split4[1];
          /** @type {?} */


          var factoryClassSuffix = FACTORY_CLASS_SUFFIX;

          if (exportName === undefined) {
            exportName = 'default';
            factoryClassSuffix = '';
          }

          return __webpack_require__("./$$_lazy_route_resource lazy recursive")(this._config.factoryPathPrefix + module + this._config.factoryPathSuffix).then(
          /**
          * @param {?} module
          * @return {?}
          */
          function (module) {
            return module[exportName + factoryClassSuffix];
          }).then(
          /**
          * @param {?} factory
          * @return {?}
          */
          function (factory) {
            return checkNotEmpty(factory, module, exportName);
          });
        }
      }]);

      return SystemJsNgModuleLoader;
    }();

    SystemJsNgModuleLoader.ɵfac = function SystemJsNgModuleLoader_Factory(t) {
      return new (t || SystemJsNgModuleLoader)(ɵɵinject(Compiler), ɵɵinject(SystemJsNgModuleLoaderConfig, 8));
    };

    SystemJsNgModuleLoader.ɵprov = ɵɵdefineInjectable({
      token: SystemJsNgModuleLoader,
      factory: SystemJsNgModuleLoader.ɵfac
    });
    /** @nocollapse */

    SystemJsNgModuleLoader.ctorParameters = function () {
      return [{
        type: Compiler
      }, {
        type: SystemJsNgModuleLoaderConfig,
        decorators: [{
          type: Optional
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      setClassMetadata(SystemJsNgModuleLoader, [{
        type: Injectable
      }], function () {
        return [{
          type: Compiler
        }, {
          type: SystemJsNgModuleLoaderConfig,
          decorators: [{
            type: Optional
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @param {?} value
     * @param {?} modulePath
     * @param {?} exportName
     * @return {?}
     */


    function checkNotEmpty(value, modulePath, exportName) {
      if (!value) {
        throw new Error("Cannot find '".concat(exportName, "' in '").concat(modulePath, "'"));
      }

      return value;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/linker/view_ref.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Represents an Angular [view](guide/glossary#view),
     * specifically the [host view](guide/glossary#view-tree) that is defined by a component.
     * Also serves as the base class
     * that adds destroy methods for [embedded views](guide/glossary#view-tree).
     *
     * @see `EmbeddedViewRef`
     *
     * \@publicApi
     * @abstract
     */


    var ViewRef$1 = /*#__PURE__*/function (_ChangeDetectorRef) {
      _inherits(ViewRef$1, _ChangeDetectorRef);

      var _super46 = _createSuper(ViewRef$1);

      function ViewRef$1() {
        _classCallCheck(this, ViewRef$1);

        return _super46.apply(this, arguments);
      }

      return ViewRef$1;
    }(ChangeDetectorRef);

    if (false) {}
    /**
     * Represents an Angular [view](guide/glossary#view) in a view container.
     * An [embedded view](guide/glossary#view-tree) can be referenced from a component
     * other than the hosting component whose template defines it, or it can be defined
     * independently by a `TemplateRef`.
     *
     * Properties of elements in a view can change, but the structure (number and order) of elements in
     * a view cannot. Change the structure of elements by inserting, moving, or
     * removing nested views in a view container.
     *
     * @see `ViewContainerRef`
     *
     * \@usageNotes
     *
     * The following template breaks down into two separate `TemplateRef` instances,
     * an outer one and an inner one.
     *
     * ```
     * Count: {{items.length}}
     * <ul>
     *   <li *ngFor="let  item of items">{{item}}</li>
     * </ul>
     * ```
     *
     * This is the outer `TemplateRef`:
     *
     * ```
     * Count: {{items.length}}
     * <ul>
     *   <ng-template ngFor let-item [ngForOf]="items"></ng-template>
     * </ul>
     * ```
     *
     * This is the inner `TemplateRef`:
     *
     * ```
     *   <li>{{item}}</li>
     * ```
     *
     * The outer and inner `TemplateRef` instances are assembled into views as follows:
     *
     * ```
     * <!-- ViewRef: outer-0 -->
     * Count: 2
     * <ul>
     *   <ng-template view-container-ref></ng-template>
     *   <!-- ViewRef: inner-1 --><li>first</li><!-- /ViewRef: inner-1 -->
     *   <!-- ViewRef: inner-2 --><li>second</li><!-- /ViewRef: inner-2 -->
     * </ul>
     * <!-- /ViewRef: outer-0 -->
     * ```
     * \@publicApi
     * @abstract
     * @template C
     */


    var EmbeddedViewRef = /*#__PURE__*/function (_ViewRef$) {
      _inherits(EmbeddedViewRef, _ViewRef$);

      var _super47 = _createSuper(EmbeddedViewRef);

      function EmbeddedViewRef() {
        _classCallCheck(this, EmbeddedViewRef);

        return _super47.apply(this, arguments);
      }

      return EmbeddedViewRef;
    }(ViewRef$1);

    if (false) {}
    /**
     * @record
     */


    function InternalViewRef() {}

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/linker.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/debug/debug_node.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@publicApi
     */


    var DebugEventListener =
    /**
     * @param {?} name
     * @param {?} callback
     */
    function DebugEventListener(name, callback) {
      _classCallCheck(this, DebugEventListener);

      this.name = name;
      this.callback = callback;
    };

    if (false) {} // WARNING: interface has both a type and a value, skipping emit


    var DebugNode__PRE_R3__ = /*#__PURE__*/function () {
      /**
       * @param {?} nativeNode
       * @param {?} parent
       * @param {?} _debugContext
       */
      function DebugNode__PRE_R3__(nativeNode, parent, _debugContext) {
        _classCallCheck(this, DebugNode__PRE_R3__);

        this.listeners = [];
        this.parent = null;
        this._debugContext = _debugContext;
        this.nativeNode = nativeNode;

        if (parent && parent instanceof DebugElement__PRE_R3__) {
          parent.addChild(this);
        }
      }
      /**
       * @return {?}
       */


      _createClass2(DebugNode__PRE_R3__, [{
        key: "injector",
        get: function get() {
          return this._debugContext.injector;
        }
        /**
         * @return {?}
         */

      }, {
        key: "componentInstance",
        get: function get() {
          return this._debugContext.component;
        }
        /**
         * @return {?}
         */

      }, {
        key: "context",
        get: function get() {
          return this._debugContext.context;
        }
        /**
         * @return {?}
         */

      }, {
        key: "references",
        get: function get() {
          return this._debugContext.references;
        }
        /**
         * @return {?}
         */

      }, {
        key: "providerTokens",
        get: function get() {
          return this._debugContext.providerTokens;
        }
      }]);

      return DebugNode__PRE_R3__;
    }();

    if (false) {} // WARNING: interface has both a type and a value, skipping emit


    var DebugElement__PRE_R3__ = /*#__PURE__*/function (_DebugNode__PRE_R3__) {
      _inherits(DebugElement__PRE_R3__, _DebugNode__PRE_R3__);

      var _super48 = _createSuper(DebugElement__PRE_R3__);

      /**
       * @param {?} nativeNode
       * @param {?} parent
       * @param {?} _debugContext
       */
      function DebugElement__PRE_R3__(nativeNode, parent, _debugContext) {
        var _this181;

        _classCallCheck(this, DebugElement__PRE_R3__);

        _this181 = _super48.call(this, nativeNode, parent, _debugContext);
        _this181.properties = {};
        _this181.attributes = {};
        _this181.classes = {};
        _this181.styles = {};
        _this181.childNodes = [];
        _this181.nativeElement = nativeNode;
        return _this181;
      }
      /**
       * @param {?} child
       * @return {?}
       */


      _createClass2(DebugElement__PRE_R3__, [{
        key: "addChild",
        value: function addChild(child) {
          if (child) {
            this.childNodes.push(child);

            /** @type {?} */
            child.parent = this;
          }
        }
        /**
         * @param {?} child
         * @return {?}
         */

      }, {
        key: "removeChild",
        value: function removeChild(child) {
          /** @type {?} */
          var childIndex = this.childNodes.indexOf(child);

          if (childIndex !== -1) {
            /** @type {?} */
            child.parent = null;
            this.childNodes.splice(childIndex, 1);
          }
        }
        /**
         * @param {?} child
         * @param {?} newChildren
         * @return {?}
         */

      }, {
        key: "insertChildrenAfter",
        value: function insertChildrenAfter(child, newChildren) {
          var _this182 = this;

          /** @type {?} */
          var siblingIndex = this.childNodes.indexOf(child);

          if (siblingIndex !== -1) {
            var _this$childNodes;

            (_this$childNodes = this.childNodes).splice.apply(_this$childNodes, [siblingIndex + 1, 0].concat(_toConsumableArray(newChildren)));

            newChildren.forEach(
            /**
            * @param {?} c
            * @return {?}
            */
            function (c) {
              if (c.parent) {
                /** @type {?} */
                c.parent.removeChild(c);
              }

              /** @type {?} */
              child.parent = _this182;
            });
          }
        }
        /**
         * @param {?} refChild
         * @param {?} newChild
         * @return {?}
         */

      }, {
        key: "insertBefore",
        value: function insertBefore(refChild, newChild) {
          /** @type {?} */
          var refIndex = this.childNodes.indexOf(refChild);

          if (refIndex === -1) {
            this.addChild(newChild);
          } else {
            if (newChild.parent) {
              /** @type {?} */
              newChild.parent.removeChild(newChild);
            }

            /** @type {?} */
            newChild.parent = this;
            this.childNodes.splice(refIndex, 0, newChild);
          }
        }
        /**
         * @param {?} predicate
         * @return {?}
         */

      }, {
        key: "query",
        value: function query(predicate) {
          /** @type {?} */
          var results = this.queryAll(predicate);
          return results[0] || null;
        }
        /**
         * @param {?} predicate
         * @return {?}
         */

      }, {
        key: "queryAll",
        value: function queryAll(predicate) {
          /** @type {?} */
          var matches = [];

          _queryElementChildren(this, predicate, matches);

          return matches;
        }
        /**
         * @param {?} predicate
         * @return {?}
         */

      }, {
        key: "queryAllNodes",
        value: function queryAllNodes(predicate) {
          /** @type {?} */
          var matches = [];

          _queryNodeChildren(this, predicate, matches);

          return matches;
        }
        /**
         * @return {?}
         */

      }, {
        key: "triggerEventHandler",

        /**
         * @param {?} eventName
         * @param {?} eventObj
         * @return {?}
         */
        value: function triggerEventHandler(eventName, eventObj) {
          this.listeners.forEach(
          /**
          * @param {?} listener
          * @return {?}
          */
          function (listener) {
            if (listener.name == eventName) {
              listener.callback(eventObj);
            }
          });
        }
      }, {
        key: "children",
        get: function get() {
          return (
            /** @type {?} */
            this.childNodes //
            .filter(
            /**
            * @param {?} node
            * @return {?}
            */
            function (node) {
              return node instanceof DebugElement__PRE_R3__;
            })
          );
        }
      }]);

      return DebugElement__PRE_R3__;
    }(DebugNode__PRE_R3__);

    if (false) {}
    /**
     * \@publicApi
     * @param {?} debugEls
     * @return {?}
     */


    function asNativeElements(debugEls) {
      return debugEls.map(
      /**
      * @param {?} el
      * @return {?}
      */
      function (el) {
        return el.nativeElement;
      });
    }
    /**
     * @param {?} element
     * @param {?} predicate
     * @param {?} matches
     * @return {?}
     */


    function _queryElementChildren(element, predicate, matches) {
      element.childNodes.forEach(
      /**
      * @param {?} node
      * @return {?}
      */
      function (node) {
        if (node instanceof DebugElement__PRE_R3__) {
          if (predicate(node)) {
            matches.push(node);
          }

          _queryElementChildren(node, predicate, matches);
        }
      });
    }
    /**
     * @param {?} parentNode
     * @param {?} predicate
     * @param {?} matches
     * @return {?}
     */


    function _queryNodeChildren(parentNode, predicate, matches) {
      if (parentNode instanceof DebugElement__PRE_R3__) {
        parentNode.childNodes.forEach(
        /**
        * @param {?} node
        * @return {?}
        */
        function (node) {
          if (predicate(node)) {
            matches.push(node);
          }

          if (node instanceof DebugElement__PRE_R3__) {
            _queryNodeChildren(node, predicate, matches);
          }
        });
      }
    }

    var DebugNode__POST_R3__ = /*#__PURE__*/function () {
      /**
       * @param {?} nativeNode
       */
      function DebugNode__POST_R3__(nativeNode) {
        _classCallCheck(this, DebugNode__POST_R3__);

        this.nativeNode = nativeNode;
      }
      /**
       * @return {?}
       */


      _createClass2(DebugNode__POST_R3__, [{
        key: "parent",
        get: function get() {
          /** @type {?} */
          var parent =
          /** @type {?} */
          this.nativeNode.parentNode;
          return parent ? new DebugElement__POST_R3__(parent) : null;
        }
        /**
         * @return {?}
         */

      }, {
        key: "injector",
        get: function get() {
          return getInjector(this.nativeNode);
        }
        /**
         * @return {?}
         */

      }, {
        key: "componentInstance",
        get: function get() {
          /** @type {?} */
          var nativeElement = this.nativeNode;
          return nativeElement && (getComponent(
          /** @type {?} */
          nativeElement) || getOwningComponent(nativeElement));
        }
        /**
         * @return {?}
         */

      }, {
        key: "context",
        get: function get() {
          return getComponent(
          /** @type {?} */
          this.nativeNode) || getContext(
          /** @type {?} */
          this.nativeNode);
        }
        /**
         * @return {?}
         */

      }, {
        key: "listeners",
        get: function get() {
          return getListeners(
          /** @type {?} */
          this.nativeNode).filter(
          /**
          * @param {?} listener
          * @return {?}
          */
          function (listener) {
            return listener.type === 'dom';
          });
        }
        /**
         * @return {?}
         */

      }, {
        key: "references",
        get: function get() {
          return getLocalRefs(this.nativeNode);
        }
        /**
         * @return {?}
         */

      }, {
        key: "providerTokens",
        get: function get() {
          return getInjectionTokens(
          /** @type {?} */
          this.nativeNode);
        }
      }]);

      return DebugNode__POST_R3__;
    }();

    if (false) {}

    var DebugElement__POST_R3__ = /*#__PURE__*/function (_DebugNode__POST_R3__) {
      _inherits(DebugElement__POST_R3__, _DebugNode__POST_R3__);

      var _super49 = _createSuper(DebugElement__POST_R3__);

      /**
       * @param {?} nativeNode
       */
      function DebugElement__POST_R3__(nativeNode) {
        _classCallCheck(this, DebugElement__POST_R3__);

        ngDevMode && assertDomNode(nativeNode);
        return _super49.call(this, nativeNode);
      }
      /**
       * @return {?}
       */


      _createClass2(DebugElement__POST_R3__, [{
        key: "query",

        /**
         * @param {?} predicate
         * @return {?}
         */
        value: function query(predicate) {
          /** @type {?} */
          var results = this.queryAll(predicate);
          return results[0] || null;
        }
        /**
         * @param {?} predicate
         * @return {?}
         */

      }, {
        key: "queryAll",
        value: function queryAll(predicate) {
          /** @type {?} */
          var matches = [];

          _queryAllR3(this, predicate, matches, true);

          return matches;
        }
        /**
         * @param {?} predicate
         * @return {?}
         */

      }, {
        key: "queryAllNodes",
        value: function queryAllNodes(predicate) {
          /** @type {?} */
          var matches = [];

          _queryAllR3(this, predicate, matches, false);

          return matches;
        }
        /**
         * @param {?} eventName
         * @param {?} eventObj
         * @return {?}
         */

      }, {
        key: "triggerEventHandler",
        value: function triggerEventHandler(eventName, eventObj) {
          /** @type {?} */
          var node =
          /** @type {?} */
          this.nativeNode;
          /** @type {?} */

          var invokedListeners = [];
          this.listeners.forEach(
          /**
          * @param {?} listener
          * @return {?}
          */
          function (listener) {
            if (listener.name === eventName) {
              /** @type {?} */
              var callback = listener.callback;
              callback.call(node, eventObj);
              invokedListeners.push(callback);
            }
          }); // We need to check whether `eventListeners` exists, because it's something
          // that Zone.js only adds to `EventTarget` in browser environments.

          if (typeof node.eventListeners === 'function') {
            // Note that in Ivy we wrap event listeners with a call to `event.preventDefault` in some
            // cases. We use '__ngUnwrap__' as a special token that gives us access to the actual event
            // listener.
            node.eventListeners(eventName).forEach(
            /**
            * @param {?} listener
            * @return {?}
            */
            function (listener) {
              // In order to ensure that we can detect the special __ngUnwrap__ token described above, we
              // use `toString` on the listener and see if it contains the token. We use this approach to
              // ensure that it still worked with compiled code since it cannot remove or rename string
              // literals. We also considered using a special function name (i.e. if(listener.name ===
              // special)) but that was more cumbersome and we were also concerned the compiled code could
              // strip the name, turning the condition in to ("" === "") and always returning true.
              if (listener.toString().indexOf('__ngUnwrap__') !== -1) {
                /** @type {?} */
                var unwrappedListener = listener('__ngUnwrap__');
                return invokedListeners.indexOf(unwrappedListener) === -1 && unwrappedListener.call(node, eventObj);
              }
            });
          }
        }
      }, {
        key: "nativeElement",
        get: function get() {
          return this.nativeNode.nodeType == Node.ELEMENT_NODE ?
          /** @type {?} */
          this.nativeNode : null;
        }
        /**
         * @return {?}
         */

      }, {
        key: "name",
        get: function get() {
          try {
            /** @type {?} */
            var context =
            /** @type {?} */
            loadLContext(this.nativeNode);
            /** @type {?} */

            var lView = context.lView;
            /** @type {?} */

            var tData = lView[TVIEW].data;
            /** @type {?} */

            var tNode =
            /** @type {?} */
            tData[context.nodeIndex];
            return (
              /** @type {?} */
              tNode.tagName
            );
          } catch (e) {
            return this.nativeNode.nodeName;
          }
        }
        /**
         *  Gets a map of property names to property values for an element.
         *
         *  This map includes:
         *  - Regular property bindings (e.g. `[id]="id"`)
         *  - Host property bindings (e.g. `host: { '[id]': "id" }`)
         *  - Interpolated property bindings (e.g. `id="{{ value }}")
         *
         *  It does not include:
         *  - input property bindings (e.g. `[myCustomInput]="value"`)
         *  - attribute bindings (e.g. `[attr.role]="menu"`)
         * @return {?}
         */

      }, {
        key: "properties",
        get: function get() {
          /** @type {?} */
          var context = loadLContext(this.nativeNode, false);

          if (context == null) {
            return {};
          }
          /** @type {?} */


          var lView = context.lView;
          /** @type {?} */

          var tData = lView[TVIEW].data;
          /** @type {?} */

          var tNode =
          /** @type {?} */
          tData[context.nodeIndex];
          /** @type {?} */

          var properties = {}; // Collect properties from the DOM.

          copyDomProperties(this.nativeElement, properties); // Collect properties from the bindings. This is needed for animation renderer which has
          // synthetic properties which don't get reflected into the DOM.

          collectPropertyBindings(properties, tNode, lView, tData);
          return properties;
        }
        /**
         * @return {?}
         */

      }, {
        key: "attributes",
        get: function get() {
          /** @type {?} */
          var attributes = {};
          /** @type {?} */

          var element = this.nativeElement;

          if (!element) {
            return attributes;
          }
          /** @type {?} */


          var context = loadLContext(element, false);

          if (context == null) {
            return {};
          }
          /** @type {?} */


          var lView = context.lView;
          /** @type {?} */

          var tNodeAttrs =
          /** @type {?} */
          lView[TVIEW].data[context.nodeIndex].attrs;
          /** @type {?} */

          var lowercaseTNodeAttrs = []; // For debug nodes we take the element's attribute directly from the DOM since it allows us
          // to account for ones that weren't set via bindings (e.g. ViewEngine keeps track of the ones
          // that are set through `Renderer2`). The problem is that the browser will lowercase all names,
          // however since we have the attributes already on the TNode, we can preserve the case by going
          // through them once, adding them to the `attributes` map and putting their lower-cased name
          // into an array. Afterwards when we're going through the native DOM attributes, we can check
          // whether we haven't run into an attribute already through the TNode.

          if (tNodeAttrs) {
            /** @type {?} */
            var i = 0;

            while (i < tNodeAttrs.length) {
              /** @type {?} */
              var attrName = tNodeAttrs[i]; // Stop as soon as we hit a marker. We only care about the regular attributes. Everything
              // else will be handled below when we read the final attributes off the DOM.

              if (typeof attrName !== 'string') break;
              /** @type {?} */

              var attrValue = tNodeAttrs[i + 1];
              attributes[attrName] =
              /** @type {?} */
              attrValue;
              lowercaseTNodeAttrs.push(attrName.toLowerCase());
              i += 2;
            }
          }
          /** @type {?} */


          var eAttrs = element.attributes;

          for (var _i18 = 0; _i18 < eAttrs.length; _i18++) {
            /** @type {?} */
            var attr = eAttrs[_i18];
            /** @type {?} */

            var lowercaseName = attr.name.toLowerCase(); // Make sure that we don't assign the same attribute both in its
            // case-sensitive form and the lower-cased one from the browser.

            if (lowercaseTNodeAttrs.indexOf(lowercaseName) === -1) {
              // Save the lowercase name to align the behavior between browsers.
              // IE preserves the case, while all other browser convert it to lower case.
              attributes[lowercaseName] = attr.value;
            }
          }

          return attributes;
        }
        /**
         * @return {?}
         */

      }, {
        key: "styles",
        get: function get() {
          if (this.nativeElement &&
          /** @type {?} */
          this.nativeElement.style) {
            return (
              /** @type {?} */

              /** @type {?} */
              this.nativeElement.style
            );
          }

          return {};
        }
        /**
         * @return {?}
         */

      }, {
        key: "classes",
        get: function get() {
          /** @type {?} */
          var result = {};
          /** @type {?} */

          var element =
          /** @type {?} */
          this.nativeElement; // SVG elements return an `SVGAnimatedString` instead of a plain string for the `className`.

          /** @type {?} */

          var className =
          /** @type {?} */
          element.className;
          /** @type {?} */

          var classes = className && typeof className !== 'string' ? className.baseVal.split(' ') : className.split(' ');
          classes.forEach(
          /**
          * @param {?} value
          * @return {?}
          */
          function (value) {
            return result[value] = true;
          });
          return result;
        }
        /**
         * @return {?}
         */

      }, {
        key: "childNodes",
        get: function get() {
          /** @type {?} */
          var childNodes = this.nativeNode.childNodes;
          /** @type {?} */

          var children = [];

          for (var i = 0; i < childNodes.length; i++) {
            /** @type {?} */
            var element = childNodes[i];
            children.push(getDebugNode__POST_R3__(element));
          }

          return children;
        }
        /**
         * @return {?}
         */

      }, {
        key: "children",
        get: function get() {
          /** @type {?} */
          var nativeElement = this.nativeElement;
          if (!nativeElement) return [];
          /** @type {?} */

          var childNodes = nativeElement.children;
          /** @type {?} */

          var children = [];

          for (var i = 0; i < childNodes.length; i++) {
            /** @type {?} */
            var element = childNodes[i];
            children.push(getDebugNode__POST_R3__(element));
          }

          return children;
        }
      }]);

      return DebugElement__POST_R3__;
    }(DebugNode__POST_R3__);
    /**
     * @param {?} element
     * @param {?} properties
     * @return {?}
     */


    function copyDomProperties(element, properties) {
      if (element) {
        // Skip own properties (as those are patched)

        /** @type {?} */
        var obj = Object.getPrototypeOf(element);
        /** @type {?} */

        var NodePrototype = Node.prototype;

        while (obj !== null && obj !== NodePrototype) {
          /** @type {?} */
          var descriptors = Object.getOwnPropertyDescriptors(obj);

          for (var key in descriptors) {
            if (!key.startsWith('__') && !key.startsWith('on')) {
              // don't include properties starting with `__` and `on`.
              // `__` are patched values which should not be included.
              // `on` are listeners which also should not be included.

              /** @type {?} */
              var value =
              /** @type {?} */
              element[key];

              if (isPrimitiveValue(value)) {
                properties[key] = value;
              }
            }
          }

          obj = Object.getPrototypeOf(obj);
        }
      }
    }
    /**
     * @param {?} value
     * @return {?}
     */


    function isPrimitiveValue(value) {
      return typeof value === 'string' || typeof value === 'boolean' || typeof value === 'number' || value === null;
    }
    /**
     * @param {?} parentElement
     * @param {?} predicate
     * @param {?} matches
     * @param {?} elementsOnly
     * @return {?}
     */


    function _queryAllR3(parentElement, predicate, matches, elementsOnly) {
      /** @type {?} */
      var context = loadLContext(parentElement.nativeNode, false);

      if (context !== null) {
        /** @type {?} */
        var parentTNode =
        /** @type {?} */
        context.lView[TVIEW].data[context.nodeIndex];

        _queryNodeChildrenR3(parentTNode, context.lView, predicate, matches, elementsOnly, parentElement.nativeNode);
      } else {
        // If the context is null, then `parentElement` was either created with Renderer2 or native DOM
        // APIs.
        _queryNativeNodeDescendants(parentElement.nativeNode, predicate, matches, elementsOnly);
      }
    }
    /**
     * Recursively match the current TNode against the predicate, and goes on with the next ones.
     *
     * @param {?} tNode the current TNode
     * @param {?} lView the LView of this TNode
     * @param {?} predicate the predicate to match
     * @param {?} matches the list of positive matches
     * @param {?} elementsOnly whether only elements should be searched
     * @param {?} rootNativeNode the root native node on which predicate should not be matched
     * @return {?}
     */


    function _queryNodeChildrenR3(tNode, lView, predicate, matches, elementsOnly, rootNativeNode) {
      /** @type {?} */
      var nativeNode = getNativeByTNodeOrNull(tNode, lView); // For each type of TNode, specific logic is executed.

      if (tNode.type === 3
      /* Element */
      || tNode.type === 4
      /* ElementContainer */
      ) {
          // Case 1: the TNode is an element
          // The native node has to be checked.
          _addQueryMatchR3(nativeNode, predicate, matches, elementsOnly, rootNativeNode);

          if (isComponentHost(tNode)) {
            // If the element is the host of a component, then all nodes in its view have to be processed.
            // Note: the component's content (tNode.child) will be processed from the insertion points.

            /** @type {?} */
            var componentView = getComponentLViewByIndex(tNode.index, lView);

            if (componentView && componentView[TVIEW].firstChild) {
              _queryNodeChildrenR3(
              /** @type {?} */
              componentView[TVIEW].firstChild, componentView, predicate, matches, elementsOnly, rootNativeNode);
            }
          } else {
            if (tNode.child) {
              // Otherwise, its children have to be processed.
              _queryNodeChildrenR3(tNode.child, lView, predicate, matches, elementsOnly, rootNativeNode);
            } // We also have to query the DOM directly in order to catch elements inserted through
            // Renderer2. Note that this is __not__ optimal, because we're walking similar trees multiple
            // times. ViewEngine could do it more efficiently, because all the insertions go through
            // Renderer2, however that's not the case in Ivy. This approach is being used because:
            // 1. Matching the ViewEngine behavior would mean potentially introducing a depedency
            //    from `Renderer2` to Ivy which could bring Ivy code into ViewEngine.
            // 2. We would have to make `Renderer3` "know" about debug nodes.
            // 3. It allows us to capture nodes that were inserted directly via the DOM.


            nativeNode && _queryNativeNodeDescendants(nativeNode, predicate, matches, elementsOnly);
          } // In all cases, if a dynamic container exists for this node, each view inside it has to be
          // processed.

          /** @type {?} */


          var nodeOrContainer = lView[tNode.index];

          if (isLContainer(nodeOrContainer)) {
            _queryNodeChildrenInContainerR3(nodeOrContainer, predicate, matches, elementsOnly, rootNativeNode);
          }
        } else if (tNode.type === 0
      /* Container */
      ) {
          // Case 2: the TNode is a container
          // The native node has to be checked.

          /** @type {?} */
          var lContainer = lView[tNode.index];

          _addQueryMatchR3(lContainer[NATIVE], predicate, matches, elementsOnly, rootNativeNode); // Each view inside the container has to be processed.


          _queryNodeChildrenInContainerR3(lContainer, predicate, matches, elementsOnly, rootNativeNode);
        } else if (tNode.type === 1
      /* Projection */
      ) {
          // Case 3: the TNode is a projection insertion point (i.e. a <ng-content>).
          // The nodes projected at this location all need to be processed.

          /** @type {?} */
          var _componentView =
          /** @type {?} */
          lView[DECLARATION_COMPONENT_VIEW];
          /** @type {?} */

          var componentHost =
          /** @type {?} */
          _componentView[T_HOST];
          /** @type {?} */

          var head =
          /** @type {?} */
          componentHost.projection[
          /** @type {?} */
          tNode.projection];

          if (Array.isArray(head)) {
            var _iterator14 = _createForOfIteratorHelper(head),
                _step14;

            try {
              for (_iterator14.s(); !(_step14 = _iterator14.n()).done;) {
                var _nativeNode2 = _step14.value;

                _addQueryMatchR3(_nativeNode2, predicate, matches, elementsOnly, rootNativeNode);
              }
            } catch (err) {
              _iterator14.e(err);
            } finally {
              _iterator14.f();
            }
          } else if (head) {
            /** @type {?} */
            var nextLView =
            /** @type {?} */

            /** @type {?} */
            _componentView[PARENT];
            /** @type {?} */

            var nextTNode =
            /** @type {?} */
            nextLView[TVIEW].data[head.index];

            _queryNodeChildrenR3(nextTNode, nextLView, predicate, matches, elementsOnly, rootNativeNode);
          }
        } else if (tNode.child) {
        // Case 4: the TNode is a view.
        _queryNodeChildrenR3(tNode.child, lView, predicate, matches, elementsOnly, rootNativeNode);
      } // We don't want to go to the next sibling of the root node.


      if (rootNativeNode !== nativeNode) {
        // To determine the next node to be processed, we need to use the next or the projectionNext
        // link, depending on whether the current node has been projected.

        /** @type {?} */
        var _nextTNode = tNode.flags & 4
        /* isProjected */
        ? tNode.projectionNext : tNode.next;

        if (_nextTNode) {
          _queryNodeChildrenR3(_nextTNode, lView, predicate, matches, elementsOnly, rootNativeNode);
        }
      }
    }
    /**
     * Process all TNodes in a given container.
     *
     * @param {?} lContainer the container to be processed
     * @param {?} predicate the predicate to match
     * @param {?} matches the list of positive matches
     * @param {?} elementsOnly whether only elements should be searched
     * @param {?} rootNativeNode the root native node on which predicate should not be matched
     * @return {?}
     */


    function _queryNodeChildrenInContainerR3(lContainer, predicate, matches, elementsOnly, rootNativeNode) {
      for (var i = CONTAINER_HEADER_OFFSET; i < lContainer.length; i++) {
        /** @type {?} */
        var childView = lContainer[i];

        _queryNodeChildrenR3(
        /** @type {?} */
        childView[TVIEW].node, childView, predicate, matches, elementsOnly, rootNativeNode);
      }
    }
    /**
     * Match the current native node against the predicate.
     *
     * @param {?} nativeNode the current native node
     * @param {?} predicate the predicate to match
     * @param {?} matches the list of positive matches
     * @param {?} elementsOnly whether only elements should be searched
     * @param {?} rootNativeNode the root native node on which predicate should not be matched
     * @return {?}
     */


    function _addQueryMatchR3(nativeNode, predicate, matches, elementsOnly, rootNativeNode) {
      if (rootNativeNode !== nativeNode) {
        /** @type {?} */
        var debugNode = getDebugNode$1(nativeNode);

        if (!debugNode) {
          return;
        } // Type of the "predicate and "matches" array are set based on the value of
        // the "elementsOnly" parameter. TypeScript is not able to properly infer these
        // types with generics, so we manually cast the parameters accordingly.


        if (elementsOnly && debugNode instanceof DebugElement__POST_R3__ && predicate(debugNode) && matches.indexOf(debugNode) === -1) {
          matches.push(debugNode);
        } else if (!elementsOnly &&
        /** @type {?} */
        predicate(debugNode) &&
        /** @type {?} */
        matches.indexOf(debugNode) === -1) {
          /** @type {?} */
          matches.push(debugNode);
        }
      }
    }
    /**
     * Match all the descendants of a DOM node against a predicate.
     *
     * @param {?} parentNode
     * @param {?} predicate the predicate to match
     * @param {?} matches the list of positive matches
     * @param {?} elementsOnly whether only elements should be searched
     * @return {?}
     */


    function _queryNativeNodeDescendants(parentNode, predicate, matches, elementsOnly) {
      /** @type {?} */
      var nodes = parentNode.childNodes;
      /** @type {?} */

      var length = nodes.length;

      for (var i = 0; i < length; i++) {
        /** @type {?} */
        var node = nodes[i];
        /** @type {?} */

        var debugNode = getDebugNode$1(node);

        if (debugNode) {
          if (elementsOnly && debugNode instanceof DebugElement__POST_R3__ && predicate(debugNode) && matches.indexOf(debugNode) === -1) {
            matches.push(debugNode);
          } else if (!elementsOnly &&
          /** @type {?} */
          predicate(debugNode) &&
          /** @type {?} */
          matches.indexOf(debugNode) === -1) {
            /** @type {?} */
            matches.push(debugNode);
          }

          _queryNativeNodeDescendants(node, predicate, matches, elementsOnly);
        }
      }
    }
    /**
     * Iterates through the property bindings for a given node and generates
     * a map of property names to values. This map only contains property bindings
     * defined in templates, not in host bindings.
     * @param {?} properties
     * @param {?} tNode
     * @param {?} lView
     * @param {?} tData
     * @return {?}
     */


    function collectPropertyBindings(properties, tNode, lView, tData) {
      /** @type {?} */
      var bindingIndexes = tNode.propertyBindings;

      if (bindingIndexes !== null) {
        for (var i = 0; i < bindingIndexes.length; i++) {
          /** @type {?} */
          var bindingIndex = bindingIndexes[i];
          /** @type {?} */

          var propMetadata =
          /** @type {?} */
          tData[bindingIndex];
          /** @type {?} */

          var metadataParts = propMetadata.split(INTERPOLATION_DELIMITER);
          /** @type {?} */

          var propertyName = metadataParts[0];

          if (metadataParts.length > 1) {
            /** @type {?} */
            var value = metadataParts[1];

            for (var j = 1; j < metadataParts.length - 1; j++) {
              value += renderStringify(lView[bindingIndex + j - 1]) + metadataParts[j + 1];
            }

            properties[propertyName] = value;
          } else {
            properties[propertyName] = lView[bindingIndex];
          }
        }
      }
    } // Need to keep the nodes in a global Map so that multiple angular apps are supported.

    /** @type {?} */


    var _nativeNodeToDebugNode = new Map();
    /**
     * @param {?} nativeNode
     * @return {?}
     */


    function getDebugNode__PRE_R3__(nativeNode) {
      return _nativeNodeToDebugNode.get(nativeNode) || null;
    }
    /** @type {?} */


    var NG_DEBUG_PROPERTY = '__ng_debug__';
    /**
     * @param {?} nativeNode
     * @return {?}
     */

    function getDebugNode__POST_R3__(nativeNode) {
      if (nativeNode instanceof Node) {
        if (!nativeNode.hasOwnProperty(NG_DEBUG_PROPERTY)) {
          /** @type {?} */
          nativeNode[NG_DEBUG_PROPERTY] = nativeNode.nodeType == Node.ELEMENT_NODE ? new DebugElement__POST_R3__(
          /** @type {?} */
          nativeNode) : new DebugNode__POST_R3__(nativeNode);
        }

        return (
          /** @type {?} */
          nativeNode[NG_DEBUG_PROPERTY]
        );
      }

      return null;
    }
    /**
     * \@publicApi
     * @type {?}
     */


    var getDebugNode$1 = getDebugNode__POST_R3__;
    /**
     * @param {?} nativeNode
     * @return {?}
     */

    function getDebugNodeR2__PRE_R3__(nativeNode) {
      return getDebugNode__PRE_R3__(nativeNode);
    }
    /**
     * @param {?} _nativeNode
     * @return {?}
     */


    function getDebugNodeR2__POST_R3__(_nativeNode) {
      return null;
    }
    /** @type {?} */


    var getDebugNodeR2 = getDebugNodeR2__POST_R3__;
    /**
     * @return {?}
     */

    function getAllDebugNodes() {
      return Array.from(_nativeNodeToDebugNode.values());
    }
    /**
     * @param {?} node
     * @return {?}
     */


    function indexDebugNode(node) {
      _nativeNodeToDebugNode.set(node.nativeNode, node);
    }
    /**
     * @param {?} node
     * @return {?}
     */


    function removeDebugNodeFromIndex(node) {
      _nativeNodeToDebugNode["delete"](node.nativeNode);
    }
    /**
     * A boolean-valued function over a value, possibly including context information
     * regarding that value's position in an array.
     *
     * \@publicApi
     * @record
     * @template T
     */


    function Predicate() {}
    /**
     * \@publicApi
     * @type {?}
     */


    var DebugNode$1 = DebugNode__POST_R3__;
    /**
     * \@publicApi
     * @type {?}
     */

    var DebugElement = DebugElement__POST_R3__;
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/change_detection.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/platform_core_providers.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */

    var _CORE_PLATFORM_PROVIDERS = [// Set a default platform name for platforms that don't set it explicitly.
    {
      provide: PLATFORM_ID,
      useValue: 'unknown'
    }, {
      provide: PlatformRef,
      deps: [Injector]
    }, {
      provide: TestabilityRegistry,
      deps: []
    }, {
      provide: Console,
      deps: []
    }];
    /**
     * This platform has to be included in any other platform
     *
     * \@publicApi
     * @type {?}
     */

    var platformCore = createPlatformFactory(null, 'core', _CORE_PLATFORM_PROVIDERS);
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/application_module.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @return {?}
     */

    function _iterableDiffersFactory() {
      return defaultIterableDiffers;
    }
    /**
     * @return {?}
     */


    function _keyValueDiffersFactory() {
      return defaultKeyValueDiffers;
    }
    /**
     * @param {?=} locale
     * @return {?}
     */


    function _localeFactory(locale) {
      locale = locale || getGlobalLocale();

      if (ivyEnabled) {
        setLocaleId(locale);
      }

      return locale;
    }
    /**
     * Work out the locale from the potential global properties.
     *
     * * Closure Compiler: use `goog.LOCALE`.
     * * Ivy enabled: use `$localize.locale`
     * @return {?}
     */


    function getGlobalLocale() {
      if (typeof ngI18nClosureMode !== 'undefined' && ngI18nClosureMode && typeof goog !== 'undefined' && goog.LOCALE !== 'en') {
        // * The default `goog.LOCALE` value is `en`, while Angular used `en-US`.
        // * In order to preserve backwards compatibility, we use Angular default value over
        //   Closure Compiler's one.
        return goog.LOCALE;
      } else {
        // KEEP `typeof $localize !== 'undefined' && $localize.locale` IN SYNC WITH THE LOCALIZE
        // COMPILE-TIME INLINER.
        //
        // * During compile time inlining of translations the expression will be replaced
        //   with a string literal that is the current locale. Other forms of this expression are not
        //   guaranteed to be replaced.
        //
        // * During runtime translation evaluation, the developer is required to set `$localize.locale`
        //   if required, or just to provide their own `LOCALE_ID` provider.
        return ivyEnabled && typeof $localize !== 'undefined' && $localize.locale || DEFAULT_LOCALE_ID;
      }
    }

    var ɵ0$g = USD_CURRENCY_CODE;
    /**
     * A built-in [dependency injection token](guide/glossary#di-token)
     * that is used to configure the root injector for bootstrapping.
     * @type {?}
     */

    var APPLICATION_MODULE_PROVIDERS = [{
      provide: ApplicationRef,
      useClass: ApplicationRef,
      deps: [NgZone, Console, Injector, ErrorHandler, ComponentFactoryResolver, ApplicationInitStatus]
    }, {
      provide: SCHEDULER,
      deps: [NgZone],
      useFactory: zoneSchedulerFactory
    }, {
      provide: ApplicationInitStatus,
      useClass: ApplicationInitStatus,
      deps: [[new Optional(), APP_INITIALIZER]]
    }, {
      provide: Compiler,
      useClass: Compiler,
      deps: []
    }, APP_ID_RANDOM_PROVIDER, {
      provide: IterableDiffers,
      useFactory: _iterableDiffersFactory,
      deps: []
    }, {
      provide: KeyValueDiffers,
      useFactory: _keyValueDiffersFactory,
      deps: []
    }, {
      provide: LOCALE_ID$1,
      useFactory: _localeFactory,
      deps: [[new Inject(LOCALE_ID$1), new Optional(), new SkipSelf()]]
    }, {
      provide: DEFAULT_CURRENCY_CODE,
      useValue: ɵ0$g
    }];
    /**
     * Schedule work at next available slot.
     *
     * In Ivy this is just `requestAnimationFrame`. For compatibility reasons when bootstrapped
     * using `platformRef.bootstrap` we need to use `NgZone.onStable` as the scheduling mechanism.
     * This overrides the scheduling mechanism in Ivy to `NgZone.onStable`.
     *
     * @param {?} ngZone NgZone to use for scheduling.
     * @return {?}
     */

    function zoneSchedulerFactory(ngZone) {
      /** @type {?} */
      var queue = [];
      ngZone.onStable.subscribe(
      /**
      * @return {?}
      */
      function () {
        while (queue.length) {
          /** @type {?} */
          queue.pop()();
        }
      });
      return (
        /**
        * @param {?} fn
        * @return {?}
        */
        function (fn) {
          queue.push(fn);
        }
      );
    }
    /**
     * Configures the root injector for an app with
     * providers of `\@angular/core` dependencies that `ApplicationRef` needs
     * to bootstrap components.
     *
     * Re-exported by `BrowserModule`, which is included automatically in the root
     * `AppModule` when you create a new app with the CLI `new` command.
     *
     * \@publicApi
     */


    var ApplicationModule = // Inject ApplicationRef to make it eager...

    /**
     * @param {?} appRef
     */
    function ApplicationModule(appRef) {
      _classCallCheck(this, ApplicationModule);
    };

    ApplicationModule.ɵmod = ɵɵdefineNgModule({
      type: ApplicationModule
    });
    ApplicationModule.ɵinj = ɵɵdefineInjector({
      factory: function ApplicationModule_Factory(t) {
        return new (t || ApplicationModule)(ɵɵinject(ApplicationRef));
      },
      providers: APPLICATION_MODULE_PROVIDERS
    });
    /** @nocollapse */

    ApplicationModule.ctorParameters = function () {
      return [{
        type: ApplicationRef
      }];
    };
    /*@__PURE__*/


    (function () {
      setClassMetadata(ApplicationModule, [{
        type: NgModule,
        args: [{
          providers: APPLICATION_MODULE_PROVIDERS
        }]
      }], function () {
        return [{
          type: ApplicationRef
        }];
      }, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/view/element.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} flags
     * @param {?} matchedQueriesDsl
     * @param {?} ngContentIndex
     * @param {?} childCount
     * @param {?=} handleEvent
     * @param {?=} templateFactory
     * @return {?}
     */


    function anchorDef(flags, matchedQueriesDsl, ngContentIndex, childCount, handleEvent, templateFactory) {
      flags |= 1
      /* TypeElement */
      ;

      var _splitMatchedQueriesD2 = splitMatchedQueriesDsl(matchedQueriesDsl),
          matchedQueries = _splitMatchedQueriesD2.matchedQueries,
          references = _splitMatchedQueriesD2.references,
          matchedQueryIds = _splitMatchedQueriesD2.matchedQueryIds;
      /** @type {?} */


      var template = templateFactory ? resolveDefinition(templateFactory) : null;
      return {
        // will bet set by the view definition
        nodeIndex: -1,
        parent: null,
        renderParent: null,
        bindingIndex: -1,
        outputIndex: -1,
        // regular values
        flags: flags,
        checkIndex: -1,
        childFlags: 0,
        directChildFlags: 0,
        childMatchedQueries: 0,
        matchedQueries: matchedQueries,
        matchedQueryIds: matchedQueryIds,
        references: references,
        ngContentIndex: ngContentIndex,
        childCount: childCount,
        bindings: [],
        bindingFlags: 0,
        outputs: [],
        element: {
          ns: null,
          name: null,
          attrs: null,
          template: template,
          componentProvider: null,
          componentView: null,
          componentRendererType: null,
          publicProviders: null,
          allProviders: null,
          handleEvent: handleEvent || NOOP
        },
        provider: null,
        text: null,
        query: null,
        ngContent: null
      };
    }
    /**
     * @param {?} checkIndex
     * @param {?} flags
     * @param {?} matchedQueriesDsl
     * @param {?} ngContentIndex
     * @param {?} childCount
     * @param {?} namespaceAndName
     * @param {?=} fixedAttrs
     * @param {?=} bindings
     * @param {?=} outputs
     * @param {?=} handleEvent
     * @param {?=} componentView
     * @param {?=} componentRendererType
     * @return {?}
     */


    function elementDef(checkIndex, flags, matchedQueriesDsl, ngContentIndex, childCount, namespaceAndName) {
      var fixedAttrs = arguments.length > 6 && arguments[6] !== undefined ? arguments[6] : [];
      var bindings = arguments.length > 7 ? arguments[7] : undefined;
      var outputs = arguments.length > 8 ? arguments[8] : undefined;
      var handleEvent = arguments.length > 9 ? arguments[9] : undefined;
      var componentView = arguments.length > 10 ? arguments[10] : undefined;
      var componentRendererType = arguments.length > 11 ? arguments[11] : undefined;

      if (!handleEvent) {
        handleEvent = NOOP;
      }

      var _splitMatchedQueriesD3 = splitMatchedQueriesDsl(matchedQueriesDsl),
          matchedQueries = _splitMatchedQueriesD3.matchedQueries,
          references = _splitMatchedQueriesD3.references,
          matchedQueryIds = _splitMatchedQueriesD3.matchedQueryIds;
      /** @type {?} */


      var ns =
      /** @type {?} */
      null;
      /** @type {?} */

      var name =
      /** @type {?} */
      null;

      if (namespaceAndName) {
        var _splitNamespace = splitNamespace(namespaceAndName);

        var _splitNamespace2 = _slicedToArray(_splitNamespace, 2);

        ns = _splitNamespace2[0];
        name = _splitNamespace2[1];
      }

      bindings = bindings || [];
      /** @type {?} */

      var bindingDefs = [];

      for (var i = 0; i < bindings.length; i++) {
        var _bindings$i = _slicedToArray(bindings[i], 3),
            bindingFlags = _bindings$i[0],
            _namespaceAndName = _bindings$i[1],
            suffixOrSecurityContext = _bindings$i[2];

        var _splitNamespace3 = splitNamespace(_namespaceAndName),
            _splitNamespace4 = _slicedToArray(_splitNamespace3, 2),
            _ns = _splitNamespace4[0],
            _name2 = _splitNamespace4[1];
        /** @type {?} */


        var securityContext =
        /** @type {?} */
        undefined;
        /** @type {?} */

        var suffix =
        /** @type {?} */
        undefined;

        switch (bindingFlags & 15
        /* Types */
        ) {
          case 4
          /* TypeElementStyle */
          :
            suffix =
            /** @type {?} */
            suffixOrSecurityContext;
            break;

          case 1
          /* TypeElementAttribute */
          :
          case 8
          /* TypeProperty */
          :
            securityContext =
            /** @type {?} */
            suffixOrSecurityContext;
            break;
        }

        bindingDefs[i] = {
          flags: bindingFlags,
          ns: _ns,
          name: _name2,
          nonMinifiedName: _name2,
          securityContext: securityContext,
          suffix: suffix
        };
      }

      outputs = outputs || [];
      /** @type {?} */

      var outputDefs = [];

      for (var _i19 = 0; _i19 < outputs.length; _i19++) {
        var _outputs$_i = _slicedToArray(outputs[_i19], 2),
            target = _outputs$_i[0],
            eventName = _outputs$_i[1];

        outputDefs[_i19] = {
          type: 0
          /* ElementOutput */
          ,
          target:
          /** @type {?} */
          target,
          eventName: eventName,
          propName: null
        };
      }

      fixedAttrs = fixedAttrs || [];
      /** @type {?} */

      var attrs =
      /** @type {?} */
      fixedAttrs.map(
      /**
      * @param {?} __0
      * @return {?}
      */
      function (_ref11) {
        var _ref12 = _slicedToArray(_ref11, 2),
            namespaceAndName = _ref12[0],
            value = _ref12[1];

        var _splitNamespace5 = splitNamespace(namespaceAndName),
            _splitNamespace6 = _slicedToArray(_splitNamespace5, 2),
            ns = _splitNamespace6[0],
            name = _splitNamespace6[1];

        return [ns, name, value];
      });
      componentRendererType = resolveRendererType2(componentRendererType);

      if (componentView) {
        flags |= 33554432
        /* ComponentView */
        ;
      }

      flags |= 1
      /* TypeElement */
      ;
      return {
        // will bet set by the view definition
        nodeIndex: -1,
        parent: null,
        renderParent: null,
        bindingIndex: -1,
        outputIndex: -1,
        // regular values
        checkIndex: checkIndex,
        flags: flags,
        childFlags: 0,
        directChildFlags: 0,
        childMatchedQueries: 0,
        matchedQueries: matchedQueries,
        matchedQueryIds: matchedQueryIds,
        references: references,
        ngContentIndex: ngContentIndex,
        childCount: childCount,
        bindings: bindingDefs,
        bindingFlags: calcBindingFlags(bindingDefs),
        outputs: outputDefs,
        element: {
          ns: ns,
          name: name,
          attrs: attrs,
          template: null,
          // will bet set by the view definition
          componentProvider: null,
          componentView: componentView || null,
          componentRendererType: componentRendererType,
          publicProviders: null,
          allProviders: null,
          handleEvent: handleEvent || NOOP
        },
        provider: null,
        text: null,
        query: null,
        ngContent: null
      };
    }
    /**
     * @param {?} view
     * @param {?} renderHost
     * @param {?} def
     * @return {?}
     */


    function createElement(view, renderHost, def) {
      /** @type {?} */
      var elDef =
      /** @type {?} */
      def.element;
      /** @type {?} */

      var rootSelectorOrNode = view.root.selectorOrNode;
      /** @type {?} */

      var renderer = view.renderer;
      /** @type {?} */

      var el;

      if (view.parent || !rootSelectorOrNode) {
        if (elDef.name) {
          el = renderer.createElement(elDef.name, elDef.ns);
        } else {
          el = renderer.createComment('');
        }
        /** @type {?} */


        var parentEl = getParentRenderElement(view, renderHost, def);

        if (parentEl) {
          renderer.appendChild(parentEl, el);
        }
      } else {
        // when using native Shadow DOM, do not clear the root element contents to allow slot projection

        /** @type {?} */
        var preserveContent = !!elDef.componentRendererType && elDef.componentRendererType.encapsulation === ViewEncapsulation$1.ShadowDom;
        el = renderer.selectRootElement(rootSelectorOrNode, preserveContent);
      }

      if (elDef.attrs) {
        for (var i = 0; i < elDef.attrs.length; i++) {
          var _elDef$attrs$i = _slicedToArray(elDef.attrs[i], 3),
              ns = _elDef$attrs$i[0],
              name = _elDef$attrs$i[1],
              value = _elDef$attrs$i[2];

          renderer.setAttribute(el, name, value, ns);
        }
      }

      return el;
    }
    /**
     * @param {?} view
     * @param {?} compView
     * @param {?} def
     * @param {?} el
     * @return {?}
     */


    function listenToElementOutputs(view, compView, def, el) {
      for (var i = 0; i < def.outputs.length; i++) {
        /** @type {?} */
        var output = def.outputs[i];
        /** @type {?} */

        var handleEventClosure = renderEventHandlerClosure(view, def.nodeIndex, elementEventFullName(output.target, output.eventName));
        /** @type {?} */

        var listenTarget = output.target;
        /** @type {?} */

        var listenerView = view;

        if (output.target === 'component') {
          listenTarget = null;
          listenerView = compView;
        }
        /** @type {?} */


        var disposable =
        /** @type {?} */
        listenerView.renderer.listen(listenTarget || el, output.eventName, handleEventClosure);

        /** @type {?} */
        view.disposables[def.outputIndex + i] = disposable;
      }
    }
    /**
     * @param {?} view
     * @param {?} index
     * @param {?} eventName
     * @return {?}
     */


    function renderEventHandlerClosure(view, index, eventName) {
      return (
        /**
        * @param {?} event
        * @return {?}
        */
        function (event) {
          return dispatchEvent(view, index, eventName, event);
        }
      );
    }
    /**
     * @param {?} view
     * @param {?} def
     * @param {?} v0
     * @param {?} v1
     * @param {?} v2
     * @param {?} v3
     * @param {?} v4
     * @param {?} v5
     * @param {?} v6
     * @param {?} v7
     * @param {?} v8
     * @param {?} v9
     * @return {?}
     */


    function checkAndUpdateElementInline(view, def, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9) {
      /** @type {?} */
      var bindLen = def.bindings.length;
      /** @type {?} */

      var changed = false;
      if (bindLen > 0 && checkAndUpdateElementValue(view, def, 0, v0)) changed = true;
      if (bindLen > 1 && checkAndUpdateElementValue(view, def, 1, v1)) changed = true;
      if (bindLen > 2 && checkAndUpdateElementValue(view, def, 2, v2)) changed = true;
      if (bindLen > 3 && checkAndUpdateElementValue(view, def, 3, v3)) changed = true;
      if (bindLen > 4 && checkAndUpdateElementValue(view, def, 4, v4)) changed = true;
      if (bindLen > 5 && checkAndUpdateElementValue(view, def, 5, v5)) changed = true;
      if (bindLen > 6 && checkAndUpdateElementValue(view, def, 6, v6)) changed = true;
      if (bindLen > 7 && checkAndUpdateElementValue(view, def, 7, v7)) changed = true;
      if (bindLen > 8 && checkAndUpdateElementValue(view, def, 8, v8)) changed = true;
      if (bindLen > 9 && checkAndUpdateElementValue(view, def, 9, v9)) changed = true;
      return changed;
    }
    /**
     * @param {?} view
     * @param {?} def
     * @param {?} values
     * @return {?}
     */


    function checkAndUpdateElementDynamic(view, def, values) {
      /** @type {?} */
      var changed = false;

      for (var i = 0; i < values.length; i++) {
        if (checkAndUpdateElementValue(view, def, i, values[i])) changed = true;
      }

      return changed;
    }
    /**
     * @param {?} view
     * @param {?} def
     * @param {?} bindingIdx
     * @param {?} value
     * @return {?}
     */


    function checkAndUpdateElementValue(view, def, bindingIdx, value) {
      if (!checkAndUpdateBinding(view, def, bindingIdx, value)) {
        return false;
      }
      /** @type {?} */


      var binding = def.bindings[bindingIdx];
      /** @type {?} */

      var elData = asElementData(view, def.nodeIndex);
      /** @type {?} */

      var renderNode = elData.renderElement;
      /** @type {?} */

      var name =
      /** @type {?} */
      binding.name;

      switch (binding.flags & 15
      /* Types */
      ) {
        case 1
        /* TypeElementAttribute */
        :
          setElementAttribute(view, binding, renderNode, binding.ns, name, value);
          break;

        case 2
        /* TypeElementClass */
        :
          setElementClass(view, renderNode, name, value);
          break;

        case 4
        /* TypeElementStyle */
        :
          setElementStyle(view, binding, renderNode, name, value);
          break;

        case 8
        /* TypeProperty */
        :
          /** @type {?} */
          var bindView = def.flags & 33554432
          /* ComponentView */
          && binding.flags & 32
          /* SyntheticHostProperty */
          ? elData.componentView : view;
          setElementProperty(bindView, binding, renderNode, name, value);
          break;
      }

      return true;
    }
    /**
     * @param {?} view
     * @param {?} binding
     * @param {?} renderNode
     * @param {?} ns
     * @param {?} name
     * @param {?} value
     * @return {?}
     */


    function setElementAttribute(view, binding, renderNode, ns, name, value) {
      /** @type {?} */
      var securityContext = binding.securityContext;
      /** @type {?} */

      var renderValue = securityContext ? view.root.sanitizer.sanitize(securityContext, value) : value;
      renderValue = renderValue != null ? renderValue.toString() : null;
      /** @type {?} */

      var renderer = view.renderer;

      if (value != null) {
        renderer.setAttribute(renderNode, name, renderValue, ns);
      } else {
        renderer.removeAttribute(renderNode, name, ns);
      }
    }
    /**
     * @param {?} view
     * @param {?} renderNode
     * @param {?} name
     * @param {?} value
     * @return {?}
     */


    function setElementClass(view, renderNode, name, value) {
      /** @type {?} */
      var renderer = view.renderer;

      if (value) {
        renderer.addClass(renderNode, name);
      } else {
        renderer.removeClass(renderNode, name);
      }
    }
    /**
     * @param {?} view
     * @param {?} binding
     * @param {?} renderNode
     * @param {?} name
     * @param {?} value
     * @return {?}
     */


    function setElementStyle(view, binding, renderNode, name, value) {
      /** @type {?} */
      var renderValue = view.root.sanitizer.sanitize(SecurityContext.STYLE,
      /** @type {?} */
      value);

      if (renderValue != null) {
        renderValue = renderValue.toString();
        /** @type {?} */

        var unit = binding.suffix;

        if (unit != null) {
          renderValue = renderValue + unit;
        }
      } else {
        renderValue = null;
      }
      /** @type {?} */


      var renderer = view.renderer;

      if (renderValue != null) {
        renderer.setStyle(renderNode, name, renderValue);
      } else {
        renderer.removeStyle(renderNode, name);
      }
    }
    /**
     * @param {?} view
     * @param {?} binding
     * @param {?} renderNode
     * @param {?} name
     * @param {?} value
     * @return {?}
     */


    function setElementProperty(view, binding, renderNode, name, value) {
      /** @type {?} */
      var securityContext = binding.securityContext;
      /** @type {?} */

      var renderValue = securityContext ? view.root.sanitizer.sanitize(securityContext, value) : value;
      view.renderer.setProperty(renderNode, name, renderValue);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/view/query.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} flags
     * @param {?} id
     * @param {?} bindings
     * @return {?}
     */


    function queryDef(flags, id, bindings) {
      /** @type {?} */
      var bindingDefs = [];

      for (var propName in bindings) {
        /** @type {?} */
        var bindingType = bindings[propName];
        bindingDefs.push({
          propName: propName,
          bindingType: bindingType
        });
      }

      return {
        // will bet set by the view definition
        nodeIndex: -1,
        parent: null,
        renderParent: null,
        bindingIndex: -1,
        outputIndex: -1,
        // regular values
        // TODO(vicb): check
        checkIndex: -1,
        flags: flags,
        childFlags: 0,
        directChildFlags: 0,
        childMatchedQueries: 0,
        ngContentIndex: -1,
        matchedQueries: {},
        matchedQueryIds: 0,
        references: {},
        childCount: 0,
        bindings: [],
        bindingFlags: 0,
        outputs: [],
        element: null,
        provider: null,
        text: null,
        query: {
          id: id,
          filterId: filterQueryId(id),
          bindings: bindingDefs
        },
        ngContent: null
      };
    }
    /**
     * @return {?}
     */


    function createQuery() {
      return new QueryList();
    }
    /**
     * @param {?} view
     * @return {?}
     */


    function dirtyParentQueries(view) {
      /** @type {?} */
      var queryIds = view.def.nodeMatchedQueries;

      while (view.parent && isEmbeddedView(view)) {
        /** @type {?} */
        var tplDef =
        /** @type {?} */
        view.parentNodeDef;
        view = view.parent; // content queries

        /** @type {?} */

        var end = tplDef.nodeIndex + tplDef.childCount;

        for (var i = 0; i <= end; i++) {
          /** @type {?} */
          var nodeDef = view.def.nodes[i];

          if (nodeDef.flags & 67108864
          /* TypeContentQuery */
          && nodeDef.flags & 536870912
          /* DynamicQuery */
          && (
          /** @type {?} */
          nodeDef.query.filterId & queryIds) ===
          /** @type {?} */
          nodeDef.query.filterId) {
            asQueryList(view, i).setDirty();
          }

          if (nodeDef.flags & 1
          /* TypeElement */
          && i + nodeDef.childCount < tplDef.nodeIndex || !(nodeDef.childFlags & 67108864
          /* TypeContentQuery */
          ) || !(nodeDef.childFlags & 536870912
          /* DynamicQuery */
          )) {
            // skip elements that don't contain the template element or no query.
            i += nodeDef.childCount;
          }
        }
      } // view queries


      if (view.def.nodeFlags & 134217728
      /* TypeViewQuery */
      ) {
          for (var _i20 = 0; _i20 < view.def.nodes.length; _i20++) {
            /** @type {?} */
            var _nodeDef = view.def.nodes[_i20];

            if (_nodeDef.flags & 134217728
            /* TypeViewQuery */
            && _nodeDef.flags & 536870912
            /* DynamicQuery */
            ) {
              asQueryList(view, _i20).setDirty();
            } // only visit the root nodes


            _i20 += _nodeDef.childCount;
          }
        }
    }
    /**
     * @param {?} view
     * @param {?} nodeDef
     * @return {?}
     */


    function checkAndUpdateQuery(view, nodeDef) {
      /** @type {?} */
      var queryList = asQueryList(view, nodeDef.nodeIndex);

      if (!queryList.dirty) {
        return;
      }
      /** @type {?} */


      var directiveInstance;
      /** @type {?} */

      var newValues =
      /** @type {?} */
      undefined;

      if (nodeDef.flags & 67108864
      /* TypeContentQuery */
      ) {
          /** @type {?} */
          var _elementDef =
          /** @type {?} */

          /** @type {?} */
          nodeDef.parent.parent;
          newValues = calcQueryValues(view, _elementDef.nodeIndex, _elementDef.nodeIndex + _elementDef.childCount,
          /** @type {?} */
          nodeDef.query, []);
          directiveInstance = asProviderData(view,
          /** @type {?} */
          nodeDef.parent.nodeIndex).instance;
        } else if (nodeDef.flags & 134217728
      /* TypeViewQuery */
      ) {
          newValues = calcQueryValues(view, 0, view.def.nodes.length - 1,
          /** @type {?} */
          nodeDef.query, []);
          directiveInstance = view.component;
        }

      queryList.reset(newValues);
      /** @type {?} */

      var bindings =
      /** @type {?} */
      nodeDef.query.bindings;
      /** @type {?} */

      var notify = false;

      for (var i = 0; i < bindings.length; i++) {
        /** @type {?} */
        var binding = bindings[i];
        /** @type {?} */

        var boundValue = void 0;

        switch (binding.bindingType) {
          case 0
          /* First */
          :
            boundValue = queryList.first;
            break;

          case 1
          /* All */
          :
            boundValue = queryList;
            notify = true;
            break;
        }

        directiveInstance[binding.propName] = boundValue;
      }

      if (notify) {
        queryList.notifyOnChanges();
      }
    }
    /**
     * @param {?} view
     * @param {?} startIndex
     * @param {?} endIndex
     * @param {?} queryDef
     * @param {?} values
     * @return {?}
     */


    function calcQueryValues(view, startIndex, endIndex, queryDef, values) {
      for (var i = startIndex; i <= endIndex; i++) {
        /** @type {?} */
        var nodeDef = view.def.nodes[i];
        /** @type {?} */

        var valueType = nodeDef.matchedQueries[queryDef.id];

        if (valueType != null) {
          values.push(getQueryValue(view, nodeDef, valueType));
        }

        if (nodeDef.flags & 1
        /* TypeElement */
        &&
        /** @type {?} */
        nodeDef.element.template && (
        /** @type {?} */

        /** @type {?} */
        nodeDef.element.template.nodeMatchedQueries & queryDef.filterId) === queryDef.filterId) {
          /** @type {?} */
          var elementData = asElementData(view, i); // check embedded views that were attached at the place of their template,
          // but process child nodes first if some match the query (see issue #16568)

          if ((nodeDef.childMatchedQueries & queryDef.filterId) === queryDef.filterId) {
            calcQueryValues(view, i + 1, i + nodeDef.childCount, queryDef, values);
            i += nodeDef.childCount;
          }

          if (nodeDef.flags & 16777216
          /* EmbeddedViews */
          ) {
              /** @type {?} */
              var embeddedViews =
              /** @type {?} */
              elementData.viewContainer._embeddedViews;

              for (var k = 0; k < embeddedViews.length; k++) {
                /** @type {?} */
                var embeddedView = embeddedViews[k];
                /** @type {?} */

                var dvc = declaredViewContainer(embeddedView);

                if (dvc && dvc === elementData) {
                  calcQueryValues(embeddedView, 0, embeddedView.def.nodes.length - 1, queryDef, values);
                }
              }
            }
          /** @type {?} */


          var projectedViews = elementData.template._projectedViews;

          if (projectedViews) {
            for (var _k = 0; _k < projectedViews.length; _k++) {
              /** @type {?} */
              var projectedView = projectedViews[_k];
              calcQueryValues(projectedView, 0, projectedView.def.nodes.length - 1, queryDef, values);
            }
          }
        }

        if ((nodeDef.childMatchedQueries & queryDef.filterId) !== queryDef.filterId) {
          // if no child matches the query, skip the children.
          i += nodeDef.childCount;
        }
      }

      return values;
    }
    /**
     * @param {?} view
     * @param {?} nodeDef
     * @param {?} queryValueType
     * @return {?}
     */


    function getQueryValue(view, nodeDef, queryValueType) {
      if (queryValueType != null) {
        // a match
        switch (queryValueType) {
          case 1
          /* RenderElement */
          :
            return asElementData(view, nodeDef.nodeIndex).renderElement;

          case 0
          /* ElementRef */
          :
            return new ElementRef(asElementData(view, nodeDef.nodeIndex).renderElement);

          case 2
          /* TemplateRef */
          :
            return asElementData(view, nodeDef.nodeIndex).template;

          case 3
          /* ViewContainerRef */
          :
            return asElementData(view, nodeDef.nodeIndex).viewContainer;

          case 4
          /* Provider */
          :
            return asProviderData(view, nodeDef.nodeIndex).instance;
        }
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/view/ng_content.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} ngContentIndex
     * @param {?} index
     * @return {?}
     */


    function ngContentDef(ngContentIndex, index) {
      return {
        // will bet set by the view definition
        nodeIndex: -1,
        parent: null,
        renderParent: null,
        bindingIndex: -1,
        outputIndex: -1,
        // regular values
        checkIndex: -1,
        flags: 8
        /* TypeNgContent */
        ,
        childFlags: 0,
        directChildFlags: 0,
        childMatchedQueries: 0,
        matchedQueries: {},
        matchedQueryIds: 0,
        references: {},
        ngContentIndex: ngContentIndex,
        childCount: 0,
        bindings: [],
        bindingFlags: 0,
        outputs: [],
        element: null,
        provider: null,
        text: null,
        query: null,
        ngContent: {
          index: index
        }
      };
    }
    /**
     * @param {?} view
     * @param {?} renderHost
     * @param {?} def
     * @return {?}
     */


    function appendNgContent(view, renderHost, def) {
      /** @type {?} */
      var parentEl = getParentRenderElement(view, renderHost, def);

      if (!parentEl) {
        // Nothing to do if there is no parent element.
        return;
      }
      /** @type {?} */


      var ngContentIndex =
      /** @type {?} */
      def.ngContent.index;
      visitProjectedRenderNodes(view, ngContentIndex, 1
      /* AppendChild */
      , parentEl, null, undefined);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/view/pure_expression.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} checkIndex
     * @param {?} argCount
     * @return {?}
     */


    function purePipeDef(checkIndex, argCount) {
      // argCount + 1 to include the pipe as first arg
      return _pureExpressionDef(128
      /* TypePurePipe */
      , checkIndex, newArray(argCount + 1));
    }
    /**
     * @param {?} checkIndex
     * @param {?} argCount
     * @return {?}
     */


    function pureArrayDef(checkIndex, argCount) {
      return _pureExpressionDef(32
      /* TypePureArray */
      , checkIndex, newArray(argCount));
    }
    /**
     * @param {?} checkIndex
     * @param {?} propToIndex
     * @return {?}
     */


    function pureObjectDef(checkIndex, propToIndex) {
      /** @type {?} */
      var keys = Object.keys(propToIndex);
      /** @type {?} */

      var nbKeys = keys.length;
      /** @type {?} */

      var propertyNames = [];

      for (var i = 0; i < nbKeys; i++) {
        /** @type {?} */
        var key = keys[i];
        /** @type {?} */

        var index = propToIndex[key];
        propertyNames.push(key);
      }

      return _pureExpressionDef(64
      /* TypePureObject */
      , checkIndex, propertyNames);
    }
    /**
     * @param {?} flags
     * @param {?} checkIndex
     * @param {?} propertyNames
     * @return {?}
     */


    function _pureExpressionDef(flags, checkIndex, propertyNames) {
      /** @type {?} */
      var bindings = [];

      for (var i = 0; i < propertyNames.length; i++) {
        /** @type {?} */
        var prop = propertyNames[i];
        bindings.push({
          flags: 8
          /* TypeProperty */
          ,
          name: prop,
          ns: null,
          nonMinifiedName: prop,
          securityContext: null,
          suffix: null
        });
      }

      return {
        // will bet set by the view definition
        nodeIndex: -1,
        parent: null,
        renderParent: null,
        bindingIndex: -1,
        outputIndex: -1,
        // regular values
        checkIndex: checkIndex,
        flags: flags,
        childFlags: 0,
        directChildFlags: 0,
        childMatchedQueries: 0,
        matchedQueries: {},
        matchedQueryIds: 0,
        references: {},
        ngContentIndex: -1,
        childCount: 0,
        bindings: bindings,
        bindingFlags: calcBindingFlags(bindings),
        outputs: [],
        element: null,
        provider: null,
        text: null,
        query: null,
        ngContent: null
      };
    }
    /**
     * @param {?} view
     * @param {?} def
     * @return {?}
     */


    function createPureExpression(view, def) {
      return {
        value: undefined
      };
    }
    /**
     * @param {?} view
     * @param {?} def
     * @param {?} v0
     * @param {?} v1
     * @param {?} v2
     * @param {?} v3
     * @param {?} v4
     * @param {?} v5
     * @param {?} v6
     * @param {?} v7
     * @param {?} v8
     * @param {?} v9
     * @return {?}
     */


    function checkAndUpdatePureExpressionInline(view, def, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9) {
      /** @type {?} */
      var bindings = def.bindings;
      /** @type {?} */

      var changed = false;
      /** @type {?} */

      var bindLen = bindings.length;
      if (bindLen > 0 && checkAndUpdateBinding(view, def, 0, v0)) changed = true;
      if (bindLen > 1 && checkAndUpdateBinding(view, def, 1, v1)) changed = true;
      if (bindLen > 2 && checkAndUpdateBinding(view, def, 2, v2)) changed = true;
      if (bindLen > 3 && checkAndUpdateBinding(view, def, 3, v3)) changed = true;
      if (bindLen > 4 && checkAndUpdateBinding(view, def, 4, v4)) changed = true;
      if (bindLen > 5 && checkAndUpdateBinding(view, def, 5, v5)) changed = true;
      if (bindLen > 6 && checkAndUpdateBinding(view, def, 6, v6)) changed = true;
      if (bindLen > 7 && checkAndUpdateBinding(view, def, 7, v7)) changed = true;
      if (bindLen > 8 && checkAndUpdateBinding(view, def, 8, v8)) changed = true;
      if (bindLen > 9 && checkAndUpdateBinding(view, def, 9, v9)) changed = true;

      if (changed) {
        /** @type {?} */
        var data = asPureExpressionData(view, def.nodeIndex);
        /** @type {?} */

        var value;

        switch (def.flags & 201347067
        /* Types */
        ) {
          case 32
          /* TypePureArray */
          :
            value = [];
            if (bindLen > 0) value.push(v0);
            if (bindLen > 1) value.push(v1);
            if (bindLen > 2) value.push(v2);
            if (bindLen > 3) value.push(v3);
            if (bindLen > 4) value.push(v4);
            if (bindLen > 5) value.push(v5);
            if (bindLen > 6) value.push(v6);
            if (bindLen > 7) value.push(v7);
            if (bindLen > 8) value.push(v8);
            if (bindLen > 9) value.push(v9);
            break;

          case 64
          /* TypePureObject */
          :
            value = {};
            if (bindLen > 0) value[
            /** @type {?} */
            bindings[0].name] = v0;
            if (bindLen > 1) value[
            /** @type {?} */
            bindings[1].name] = v1;
            if (bindLen > 2) value[
            /** @type {?} */
            bindings[2].name] = v2;
            if (bindLen > 3) value[
            /** @type {?} */
            bindings[3].name] = v3;
            if (bindLen > 4) value[
            /** @type {?} */
            bindings[4].name] = v4;
            if (bindLen > 5) value[
            /** @type {?} */
            bindings[5].name] = v5;
            if (bindLen > 6) value[
            /** @type {?} */
            bindings[6].name] = v6;
            if (bindLen > 7) value[
            /** @type {?} */
            bindings[7].name] = v7;
            if (bindLen > 8) value[
            /** @type {?} */
            bindings[8].name] = v8;
            if (bindLen > 9) value[
            /** @type {?} */
            bindings[9].name] = v9;
            break;

          case 128
          /* TypePurePipe */
          :
            /** @type {?} */
            var pipe = v0;

            switch (bindLen) {
              case 1:
                value = pipe.transform(v0);
                break;

              case 2:
                value = pipe.transform(v1);
                break;

              case 3:
                value = pipe.transform(v1, v2);
                break;

              case 4:
                value = pipe.transform(v1, v2, v3);
                break;

              case 5:
                value = pipe.transform(v1, v2, v3, v4);
                break;

              case 6:
                value = pipe.transform(v1, v2, v3, v4, v5);
                break;

              case 7:
                value = pipe.transform(v1, v2, v3, v4, v5, v6);
                break;

              case 8:
                value = pipe.transform(v1, v2, v3, v4, v5, v6, v7);
                break;

              case 9:
                value = pipe.transform(v1, v2, v3, v4, v5, v6, v7, v8);
                break;

              case 10:
                value = pipe.transform(v1, v2, v3, v4, v5, v6, v7, v8, v9);
                break;
            }

            break;
        }

        data.value = value;
      }

      return changed;
    }
    /**
     * @param {?} view
     * @param {?} def
     * @param {?} values
     * @return {?}
     */


    function checkAndUpdatePureExpressionDynamic(view, def, values) {
      /** @type {?} */
      var bindings = def.bindings;
      /** @type {?} */

      var changed = false;

      for (var i = 0; i < values.length; i++) {
        // Note: We need to loop over all values, so that
        // the old values are updates as well!
        if (checkAndUpdateBinding(view, def, i, values[i])) {
          changed = true;
        }
      }

      if (changed) {
        /** @type {?} */
        var data = asPureExpressionData(view, def.nodeIndex);
        /** @type {?} */

        var value;

        switch (def.flags & 201347067
        /* Types */
        ) {
          case 32
          /* TypePureArray */
          :
            value = values;
            break;

          case 64
          /* TypePureObject */
          :
            value = {};

            for (var _i21 = 0; _i21 < values.length; _i21++) {
              value[
              /** @type {?} */
              bindings[_i21].name] = values[_i21];
            }

            break;

          case 128
          /* TypePurePipe */
          :
            /** @type {?} */
            var pipe = values[0];
            /** @type {?} */

            var params = values.slice(1);
            value =
            /** @type {?} */
            pipe.transform.apply(pipe, _toConsumableArray(params));
            break;
        }

        data.value = value;
      }

      return changed;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/view/text.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} checkIndex
     * @param {?} ngContentIndex
     * @param {?} staticText
     * @return {?}
     */


    function textDef(checkIndex, ngContentIndex, staticText) {
      /** @type {?} */
      var bindings = [];

      for (var i = 1; i < staticText.length; i++) {
        bindings[i - 1] = {
          flags: 8
          /* TypeProperty */
          ,
          name: null,
          ns: null,
          nonMinifiedName: null,
          securityContext: null,
          suffix: staticText[i]
        };
      }

      return {
        // will bet set by the view definition
        nodeIndex: -1,
        parent: null,
        renderParent: null,
        bindingIndex: -1,
        outputIndex: -1,
        // regular values
        checkIndex: checkIndex,
        flags: 2
        /* TypeText */
        ,
        childFlags: 0,
        directChildFlags: 0,
        childMatchedQueries: 0,
        matchedQueries: {},
        matchedQueryIds: 0,
        references: {},
        ngContentIndex: ngContentIndex,
        childCount: 0,
        bindings: bindings,
        bindingFlags: 8
        /* TypeProperty */
        ,
        outputs: [],
        element: null,
        provider: null,
        text: {
          prefix: staticText[0]
        },
        query: null,
        ngContent: null
      };
    }
    /**
     * @param {?} view
     * @param {?} renderHost
     * @param {?} def
     * @return {?}
     */


    function createText(view, renderHost, def) {
      /** @type {?} */
      var renderNode;
      /** @type {?} */

      var renderer = view.renderer;
      renderNode = renderer.createText(
      /** @type {?} */
      def.text.prefix);
      /** @type {?} */

      var parentEl = getParentRenderElement(view, renderHost, def);

      if (parentEl) {
        renderer.appendChild(parentEl, renderNode);
      }

      return {
        renderText: renderNode
      };
    }
    /**
     * @param {?} view
     * @param {?} def
     * @param {?} v0
     * @param {?} v1
     * @param {?} v2
     * @param {?} v3
     * @param {?} v4
     * @param {?} v5
     * @param {?} v6
     * @param {?} v7
     * @param {?} v8
     * @param {?} v9
     * @return {?}
     */


    function checkAndUpdateTextInline(view, def, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9) {
      /** @type {?} */
      var changed = false;
      /** @type {?} */

      var bindings = def.bindings;
      /** @type {?} */

      var bindLen = bindings.length;
      if (bindLen > 0 && checkAndUpdateBinding(view, def, 0, v0)) changed = true;
      if (bindLen > 1 && checkAndUpdateBinding(view, def, 1, v1)) changed = true;
      if (bindLen > 2 && checkAndUpdateBinding(view, def, 2, v2)) changed = true;
      if (bindLen > 3 && checkAndUpdateBinding(view, def, 3, v3)) changed = true;
      if (bindLen > 4 && checkAndUpdateBinding(view, def, 4, v4)) changed = true;
      if (bindLen > 5 && checkAndUpdateBinding(view, def, 5, v5)) changed = true;
      if (bindLen > 6 && checkAndUpdateBinding(view, def, 6, v6)) changed = true;
      if (bindLen > 7 && checkAndUpdateBinding(view, def, 7, v7)) changed = true;
      if (bindLen > 8 && checkAndUpdateBinding(view, def, 8, v8)) changed = true;
      if (bindLen > 9 && checkAndUpdateBinding(view, def, 9, v9)) changed = true;

      if (changed) {
        /** @type {?} */
        var value =
        /** @type {?} */
        def.text.prefix;
        if (bindLen > 0) value += _addInterpolationPart(v0, bindings[0]);
        if (bindLen > 1) value += _addInterpolationPart(v1, bindings[1]);
        if (bindLen > 2) value += _addInterpolationPart(v2, bindings[2]);
        if (bindLen > 3) value += _addInterpolationPart(v3, bindings[3]);
        if (bindLen > 4) value += _addInterpolationPart(v4, bindings[4]);
        if (bindLen > 5) value += _addInterpolationPart(v5, bindings[5]);
        if (bindLen > 6) value += _addInterpolationPart(v6, bindings[6]);
        if (bindLen > 7) value += _addInterpolationPart(v7, bindings[7]);
        if (bindLen > 8) value += _addInterpolationPart(v8, bindings[8]);
        if (bindLen > 9) value += _addInterpolationPart(v9, bindings[9]);
        /** @type {?} */

        var _renderNode = asTextData(view, def.nodeIndex).renderText;
        view.renderer.setValue(_renderNode, value);
      }

      return changed;
    }
    /**
     * @param {?} view
     * @param {?} def
     * @param {?} values
     * @return {?}
     */


    function checkAndUpdateTextDynamic(view, def, values) {
      /** @type {?} */
      var bindings = def.bindings;
      /** @type {?} */

      var changed = false;

      for (var i = 0; i < values.length; i++) {
        // Note: We need to loop over all values, so that
        // the old values are updates as well!
        if (checkAndUpdateBinding(view, def, i, values[i])) {
          changed = true;
        }
      }

      if (changed) {
        /** @type {?} */
        var value = '';

        for (var _i22 = 0; _i22 < values.length; _i22++) {
          value = value + _addInterpolationPart(values[_i22], bindings[_i22]);
        }

        value =
        /** @type {?} */
        def.text.prefix + value;
        /** @type {?} */

        var _renderNode2 = asTextData(view, def.nodeIndex).renderText;
        view.renderer.setValue(_renderNode2, value);
      }

      return changed;
    }
    /**
     * @param {?} value
     * @param {?} binding
     * @return {?}
     */


    function _addInterpolationPart(value, binding) {
      /** @type {?} */
      var valueStr = value != null ? value.toString() : '';
      return valueStr + binding.suffix;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/view/view.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} flags
     * @param {?} nodes
     * @param {?=} updateDirectives
     * @param {?=} updateRenderer
     * @return {?}
     */


    function viewDef(flags, nodes, updateDirectives, updateRenderer) {
      // clone nodes and set auto calculated values

      /** @type {?} */
      var viewBindingCount = 0;
      /** @type {?} */

      var viewDisposableCount = 0;
      /** @type {?} */

      var viewNodeFlags = 0;
      /** @type {?} */

      var viewRootNodeFlags = 0;
      /** @type {?} */

      var viewMatchedQueries = 0;
      /** @type {?} */

      var currentParent = null;
      /** @type {?} */

      var currentRenderParent = null;
      /** @type {?} */

      var currentElementHasPublicProviders = false;
      /** @type {?} */

      var currentElementHasPrivateProviders = false;
      /** @type {?} */

      var lastRenderRootNode = null;

      for (var i = 0; i < nodes.length; i++) {
        /** @type {?} */
        var node = nodes[i];
        node.nodeIndex = i;
        node.parent = currentParent;
        node.bindingIndex = viewBindingCount;
        node.outputIndex = viewDisposableCount;
        node.renderParent = currentRenderParent;
        viewNodeFlags |= node.flags;
        viewMatchedQueries |= node.matchedQueryIds;

        if (node.element) {
          /** @type {?} */
          var elDef = node.element;
          elDef.publicProviders = currentParent ?
          /** @type {?} */
          currentParent.element.publicProviders : Object.create(null);
          elDef.allProviders = elDef.publicProviders; // Note: We assume that all providers of an element are before any child element!

          currentElementHasPublicProviders = false;
          currentElementHasPrivateProviders = false;

          if (node.element.template) {
            viewMatchedQueries |= node.element.template.nodeMatchedQueries;
          }
        }

        validateNode(currentParent, node, nodes.length);
        viewBindingCount += node.bindings.length;
        viewDisposableCount += node.outputs.length;

        if (!currentRenderParent && node.flags & 3
        /* CatRenderNode */
        ) {
          lastRenderRootNode = node;
        }

        if (node.flags & 20224
        /* CatProvider */
        ) {
            if (!currentElementHasPublicProviders) {
              currentElementHasPublicProviders = true; // Use prototypical inheritance to not get O(n^2) complexity...

              /** @type {?} */

              /** @type {?} */
              currentParent.element.publicProviders = Object.create(
              /** @type {?} */

              /** @type {?} */
              currentParent.element.publicProviders);

              /** @type {?} */

              /** @type {?} */
              currentParent.element.allProviders =
              /** @type {?} */

              /** @type {?} */
              currentParent.element.publicProviders;
            }
            /** @type {?} */


            var isPrivateService = (node.flags & 8192
            /* PrivateProvider */
            ) !== 0;
            /** @type {?} */

            var isComponent = (node.flags & 32768
            /* Component */
            ) !== 0;

            if (!isPrivateService || isComponent) {
              /** @type {?} */

              /** @type {?} */

              /** @type {?} */
              currentParent.element.publicProviders[tokenKey(
              /** @type {?} */
              node.provider.token)] = node;
            } else {
              if (!currentElementHasPrivateProviders) {
                currentElementHasPrivateProviders = true; // Use prototypical inheritance to not get O(n^2) complexity...

                /** @type {?} */

                /** @type {?} */
                currentParent.element.allProviders = Object.create(
                /** @type {?} */

                /** @type {?} */
                currentParent.element.publicProviders);
              }

              /** @type {?} */

              /** @type {?} */

              /** @type {?} */
              currentParent.element.allProviders[tokenKey(
              /** @type {?} */
              node.provider.token)] = node;
            }

            if (isComponent) {
              /** @type {?} */

              /** @type {?} */
              currentParent.element.componentProvider = node;
            }
          }

        if (currentParent) {
          currentParent.childFlags |= node.flags;
          currentParent.directChildFlags |= node.flags;
          currentParent.childMatchedQueries |= node.matchedQueryIds;

          if (node.element && node.element.template) {
            currentParent.childMatchedQueries |= node.element.template.nodeMatchedQueries;
          }
        } else {
          viewRootNodeFlags |= node.flags;
        }

        if (node.childCount > 0) {
          currentParent = node;

          if (!isNgContainer(node)) {
            currentRenderParent = node;
          }
        } else {
          // When the current node has no children, check if it is the last children of its parent.
          // When it is, propagate the flags up.
          // The loop is required because an element could be the last transitive children of several
          // elements. We loop to either the root or the highest opened element (= with remaining
          // children)
          while (currentParent && i === currentParent.nodeIndex + currentParent.childCount) {
            /** @type {?} */
            var newParent = currentParent.parent;

            if (newParent) {
              newParent.childFlags |= currentParent.childFlags;
              newParent.childMatchedQueries |= currentParent.childMatchedQueries;
            }

            currentParent = newParent; // We also need to update the render parent & account for ng-container

            if (currentParent && isNgContainer(currentParent)) {
              currentRenderParent = currentParent.renderParent;
            } else {
              currentRenderParent = currentParent;
            }
          }
        }
      }
      /** @type {?} */


      var handleEvent =
      /**
      * @param {?} view
      * @param {?} nodeIndex
      * @param {?} eventName
      * @param {?} event
      * @return {?}
      */
      function handleEvent(view, nodeIndex, eventName, event) {
        return (
          /** @type {?} */

          /** @type {?} */
          nodes[nodeIndex].element.handleEvent(view, eventName, event)
        );
      };

      return {
        // Will be filled later...
        factory: null,
        nodeFlags: viewNodeFlags,
        rootNodeFlags: viewRootNodeFlags,
        nodeMatchedQueries: viewMatchedQueries,
        flags: flags,
        nodes: nodes,
        updateDirectives: updateDirectives || NOOP,
        updateRenderer: updateRenderer || NOOP,
        handleEvent: handleEvent,
        bindingCount: viewBindingCount,
        outputCount: viewDisposableCount,
        lastRenderRootNode: lastRenderRootNode
      };
    }
    /**
     * @param {?} node
     * @return {?}
     */


    function isNgContainer(node) {
      return (node.flags & 1
      /* TypeElement */
      ) !== 0 &&
      /** @type {?} */
      node.element.name === null;
    }
    /**
     * @param {?} parent
     * @param {?} node
     * @param {?} nodeCount
     * @return {?}
     */


    function validateNode(parent, node, nodeCount) {
      /** @type {?} */
      var template = node.element && node.element.template;

      if (template) {
        if (!template.lastRenderRootNode) {
          throw new Error("Illegal State: Embedded templates without nodes are not allowed!");
        }

        if (template.lastRenderRootNode && template.lastRenderRootNode.flags & 16777216
        /* EmbeddedViews */
        ) {
            throw new Error("Illegal State: Last root node of a template can't have embedded views, at index ".concat(node.nodeIndex, "!"));
          }
      }

      if (node.flags & 20224
      /* CatProvider */
      ) {
          /** @type {?} */
          var parentFlags = parent ? parent.flags : 0;

          if ((parentFlags & 1
          /* TypeElement */
          ) === 0) {
            throw new Error("Illegal State: StaticProvider/Directive nodes need to be children of elements or anchors, at index ".concat(node.nodeIndex, "!"));
          }
        }

      if (node.query) {
        if (node.flags & 67108864
        /* TypeContentQuery */
        && (!parent || (parent.flags & 16384
        /* TypeDirective */
        ) === 0)) {
          throw new Error("Illegal State: Content Query nodes need to be children of directives, at index ".concat(node.nodeIndex, "!"));
        }

        if (node.flags & 134217728
        /* TypeViewQuery */
        && parent) {
          throw new Error("Illegal State: View Query nodes have to be top level nodes, at index ".concat(node.nodeIndex, "!"));
        }
      }

      if (node.childCount) {
        /** @type {?} */
        var parentEnd = parent ? parent.nodeIndex + parent.childCount : nodeCount - 1;

        if (node.nodeIndex <= parentEnd && node.nodeIndex + node.childCount > parentEnd) {
          throw new Error("Illegal State: childCount of node leads outside of parent, at index ".concat(node.nodeIndex, "!"));
        }
      }
    }
    /**
     * @param {?} parent
     * @param {?} anchorDef
     * @param {?} viewDef
     * @param {?=} context
     * @return {?}
     */


    function createEmbeddedView(parent, anchorDef, viewDef, context) {
      // embedded views are seen as siblings to the anchor, so we need
      // to get the parent of the anchor and use it as parentIndex.

      /** @type {?} */
      var view = createView(parent.root, parent.renderer, parent, anchorDef, viewDef);
      initView(view, parent.component, context);
      createViewNodes(view);
      return view;
    }
    /**
     * @param {?} root
     * @param {?} def
     * @param {?=} context
     * @return {?}
     */


    function createRootView(root, def, context) {
      /** @type {?} */
      var view = createView(root, root.renderer, null, null, def);
      initView(view, context, context);
      createViewNodes(view);
      return view;
    }
    /**
     * @param {?} parentView
     * @param {?} nodeDef
     * @param {?} viewDef
     * @param {?} hostElement
     * @return {?}
     */


    function createComponentView(parentView, nodeDef, viewDef, hostElement) {
      /** @type {?} */
      var rendererType =
      /** @type {?} */
      nodeDef.element.componentRendererType;
      /** @type {?} */

      var compRenderer;

      if (!rendererType) {
        compRenderer = parentView.root.renderer;
      } else {
        compRenderer = parentView.root.rendererFactory.createRenderer(hostElement, rendererType);
      }

      return createView(parentView.root, compRenderer, parentView,
      /** @type {?} */
      nodeDef.element.componentProvider, viewDef);
    }
    /**
     * @param {?} root
     * @param {?} renderer
     * @param {?} parent
     * @param {?} parentNodeDef
     * @param {?} def
     * @return {?}
     */


    function createView(root, renderer, parent, parentNodeDef, def) {
      /** @type {?} */
      var nodes = new Array(def.nodes.length);
      /** @type {?} */

      var disposables = def.outputCount ? new Array(def.outputCount) : null;
      /** @type {?} */

      var view = {
        def: def,
        parent: parent,
        viewContainerParent: null,
        parentNodeDef: parentNodeDef,
        context: null,
        component: null,
        nodes: nodes,
        state: 13
        /* CatInit */
        ,
        root: root,
        renderer: renderer,
        oldValues: new Array(def.bindingCount),
        disposables: disposables,
        initIndex: -1
      };
      return view;
    }
    /**
     * @param {?} view
     * @param {?} component
     * @param {?} context
     * @return {?}
     */


    function initView(view, component, context) {
      view.component = component;
      view.context = context;
    }
    /**
     * @param {?} view
     * @return {?}
     */


    function createViewNodes(view) {
      /** @type {?} */
      var renderHost;

      if (isComponentView(view)) {
        /** @type {?} */
        var hostDef = view.parentNodeDef;
        renderHost = asElementData(
        /** @type {?} */
        view.parent,
        /** @type {?} */

        /** @type {?} */
        hostDef.parent.nodeIndex).renderElement;
      }
      /** @type {?} */


      var def = view.def;
      /** @type {?} */

      var nodes = view.nodes;

      for (var i = 0; i < def.nodes.length; i++) {
        /** @type {?} */
        var nodeDef = def.nodes[i];
        Services.setCurrentNode(view, i);
        /** @type {?} */

        var nodeData = void 0;

        switch (nodeDef.flags & 201347067
        /* Types */
        ) {
          case 1
          /* TypeElement */
          :
            /** @type {?} */
            var el =
            /** @type {?} */
            createElement(view, renderHost, nodeDef);
            /** @type {?} */

            var componentView =
            /** @type {?} */
            undefined;

            if (nodeDef.flags & 33554432
            /* ComponentView */
            ) {
                /** @type {?} */
                var compViewDef = resolveDefinition(
                /** @type {?} */

                /** @type {?} */
                nodeDef.element.componentView);
                componentView = Services.createComponentView(view, nodeDef, compViewDef, el);
              }

            listenToElementOutputs(view, componentView, nodeDef, el);
            nodeData =
            /** @type {?} */
            {
              renderElement: el,
              componentView: componentView,
              viewContainer: null,
              template:
              /** @type {?} */
              nodeDef.element.template ? createTemplateData(view, nodeDef) : undefined
            };

            if (nodeDef.flags & 16777216
            /* EmbeddedViews */
            ) {
                nodeData.viewContainer = createViewContainerData(view, nodeDef, nodeData);
              }

            break;

          case 2
          /* TypeText */
          :
            nodeData =
            /** @type {?} */
            createText(view, renderHost, nodeDef);
            break;

          case 512
          /* TypeClassProvider */
          :
          case 1024
          /* TypeFactoryProvider */
          :
          case 2048
          /* TypeUseExistingProvider */
          :
          case 256
          /* TypeValueProvider */
          :
            {
              nodeData = nodes[i];

              if (!nodeData && !(nodeDef.flags & 4096
              /* LazyProvider */
              )) {
                /** @type {?} */
                var instance = createProviderInstance(view, nodeDef);
                nodeData =
                /** @type {?} */
                {
                  instance: instance
                };
              }

              break;
            }

          case 16
          /* TypePipe */
          :
            {
              /** @type {?} */
              var _instance = createPipeInstance(view, nodeDef);

              nodeData =
              /** @type {?} */
              {
                instance: _instance
              };
              break;
            }

          case 16384
          /* TypeDirective */
          :
            {
              nodeData = nodes[i];

              if (!nodeData) {
                /** @type {?} */
                var _instance2 = createDirectiveInstance(view, nodeDef);

                nodeData =
                /** @type {?} */
                {
                  instance: _instance2
                };
              }

              if (nodeDef.flags & 32768
              /* Component */
              ) {
                  /** @type {?} */
                  var compView = asElementData(view,
                  /** @type {?} */
                  nodeDef.parent.nodeIndex).componentView;
                  initView(compView, nodeData.instance, nodeData.instance);
                }

              break;
            }

          case 32
          /* TypePureArray */
          :
          case 64
          /* TypePureObject */
          :
          case 128
          /* TypePurePipe */
          :
            nodeData =
            /** @type {?} */
            createPureExpression(view, nodeDef);
            break;

          case 67108864
          /* TypeContentQuery */
          :
          case 134217728
          /* TypeViewQuery */
          :
            nodeData =
            /** @type {?} */
            createQuery();
            break;

          case 8
          /* TypeNgContent */
          :
            appendNgContent(view, renderHost, nodeDef); // no runtime data needed for NgContent...

            nodeData = undefined;
            break;
        }

        nodes[i] = nodeData;
      } // Create the ViewData.nodes of component views after we created everything else,
      // so that e.g. ng-content works


      execComponentViewsAction(view, ViewAction.CreateViewNodes); // fill static content and view queries

      execQueriesAction(view, 67108864
      /* TypeContentQuery */
      | 134217728
      /* TypeViewQuery */
      , 268435456
      /* StaticQuery */
      , 0
      /* CheckAndUpdate */
      );
    }
    /**
     * @param {?} view
     * @return {?}
     */


    function checkNoChangesView(view) {
      markProjectedViewsForCheck(view);
      Services.updateDirectives(view, 1
      /* CheckNoChanges */
      );
      execEmbeddedViewsAction(view, ViewAction.CheckNoChanges);
      Services.updateRenderer(view, 1
      /* CheckNoChanges */
      );
      execComponentViewsAction(view, ViewAction.CheckNoChanges); // Note: We don't check queries for changes as we didn't do this in v2.x.
      // TODO(tbosch): investigate if we can enable the check again in v5.x with a nicer error message.

      view.state &= ~(64
      /* CheckProjectedViews */
      | 32
      /* CheckProjectedView */
      );
    }
    /**
     * @param {?} view
     * @return {?}
     */


    function checkAndUpdateView(view) {
      if (view.state & 1
      /* BeforeFirstCheck */
      ) {
          view.state &= ~1
          /* BeforeFirstCheck */
          ;
          view.state |= 2
          /* FirstCheck */
          ;
        } else {
        view.state &= ~2
        /* FirstCheck */
        ;
      }

      shiftInitState(view, 0
      /* InitState_BeforeInit */
      , 256
      /* InitState_CallingOnInit */
      );
      markProjectedViewsForCheck(view);
      Services.updateDirectives(view, 0
      /* CheckAndUpdate */
      );
      execEmbeddedViewsAction(view, ViewAction.CheckAndUpdate);
      execQueriesAction(view, 67108864
      /* TypeContentQuery */
      , 536870912
      /* DynamicQuery */
      , 0
      /* CheckAndUpdate */
      );
      /** @type {?} */

      var callInit = shiftInitState(view, 256
      /* InitState_CallingOnInit */
      , 512
      /* InitState_CallingAfterContentInit */
      );
      callLifecycleHooksChildrenFirst(view, 2097152
      /* AfterContentChecked */
      | (callInit ? 1048576
      /* AfterContentInit */
      : 0));
      Services.updateRenderer(view, 0
      /* CheckAndUpdate */
      );
      execComponentViewsAction(view, ViewAction.CheckAndUpdate);
      execQueriesAction(view, 134217728
      /* TypeViewQuery */
      , 536870912
      /* DynamicQuery */
      , 0
      /* CheckAndUpdate */
      );
      callInit = shiftInitState(view, 512
      /* InitState_CallingAfterContentInit */
      , 768
      /* InitState_CallingAfterViewInit */
      );
      callLifecycleHooksChildrenFirst(view, 8388608
      /* AfterViewChecked */
      | (callInit ? 4194304
      /* AfterViewInit */
      : 0));

      if (view.def.flags & 2
      /* OnPush */
      ) {
          view.state &= ~8
          /* ChecksEnabled */
          ;
        }

      view.state &= ~(64
      /* CheckProjectedViews */
      | 32
      /* CheckProjectedView */
      );
      shiftInitState(view, 768
      /* InitState_CallingAfterViewInit */
      , 1024
      /* InitState_AfterInit */
      );
    }
    /**
     * @param {?} view
     * @param {?} nodeDef
     * @param {?} argStyle
     * @param {?=} v0
     * @param {?=} v1
     * @param {?=} v2
     * @param {?=} v3
     * @param {?=} v4
     * @param {?=} v5
     * @param {?=} v6
     * @param {?=} v7
     * @param {?=} v8
     * @param {?=} v9
     * @return {?}
     */


    function checkAndUpdateNode(view, nodeDef, argStyle, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9) {
      if (argStyle === 0
      /* Inline */
      ) {
          return checkAndUpdateNodeInline(view, nodeDef, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9);
        } else {
        return checkAndUpdateNodeDynamic(view, nodeDef, v0);
      }
    }
    /**
     * @param {?} view
     * @return {?}
     */


    function markProjectedViewsForCheck(view) {
      /** @type {?} */
      var def = view.def;

      if (!(def.nodeFlags & 4
      /* ProjectedTemplate */
      )) {
        return;
      }

      for (var i = 0; i < def.nodes.length; i++) {
        /** @type {?} */
        var nodeDef = def.nodes[i];

        if (nodeDef.flags & 4
        /* ProjectedTemplate */
        ) {
            /** @type {?} */
            var projectedViews = asElementData(view, i).template._projectedViews;

            if (projectedViews) {
              for (var _i23 = 0; _i23 < projectedViews.length; _i23++) {
                /** @type {?} */
                var projectedView = projectedViews[_i23];
                projectedView.state |= 32
                /* CheckProjectedView */
                ;
                markParentViewsForCheckProjectedViews(projectedView, view);
              }
            }
          } else if ((nodeDef.childFlags & 4
        /* ProjectedTemplate */
        ) === 0) {
          // a parent with leafs
          // no child is a component,
          // then skip the children
          i += nodeDef.childCount;
        }
      }
    }
    /**
     * @param {?} view
     * @param {?} nodeDef
     * @param {?=} v0
     * @param {?=} v1
     * @param {?=} v2
     * @param {?=} v3
     * @param {?=} v4
     * @param {?=} v5
     * @param {?=} v6
     * @param {?=} v7
     * @param {?=} v8
     * @param {?=} v9
     * @return {?}
     */


    function checkAndUpdateNodeInline(view, nodeDef, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9) {
      switch (nodeDef.flags & 201347067
      /* Types */
      ) {
        case 1
        /* TypeElement */
        :
          return checkAndUpdateElementInline(view, nodeDef, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9);

        case 2
        /* TypeText */
        :
          return checkAndUpdateTextInline(view, nodeDef, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9);

        case 16384
        /* TypeDirective */
        :
          return checkAndUpdateDirectiveInline(view, nodeDef, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9);

        case 32
        /* TypePureArray */
        :
        case 64
        /* TypePureObject */
        :
        case 128
        /* TypePurePipe */
        :
          return checkAndUpdatePureExpressionInline(view, nodeDef, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9);

        default:
          throw 'unreachable';
      }
    }
    /**
     * @param {?} view
     * @param {?} nodeDef
     * @param {?} values
     * @return {?}
     */


    function checkAndUpdateNodeDynamic(view, nodeDef, values) {
      switch (nodeDef.flags & 201347067
      /* Types */
      ) {
        case 1
        /* TypeElement */
        :
          return checkAndUpdateElementDynamic(view, nodeDef, values);

        case 2
        /* TypeText */
        :
          return checkAndUpdateTextDynamic(view, nodeDef, values);

        case 16384
        /* TypeDirective */
        :
          return checkAndUpdateDirectiveDynamic(view, nodeDef, values);

        case 32
        /* TypePureArray */
        :
        case 64
        /* TypePureObject */
        :
        case 128
        /* TypePurePipe */
        :
          return checkAndUpdatePureExpressionDynamic(view, nodeDef, values);

        default:
          throw 'unreachable';
      }
    }
    /**
     * @param {?} view
     * @param {?} nodeDef
     * @param {?} argStyle
     * @param {?=} v0
     * @param {?=} v1
     * @param {?=} v2
     * @param {?=} v3
     * @param {?=} v4
     * @param {?=} v5
     * @param {?=} v6
     * @param {?=} v7
     * @param {?=} v8
     * @param {?=} v9
     * @return {?}
     */


    function checkNoChangesNode(view, nodeDef, argStyle, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9) {
      if (argStyle === 0
      /* Inline */
      ) {
          checkNoChangesNodeInline(view, nodeDef, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9);
        } else {
        checkNoChangesNodeDynamic(view, nodeDef, v0);
      } // Returning false is ok here as we would have thrown in case of a change.


      return false;
    }
    /**
     * @param {?} view
     * @param {?} nodeDef
     * @param {?} v0
     * @param {?} v1
     * @param {?} v2
     * @param {?} v3
     * @param {?} v4
     * @param {?} v5
     * @param {?} v6
     * @param {?} v7
     * @param {?} v8
     * @param {?} v9
     * @return {?}
     */


    function checkNoChangesNodeInline(view, nodeDef, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9) {
      /** @type {?} */
      var bindLen = nodeDef.bindings.length;
      if (bindLen > 0) checkBindingNoChanges(view, nodeDef, 0, v0);
      if (bindLen > 1) checkBindingNoChanges(view, nodeDef, 1, v1);
      if (bindLen > 2) checkBindingNoChanges(view, nodeDef, 2, v2);
      if (bindLen > 3) checkBindingNoChanges(view, nodeDef, 3, v3);
      if (bindLen > 4) checkBindingNoChanges(view, nodeDef, 4, v4);
      if (bindLen > 5) checkBindingNoChanges(view, nodeDef, 5, v5);
      if (bindLen > 6) checkBindingNoChanges(view, nodeDef, 6, v6);
      if (bindLen > 7) checkBindingNoChanges(view, nodeDef, 7, v7);
      if (bindLen > 8) checkBindingNoChanges(view, nodeDef, 8, v8);
      if (bindLen > 9) checkBindingNoChanges(view, nodeDef, 9, v9);
    }
    /**
     * @param {?} view
     * @param {?} nodeDef
     * @param {?} values
     * @return {?}
     */


    function checkNoChangesNodeDynamic(view, nodeDef, values) {
      for (var i = 0; i < values.length; i++) {
        checkBindingNoChanges(view, nodeDef, i, values[i]);
      }
    }
    /**
     * Workaround https://github.com/angular/tsickle/issues/497
     * @suppress {misplacedTypeAnnotation}
     * @param {?} view
     * @param {?} nodeDef
     * @return {?}
     */


    function checkNoChangesQuery(view, nodeDef) {
      /** @type {?} */
      var queryList = asQueryList(view, nodeDef.nodeIndex);

      if (queryList.dirty) {
        throw expressionChangedAfterItHasBeenCheckedError(Services.createDebugContext(view, nodeDef.nodeIndex), "Query ".concat(
        /** @type {?} */
        nodeDef.query.id, " not dirty"), "Query ".concat(
        /** @type {?} */
        nodeDef.query.id, " dirty"), (view.state & 1
        /* BeforeFirstCheck */
        ) !== 0);
      }
    }
    /**
     * @param {?} view
     * @return {?}
     */


    function destroyView(view) {
      if (view.state & 128
      /* Destroyed */
      ) {
          return;
        }

      execEmbeddedViewsAction(view, ViewAction.Destroy);
      execComponentViewsAction(view, ViewAction.Destroy);
      callLifecycleHooksChildrenFirst(view, 131072
      /* OnDestroy */
      );

      if (view.disposables) {
        for (var i = 0; i < view.disposables.length; i++) {
          view.disposables[i]();
        }
      }

      detachProjectedView(view);

      if (view.renderer.destroyNode) {
        destroyViewNodes(view);
      }

      if (isComponentView(view)) {
        view.renderer.destroy();
      }

      view.state |= 128
      /* Destroyed */
      ;
    }
    /**
     * @param {?} view
     * @return {?}
     */


    function destroyViewNodes(view) {
      /** @type {?} */
      var len = view.def.nodes.length;

      for (var i = 0; i < len; i++) {
        /** @type {?} */
        var def = view.def.nodes[i];

        if (def.flags & 1
        /* TypeElement */
        ) {
            /** @type {?} */
            view.renderer.destroyNode(asElementData(view, i).renderElement);
          } else if (def.flags & 2
        /* TypeText */
        ) {
            /** @type {?} */
            view.renderer.destroyNode(asTextData(view, i).renderText);
          } else if (def.flags & 67108864
        /* TypeContentQuery */
        || def.flags & 134217728
        /* TypeViewQuery */
        ) {
            asQueryList(view, i).destroy();
          }
      }
    }
    /** @enum {number} */


    var ViewAction = {
      CreateViewNodes: 0,
      CheckNoChanges: 1,
      CheckNoChangesProjectedViews: 2,
      CheckAndUpdate: 3,
      CheckAndUpdateProjectedViews: 4,
      Destroy: 5
    };
    ViewAction[ViewAction.CreateViewNodes] = 'CreateViewNodes';
    ViewAction[ViewAction.CheckNoChanges] = 'CheckNoChanges';
    ViewAction[ViewAction.CheckNoChangesProjectedViews] = 'CheckNoChangesProjectedViews';
    ViewAction[ViewAction.CheckAndUpdate] = 'CheckAndUpdate';
    ViewAction[ViewAction.CheckAndUpdateProjectedViews] = 'CheckAndUpdateProjectedViews';
    ViewAction[ViewAction.Destroy] = 'Destroy';
    /**
     * @param {?} view
     * @param {?} action
     * @return {?}
     */

    function execComponentViewsAction(view, action) {
      /** @type {?} */
      var def = view.def;

      if (!(def.nodeFlags & 33554432
      /* ComponentView */
      )) {
        return;
      }

      for (var i = 0; i < def.nodes.length; i++) {
        /** @type {?} */
        var nodeDef = def.nodes[i];

        if (nodeDef.flags & 33554432
        /* ComponentView */
        ) {
            // a leaf
            callViewAction(asElementData(view, i).componentView, action);
          } else if ((nodeDef.childFlags & 33554432
        /* ComponentView */
        ) === 0) {
          // a parent with leafs
          // no child is a component,
          // then skip the children
          i += nodeDef.childCount;
        }
      }
    }
    /**
     * @param {?} view
     * @param {?} action
     * @return {?}
     */


    function execEmbeddedViewsAction(view, action) {
      /** @type {?} */
      var def = view.def;

      if (!(def.nodeFlags & 16777216
      /* EmbeddedViews */
      )) {
        return;
      }

      for (var i = 0; i < def.nodes.length; i++) {
        /** @type {?} */
        var nodeDef = def.nodes[i];

        if (nodeDef.flags & 16777216
        /* EmbeddedViews */
        ) {
            // a leaf

            /** @type {?} */
            var embeddedViews =
            /** @type {?} */
            asElementData(view, i).viewContainer._embeddedViews;

            for (var k = 0; k < embeddedViews.length; k++) {
              callViewAction(embeddedViews[k], action);
            }
          } else if ((nodeDef.childFlags & 16777216
        /* EmbeddedViews */
        ) === 0) {
          // a parent with leafs
          // no child is a component,
          // then skip the children
          i += nodeDef.childCount;
        }
      }
    }
    /**
     * @param {?} view
     * @param {?} action
     * @return {?}
     */


    function callViewAction(view, action) {
      /** @type {?} */
      var viewState = view.state;

      switch (action) {
        case ViewAction.CheckNoChanges:
          if ((viewState & 128
          /* Destroyed */
          ) === 0) {
            if ((viewState & 12
            /* CatDetectChanges */
            ) === 12
            /* CatDetectChanges */
            ) {
                checkNoChangesView(view);
              } else if (viewState & 64
            /* CheckProjectedViews */
            ) {
                execProjectedViewsAction(view, ViewAction.CheckNoChangesProjectedViews);
              }
          }

          break;

        case ViewAction.CheckNoChangesProjectedViews:
          if ((viewState & 128
          /* Destroyed */
          ) === 0) {
            if (viewState & 32
            /* CheckProjectedView */
            ) {
                checkNoChangesView(view);
              } else if (viewState & 64
            /* CheckProjectedViews */
            ) {
                execProjectedViewsAction(view, action);
              }
          }

          break;

        case ViewAction.CheckAndUpdate:
          if ((viewState & 128
          /* Destroyed */
          ) === 0) {
            if ((viewState & 12
            /* CatDetectChanges */
            ) === 12
            /* CatDetectChanges */
            ) {
                checkAndUpdateView(view);
              } else if (viewState & 64
            /* CheckProjectedViews */
            ) {
                execProjectedViewsAction(view, ViewAction.CheckAndUpdateProjectedViews);
              }
          }

          break;

        case ViewAction.CheckAndUpdateProjectedViews:
          if ((viewState & 128
          /* Destroyed */
          ) === 0) {
            if (viewState & 32
            /* CheckProjectedView */
            ) {
                checkAndUpdateView(view);
              } else if (viewState & 64
            /* CheckProjectedViews */
            ) {
                execProjectedViewsAction(view, action);
              }
          }

          break;

        case ViewAction.Destroy:
          // Note: destroyView recurses over all views,
          // so we don't need to special case projected views here.
          destroyView(view);
          break;

        case ViewAction.CreateViewNodes:
          createViewNodes(view);
          break;
      }
    }
    /**
     * @param {?} view
     * @param {?} action
     * @return {?}
     */


    function execProjectedViewsAction(view, action) {
      execEmbeddedViewsAction(view, action);
      execComponentViewsAction(view, action);
    }
    /**
     * @param {?} view
     * @param {?} queryFlags
     * @param {?} staticDynamicQueryFlag
     * @param {?} checkType
     * @return {?}
     */


    function execQueriesAction(view, queryFlags, staticDynamicQueryFlag, checkType) {
      if (!(view.def.nodeFlags & queryFlags) || !(view.def.nodeFlags & staticDynamicQueryFlag)) {
        return;
      }
      /** @type {?} */


      var nodeCount = view.def.nodes.length;

      for (var i = 0; i < nodeCount; i++) {
        /** @type {?} */
        var nodeDef = view.def.nodes[i];

        if (nodeDef.flags & queryFlags && nodeDef.flags & staticDynamicQueryFlag) {
          Services.setCurrentNode(view, nodeDef.nodeIndex);

          switch (checkType) {
            case 0
            /* CheckAndUpdate */
            :
              checkAndUpdateQuery(view, nodeDef);
              break;

            case 1
            /* CheckNoChanges */
            :
              checkNoChangesQuery(view, nodeDef);
              break;
          }
        }

        if (!(nodeDef.childFlags & queryFlags) || !(nodeDef.childFlags & staticDynamicQueryFlag)) {
          // no child has a matching query
          // then skip the children
          i += nodeDef.childCount;
        }
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/view/services.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var initialized = false;
    /**
     * @return {?}
     */

    function initServicesIfNeeded() {
      if (initialized) {
        return;
      }

      initialized = true;
      /** @type {?} */

      var services = isDevMode() ? createDebugServices() : createProdServices();
      Services.setCurrentNode = services.setCurrentNode;
      Services.createRootView = services.createRootView;
      Services.createEmbeddedView = services.createEmbeddedView;
      Services.createComponentView = services.createComponentView;
      Services.createNgModuleRef = services.createNgModuleRef;
      Services.overrideProvider = services.overrideProvider;
      Services.overrideComponentView = services.overrideComponentView;
      Services.clearOverrides = services.clearOverrides;
      Services.checkAndUpdateView = services.checkAndUpdateView;
      Services.checkNoChangesView = services.checkNoChangesView;
      Services.destroyView = services.destroyView;
      Services.resolveDep = resolveDep;
      Services.createDebugContext = services.createDebugContext;
      Services.handleEvent = services.handleEvent;
      Services.updateDirectives = services.updateDirectives;
      Services.updateRenderer = services.updateRenderer;
      Services.dirtyParentQueries = dirtyParentQueries;
    }
    /**
     * @return {?}
     */


    function createProdServices() {
      return {
        setCurrentNode:
        /**
        * @return {?}
        */
        function setCurrentNode() {},
        createRootView: createProdRootView,
        createEmbeddedView: createEmbeddedView,
        createComponentView: createComponentView,
        createNgModuleRef: createNgModuleRef,
        overrideProvider: NOOP,
        overrideComponentView: NOOP,
        clearOverrides: NOOP,
        checkAndUpdateView: checkAndUpdateView,
        checkNoChangesView: checkNoChangesView,
        destroyView: destroyView,
        createDebugContext:
        /**
        * @param {?} view
        * @param {?} nodeIndex
        * @return {?}
        */
        function createDebugContext(view, nodeIndex) {
          return new DebugContext_(view, nodeIndex);
        },
        handleEvent:
        /**
        * @param {?} view
        * @param {?} nodeIndex
        * @param {?} eventName
        * @param {?} event
        * @return {?}
        */
        function handleEvent(view, nodeIndex, eventName, event) {
          return view.def.handleEvent(view, nodeIndex, eventName, event);
        },
        updateDirectives:
        /**
        * @param {?} view
        * @param {?} checkType
        * @return {?}
        */
        function updateDirectives(view, checkType) {
          return view.def.updateDirectives(checkType === 0
          /* CheckAndUpdate */
          ? prodCheckAndUpdateNode : prodCheckNoChangesNode, view);
        },
        updateRenderer:
        /**
        * @param {?} view
        * @param {?} checkType
        * @return {?}
        */
        function updateRenderer(view, checkType) {
          return view.def.updateRenderer(checkType === 0
          /* CheckAndUpdate */
          ? prodCheckAndUpdateNode : prodCheckNoChangesNode, view);
        }
      };
    }
    /**
     * @return {?}
     */


    function createDebugServices() {
      return {
        setCurrentNode: debugSetCurrentNode,
        createRootView: debugCreateRootView,
        createEmbeddedView: debugCreateEmbeddedView,
        createComponentView: debugCreateComponentView,
        createNgModuleRef: debugCreateNgModuleRef,
        overrideProvider: debugOverrideProvider,
        overrideComponentView: debugOverrideComponentView,
        clearOverrides: debugClearOverrides,
        checkAndUpdateView: debugCheckAndUpdateView,
        checkNoChangesView: debugCheckNoChangesView,
        destroyView: debugDestroyView,
        createDebugContext:
        /**
        * @param {?} view
        * @param {?} nodeIndex
        * @return {?}
        */
        function createDebugContext(view, nodeIndex) {
          return new DebugContext_(view, nodeIndex);
        },
        handleEvent: debugHandleEvent,
        updateDirectives: debugUpdateDirectives,
        updateRenderer: debugUpdateRenderer
      };
    }
    /**
     * @param {?} elInjector
     * @param {?} projectableNodes
     * @param {?} rootSelectorOrNode
     * @param {?} def
     * @param {?} ngModule
     * @param {?=} context
     * @return {?}
     */


    function createProdRootView(elInjector, projectableNodes, rootSelectorOrNode, def, ngModule, context) {
      /** @type {?} */
      var rendererFactory = ngModule.injector.get(RendererFactory2);
      return createRootView(createRootData(elInjector, ngModule, rendererFactory, projectableNodes, rootSelectorOrNode), def, context);
    }
    /**
     * @param {?} elInjector
     * @param {?} projectableNodes
     * @param {?} rootSelectorOrNode
     * @param {?} def
     * @param {?} ngModule
     * @param {?=} context
     * @return {?}
     */


    function debugCreateRootView(elInjector, projectableNodes, rootSelectorOrNode, def, ngModule, context) {
      /** @type {?} */
      var rendererFactory = ngModule.injector.get(RendererFactory2);
      /** @type {?} */

      var root = createRootData(elInjector, ngModule, new DebugRendererFactory2(rendererFactory), projectableNodes, rootSelectorOrNode);
      /** @type {?} */

      var defWithOverride = applyProviderOverridesToView(def);
      return callWithDebugContext(DebugAction.create, createRootView, null, [root, defWithOverride, context]);
    }
    /**
     * @param {?} elInjector
     * @param {?} ngModule
     * @param {?} rendererFactory
     * @param {?} projectableNodes
     * @param {?} rootSelectorOrNode
     * @return {?}
     */


    function createRootData(elInjector, ngModule, rendererFactory, projectableNodes, rootSelectorOrNode) {
      /** @type {?} */
      var sanitizer = ngModule.injector.get(Sanitizer);
      /** @type {?} */

      var errorHandler = ngModule.injector.get(ErrorHandler);
      /** @type {?} */

      var renderer = rendererFactory.createRenderer(null, null);
      return {
        ngModule: ngModule,
        injector: elInjector,
        projectableNodes: projectableNodes,
        selectorOrNode: rootSelectorOrNode,
        sanitizer: sanitizer,
        rendererFactory: rendererFactory,
        renderer: renderer,
        errorHandler: errorHandler
      };
    }
    /**
     * @param {?} parentView
     * @param {?} anchorDef
     * @param {?} viewDef
     * @param {?=} context
     * @return {?}
     */


    function debugCreateEmbeddedView(parentView, anchorDef, viewDef, context) {
      /** @type {?} */
      var defWithOverride = applyProviderOverridesToView(viewDef);
      return callWithDebugContext(DebugAction.create, createEmbeddedView, null, [parentView, anchorDef, defWithOverride, context]);
    }
    /**
     * @param {?} parentView
     * @param {?} nodeDef
     * @param {?} viewDef
     * @param {?} hostElement
     * @return {?}
     */


    function debugCreateComponentView(parentView, nodeDef, viewDef, hostElement) {
      /** @type {?} */
      var overrideComponentView = viewDefOverrides.get(
      /** @type {?} */

      /** @type {?} */

      /** @type {?} */
      nodeDef.element.componentProvider.provider.token);

      if (overrideComponentView) {
        viewDef = overrideComponentView;
      } else {
        viewDef = applyProviderOverridesToView(viewDef);
      }

      return callWithDebugContext(DebugAction.create, createComponentView, null, [parentView, nodeDef, viewDef, hostElement]);
    }
    /**
     * @param {?} moduleType
     * @param {?} parentInjector
     * @param {?} bootstrapComponents
     * @param {?} def
     * @return {?}
     */


    function debugCreateNgModuleRef(moduleType, parentInjector, bootstrapComponents, def) {
      /** @type {?} */
      var defWithOverride = applyProviderOverridesToNgModule(def);
      return createNgModuleRef(moduleType, parentInjector, bootstrapComponents, defWithOverride);
    }
    /** @type {?} */


    var providerOverrides = new Map();
    /** @type {?} */

    var providerOverridesWithScope = new Map();
    /** @type {?} */

    var viewDefOverrides = new Map();
    /**
     * @param {?} override
     * @return {?}
     */

    function debugOverrideProvider(override) {
      providerOverrides.set(override.token, override);
      /** @type {?} */

      var injectableDef;

      if (typeof override.token === 'function' && (injectableDef = getInjectableDef(override.token)) && typeof injectableDef.providedIn === 'function') {
        providerOverridesWithScope.set(
        /** @type {?} */
        override.token, override);
      }
    }
    /**
     * @param {?} comp
     * @param {?} compFactory
     * @return {?}
     */


    function debugOverrideComponentView(comp, compFactory) {
      /** @type {?} */
      var hostViewDef = resolveDefinition(getComponentViewDefinitionFactory(compFactory));
      /** @type {?} */

      var compViewDef = resolveDefinition(
      /** @type {?} */

      /** @type {?} */
      hostViewDef.nodes[0].element.componentView);
      viewDefOverrides.set(comp, compViewDef);
    }
    /**
     * @return {?}
     */


    function debugClearOverrides() {
      providerOverrides.clear();
      providerOverridesWithScope.clear();
      viewDefOverrides.clear();
    } // Notes about the algorithm:
    // 1) Locate the providers of an element and check if one of them was overwritten
    // 2) Change the providers of that element
    //
    // We only create new datastructures if we need to, to keep perf impact
    // reasonable.

    /**
     * @param {?} def
     * @return {?}
     */


    function applyProviderOverridesToView(def) {
      if (providerOverrides.size === 0) {
        return def;
      }
      /** @type {?} */


      var elementIndicesWithOverwrittenProviders = findElementIndicesWithOverwrittenProviders(def);

      if (elementIndicesWithOverwrittenProviders.length === 0) {
        return def;
      } // clone the whole view definition,
      // as it maintains references between the nodes that are hard to update.


      def =
      /** @type {?} */
      def.factory(
      /**
      * @return {?}
      */
      function () {
        return NOOP;
      });

      for (var i = 0; i < elementIndicesWithOverwrittenProviders.length; i++) {
        applyProviderOverridesToElement(def, elementIndicesWithOverwrittenProviders[i]);
      }

      return def;
      /**
       * @param {?} def
       * @return {?}
       */

      function findElementIndicesWithOverwrittenProviders(def) {
        /** @type {?} */
        var elIndicesWithOverwrittenProviders = [];
        /** @type {?} */

        var lastElementDef = null;

        for (var _i24 = 0; _i24 < def.nodes.length; _i24++) {
          /** @type {?} */
          var nodeDef = def.nodes[_i24];

          if (nodeDef.flags & 1
          /* TypeElement */
          ) {
              lastElementDef = nodeDef;
            }

          if (lastElementDef && nodeDef.flags & 3840
          /* CatProviderNoDirective */
          && providerOverrides.has(
          /** @type {?} */
          nodeDef.provider.token)) {
            elIndicesWithOverwrittenProviders.push(
            /** @type {?} */
            lastElementDef.nodeIndex);
            lastElementDef = null;
          }
        }

        return elIndicesWithOverwrittenProviders;
      }
      /**
       * @param {?} viewDef
       * @param {?} elIndex
       * @return {?}
       */


      function applyProviderOverridesToElement(viewDef, elIndex) {
        for (var _i25 = elIndex + 1; _i25 < viewDef.nodes.length; _i25++) {
          /** @type {?} */
          var nodeDef = viewDef.nodes[_i25];

          if (nodeDef.flags & 1
          /* TypeElement */
          ) {
              // stop at the next element
              return;
            }

          if (nodeDef.flags & 3840
          /* CatProviderNoDirective */
          ) {
              /** @type {?} */
              var provider =
              /** @type {?} */
              nodeDef.provider;
              /** @type {?} */

              var override = providerOverrides.get(provider.token);

              if (override) {
                nodeDef.flags = nodeDef.flags & ~3840
                /* CatProviderNoDirective */
                | override.flags;
                provider.deps = splitDepsDsl(override.deps);
                provider.value = override.value;
              }
            }
        }
      }
    } // Notes about the algorithm:
    // We only create new datastructures if we need to, to keep perf impact
    // reasonable.

    /**
     * @param {?} def
     * @return {?}
     */


    function applyProviderOverridesToNgModule(def) {
      var _calcHasOverrides = calcHasOverrides(def),
          hasOverrides = _calcHasOverrides.hasOverrides,
          hasDeprecatedOverrides = _calcHasOverrides.hasDeprecatedOverrides;

      if (!hasOverrides) {
        return def;
      } // clone the whole view definition,
      // as it maintains references between the nodes that are hard to update.


      def =
      /** @type {?} */
      def.factory(
      /**
      * @return {?}
      */
      function () {
        return NOOP;
      });
      applyProviderOverrides(def);
      return def;
      /**
       * @param {?} def
       * @return {?}
       */

      function calcHasOverrides(def) {
        /** @type {?} */
        var hasOverrides = false;
        /** @type {?} */

        var hasDeprecatedOverrides = false;

        if (providerOverrides.size === 0) {
          return {
            hasOverrides: hasOverrides,
            hasDeprecatedOverrides: hasDeprecatedOverrides
          };
        }

        def.providers.forEach(
        /**
        * @param {?} node
        * @return {?}
        */
        function (node) {
          /** @type {?} */
          var override = providerOverrides.get(node.token);

          if (node.flags & 3840
          /* CatProviderNoDirective */
          && override) {
            hasOverrides = true;
            hasDeprecatedOverrides = hasDeprecatedOverrides || override.deprecatedBehavior;
          }
        });
        def.modules.forEach(
        /**
        * @param {?} module
        * @return {?}
        */
        function (module) {
          providerOverridesWithScope.forEach(
          /**
          * @param {?} override
          * @param {?} token
          * @return {?}
          */
          function (override, token) {
            if (
            /** @type {?} */
            getInjectableDef(token).providedIn === module) {
              hasOverrides = true;
              hasDeprecatedOverrides = hasDeprecatedOverrides || override.deprecatedBehavior;
            }
          });
        });
        return {
          hasOverrides: hasOverrides,
          hasDeprecatedOverrides: hasDeprecatedOverrides
        };
      }
      /**
       * @param {?} def
       * @return {?}
       */


      function applyProviderOverrides(def) {
        for (var i = 0; i < def.providers.length; i++) {
          /** @type {?} */
          var provider = def.providers[i];

          if (hasDeprecatedOverrides) {
            // We had a bug where me made
            // all providers lazy. Keep this logic behind a flag
            // for migrating existing users.
            provider.flags |= 4096
            /* LazyProvider */
            ;
          }
          /** @type {?} */


          var override = providerOverrides.get(provider.token);

          if (override) {
            provider.flags = provider.flags & ~3840
            /* CatProviderNoDirective */
            | override.flags;
            provider.deps = splitDepsDsl(override.deps);
            provider.value = override.value;
          }
        }

        if (providerOverridesWithScope.size > 0) {
          /** @type {?} */
          var moduleSet = new Set(def.modules);
          providerOverridesWithScope.forEach(
          /**
          * @param {?} override
          * @param {?} token
          * @return {?}
          */
          function (override, token) {
            if (moduleSet.has(
            /** @type {?} */
            getInjectableDef(token).providedIn)) {
              /** @type {?} */
              var _provider = {
                token: token,
                flags: override.flags | (hasDeprecatedOverrides ? 4096
                /* LazyProvider */
                : 0
                /* None */
                ),
                deps: splitDepsDsl(override.deps),
                value: override.value,
                index: def.providers.length
              };
              def.providers.push(_provider);
              def.providersByKey[tokenKey(token)] = _provider;
            }
          });
        }
      }
    }
    /**
     * @param {?} view
     * @param {?} checkIndex
     * @param {?} argStyle
     * @param {?=} v0
     * @param {?=} v1
     * @param {?=} v2
     * @param {?=} v3
     * @param {?=} v4
     * @param {?=} v5
     * @param {?=} v6
     * @param {?=} v7
     * @param {?=} v8
     * @param {?=} v9
     * @return {?}
     */


    function prodCheckAndUpdateNode(view, checkIndex, argStyle, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9) {
      /** @type {?} */
      var nodeDef = view.def.nodes[checkIndex];
      checkAndUpdateNode(view, nodeDef, argStyle, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9);
      return nodeDef.flags & 224
      /* CatPureExpression */
      ? asPureExpressionData(view, checkIndex).value : undefined;
    }
    /**
     * @param {?} view
     * @param {?} checkIndex
     * @param {?} argStyle
     * @param {?=} v0
     * @param {?=} v1
     * @param {?=} v2
     * @param {?=} v3
     * @param {?=} v4
     * @param {?=} v5
     * @param {?=} v6
     * @param {?=} v7
     * @param {?=} v8
     * @param {?=} v9
     * @return {?}
     */


    function prodCheckNoChangesNode(view, checkIndex, argStyle, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9) {
      /** @type {?} */
      var nodeDef = view.def.nodes[checkIndex];
      checkNoChangesNode(view, nodeDef, argStyle, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9);
      return nodeDef.flags & 224
      /* CatPureExpression */
      ? asPureExpressionData(view, checkIndex).value : undefined;
    }
    /**
     * @param {?} view
     * @return {?}
     */


    function debugCheckAndUpdateView(view) {
      return callWithDebugContext(DebugAction.detectChanges, checkAndUpdateView, null, [view]);
    }
    /**
     * @param {?} view
     * @return {?}
     */


    function debugCheckNoChangesView(view) {
      return callWithDebugContext(DebugAction.checkNoChanges, checkNoChangesView, null, [view]);
    }
    /**
     * @param {?} view
     * @return {?}
     */


    function debugDestroyView(view) {
      return callWithDebugContext(DebugAction.destroy, destroyView, null, [view]);
    }
    /** @enum {number} */


    var DebugAction = {
      create: 0,
      detectChanges: 1,
      checkNoChanges: 2,
      destroy: 3,
      handleEvent: 4
    };
    DebugAction[DebugAction.create] = 'create';
    DebugAction[DebugAction.detectChanges] = 'detectChanges';
    DebugAction[DebugAction.checkNoChanges] = 'checkNoChanges';
    DebugAction[DebugAction.destroy] = 'destroy';
    DebugAction[DebugAction.handleEvent] = 'handleEvent';
    /** @type {?} */

    var _currentAction;
    /** @type {?} */


    var _currentView;
    /** @type {?} */


    var _currentNodeIndex;
    /**
     * @param {?} view
     * @param {?} nodeIndex
     * @return {?}
     */


    function debugSetCurrentNode(view, nodeIndex) {
      _currentView = view;
      _currentNodeIndex = nodeIndex;
    }
    /**
     * @param {?} view
     * @param {?} nodeIndex
     * @param {?} eventName
     * @param {?} event
     * @return {?}
     */


    function debugHandleEvent(view, nodeIndex, eventName, event) {
      debugSetCurrentNode(view, nodeIndex);
      return callWithDebugContext(DebugAction.handleEvent, view.def.handleEvent, null, [view, nodeIndex, eventName, event]);
    }
    /**
     * @param {?} view
     * @param {?} checkType
     * @return {?}
     */


    function debugUpdateDirectives(view, checkType) {
      if (view.state & 128
      /* Destroyed */
      ) {
          throw viewDestroyedError(DebugAction[_currentAction]);
        }

      debugSetCurrentNode(view, nextDirectiveWithBinding(view, 0));
      return view.def.updateDirectives(debugCheckDirectivesFn, view);
      /**
       * @param {?} view
       * @param {?} nodeIndex
       * @param {?} argStyle
       * @param {...?} values
       * @return {?}
       */

      function debugCheckDirectivesFn(view, nodeIndex, argStyle) {
        /** @type {?} */
        var nodeDef = view.def.nodes[nodeIndex];

        for (var _len16 = arguments.length, values = new Array(_len16 > 3 ? _len16 - 3 : 0), _key17 = 3; _key17 < _len16; _key17++) {
          values[_key17 - 3] = arguments[_key17];
        }

        if (checkType === 0
        /* CheckAndUpdate */
        ) {
            debugCheckAndUpdateNode(view, nodeDef, argStyle, values);
          } else {
          debugCheckNoChangesNode(view, nodeDef, argStyle, values);
        }

        if (nodeDef.flags & 16384
        /* TypeDirective */
        ) {
            debugSetCurrentNode(view, nextDirectiveWithBinding(view, nodeIndex));
          }

        return nodeDef.flags & 224
        /* CatPureExpression */
        ? asPureExpressionData(view, nodeDef.nodeIndex).value : undefined;
      }
    }
    /**
     * @param {?} view
     * @param {?} checkType
     * @return {?}
     */


    function debugUpdateRenderer(view, checkType) {
      if (view.state & 128
      /* Destroyed */
      ) {
          throw viewDestroyedError(DebugAction[_currentAction]);
        }

      debugSetCurrentNode(view, nextRenderNodeWithBinding(view, 0));
      return view.def.updateRenderer(debugCheckRenderNodeFn, view);
      /**
       * @param {?} view
       * @param {?} nodeIndex
       * @param {?} argStyle
       * @param {...?} values
       * @return {?}
       */

      function debugCheckRenderNodeFn(view, nodeIndex, argStyle) {
        /** @type {?} */
        var nodeDef = view.def.nodes[nodeIndex];

        for (var _len17 = arguments.length, values = new Array(_len17 > 3 ? _len17 - 3 : 0), _key18 = 3; _key18 < _len17; _key18++) {
          values[_key18 - 3] = arguments[_key18];
        }

        if (checkType === 0
        /* CheckAndUpdate */
        ) {
            debugCheckAndUpdateNode(view, nodeDef, argStyle, values);
          } else {
          debugCheckNoChangesNode(view, nodeDef, argStyle, values);
        }

        if (nodeDef.flags & 3
        /* CatRenderNode */
        ) {
            debugSetCurrentNode(view, nextRenderNodeWithBinding(view, nodeIndex));
          }

        return nodeDef.flags & 224
        /* CatPureExpression */
        ? asPureExpressionData(view, nodeDef.nodeIndex).value : undefined;
      }
    }
    /**
     * @param {?} view
     * @param {?} nodeDef
     * @param {?} argStyle
     * @param {?} givenValues
     * @return {?}
     */


    function debugCheckAndUpdateNode(view, nodeDef, argStyle, givenValues) {
      /** @type {?} */
      var changed =
      /** @type {?} */
      checkAndUpdateNode.apply(void 0, [view, nodeDef, argStyle].concat(_toConsumableArray(givenValues)));

      if (changed) {
        /** @type {?} */
        var values = argStyle === 1
        /* Dynamic */
        ? givenValues[0] : givenValues;

        if (nodeDef.flags & 16384
        /* TypeDirective */
        ) {
            /** @type {?} */
            var bindingValues = {};

            for (var i = 0; i < nodeDef.bindings.length; i++) {
              /** @type {?} */
              var binding = nodeDef.bindings[i];
              /** @type {?} */

              var value = values[i];

              if (binding.flags & 8
              /* TypeProperty */
              ) {
                  bindingValues[normalizeDebugBindingName(
                  /** @type {?} */
                  binding.nonMinifiedName)] = normalizeDebugBindingValue(value);
                }
            }
            /** @type {?} */


            var elDef =
            /** @type {?} */
            nodeDef.parent;
            /** @type {?} */

            var el = asElementData(view, elDef.nodeIndex).renderElement;

            if (!
            /** @type {?} */
            elDef.element.name) {
              // a comment.
              view.renderer.setValue(el, "bindings=".concat(JSON.stringify(bindingValues, null, 2)));
            } else {
              // a regular element.
              for (var attr in bindingValues) {
                /** @type {?} */
                var _value3 = bindingValues[attr];

                if (_value3 != null) {
                  view.renderer.setAttribute(el, attr, _value3);
                } else {
                  view.renderer.removeAttribute(el, attr);
                }
              }
            }
          }
      }
    }
    /**
     * @param {?} view
     * @param {?} nodeDef
     * @param {?} argStyle
     * @param {?} values
     * @return {?}
     */


    function debugCheckNoChangesNode(view, nodeDef, argStyle, values) {
      /** @type {?} */
      checkNoChangesNode.apply(void 0, [view, nodeDef, argStyle].concat(_toConsumableArray(values)));
    }
    /**
     * @param {?} view
     * @param {?} nodeIndex
     * @return {?}
     */


    function nextDirectiveWithBinding(view, nodeIndex) {
      for (var i = nodeIndex; i < view.def.nodes.length; i++) {
        /** @type {?} */
        var nodeDef = view.def.nodes[i];

        if (nodeDef.flags & 16384
        /* TypeDirective */
        && nodeDef.bindings && nodeDef.bindings.length) {
          return i;
        }
      }

      return null;
    }
    /**
     * @param {?} view
     * @param {?} nodeIndex
     * @return {?}
     */


    function nextRenderNodeWithBinding(view, nodeIndex) {
      for (var i = nodeIndex; i < view.def.nodes.length; i++) {
        /** @type {?} */
        var nodeDef = view.def.nodes[i];

        if (nodeDef.flags & 3
        /* CatRenderNode */
        && nodeDef.bindings && nodeDef.bindings.length) {
          return i;
        }
      }

      return null;
    }

    var DebugContext_ = /*#__PURE__*/function () {
      /**
       * @param {?} view
       * @param {?} nodeIndex
       */
      function DebugContext_(view, nodeIndex) {
        _classCallCheck(this, DebugContext_);

        this.view = view;
        this.nodeIndex = nodeIndex;

        if (nodeIndex == null) {
          this.nodeIndex = nodeIndex = 0;
        }

        this.nodeDef = view.def.nodes[nodeIndex];
        /** @type {?} */

        var elDef = this.nodeDef;
        /** @type {?} */

        var elView = view;

        while (elDef && (elDef.flags & 1
        /* TypeElement */
        ) === 0) {
          elDef =
          /** @type {?} */
          elDef.parent;
        }

        if (!elDef) {
          while (!elDef && elView) {
            elDef =
            /** @type {?} */
            viewParentEl(elView);
            elView =
            /** @type {?} */
            elView.parent;
          }
        }

        this.elDef = elDef;
        this.elView = elView;
      }
      /**
       * @private
       * @return {?}
       */


      _createClass2(DebugContext_, [{
        key: "logError",

        /**
         * @param {?} console
         * @param {...?} values
         * @return {?}
         */
        value: function logError(console) {
          for (var _len18 = arguments.length, values = new Array(_len18 > 1 ? _len18 - 1 : 0), _key19 = 1; _key19 < _len18; _key19++) {
            values[_key19 - 1] = arguments[_key19];
          }

          /** @type {?} */
          var logViewDef;
          /** @type {?} */

          var logNodeIndex;

          if (this.nodeDef.flags & 2
          /* TypeText */
          ) {
              logViewDef = this.view.def;
              logNodeIndex = this.nodeDef.nodeIndex;
            } else {
            logViewDef = this.elView.def;
            logNodeIndex = this.elDef.nodeIndex;
          } // Note: we only generate a log function for text and element nodes
          // to make the generated code as small as possible.

          /** @type {?} */


          var renderNodeIndex = getRenderNodeIndex(logViewDef, logNodeIndex);
          /** @type {?} */

          var currRenderNodeIndex = -1;
          /** @type {?} */

          var nodeLogger =
          /**
          * @return {?}
          */
          function nodeLogger() {
            currRenderNodeIndex++;

            if (currRenderNodeIndex === renderNodeIndex) {
              var _console$error;

              return (_console$error = console.error).bind.apply(_console$error, [console].concat(values));
            } else {
              return NOOP;
            }
          };

          /** @type {?} */
          logViewDef.factory(nodeLogger);

          if (currRenderNodeIndex < renderNodeIndex) {
            console.error('Illegal state: the ViewDefinitionFactory did not call the logger!');

            /** @type {?} */
            console.error.apply(console, values);
          }
        }
      }, {
        key: "elOrCompView",
        get: function get() {
          // Has to be done lazily as we use the DebugContext also during creation of elements...
          return asElementData(this.elView, this.elDef.nodeIndex).componentView || this.view;
        }
        /**
         * @return {?}
         */

      }, {
        key: "injector",
        get: function get() {
          return createInjector$1(this.elView, this.elDef);
        }
        /**
         * @return {?}
         */

      }, {
        key: "component",
        get: function get() {
          return this.elOrCompView.component;
        }
        /**
         * @return {?}
         */

      }, {
        key: "context",
        get: function get() {
          return this.elOrCompView.context;
        }
        /**
         * @return {?}
         */

      }, {
        key: "providerTokens",
        get: function get() {
          /** @type {?} */
          var tokens = [];

          if (this.elDef) {
            for (var i = this.elDef.nodeIndex + 1; i <= this.elDef.nodeIndex + this.elDef.childCount; i++) {
              /** @type {?} */
              var childDef = this.elView.def.nodes[i];

              if (childDef.flags & 20224
              /* CatProvider */
              ) {
                  tokens.push(
                  /** @type {?} */
                  childDef.provider.token);
                }

              i += childDef.childCount;
            }
          }

          return tokens;
        }
        /**
         * @return {?}
         */

      }, {
        key: "references",
        get: function get() {
          /** @type {?} */
          var references = {};

          if (this.elDef) {
            collectReferences(this.elView, this.elDef, references);

            for (var i = this.elDef.nodeIndex + 1; i <= this.elDef.nodeIndex + this.elDef.childCount; i++) {
              /** @type {?} */
              var childDef = this.elView.def.nodes[i];

              if (childDef.flags & 20224
              /* CatProvider */
              ) {
                  collectReferences(this.elView, childDef, references);
                }

              i += childDef.childCount;
            }
          }

          return references;
        }
        /**
         * @return {?}
         */

      }, {
        key: "componentRenderElement",
        get: function get() {
          /** @type {?} */
          var elData = findHostElement(this.elOrCompView);
          return elData ? elData.renderElement : undefined;
        }
        /**
         * @return {?}
         */

      }, {
        key: "renderNode",
        get: function get() {
          return this.nodeDef.flags & 2
          /* TypeText */
          ? renderNode(this.view, this.nodeDef) : renderNode(this.elView, this.elDef);
        }
      }]);

      return DebugContext_;
    }();

    if (false) {}
    /**
     * @param {?} viewDef
     * @param {?} nodeIndex
     * @return {?}
     */


    function getRenderNodeIndex(viewDef, nodeIndex) {
      /** @type {?} */
      var renderNodeIndex = -1;

      for (var i = 0; i <= nodeIndex; i++) {
        /** @type {?} */
        var nodeDef = viewDef.nodes[i];

        if (nodeDef.flags & 3
        /* CatRenderNode */
        ) {
            renderNodeIndex++;
          }
      }

      return renderNodeIndex;
    }
    /**
     * @param {?} view
     * @return {?}
     */


    function findHostElement(view) {
      while (view && !isComponentView(view)) {
        view =
        /** @type {?} */
        view.parent;
      }

      if (view.parent) {
        return asElementData(view.parent,
        /** @type {?} */
        viewParentEl(view).nodeIndex);
      }

      return null;
    }
    /**
     * @param {?} view
     * @param {?} nodeDef
     * @param {?} references
     * @return {?}
     */


    function collectReferences(view, nodeDef, references) {
      for (var refName in nodeDef.references) {
        references[refName] = getQueryValue(view, nodeDef, nodeDef.references[refName]);
      }
    }
    /**
     * @param {?} action
     * @param {?} fn
     * @param {?} self
     * @param {?} args
     * @return {?}
     */


    function callWithDebugContext(action, fn, self, args) {
      /** @type {?} */
      var oldAction = _currentAction;
      /** @type {?} */

      var oldView = _currentView;
      /** @type {?} */

      var oldNodeIndex = _currentNodeIndex;

      try {
        _currentAction = action;
        /** @type {?} */

        var result = fn.apply(self, args);
        _currentView = oldView;
        _currentNodeIndex = oldNodeIndex;
        _currentAction = oldAction;
        return result;
      } catch (e) {
        if (isViewDebugError(e) || !_currentView) {
          throw e;
        }

        throw viewWrappedDebugError(e,
        /** @type {?} */
        getCurrentDebugContext());
      }
    }
    /**
     * @return {?}
     */


    function getCurrentDebugContext() {
      return _currentView ? new DebugContext_(_currentView, _currentNodeIndex) : null;
    }

    var DebugRendererFactory2 = /*#__PURE__*/function () {
      /**
       * @param {?} delegate
       */
      function DebugRendererFactory2(delegate) {
        _classCallCheck(this, DebugRendererFactory2);

        this.delegate = delegate;
      }
      /**
       * @param {?} element
       * @param {?} renderData
       * @return {?}
       */


      _createClass2(DebugRendererFactory2, [{
        key: "createRenderer",
        value: function createRenderer(element, renderData) {
          return new DebugRenderer2(this.delegate.createRenderer(element, renderData));
        }
        /**
         * @return {?}
         */

      }, {
        key: "begin",
        value: function begin() {
          if (this.delegate.begin) {
            this.delegate.begin();
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "end",
        value: function end() {
          if (this.delegate.end) {
            this.delegate.end();
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "whenRenderingDone",
        value: function whenRenderingDone() {
          if (this.delegate.whenRenderingDone) {
            return this.delegate.whenRenderingDone();
          }

          return Promise.resolve(null);
        }
      }]);

      return DebugRendererFactory2;
    }();

    if (false) {}

    var DebugRenderer2 = /*#__PURE__*/function () {
      /**
       * @param {?} delegate
       */
      function DebugRenderer2(delegate) {
        _classCallCheck(this, DebugRenderer2);

        this.delegate = delegate;
        /**
         * Factory function used to create a `DebugContext` when a node is created.
         *
         * The `DebugContext` allows to retrieve information about the nodes that are useful in tests.
         *
         * The factory is configurable so that the `DebugRenderer2` could instantiate either a View Engine
         * or a Render context.
         */

        this.debugContextFactory = getCurrentDebugContext;
        this.data = this.delegate.data;
      }
      /**
       * @private
       * @param {?} nativeElement
       * @return {?}
       */


      _createClass2(DebugRenderer2, [{
        key: "createDebugContext",
        value: function createDebugContext(nativeElement) {
          return this.debugContextFactory(nativeElement);
        }
        /**
         * @param {?} node
         * @return {?}
         */

      }, {
        key: "destroyNode",
        value: function destroyNode(node) {
          /** @type {?} */
          var debugNode =
          /** @type {?} */
          getDebugNode$1(node);
          removeDebugNodeFromIndex(debugNode);

          if (debugNode instanceof DebugNode__PRE_R3__) {
            debugNode.listeners.length = 0;
          }

          if (this.delegate.destroyNode) {
            this.delegate.destroyNode(node);
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "destroy",
        value: function destroy() {
          this.delegate.destroy();
        }
        /**
         * @param {?} name
         * @param {?=} namespace
         * @return {?}
         */

      }, {
        key: "createElement",
        value: function createElement(name, namespace) {
          /** @type {?} */
          var el = this.delegate.createElement(name, namespace);
          /** @type {?} */

          var debugCtx = this.createDebugContext(el);

          if (debugCtx) {
            /** @type {?} */
            var debugEl = new DebugElement__PRE_R3__(el, null, debugCtx);

            /** @type {?} */
            debugEl.name = name;
            indexDebugNode(debugEl);
          }

          return el;
        }
        /**
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "createComment",
        value: function createComment(value) {
          /** @type {?} */
          var comment = this.delegate.createComment(value);
          /** @type {?} */

          var debugCtx = this.createDebugContext(comment);

          if (debugCtx) {
            indexDebugNode(new DebugNode__PRE_R3__(comment, null, debugCtx));
          }

          return comment;
        }
        /**
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "createText",
        value: function createText(value) {
          /** @type {?} */
          var text = this.delegate.createText(value);
          /** @type {?} */

          var debugCtx = this.createDebugContext(text);

          if (debugCtx) {
            indexDebugNode(new DebugNode__PRE_R3__(text, null, debugCtx));
          }

          return text;
        }
        /**
         * @param {?} parent
         * @param {?} newChild
         * @return {?}
         */

      }, {
        key: "appendChild",
        value: function appendChild(parent, newChild) {
          /** @type {?} */
          var debugEl = getDebugNode$1(parent);
          /** @type {?} */

          var debugChildEl = getDebugNode$1(newChild);

          if (debugEl && debugChildEl && debugEl instanceof DebugElement__PRE_R3__) {
            debugEl.addChild(debugChildEl);
          }

          this.delegate.appendChild(parent, newChild);
        }
        /**
         * @param {?} parent
         * @param {?} newChild
         * @param {?} refChild
         * @return {?}
         */

      }, {
        key: "insertBefore",
        value: function insertBefore(parent, newChild, refChild) {
          /** @type {?} */
          var debugEl = getDebugNode$1(parent);
          /** @type {?} */

          var debugChildEl = getDebugNode$1(newChild);
          /** @type {?} */

          var debugRefEl =
          /** @type {?} */
          getDebugNode$1(refChild);

          if (debugEl && debugChildEl && debugEl instanceof DebugElement__PRE_R3__) {
            debugEl.insertBefore(debugRefEl, debugChildEl);
          }

          this.delegate.insertBefore(parent, newChild, refChild);
        }
        /**
         * @param {?} parent
         * @param {?} oldChild
         * @return {?}
         */

      }, {
        key: "removeChild",
        value: function removeChild(parent, oldChild) {
          /** @type {?} */
          var debugEl = getDebugNode$1(parent);
          /** @type {?} */

          var debugChildEl = getDebugNode$1(oldChild);

          if (debugEl && debugChildEl && debugEl instanceof DebugElement__PRE_R3__) {
            debugEl.removeChild(debugChildEl);
          }

          this.delegate.removeChild(parent, oldChild);
        }
        /**
         * @param {?} selectorOrNode
         * @param {?=} preserveContent
         * @return {?}
         */

      }, {
        key: "selectRootElement",
        value: function selectRootElement(selectorOrNode, preserveContent) {
          /** @type {?} */
          var el = this.delegate.selectRootElement(selectorOrNode, preserveContent);
          /** @type {?} */

          var debugCtx = getCurrentDebugContext();

          if (debugCtx) {
            indexDebugNode(new DebugElement__PRE_R3__(el, null, debugCtx));
          }

          return el;
        }
        /**
         * @param {?} el
         * @param {?} name
         * @param {?} value
         * @param {?=} namespace
         * @return {?}
         */

      }, {
        key: "setAttribute",
        value: function setAttribute(el, name, value, namespace) {
          /** @type {?} */
          var debugEl = getDebugNode$1(el);

          if (debugEl && debugEl instanceof DebugElement__PRE_R3__) {
            /** @type {?} */
            var fullName = namespace ? namespace + ':' + name : name;
            debugEl.attributes[fullName] = value;
          }

          this.delegate.setAttribute(el, name, value, namespace);
        }
        /**
         * @param {?} el
         * @param {?} name
         * @param {?=} namespace
         * @return {?}
         */

      }, {
        key: "removeAttribute",
        value: function removeAttribute(el, name, namespace) {
          /** @type {?} */
          var debugEl = getDebugNode$1(el);

          if (debugEl && debugEl instanceof DebugElement__PRE_R3__) {
            /** @type {?} */
            var fullName = namespace ? namespace + ':' + name : name;
            debugEl.attributes[fullName] = null;
          }

          this.delegate.removeAttribute(el, name, namespace);
        }
        /**
         * @param {?} el
         * @param {?} name
         * @return {?}
         */

      }, {
        key: "addClass",
        value: function addClass(el, name) {
          /** @type {?} */
          var debugEl = getDebugNode$1(el);

          if (debugEl && debugEl instanceof DebugElement__PRE_R3__) {
            debugEl.classes[name] = true;
          }

          this.delegate.addClass(el, name);
        }
        /**
         * @param {?} el
         * @param {?} name
         * @return {?}
         */

      }, {
        key: "removeClass",
        value: function removeClass(el, name) {
          /** @type {?} */
          var debugEl = getDebugNode$1(el);

          if (debugEl && debugEl instanceof DebugElement__PRE_R3__) {
            debugEl.classes[name] = false;
          }

          this.delegate.removeClass(el, name);
        }
        /**
         * @param {?} el
         * @param {?} style
         * @param {?} value
         * @param {?} flags
         * @return {?}
         */

      }, {
        key: "setStyle",
        value: function setStyle(el, style, value, flags) {
          /** @type {?} */
          var debugEl = getDebugNode$1(el);

          if (debugEl && debugEl instanceof DebugElement__PRE_R3__) {
            debugEl.styles[style] = value;
          }

          this.delegate.setStyle(el, style, value, flags);
        }
        /**
         * @param {?} el
         * @param {?} style
         * @param {?} flags
         * @return {?}
         */

      }, {
        key: "removeStyle",
        value: function removeStyle(el, style, flags) {
          /** @type {?} */
          var debugEl = getDebugNode$1(el);

          if (debugEl && debugEl instanceof DebugElement__PRE_R3__) {
            debugEl.styles[style] = null;
          }

          this.delegate.removeStyle(el, style, flags);
        }
        /**
         * @param {?} el
         * @param {?} name
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "setProperty",
        value: function setProperty(el, name, value) {
          /** @type {?} */
          var debugEl = getDebugNode$1(el);

          if (debugEl && debugEl instanceof DebugElement__PRE_R3__) {
            debugEl.properties[name] = value;
          }

          this.delegate.setProperty(el, name, value);
        }
        /**
         * @param {?} target
         * @param {?} eventName
         * @param {?} callback
         * @return {?}
         */

      }, {
        key: "listen",
        value: function listen(target, eventName, callback) {
          if (typeof target !== 'string') {
            /** @type {?} */
            var debugEl = getDebugNode$1(target);

            if (debugEl) {
              debugEl.listeners.push(new DebugEventListener(eventName, callback));
            }
          }

          return this.delegate.listen(target, eventName, callback);
        }
        /**
         * @param {?} node
         * @return {?}
         */

      }, {
        key: "parentNode",
        value: function parentNode(node) {
          return this.delegate.parentNode(node);
        }
        /**
         * @param {?} node
         * @return {?}
         */

      }, {
        key: "nextSibling",
        value: function nextSibling(node) {
          return this.delegate.nextSibling(node);
        }
        /**
         * @param {?} node
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "setValue",
        value: function setValue(node, value) {
          return this.delegate.setValue(node, value);
        }
      }]);

      return DebugRenderer2;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/view/entrypoint.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} override
     * @return {?}
     */


    function overrideProvider(override) {
      initServicesIfNeeded();
      return Services.overrideProvider(override);
    }
    /**
     * @param {?} comp
     * @param {?} componentFactory
     * @return {?}
     */


    function overrideComponentView(comp, componentFactory) {
      initServicesIfNeeded();
      return Services.overrideComponentView(comp, componentFactory);
    }
    /**
     * @return {?}
     */


    function clearOverrides() {
      initServicesIfNeeded();
      return Services.clearOverrides();
    } // Attention: this function is called as top level function.
    // Putting any logic in here will destroy closure tree shaking!

    /**
     * @param {?} ngModuleType
     * @param {?} bootstrapComponents
     * @param {?} defFactory
     * @return {?}
     */


    function createNgModuleFactory(ngModuleType, bootstrapComponents, defFactory) {
      return new NgModuleFactory_(ngModuleType, bootstrapComponents, defFactory);
    }
    /**
     * @param {?} def
     * @return {?}
     */


    function cloneNgModuleDefinition(def) {
      /** @type {?} */
      var providers = Array.from(def.providers);
      /** @type {?} */

      var modules = Array.from(def.modules);
      /** @type {?} */

      var providersByKey = {};

      for (var key in def.providersByKey) {
        providersByKey[key] = def.providersByKey[key];
      }

      return {
        factory: def.factory,
        scope: def.scope,
        providers: providers,
        modules: modules,
        providersByKey: providersByKey
      };
    }

    var NgModuleFactory_ = /*#__PURE__*/function (_NgModuleFactory2) {
      _inherits(NgModuleFactory_, _NgModuleFactory2);

      var _super50 = _createSuper(NgModuleFactory_);

      /**
       * @param {?} moduleType
       * @param {?} _bootstrapComponents
       * @param {?} _ngModuleDefFactory
       */
      function NgModuleFactory_(moduleType, _bootstrapComponents, _ngModuleDefFactory) {
        var _this183;

        _classCallCheck(this, NgModuleFactory_);

        // Attention: this ctor is called as top level function.
        // Putting any logic in here will destroy closure tree shaking!
        _this183 = _super50.call(this);
        _this183.moduleType = moduleType;
        _this183._bootstrapComponents = _bootstrapComponents;
        _this183._ngModuleDefFactory = _ngModuleDefFactory;
        return _this183;
      }
      /**
       * @param {?} parentInjector
       * @return {?}
       */


      _createClass2(NgModuleFactory_, [{
        key: "create",
        value: function create(parentInjector) {
          initServicesIfNeeded(); // Clone the NgModuleDefinition so that any tree shakeable provider definition
          // added to this instance of the NgModuleRef doesn't affect the cached copy.
          // See https://github.com/angular/angular/issues/25018.

          /** @type {?} */

          var def = cloneNgModuleDefinition(resolveDefinition(this._ngModuleDefFactory));
          return Services.createNgModuleRef(this.moduleType, parentInjector || Injector.NULL, this._bootstrapComponents, def);
        }
      }]);

      return NgModuleFactory_;
    }(NgModuleFactory);

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/view/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/core_private_export.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/core_render3_private_export.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/codegen_private_exports.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/src/core.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    if (ngDevMode) {
      // This helper is to give a reasonable error message to people upgrading to v9 that have not yet
      // installed `@angular/localize` in their app.
      // tslint:disable-next-line: no-toplevel-property-access
      _global.$localize = _global.$localize ||
      /**
      * @return {?}
      */
      function () {
        throw new Error('It looks like your application or one of its dependencies is using i18n.\n' + 'Angular 9 introduced a global `$localize()` function that needs to be loaded.\n' + 'Please run `ng add @angular/localize` from the Angular CLI.\n' + '(For non-CLI projects, add `import \'@angular/localize/init\';` to your `polyfills.ts` file.\n' + 'For server-side rendering applications add the import to your `main.server.ts` file.)');
      };
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/public_api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/core/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=core.js.map

    /***/

  },

  /***/
  "./node_modules/@angular/forms/__ivy_ngcc__/fesm2015/forms.js":
  /*!********************************************************************!*\
    !*** ./node_modules/@angular/forms/__ivy_ngcc__/fesm2015/forms.js ***!
    \********************************************************************/

  /*! exports provided: AbstractControl, AbstractControlDirective, AbstractFormGroupDirective, COMPOSITION_BUFFER_MODE, CheckboxControlValueAccessor, CheckboxRequiredValidator, ControlContainer, DefaultValueAccessor, EmailValidator, FormArray, FormArrayName, FormBuilder, FormControl, FormControlDirective, FormControlName, FormGroup, FormGroupDirective, FormGroupName, FormsModule, MaxLengthValidator, MinLengthValidator, NG_ASYNC_VALIDATORS, NG_VALIDATORS, NG_VALUE_ACCESSOR, NgControl, NgControlStatus, NgControlStatusGroup, NgForm, NgModel, NgModelGroup, NgSelectOption, NumberValueAccessor, PatternValidator, RadioControlValueAccessor, RangeValueAccessor, ReactiveFormsModule, RequiredValidator, SelectControlValueAccessor, SelectMultipleControlValueAccessor, VERSION, Validators, ɵInternalFormsSharedModule, ɵNgNoValidate, ɵNgSelectMultipleOption, ɵangular_packages_forms_forms_a, ɵangular_packages_forms_forms_b, ɵangular_packages_forms_forms_ba, ɵangular_packages_forms_forms_bb, ɵangular_packages_forms_forms_bc, ɵangular_packages_forms_forms_bd, ɵangular_packages_forms_forms_be, ɵangular_packages_forms_forms_c, ɵangular_packages_forms_forms_d, ɵangular_packages_forms_forms_e, ɵangular_packages_forms_forms_f, ɵangular_packages_forms_forms_g, ɵangular_packages_forms_forms_h, ɵangular_packages_forms_forms_i, ɵangular_packages_forms_forms_j, ɵangular_packages_forms_forms_k, ɵangular_packages_forms_forms_l, ɵangular_packages_forms_forms_m, ɵangular_packages_forms_forms_n, ɵangular_packages_forms_forms_o, ɵangular_packages_forms_forms_p, ɵangular_packages_forms_forms_q, ɵangular_packages_forms_forms_r, ɵangular_packages_forms_forms_s, ɵangular_packages_forms_forms_t, ɵangular_packages_forms_forms_u, ɵangular_packages_forms_forms_v, ɵangular_packages_forms_forms_w, ɵangular_packages_forms_forms_x, ɵangular_packages_forms_forms_y, ɵangular_packages_forms_forms_z */

  /***/
  function node_modulesAngularForms__ivy_ngcc__Fesm2015FormsJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AbstractControl", function () {
      return AbstractControl;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AbstractControlDirective", function () {
      return AbstractControlDirective;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AbstractFormGroupDirective", function () {
      return AbstractFormGroupDirective;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "COMPOSITION_BUFFER_MODE", function () {
      return COMPOSITION_BUFFER_MODE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CheckboxControlValueAccessor", function () {
      return CheckboxControlValueAccessor;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CheckboxRequiredValidator", function () {
      return CheckboxRequiredValidator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ControlContainer", function () {
      return ControlContainer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DefaultValueAccessor", function () {
      return DefaultValueAccessor;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "EmailValidator", function () {
      return EmailValidator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FormArray", function () {
      return FormArray;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FormArrayName", function () {
      return FormArrayName;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FormBuilder", function () {
      return FormBuilder;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FormControl", function () {
      return FormControl;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FormControlDirective", function () {
      return FormControlDirective;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FormControlName", function () {
      return FormControlName;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FormGroup", function () {
      return FormGroup;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FormGroupDirective", function () {
      return FormGroupDirective;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FormGroupName", function () {
      return FormGroupName;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FormsModule", function () {
      return FormsModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MaxLengthValidator", function () {
      return MaxLengthValidator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MinLengthValidator", function () {
      return MinLengthValidator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NG_ASYNC_VALIDATORS", function () {
      return NG_ASYNC_VALIDATORS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NG_VALIDATORS", function () {
      return NG_VALIDATORS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NG_VALUE_ACCESSOR", function () {
      return NG_VALUE_ACCESSOR;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgControl", function () {
      return NgControl;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgControlStatus", function () {
      return NgControlStatus;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgControlStatusGroup", function () {
      return NgControlStatusGroup;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgForm", function () {
      return NgForm;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgModel", function () {
      return NgModel;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgModelGroup", function () {
      return NgModelGroup;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NgSelectOption", function () {
      return NgSelectOption;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NumberValueAccessor", function () {
      return NumberValueAccessor;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "PatternValidator", function () {
      return PatternValidator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RadioControlValueAccessor", function () {
      return RadioControlValueAccessor;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RangeValueAccessor", function () {
      return RangeValueAccessor;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ReactiveFormsModule", function () {
      return ReactiveFormsModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RequiredValidator", function () {
      return RequiredValidator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SelectControlValueAccessor", function () {
      return SelectControlValueAccessor;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SelectMultipleControlValueAccessor", function () {
      return SelectMultipleControlValueAccessor;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "VERSION", function () {
      return VERSION;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Validators", function () {
      return Validators;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵInternalFormsSharedModule", function () {
      return ɵInternalFormsSharedModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵNgNoValidate", function () {
      return ɵNgNoValidate;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵNgSelectMultipleOption", function () {
      return ɵNgSelectMultipleOption;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_a", function () {
      return SHARED_FORM_DIRECTIVES;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_b", function () {
      return TEMPLATE_DRIVEN_DIRECTIVES;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_ba", function () {
      return CHECKBOX_REQUIRED_VALIDATOR;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_bb", function () {
      return EMAIL_VALIDATOR;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_bc", function () {
      return MIN_LENGTH_VALIDATOR;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_bd", function () {
      return MAX_LENGTH_VALIDATOR;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_be", function () {
      return PATTERN_VALIDATOR;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_c", function () {
      return REACTIVE_DRIVEN_DIRECTIVES;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_d", function () {
      return ɵInternalFormsSharedModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_e", function () {
      return CHECKBOX_VALUE_ACCESSOR;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_f", function () {
      return DEFAULT_VALUE_ACCESSOR;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_g", function () {
      return AbstractControlStatus;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_h", function () {
      return ngControlStatusHost;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_i", function () {
      return formDirectiveProvider;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_j", function () {
      return formControlBinding;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_k", function () {
      return modelGroupProvider;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_l", function () {
      return NUMBER_VALUE_ACCESSOR;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_m", function () {
      return RADIO_VALUE_ACCESSOR;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_n", function () {
      return RadioControlRegistry;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_o", function () {
      return RANGE_VALUE_ACCESSOR;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_p", function () {
      return NG_MODEL_WITH_FORM_CONTROL_WARNING;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_q", function () {
      return formControlBinding$1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_r", function () {
      return controlNameBinding;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_s", function () {
      return formDirectiveProvider$1;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_t", function () {
      return formGroupNameProvider;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_u", function () {
      return formArrayNameProvider;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_v", function () {
      return SELECT_VALUE_ACCESSOR;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_w", function () {
      return SELECT_MULTIPLE_VALUE_ACCESSOR;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_x", function () {
      return ɵNgSelectMultipleOption;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_y", function () {
      return ɵNgNoValidate;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_z", function () {
      return REQUIRED_VALIDATOR;
    });
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var _angular_common__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! @angular/common */
    "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/common.js");
    /* harmony import */


    var rxjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! rxjs */
    "./node_modules/rxjs/_esm2015/index.js");
    /* harmony import */


    var rxjs_operators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! rxjs/operators */
    "./node_modules/rxjs/_esm2015/operators/index.js");
    /**
     * @license Angular v9.1.4
     * (c) 2010-2020 Google LLC. https://angular.io/
     * License: MIT
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/control_value_accessor.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@description
     * Defines an interface that acts as a bridge between the Angular forms API and a
     * native element in the DOM.
     *
     * Implement this interface to create a custom form control directive
     * that integrates with Angular forms.
     *
     * @see DefaultValueAccessor
     *
     * \@publicApi
     * @record
     */


    function ControlValueAccessor() {}

    if (false) {}
    /**
     * Used to provide a `ControlValueAccessor` for form controls.
     *
     * See `DefaultValueAccessor` for how to implement one.
     *
     * \@publicApi
     * @type {?}
     */


    var NG_VALUE_ACCESSOR = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('NgValueAccessor');
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/checkbox_value_accessor.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */

    var CHECKBOX_VALUE_ACCESSOR = {
      provide: NG_VALUE_ACCESSOR,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return CheckboxControlValueAccessor;
      }),
      multi: true
    };
    /**
     * \@description
     * A `ControlValueAccessor` for writing a value and listening to changes on a checkbox input
     * element.
     *
     * \@usageNotes
     *
     * ### Using a checkbox with a reactive form.
     *
     * The following example shows how to use a checkbox with a reactive form.
     *
     * ```ts
     * const rememberLoginControl = new FormControl();
     * ```
     *
     * ```
     * <input type="checkbox" [formControl]="rememberLoginControl">
     * ```
     *
     * \@ngModule ReactiveFormsModule
     * \@ngModule FormsModule
     * \@publicApi
     */

    var CheckboxControlValueAccessor = /*#__PURE__*/function () {
      /**
       * @param {?} _renderer
       * @param {?} _elementRef
       */
      function CheckboxControlValueAccessor(_renderer, _elementRef) {
        _classCallCheck(this, CheckboxControlValueAccessor);

        this._renderer = _renderer;
        this._elementRef = _elementRef;
        /**
         * \@description
         * The registered callback function called when a change event occurs on the input element.
         */

        this.onChange =
        /**
        * @param {?} _
        * @return {?}
        */
        function (_) {};
        /**
         * \@description
         * The registered callback function called when a blur event occurs on the input element.
         */


        this.onTouched =
        /**
        * @return {?}
        */
        function () {};
      }
      /**
       * Sets the "checked" property on the input element.
       *
       * @param {?} value The checked value
       * @return {?}
       */


      _createClass2(CheckboxControlValueAccessor, [{
        key: "writeValue",
        value: function writeValue(value) {
          this._renderer.setProperty(this._elementRef.nativeElement, 'checked', value);
        }
        /**
         * \@description
         * Registers a function called when the control value changes.
         *
         * @param {?} fn The callback function
         * @return {?}
         */

      }, {
        key: "registerOnChange",
        value: function registerOnChange(fn) {
          this.onChange = fn;
        }
        /**
         * \@description
         * Registers a function called when the control is touched.
         *
         * @param {?} fn The callback function
         * @return {?}
         */

      }, {
        key: "registerOnTouched",
        value: function registerOnTouched(fn) {
          this.onTouched = fn;
        }
        /**
         * Sets the "disabled" property on the input element.
         *
         * @param {?} isDisabled The disabled value
         * @return {?}
         */

      }, {
        key: "setDisabledState",
        value: function setDisabledState(isDisabled) {
          this._renderer.setProperty(this._elementRef.nativeElement, 'disabled', isDisabled);
        }
      }]);

      return CheckboxControlValueAccessor;
    }();

    CheckboxControlValueAccessor.ɵfac = function CheckboxControlValueAccessor_Factory(t) {
      return new (t || CheckboxControlValueAccessor)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]));
    };

    CheckboxControlValueAccessor.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: CheckboxControlValueAccessor,
      selectors: [["input", "type", "checkbox", "formControlName", ""], ["input", "type", "checkbox", "formControl", ""], ["input", "type", "checkbox", "ngModel", ""]],
      hostBindings: function CheckboxControlValueAccessor_HostBindings(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵlistener"]("change", function CheckboxControlValueAccessor_change_HostBindingHandler($event) {
            return ctx.onChange($event.target.checked);
          })("blur", function CheckboxControlValueAccessor_blur_HostBindingHandler() {
            return ctx.onTouched();
          });
        }
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([CHECKBOX_VALUE_ACCESSOR])]
    });
    /** @nocollapse */

    CheckboxControlValueAccessor.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](CheckboxControlValueAccessor, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: 'input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]',
          host: {
            '(change)': 'onChange($event.target.checked)',
            '(blur)': 'onTouched()'
          },
          providers: [CHECKBOX_VALUE_ACCESSOR]
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/default_value_accessor.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var DEFAULT_VALUE_ACCESSOR = {
      provide: NG_VALUE_ACCESSOR,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return DefaultValueAccessor;
      }),
      multi: true
    };
    /**
     * We must check whether the agent is Android because composition events
     * behave differently between iOS and Android.
     * @return {?}
     */

    function _isAndroid() {
      /** @type {?} */
      var userAgent = Object(_angular_common__WEBPACK_IMPORTED_MODULE_1__["ɵgetDOM"])() ? Object(_angular_common__WEBPACK_IMPORTED_MODULE_1__["ɵgetDOM"])().getUserAgent() : '';
      return /android (\d+)/.test(userAgent.toLowerCase());
    }
    /**
     * \@description
     * Provide this token to control if form directives buffer IME input until
     * the "compositionend" event occurs.
     * \@publicApi
     * @type {?}
     */


    var COMPOSITION_BUFFER_MODE = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('CompositionEventMode');
    /**
     * \@description
     * The default `ControlValueAccessor` for writing a value and listening to changes on input
     * elements. The accessor is used by the `FormControlDirective`, `FormControlName`, and
     * `NgModel` directives.
     *
     * \@usageNotes
     *
     * ### Using the default value accessor
     *
     * The following example shows how to use an input element that activates the default value accessor
     * (in this case, a text field).
     *
     * ```ts
     * const firstNameControl = new FormControl();
     * ```
     *
     * ```
     * <input type="text" [formControl]="firstNameControl">
     * ```
     *
     * \@ngModule ReactiveFormsModule
     * \@ngModule FormsModule
     * \@publicApi
     */

    var DefaultValueAccessor = /*#__PURE__*/function () {
      /**
       * @param {?} _renderer
       * @param {?} _elementRef
       * @param {?} _compositionMode
       */
      function DefaultValueAccessor(_renderer, _elementRef, _compositionMode) {
        _classCallCheck(this, DefaultValueAccessor);

        this._renderer = _renderer;
        this._elementRef = _elementRef;
        this._compositionMode = _compositionMode;
        /**
         * \@description
         * The registered callback function called when an input event occurs on the input element.
         */

        this.onChange =
        /**
        * @param {?} _
        * @return {?}
        */
        function (_) {};
        /**
         * \@description
         * The registered callback function called when a blur event occurs on the input element.
         */


        this.onTouched =
        /**
        * @return {?}
        */
        function () {};
        /**
         * Whether the user is creating a composition string (IME events).
         */


        this._composing = false;

        if (this._compositionMode == null) {
          this._compositionMode = !_isAndroid();
        }
      }
      /**
       * Sets the "value" property on the input element.
       *
       * @param {?} value The checked value
       * @return {?}
       */


      _createClass2(DefaultValueAccessor, [{
        key: "writeValue",
        value: function writeValue(value) {
          /** @type {?} */
          var normalizedValue = value == null ? '' : value;

          this._renderer.setProperty(this._elementRef.nativeElement, 'value', normalizedValue);
        }
        /**
         * \@description
         * Registers a function called when the control value changes.
         *
         * @param {?} fn The callback function
         * @return {?}
         */

      }, {
        key: "registerOnChange",
        value: function registerOnChange(fn) {
          this.onChange = fn;
        }
        /**
         * \@description
         * Registers a function called when the control is touched.
         *
         * @param {?} fn The callback function
         * @return {?}
         */

      }, {
        key: "registerOnTouched",
        value: function registerOnTouched(fn) {
          this.onTouched = fn;
        }
        /**
         * Sets the "disabled" property on the input element.
         *
         * @param {?} isDisabled The disabled value
         * @return {?}
         */

      }, {
        key: "setDisabledState",
        value: function setDisabledState(isDisabled) {
          this._renderer.setProperty(this._elementRef.nativeElement, 'disabled', isDisabled);
        }
        /**
         * \@internal
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "_handleInput",
        value: function _handleInput(value) {
          if (!this._compositionMode || this._compositionMode && !this._composing) {
            this.onChange(value);
          }
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_compositionStart",
        value: function _compositionStart() {
          this._composing = true;
        }
        /**
         * \@internal
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "_compositionEnd",
        value: function _compositionEnd(value) {
          this._composing = false;
          this._compositionMode && this.onChange(value);
        }
      }]);

      return DefaultValueAccessor;
    }();

    DefaultValueAccessor.ɵfac = function DefaultValueAccessor_Factory(t) {
      return new (t || DefaultValueAccessor)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](COMPOSITION_BUFFER_MODE, 8));
    };

    DefaultValueAccessor.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: DefaultValueAccessor,
      selectors: [["input", "formControlName", "", 3, "type", "checkbox"], ["textarea", "formControlName", ""], ["input", "formControl", "", 3, "type", "checkbox"], ["textarea", "formControl", ""], ["input", "ngModel", "", 3, "type", "checkbox"], ["textarea", "ngModel", ""], ["", "ngDefaultControl", ""]],
      hostBindings: function DefaultValueAccessor_HostBindings(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵlistener"]("input", function DefaultValueAccessor_input_HostBindingHandler($event) {
            return ctx._handleInput($event.target.value);
          })("blur", function DefaultValueAccessor_blur_HostBindingHandler() {
            return ctx.onTouched();
          })("compositionstart", function DefaultValueAccessor_compositionstart_HostBindingHandler() {
            return ctx._compositionStart();
          })("compositionend", function DefaultValueAccessor_compositionend_HostBindingHandler($event) {
            return ctx._compositionEnd($event.target.value);
          });
        }
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([DEFAULT_VALUE_ACCESSOR])]
    });
    /** @nocollapse */

    DefaultValueAccessor.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
      }, {
        type: Boolean,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [COMPOSITION_BUFFER_MODE]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](DefaultValueAccessor, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: 'input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]',
          // TODO: vsavkin replace the above selector with the one below it once
          // https://github.com/angular/angular/issues/3011 is implemented
          // selector: '[ngModel],[formControl],[formControlName]',
          host: {
            '(input)': '$any(this)._handleInput($event.target.value)',
            '(blur)': 'onTouched()',
            '(compositionstart)': '$any(this)._compositionStart()',
            '(compositionend)': '$any(this)._compositionEnd($event.target.value)'
          },
          providers: [DEFAULT_VALUE_ACCESSOR]
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
        }, {
          type: Boolean,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [COMPOSITION_BUFFER_MODE]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/abstract_control_directive.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * \@description
     * Base class for control directives.
     *
     * This class is only used internally in the `ReactiveFormsModule` and the `FormsModule`.
     *
     * \@publicApi
     * @abstract
     */


    var AbstractControlDirective = /*#__PURE__*/function () {
      function AbstractControlDirective() {
        _classCallCheck(this, AbstractControlDirective);
      }

      _createClass2(AbstractControlDirective, [{
        key: "reset",

        /**
         * \@description
         * Resets the control with the provided value if the control is present.
         * @param {?=} value
         * @return {?}
         */
        value: function reset() {
          var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : undefined;
          if (this.control) this.control.reset(value);
        }
        /**
         * \@description
         * Reports whether the control with the given path has the error specified.
         *
         * \@usageNotes
         * For example, for the following `FormGroup`:
         *
         * ```
         * form = new FormGroup({
         *   address: new FormGroup({ street: new FormControl() })
         * });
         * ```
         *
         * The path to the 'street' control from the root form would be 'address' -> 'street'.
         *
         * It can be provided to this method in one of two formats:
         *
         * 1. An array of string control names, e.g. `['address', 'street']`
         * 1. A period-delimited list of control names in one string, e.g. `'address.street'`
         *
         * If no path is given, this method checks for the error on the current control.
         *
         * @param {?} errorCode The code of the error to check
         * @param {?=} path A list of control names that designates how to move from the current control
         * to the control that should be queried for errors.
         *
         * @return {?} whether the given error is present in the control at the given path.
         *
         * If the control is not present, false is returned.
         */

      }, {
        key: "hasError",
        value: function hasError(errorCode, path) {
          return this.control ? this.control.hasError(errorCode, path) : false;
        }
        /**
         * \@description
         * Reports error data for the control with the given path.
         *
         * \@usageNotes
         * For example, for the following `FormGroup`:
         *
         * ```
         * form = new FormGroup({
         *   address: new FormGroup({ street: new FormControl() })
         * });
         * ```
         *
         * The path to the 'street' control from the root form would be 'address' -> 'street'.
         *
         * It can be provided to this method in one of two formats:
         *
         * 1. An array of string control names, e.g. `['address', 'street']`
         * 1. A period-delimited list of control names in one string, e.g. `'address.street'`
         *
         * @param {?} errorCode The code of the error to check
         * @param {?=} path A list of control names that designates how to move from the current control
         * to the control that should be queried for errors.
         *
         * @return {?} error data for that particular error. If the control or error is not present,
         * null is returned.
         */

      }, {
        key: "getError",
        value: function getError(errorCode, path) {
          return this.control ? this.control.getError(errorCode, path) : null;
        }
      }, {
        key: "value",

        /**
         * \@description
         * Reports the value of the control if it is present, otherwise null.
         * @return {?}
         */
        get: function get() {
          return this.control ? this.control.value : null;
        }
        /**
         * \@description
         * Reports whether the control is valid. A control is considered valid if no
         * validation errors exist with the current value.
         * If the control is not present, null is returned.
         * @return {?}
         */

      }, {
        key: "valid",
        get: function get() {
          return this.control ? this.control.valid : null;
        }
        /**
         * \@description
         * Reports whether the control is invalid, meaning that an error exists in the input value.
         * If the control is not present, null is returned.
         * @return {?}
         */

      }, {
        key: "invalid",
        get: function get() {
          return this.control ? this.control.invalid : null;
        }
        /**
         * \@description
         * Reports whether a control is pending, meaning that that async validation is occurring and
         * errors are not yet available for the input value. If the control is not present, null is
         * returned.
         * @return {?}
         */

      }, {
        key: "pending",
        get: function get() {
          return this.control ? this.control.pending : null;
        }
        /**
         * \@description
         * Reports whether the control is disabled, meaning that the control is disabled
         * in the UI and is exempt from validation checks and excluded from aggregate
         * values of ancestor controls. If the control is not present, null is returned.
         * @return {?}
         */

      }, {
        key: "disabled",
        get: function get() {
          return this.control ? this.control.disabled : null;
        }
        /**
         * \@description
         * Reports whether the control is enabled, meaning that the control is included in ancestor
         * calculations of validity or value. If the control is not present, null is returned.
         * @return {?}
         */

      }, {
        key: "enabled",
        get: function get() {
          return this.control ? this.control.enabled : null;
        }
        /**
         * \@description
         * Reports the control's validation errors. If the control is not present, null is returned.
         * @return {?}
         */

      }, {
        key: "errors",
        get: function get() {
          return this.control ? this.control.errors : null;
        }
        /**
         * \@description
         * Reports whether the control is pristine, meaning that the user has not yet changed
         * the value in the UI. If the control is not present, null is returned.
         * @return {?}
         */

      }, {
        key: "pristine",
        get: function get() {
          return this.control ? this.control.pristine : null;
        }
        /**
         * \@description
         * Reports whether the control is dirty, meaning that the user has changed
         * the value in the UI. If the control is not present, null is returned.
         * @return {?}
         */

      }, {
        key: "dirty",
        get: function get() {
          return this.control ? this.control.dirty : null;
        }
        /**
         * \@description
         * Reports whether the control is touched, meaning that the user has triggered
         * a `blur` event on it. If the control is not present, null is returned.
         * @return {?}
         */

      }, {
        key: "touched",
        get: function get() {
          return this.control ? this.control.touched : null;
        }
        /**
         * \@description
         * Reports the validation status of the control. Possible values include:
         * 'VALID', 'INVALID', 'DISABLED', and 'PENDING'.
         * If the control is not present, null is returned.
         * @return {?}
         */

      }, {
        key: "status",
        get: function get() {
          return this.control ? this.control.status : null;
        }
        /**
         * \@description
         * Reports whether the control is untouched, meaning that the user has not yet triggered
         * a `blur` event on it. If the control is not present, null is returned.
         * @return {?}
         */

      }, {
        key: "untouched",
        get: function get() {
          return this.control ? this.control.untouched : null;
        }
        /**
         * \@description
         * Returns a multicasting observable that emits a validation status whenever it is
         * calculated for the control. If the control is not present, null is returned.
         * @return {?}
         */

      }, {
        key: "statusChanges",
        get: function get() {
          return this.control ? this.control.statusChanges : null;
        }
        /**
         * \@description
         * Returns a multicasting observable of value changes for the control that emits every time the
         * value of the control changes in the UI or programmatically.
         * If the control is not present, null is returned.
         * @return {?}
         */

      }, {
        key: "valueChanges",
        get: function get() {
          return this.control ? this.control.valueChanges : null;
        }
        /**
         * \@description
         * Returns an array that represents the path from the top-level form to this control.
         * Each index is the string name of the control on that level.
         * @return {?}
         */

      }, {
        key: "path",
        get: function get() {
          return null;
        }
      }]);

      return AbstractControlDirective;
    }();

    AbstractControlDirective.ɵfac = function AbstractControlDirective_Factory(t) {
      return new (t || AbstractControlDirective)();
    };

    AbstractControlDirective.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: AbstractControlDirective
    });

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/control_container.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@description
     * A base class for directives that contain multiple registered instances of `NgControl`.
     * Only used by the forms module.
     *
     * \@publicApi
     * @abstract
     */


    var ControlContainer = /*#__PURE__*/function (_AbstractControlDirec) {
      _inherits(ControlContainer, _AbstractControlDirec);

      var _super51 = _createSuper(ControlContainer);

      function ControlContainer() {
        _classCallCheck(this, ControlContainer);

        return _super51.apply(this, arguments);
      }

      _createClass2(ControlContainer, [{
        key: "formDirective",

        /**
         * \@description
         * The top-level form directive for the control.
         * @return {?}
         */
        get: function get() {
          return null;
        }
        /**
         * \@description
         * The path to this group.
         * @return {?}
         */

      }, {
        key: "path",
        get: function get() {
          return null;
        }
      }]);

      return ControlContainer;
    }(AbstractControlDirective);

    ControlContainer.ɵfac = function ControlContainer_Factory(t) {
      return ɵControlContainer_BaseFactory(t || ControlContainer);
    };

    ControlContainer.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: ControlContainer,
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]]
    });

    var ɵControlContainer_BaseFactory = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵgetInheritedFactory"](ControlContainer);

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/ng_control.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @return {?}
     */


    function unimplemented() {
      throw new Error('unimplemented');
    }
    /**
     * \@description
     * A base class that all control `FormControl`-based directives extend. It binds a `FormControl`
     * object to a DOM element.
     *
     * \@publicApi
     * @abstract
     */


    var NgControl = /*#__PURE__*/function (_AbstractControlDirec2) {
      _inherits(NgControl, _AbstractControlDirec2);

      var _super52 = _createSuper(NgControl);

      function NgControl() {
        var _this184;

        _classCallCheck(this, NgControl);

        _this184 = _super52.apply(this, arguments);
        /**
         * \@description
         * The parent form for the control.
         *
         * \@internal
         */

        _this184._parent = null;
        /**
         * \@description
         * The name for the control
         */

        _this184.name = null;
        /**
         * \@description
         * The value accessor for the control
         */

        _this184.valueAccessor = null;
        /**
         * \@description
         * The uncomposed array of synchronous validators for the control
         *
         * \@internal
         */

        _this184._rawValidators = [];
        /**
         * \@description
         * The uncomposed array of async validators for the control
         *
         * \@internal
         */

        _this184._rawAsyncValidators = [];
        return _this184;
      }
      /**
       * \@description
       * The registered synchronous validator function for the control
       *
       * @throws An exception that this method is not implemented
       * @return {?}
       */


      _createClass2(NgControl, [{
        key: "validator",
        get: function get() {
          return (
            /** @type {?} */
            unimplemented()
          );
        }
        /**
         * \@description
         * The registered async validator function for the control
         *
         * @throws An exception that this method is not implemented
         * @return {?}
         */

      }, {
        key: "asyncValidator",
        get: function get() {
          return (
            /** @type {?} */
            unimplemented()
          );
        }
      }]);

      return NgControl;
    }(AbstractControlDirective);

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/ng_control_status.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var AbstractControlStatus = /*#__PURE__*/function () {
      /**
       * @param {?} cd
       */
      function AbstractControlStatus(cd) {
        _classCallCheck(this, AbstractControlStatus);

        this._cd = cd;
      }
      /**
       * @return {?}
       */


      _createClass2(AbstractControlStatus, [{
        key: "ngClassUntouched",
        get: function get() {
          return this._cd.control ? this._cd.control.untouched : false;
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngClassTouched",
        get: function get() {
          return this._cd.control ? this._cd.control.touched : false;
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngClassPristine",
        get: function get() {
          return this._cd.control ? this._cd.control.pristine : false;
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngClassDirty",
        get: function get() {
          return this._cd.control ? this._cd.control.dirty : false;
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngClassValid",
        get: function get() {
          return this._cd.control ? this._cd.control.valid : false;
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngClassInvalid",
        get: function get() {
          return this._cd.control ? this._cd.control.invalid : false;
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngClassPending",
        get: function get() {
          return this._cd.control ? this._cd.control.pending : false;
        }
      }]);

      return AbstractControlStatus;
    }();

    if (false) {}
    /** @type {?} */


    var ngControlStatusHost = {
      '[class.ng-untouched]': 'ngClassUntouched',
      '[class.ng-touched]': 'ngClassTouched',
      '[class.ng-pristine]': 'ngClassPristine',
      '[class.ng-dirty]': 'ngClassDirty',
      '[class.ng-valid]': 'ngClassValid',
      '[class.ng-invalid]': 'ngClassInvalid',
      '[class.ng-pending]': 'ngClassPending'
    };
    /**
     * \@description
     * Directive automatically applied to Angular form controls that sets CSS classes
     * based on control status.
     *
     * \@usageNotes
     *
     * ### CSS classes applied
     *
     * The following classes are applied as the properties become true:
     *
     * * ng-valid
     * * ng-invalid
     * * ng-pending
     * * ng-pristine
     * * ng-dirty
     * * ng-untouched
     * * ng-touched
     *
     * \@ngModule ReactiveFormsModule
     * \@ngModule FormsModule
     * \@publicApi
     */

    var NgControlStatus = /*#__PURE__*/function (_AbstractControlStatu) {
      _inherits(NgControlStatus, _AbstractControlStatu);

      var _super53 = _createSuper(NgControlStatus);

      /**
       * @param {?} cd
       */
      function NgControlStatus(cd) {
        _classCallCheck(this, NgControlStatus);

        return _super53.call(this, cd);
      }

      return NgControlStatus;
    }(AbstractControlStatus);

    NgControlStatus.ɵfac = function NgControlStatus_Factory(t) {
      return new (t || NgControlStatus)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NgControl, 2));
    };

    NgControlStatus.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: NgControlStatus,
      selectors: [["", "formControlName", ""], ["", "ngModel", ""], ["", "formControl", ""]],
      hostVars: 14,
      hostBindings: function NgControlStatus_HostBindings(rf, ctx) {
        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵclassProp"]("ng-untouched", ctx.ngClassUntouched)("ng-touched", ctx.ngClassTouched)("ng-pristine", ctx.ngClassPristine)("ng-dirty", ctx.ngClassDirty)("ng-valid", ctx.ngClassValid)("ng-invalid", ctx.ngClassInvalid)("ng-pending", ctx.ngClassPending);
        }
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]]
    });
    /** @nocollapse */

    NgControlStatus.ctorParameters = function () {
      return [{
        type: NgControl,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NgControlStatus, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[formControlName],[ngModel],[formControl]',
          host: ngControlStatusHost
        }]
      }], function () {
        return [{
          type: NgControl,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }]
        }];
      }, null);
    })();
    /**
     * \@description
     * Directive automatically applied to Angular form groups that sets CSS classes
     * based on control status (valid/invalid/dirty/etc).
     *
     * @see `NgControlStatus`
     *
     * \@ngModule ReactiveFormsModule
     * \@ngModule FormsModule
     * \@publicApi
     */


    var NgControlStatusGroup = /*#__PURE__*/function (_AbstractControlStatu2) {
      _inherits(NgControlStatusGroup, _AbstractControlStatu2);

      var _super54 = _createSuper(NgControlStatusGroup);

      /**
       * @param {?} cd
       */
      function NgControlStatusGroup(cd) {
        _classCallCheck(this, NgControlStatusGroup);

        return _super54.call(this, cd);
      }

      return NgControlStatusGroup;
    }(AbstractControlStatus);

    NgControlStatusGroup.ɵfac = function NgControlStatusGroup_Factory(t) {
      return new (t || NgControlStatusGroup)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](ControlContainer, 2));
    };

    NgControlStatusGroup.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: NgControlStatusGroup,
      selectors: [["", "formGroupName", ""], ["", "formArrayName", ""], ["", "ngModelGroup", ""], ["", "formGroup", ""], ["form", 3, "ngNoForm", ""], ["", "ngForm", ""]],
      hostVars: 14,
      hostBindings: function NgControlStatusGroup_HostBindings(rf, ctx) {
        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵclassProp"]("ng-untouched", ctx.ngClassUntouched)("ng-touched", ctx.ngClassTouched)("ng-pristine", ctx.ngClassPristine)("ng-dirty", ctx.ngClassDirty)("ng-valid", ctx.ngClassValid)("ng-invalid", ctx.ngClassInvalid)("ng-pending", ctx.ngClassPending);
        }
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]]
    });
    /** @nocollapse */

    NgControlStatusGroup.ctorParameters = function () {
      return [{
        type: ControlContainer,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NgControlStatusGroup, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]',
          host: ngControlStatusHost
        }]
      }], function () {
        return [{
          type: ControlContainer,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }]
        }];
      }, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/validators.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} value
     * @return {?}
     */


    function isEmptyInputValue(value) {
      // we don't check for string here so it also works with arrays
      return value == null || value.length === 0;
    }
    /**
     * \@description
     * An `InjectionToken` for registering additional synchronous validators used with
     * `AbstractControl`s.
     *
     * @see `NG_ASYNC_VALIDATORS`
     *
     * \@usageNotes
     *
     * ### Providing a custom validator
     *
     * The following example registers a custom validator directive. Adding the validator to the
     * existing collection of validators requires the `multi: true` option.
     *
     * ```typescript
     * \@Directive({
     *   selector: '[customValidator]',
     *   providers: [{provide: NG_VALIDATORS, useExisting: CustomValidatorDirective, multi: true}]
     * })
     * class CustomValidatorDirective implements Validator {
     *   validate(control: AbstractControl): ValidationErrors | null {
     *     return { 'custom': true };
     *   }
     * }
     * ```
     *
     * \@publicApi
     * @type {?}
     */


    var NG_VALIDATORS = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('NgValidators');
    /**
     * \@description
     * An `InjectionToken` for registering additional asynchronous validators used with
     * `AbstractControl`s.
     *
     * @see `NG_VALIDATORS`
     *
     * \@publicApi
     * @type {?}
     */

    var NG_ASYNC_VALIDATORS = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('NgAsyncValidators');
    /**
     * A regular expression that matches valid e-mail addresses.
     *
     * At a high level, this regexp matches e-mail addresses of the format `local-part\@tld`, where:
     * - `local-part` consists of one or more of the allowed characters (alphanumeric and some
     *   punctuation symbols).
     * - `local-part` cannot begin or end with a period (`.`).
     * - `local-part` cannot be longer than 64 characters.
     * - `tld` consists of one or more `labels` separated by periods (`.`). For example `localhost` or
     *   `foo.com`.
     * - A `label` consists of one or more of the allowed characters (alphanumeric, dashes (`-`) and
     *   periods (`.`)).
     * - A `label` cannot begin or end with a dash (`-`) or a period (`.`).
     * - A `label` cannot be longer than 63 characters.
     * - The whole address cannot be longer than 254 characters.
     *
     * ## Implementation background
     *
     * This regexp was ported over from AngularJS (see there for git history):
     * https://github.com/angular/angular.js/blob/c133ef836/src/ng/directive/input.js#L27
     * It is based on the
     * [WHATWG version](https://html.spec.whatwg.org/multipage/input.html#valid-e-mail-address) with
     * some enhancements to incorporate more RFC rules (such as rules related to domain names and the
     * lengths of different parts of the address). The main differences from the WHATWG version are:
     *   - Disallow `local-part` to begin or end with a period (`.`).
     *   - Disallow `local-part` length to exceed 64 characters.
     *   - Disallow total address length to exceed 254 characters.
     *
     * See [this commit](https://github.com/angular/angular.js/commit/f3f5cf72e) for more details.
     * @type {?}
     */

    var EMAIL_REGEXP = /^(?=.{1,254}$)(?=.{1,64}@)[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/;
    /**
     * \@description
     * Provides a set of built-in validators that can be used by form controls.
     *
     * A validator is a function that processes a `FormControl` or collection of
     * controls and returns an error map or null. A null map means that validation has passed.
     *
     * @see [Form Validation](/guide/form-validation)
     *
     * \@publicApi
     */

    var Validators = /*#__PURE__*/function () {
      function Validators() {
        _classCallCheck(this, Validators);
      }

      _createClass2(Validators, null, [{
        key: "min",

        /**
         * \@description
         * Validator that requires the control's value to be greater than or equal to the provided number.
         * The validator exists only as a function and not as a directive.
         *
         * \@usageNotes
         *
         * ### Validate against a minimum of 3
         *
         * ```typescript
         * const control = new FormControl(2, Validators.min(3));
         *
         * console.log(control.errors); // {min: {min: 3, actual: 2}}
         * ```
         *
         * @see `updateValueAndValidity()`
         *
         * @param {?} min
         * @return {?} A validator function that returns an error map with the
         * `min` property if the validation check fails, otherwise `null`.
         *
         */
        value: function min(_min) {
          return (
            /**
            * @param {?} control
            * @return {?}
            */
            function (control) {
              if (isEmptyInputValue(control.value) || isEmptyInputValue(_min)) {
                return null; // don't validate empty values to allow optional controls
              }
              /** @type {?} */


              var value = parseFloat(control.value); // Controls with NaN values after parsing should be treated as not having a
              // minimum, per the HTML forms spec: https://www.w3.org/TR/html5/forms.html#attr-input-min

              return !isNaN(value) && value < _min ? {
                'min': {
                  'min': _min,
                  'actual': control.value
                }
              } : null;
            }
          );
        }
        /**
         * \@description
         * Validator that requires the control's value to be less than or equal to the provided number.
         * The validator exists only as a function and not as a directive.
         *
         * \@usageNotes
         *
         * ### Validate against a maximum of 15
         *
         * ```typescript
         * const control = new FormControl(16, Validators.max(15));
         *
         * console.log(control.errors); // {max: {max: 15, actual: 16}}
         * ```
         *
         * @see `updateValueAndValidity()`
         *
         * @param {?} max
         * @return {?} A validator function that returns an error map with the
         * `max` property if the validation check fails, otherwise `null`.
         *
         */

      }, {
        key: "max",
        value: function max(_max) {
          return (
            /**
            * @param {?} control
            * @return {?}
            */
            function (control) {
              if (isEmptyInputValue(control.value) || isEmptyInputValue(_max)) {
                return null; // don't validate empty values to allow optional controls
              }
              /** @type {?} */


              var value = parseFloat(control.value); // Controls with NaN values after parsing should be treated as not having a
              // maximum, per the HTML forms spec: https://www.w3.org/TR/html5/forms.html#attr-input-max

              return !isNaN(value) && value > _max ? {
                'max': {
                  'max': _max,
                  'actual': control.value
                }
              } : null;
            }
          );
        }
        /**
         * \@description
         * Validator that requires the control have a non-empty value.
         *
         * \@usageNotes
         *
         * ### Validate that the field is non-empty
         *
         * ```typescript
         * const control = new FormControl('', Validators.required);
         *
         * console.log(control.errors); // {required: true}
         * ```
         *
         * @see `updateValueAndValidity()`
         *
         * @param {?} control
         * @return {?} An error map with the `required` property
         * if the validation check fails, otherwise `null`.
         *
         */

      }, {
        key: "required",
        value: function required(control) {
          return isEmptyInputValue(control.value) ? {
            'required': true
          } : null;
        }
        /**
         * \@description
         * Validator that requires the control's value be true. This validator is commonly
         * used for required checkboxes.
         *
         * \@usageNotes
         *
         * ### Validate that the field value is true
         *
         * ```typescript
         * const control = new FormControl('', Validators.requiredTrue);
         *
         * console.log(control.errors); // {required: true}
         * ```
         *
         * @see `updateValueAndValidity()`
         *
         * @param {?} control
         * @return {?} An error map that contains the `required` property
         * set to `true` if the validation check fails, otherwise `null`.
         *
         */

      }, {
        key: "requiredTrue",
        value: function requiredTrue(control) {
          return control.value === true ? null : {
            'required': true
          };
        }
        /**
         * \@description
         * Validator that requires the control's value pass an email validation test.
         *
         * Tests the value using a [regular
         * expression](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_Expressions)
         * pattern suitable for common usecases. The pattern is based on the definition of a valid email
         * address in the [WHATWG HTML
         * specification](https://html.spec.whatwg.org/multipage/input.html#valid-e-mail-address) with
         * some enhancements to incorporate more RFC rules (such as rules related to domain names and the
         * lengths of different parts of the address).
         *
         * The differences from the WHATWG version include:
         * - Disallow `local-part` (the part before the `\@` symbol) to begin or end with a period (`.`).
         * - Disallow `local-part` to be longer than 64 characters.
         * - Disallow the whole address to be longer than 254 characters.
         *
         * If this pattern does not satisfy your business needs, you can use `Validators.pattern()` to
         * validate the value against a different pattern.
         *
         * \@usageNotes
         *
         * ### Validate that the field matches a valid email pattern
         *
         * ```typescript
         * const control = new FormControl('bad\@', Validators.email);
         *
         * console.log(control.errors); // {email: true}
         * ```
         *
         * @see `updateValueAndValidity()`
         *
         * @param {?} control
         * @return {?} An error map with the `email` property
         * if the validation check fails, otherwise `null`.
         *
         */

      }, {
        key: "email",
        value: function email(control) {
          if (isEmptyInputValue(control.value)) {
            return null; // don't validate empty values to allow optional controls
          }

          return EMAIL_REGEXP.test(control.value) ? null : {
            'email': true
          };
        }
        /**
         * \@description
         * Validator that requires the length of the control's value to be greater than or equal
         * to the provided minimum length. This validator is also provided by default if you use the
         * the HTML5 `minlength` attribute. Note that the `minLength` validator is intended to be used
         * only for types that have a numeric `length` property, such as strings or arrays. The
         * `minLength` validator logic is also not invoked for values when their `length` property is 0
         * (for example in case of an empty string or an empty array), to support optional controls. You
         * can use the standard `required` validator if empty values should not be considered valid.
         *
         * \@usageNotes
         *
         * ### Validate that the field has a minimum of 3 characters
         *
         * ```typescript
         * const control = new FormControl('ng', Validators.minLength(3));
         *
         * console.log(control.errors); // {minlength: {requiredLength: 3, actualLength: 2}}
         * ```
         *
         * ```html
         * <input minlength="5">
         * ```
         *
         * @see `updateValueAndValidity()`
         *
         * @param {?} minLength
         * @return {?} A validator function that returns an error map with the
         * `minlength` if the validation check fails, otherwise `null`.
         *
         */

      }, {
        key: "minLength",
        value: function minLength(_minLength) {
          return (
            /**
            * @param {?} control
            * @return {?}
            */
            function (control) {
              if (isEmptyInputValue(control.value)) {
                return null; // don't validate empty values to allow optional controls
              }
              /** @type {?} */


              var length = control.value ? control.value.length : 0;
              return length < _minLength ? {
                'minlength': {
                  'requiredLength': _minLength,
                  'actualLength': length
                }
              } : null;
            }
          );
        }
        /**
         * \@description
         * Validator that requires the length of the control's value to be less than or equal
         * to the provided maximum length. This validator is also provided by default if you use the
         * the HTML5 `maxlength` attribute. Note that the `maxLength` validator is intended to be used
         * only for types that have a numeric `length` property, such as strings or arrays.
         *
         * \@usageNotes
         *
         * ### Validate that the field has maximum of 5 characters
         *
         * ```typescript
         * const control = new FormControl('Angular', Validators.maxLength(5));
         *
         * console.log(control.errors); // {maxlength: {requiredLength: 5, actualLength: 7}}
         * ```
         *
         * ```html
         * <input maxlength="5">
         * ```
         *
         * @see `updateValueAndValidity()`
         *
         * @param {?} maxLength
         * @return {?} A validator function that returns an error map with the
         * `maxlength` property if the validation check fails, otherwise `null`.
         *
         */

      }, {
        key: "maxLength",
        value: function maxLength(_maxLength) {
          return (
            /**
            * @param {?} control
            * @return {?}
            */
            function (control) {
              /** @type {?} */
              var length = control.value ? control.value.length : 0;
              return length > _maxLength ? {
                'maxlength': {
                  'requiredLength': _maxLength,
                  'actualLength': length
                }
              } : null;
            }
          );
        }
        /**
         * \@description
         * Validator that requires the control's value to match a regex pattern. This validator is also
         * provided by default if you use the HTML5 `pattern` attribute.
         *
         * \@usageNotes
         *
         * ### Validate that the field only contains letters or spaces
         *
         * ```typescript
         * const control = new FormControl('1', Validators.pattern('[a-zA-Z ]*'));
         *
         * console.log(control.errors); // {pattern: {requiredPattern: '^[a-zA-Z ]*$', actualValue: '1'}}
         * ```
         *
         * ```html
         * <input pattern="[a-zA-Z ]*">
         * ```
         *
         * @see `updateValueAndValidity()`
         *
         * @param {?} pattern A regular expression to be used as is to test the values, or a string.
         * If a string is passed, the `^` character is prepended and the `$` character is
         * appended to the provided string (if not already present), and the resulting regular
         * expression is used to test the values.
         *
         * @return {?} A validator function that returns an error map with the
         * `pattern` property if the validation check fails, otherwise `null`.
         *
         */

      }, {
        key: "pattern",
        value: function pattern(_pattern) {
          if (!_pattern) return Validators.nullValidator;
          /** @type {?} */

          var regex;
          /** @type {?} */

          var regexStr;

          if (typeof _pattern === 'string') {
            regexStr = '';
            if (_pattern.charAt(0) !== '^') regexStr += '^';
            regexStr += _pattern;
            if (_pattern.charAt(_pattern.length - 1) !== '$') regexStr += '$';
            regex = new RegExp(regexStr);
          } else {
            regexStr = _pattern.toString();
            regex = _pattern;
          }

          return (
            /**
            * @param {?} control
            * @return {?}
            */
            function (control) {
              if (isEmptyInputValue(control.value)) {
                return null; // don't validate empty values to allow optional controls
              }
              /** @type {?} */


              var value = control.value;
              return regex.test(value) ? null : {
                'pattern': {
                  'requiredPattern': regexStr,
                  'actualValue': value
                }
              };
            }
          );
        }
        /**
         * \@description
         * Validator that performs no operation.
         *
         * @see `updateValueAndValidity()`
         *
         * @param {?} control
         * @return {?}
         */

      }, {
        key: "nullValidator",
        value: function nullValidator(control) {
          return null;
        }
        /**
         * @param {?} validators
         * @return {?}
         */

      }, {
        key: "compose",
        value: function compose(validators) {
          if (!validators) return null;
          /** @type {?} */

          var presentValidators =
          /** @type {?} */
          validators.filter(isPresent);
          if (presentValidators.length == 0) return null;
          return (
            /**
            * @param {?} control
            * @return {?}
            */
            function (control) {
              return _mergeErrors(_executeValidators(control, presentValidators));
            }
          );
        }
        /**
         * \@description
         * Compose multiple async validators into a single function that returns the union
         * of the individual error objects for the provided control.
         *
         * @see `updateValueAndValidity()`
         *
         * @param {?} validators
         * @return {?} A validator function that returns an error map with the
         * merged error objects of the async validators if the validation check fails, otherwise `null`.
         *
         */

      }, {
        key: "composeAsync",
        value: function composeAsync(validators) {
          if (!validators) return null;
          /** @type {?} */

          var presentValidators =
          /** @type {?} */
          validators.filter(isPresent);
          if (presentValidators.length == 0) return null;
          return (
            /**
            * @param {?} control
            * @return {?}
            */
            function (control) {
              /** @type {?} */
              var observables = _executeAsyncValidators(control, presentValidators).map(toObservable);

              return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["forkJoin"])(observables).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(_mergeErrors));
            }
          );
        }
      }]);

      return Validators;
    }();
    /**
     * @param {?} o
     * @return {?}
     */


    function isPresent(o) {
      return o != null;
    }
    /**
     * @param {?} r
     * @return {?}
     */


    function toObservable(r) {
      /** @type {?} */
      var obs = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵisPromise"])(r) ? Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["from"])(r) : r;

      if (!Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵisObservable"])(obs)) {
        throw new Error("Expected validator to return Promise or Observable.");
      }

      return obs;
    }
    /**
     * @param {?} control
     * @param {?} validators
     * @return {?}
     */


    function _executeValidators(control, validators) {
      return validators.map(
      /**
      * @param {?} v
      * @return {?}
      */
      function (v) {
        return v(control);
      });
    }
    /**
     * @param {?} control
     * @param {?} validators
     * @return {?}
     */


    function _executeAsyncValidators(control, validators) {
      return validators.map(
      /**
      * @param {?} v
      * @return {?}
      */
      function (v) {
        return v(control);
      });
    }
    /**
     * @param {?} arrayOfErrors
     * @return {?}
     */


    function _mergeErrors(arrayOfErrors) {
      /** @type {?} */
      var res = {}; // Not using Array.reduce here due to a Chrome 80 bug
      // https://bugs.chromium.org/p/chromium/issues/detail?id=1049982

      arrayOfErrors.forEach(
      /**
      * @param {?} errors
      * @return {?}
      */
      function (errors) {
        res = errors != null ? Object.assign(Object.assign({},
        /** @type {?} */
        res), errors) :
        /** @type {?} */
        res;
      });
      return Object.keys(res).length === 0 ? null : res;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/normalize_validator.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * @param {?} validator
     * @return {?}
     */


    function normalizeValidator(validator) {
      if (
      /** @type {?} */
      validator.validate) {
        return (
          /**
          * @param {?} c
          * @return {?}
          */
          function (c) {
            return (
              /** @type {?} */
              validator.validate(c)
            );
          }
        );
      } else {
        return (
          /** @type {?} */
          validator
        );
      }
    }
    /**
     * @param {?} validator
     * @return {?}
     */


    function normalizeAsyncValidator(validator) {
      if (
      /** @type {?} */
      validator.validate) {
        return (
          /**
          * @param {?} c
          * @return {?}
          */
          function (c) {
            return (
              /** @type {?} */
              validator.validate(c)
            );
          }
        );
      } else {
        return (
          /** @type {?} */
          validator
        );
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/number_value_accessor.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var NUMBER_VALUE_ACCESSOR = {
      provide: NG_VALUE_ACCESSOR,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return NumberValueAccessor;
      }),
      multi: true
    };
    /**
     * \@description
     * The `ControlValueAccessor` for writing a number value and listening to number input changes.
     * The value accessor is used by the `FormControlDirective`, `FormControlName`, and  `NgModel`
     * directives.
     *
     * \@usageNotes
     *
     * ### Using a number input with a reactive form.
     *
     * The following example shows how to use a number input with a reactive form.
     *
     * ```ts
     * const totalCountControl = new FormControl();
     * ```
     *
     * ```
     * <input type="number" [formControl]="totalCountControl">
     * ```
     *
     * \@ngModule ReactiveFormsModule
     * \@ngModule FormsModule
     * \@publicApi
     */

    var NumberValueAccessor = /*#__PURE__*/function () {
      /**
       * @param {?} _renderer
       * @param {?} _elementRef
       */
      function NumberValueAccessor(_renderer, _elementRef) {
        _classCallCheck(this, NumberValueAccessor);

        this._renderer = _renderer;
        this._elementRef = _elementRef;
        /**
         * \@description
         * The registered callback function called when a change or input event occurs on the input
         * element.
         */

        this.onChange =
        /**
        * @param {?} _
        * @return {?}
        */
        function (_) {};
        /**
         * \@description
         * The registered callback function called when a blur event occurs on the input element.
         */


        this.onTouched =
        /**
        * @return {?}
        */
        function () {};
      }
      /**
       * Sets the "value" property on the input element.
       *
       * @param {?} value The checked value
       * @return {?}
       */


      _createClass2(NumberValueAccessor, [{
        key: "writeValue",
        value: function writeValue(value) {
          // The value needs to be normalized for IE9, otherwise it is set to 'null' when null

          /** @type {?} */
          var normalizedValue = value == null ? '' : value;

          this._renderer.setProperty(this._elementRef.nativeElement, 'value', normalizedValue);
        }
        /**
         * \@description
         * Registers a function called when the control value changes.
         *
         * @param {?} fn The callback function
         * @return {?}
         */

      }, {
        key: "registerOnChange",
        value: function registerOnChange(fn) {
          this.onChange =
          /**
          * @param {?} value
          * @return {?}
          */
          function (value) {
            fn(value == '' ? null : parseFloat(value));
          };
        }
        /**
         * \@description
         * Registers a function called when the control is touched.
         *
         * @param {?} fn The callback function
         * @return {?}
         */

      }, {
        key: "registerOnTouched",
        value: function registerOnTouched(fn) {
          this.onTouched = fn;
        }
        /**
         * Sets the "disabled" property on the input element.
         *
         * @param {?} isDisabled The disabled value
         * @return {?}
         */

      }, {
        key: "setDisabledState",
        value: function setDisabledState(isDisabled) {
          this._renderer.setProperty(this._elementRef.nativeElement, 'disabled', isDisabled);
        }
      }]);

      return NumberValueAccessor;
    }();

    NumberValueAccessor.ɵfac = function NumberValueAccessor_Factory(t) {
      return new (t || NumberValueAccessor)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]));
    };

    NumberValueAccessor.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: NumberValueAccessor,
      selectors: [["input", "type", "number", "formControlName", ""], ["input", "type", "number", "formControl", ""], ["input", "type", "number", "ngModel", ""]],
      hostBindings: function NumberValueAccessor_HostBindings(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵlistener"]("change", function NumberValueAccessor_change_HostBindingHandler($event) {
            return ctx.onChange($event.target.value);
          })("input", function NumberValueAccessor_input_HostBindingHandler($event) {
            return ctx.onChange($event.target.value);
          })("blur", function NumberValueAccessor_blur_HostBindingHandler() {
            return ctx.onTouched();
          });
        }
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([NUMBER_VALUE_ACCESSOR])]
    });
    /** @nocollapse */

    NumberValueAccessor.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NumberValueAccessor, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: 'input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]',
          host: {
            '(change)': 'onChange($event.target.value)',
            '(input)': 'onChange($event.target.value)',
            '(blur)': 'onTouched()'
          },
          providers: [NUMBER_VALUE_ACCESSOR]
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/radio_control_value_accessor.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var RADIO_VALUE_ACCESSOR = {
      provide: NG_VALUE_ACCESSOR,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return RadioControlValueAccessor;
      }),
      multi: true
    };
    /**
     * \@description
     * Class used by Angular to track radio buttons. For internal use only.
     */

    var RadioControlRegistry = /*#__PURE__*/function () {
      function RadioControlRegistry() {
        _classCallCheck(this, RadioControlRegistry);

        this._accessors = [];
      }
      /**
       * \@description
       * Adds a control to the internal registry. For internal use only.
       * @param {?} control
       * @param {?} accessor
       * @return {?}
       */


      _createClass2(RadioControlRegistry, [{
        key: "add",
        value: function add(control, accessor) {
          this._accessors.push([control, accessor]);
        }
        /**
         * \@description
         * Removes a control from the internal registry. For internal use only.
         * @param {?} accessor
         * @return {?}
         */

      }, {
        key: "remove",
        value: function remove(accessor) {
          for (var i = this._accessors.length - 1; i >= 0; --i) {
            if (this._accessors[i][1] === accessor) {
              this._accessors.splice(i, 1);

              return;
            }
          }
        }
        /**
         * \@description
         * Selects a radio button. For internal use only.
         * @param {?} accessor
         * @return {?}
         */

      }, {
        key: "select",
        value: function select(accessor) {
          var _this185 = this;

          this._accessors.forEach(
          /**
          * @param {?} c
          * @return {?}
          */
          function (c) {
            if (_this185._isSameGroup(c, accessor) && c[1] !== accessor) {
              c[1].fireUncheck(accessor.value);
            }
          });
        }
        /**
         * @private
         * @param {?} controlPair
         * @param {?} accessor
         * @return {?}
         */

      }, {
        key: "_isSameGroup",
        value: function _isSameGroup(controlPair, accessor) {
          if (!controlPair[0].control) return false;
          return controlPair[0]._parent === accessor._control._parent && controlPair[1].name === accessor.name;
        }
      }]);

      return RadioControlRegistry;
    }();

    RadioControlRegistry.ɵfac = function RadioControlRegistry_Factory(t) {
      return new (t || RadioControlRegistry)();
    };

    RadioControlRegistry.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({
      token: RadioControlRegistry,
      factory: RadioControlRegistry.ɵfac
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](RadioControlRegistry, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"]
      }], function () {
        return [];
      }, null);
    })();

    if (false) {}
    /**
     * \@description
     * The `ControlValueAccessor` for writing radio control values and listening to radio control
     * changes. The value accessor is used by the `FormControlDirective`, `FormControlName`, and
     * `NgModel` directives.
     *
     * \@usageNotes
     *
     * ### Using radio buttons with reactive form directives
     *
     * The follow example shows how to use radio buttons in a reactive form. When using radio buttons in
     * a reactive form, radio buttons in the same group should have the same `formControlName`.
     * Providing a `name` attribute is optional.
     *
     * {\@example forms/ts/reactiveRadioButtons/reactive_radio_button_example.ts region='Reactive'}
     *
     * \@ngModule ReactiveFormsModule
     * \@ngModule FormsModule
     * \@publicApi
     */


    var RadioControlValueAccessor = /*#__PURE__*/function () {
      /**
       * @param {?} _renderer
       * @param {?} _elementRef
       * @param {?} _registry
       * @param {?} _injector
       */
      function RadioControlValueAccessor(_renderer, _elementRef, _registry, _injector) {
        _classCallCheck(this, RadioControlValueAccessor);

        this._renderer = _renderer;
        this._elementRef = _elementRef;
        this._registry = _registry;
        this._injector = _injector;
        /**
         * \@description
         * The registered callback function called when a change event occurs on the input element.
         */

        this.onChange =
        /**
        * @return {?}
        */
        function () {};
        /**
         * \@description
         * The registered callback function called when a blur event occurs on the input element.
         */


        this.onTouched =
        /**
        * @return {?}
        */
        function () {};
      }
      /**
       * \@description
       * A lifecycle method called when the directive is initialized. For internal use only.
       * @return {?}
       */


      _createClass2(RadioControlValueAccessor, [{
        key: "ngOnInit",
        value: function ngOnInit() {
          this._control = this._injector.get(NgControl);

          this._checkName();

          this._registry.add(this._control, this);
        }
        /**
         * \@description
         * Lifecycle method called before the directive's instance is destroyed. For internal use only.
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this._registry.remove(this);
        }
        /**
         * \@description
         * Sets the "checked" property value on the radio input element.
         *
         * @param {?} value The checked value
         * @return {?}
         */

      }, {
        key: "writeValue",
        value: function writeValue(value) {
          this._state = value === this.value;

          this._renderer.setProperty(this._elementRef.nativeElement, 'checked', this._state);
        }
        /**
         * \@description
         * Registers a function called when the control value changes.
         *
         * @param {?} fn The callback function
         * @return {?}
         */

      }, {
        key: "registerOnChange",
        value: function registerOnChange(fn) {
          var _this186 = this;

          this._fn = fn;

          this.onChange =
          /**
          * @return {?}
          */
          function () {
            fn(_this186.value);

            _this186._registry.select(_this186);
          };
        }
        /**
         * Sets the "value" on the radio input element and unchecks it.
         *
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "fireUncheck",
        value: function fireUncheck(value) {
          this.writeValue(value);
        }
        /**
         * \@description
         * Registers a function called when the control is touched.
         *
         * @param {?} fn The callback function
         * @return {?}
         */

      }, {
        key: "registerOnTouched",
        value: function registerOnTouched(fn) {
          this.onTouched = fn;
        }
        /**
         * Sets the "disabled" property on the input element.
         *
         * @param {?} isDisabled The disabled value
         * @return {?}
         */

      }, {
        key: "setDisabledState",
        value: function setDisabledState(isDisabled) {
          this._renderer.setProperty(this._elementRef.nativeElement, 'disabled', isDisabled);
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_checkName",
        value: function _checkName() {
          if (this.name && this.formControlName && this.name !== this.formControlName) {
            this._throwNameError();
          }

          if (!this.name && this.formControlName) this.name = this.formControlName;
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_throwNameError",
        value: function _throwNameError() {
          throw new Error("\n      If you define both a name and a formControlName attribute on your radio button, their values\n      must match. Ex: <input type=\"radio\" formControlName=\"food\" name=\"food\">\n    ");
        }
      }]);

      return RadioControlValueAccessor;
    }();

    RadioControlValueAccessor.ɵfac = function RadioControlValueAccessor_Factory(t) {
      return new (t || RadioControlValueAccessor)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](RadioControlRegistry), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injector"]));
    };

    RadioControlValueAccessor.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: RadioControlValueAccessor,
      selectors: [["input", "type", "radio", "formControlName", ""], ["input", "type", "radio", "formControl", ""], ["input", "type", "radio", "ngModel", ""]],
      hostBindings: function RadioControlValueAccessor_HostBindings(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵlistener"]("change", function RadioControlValueAccessor_change_HostBindingHandler() {
            return ctx.onChange();
          })("blur", function RadioControlValueAccessor_blur_HostBindingHandler() {
            return ctx.onTouched();
          });
        }
      },
      inputs: {
        name: "name",
        formControlName: "formControlName",
        value: "value"
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([RADIO_VALUE_ACCESSOR])]
    });
    /** @nocollapse */

    RadioControlValueAccessor.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
      }, {
        type: RadioControlRegistry
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injector"]
      }];
    };

    RadioControlValueAccessor.propDecorators = {
      name: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }],
      formControlName: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }],
      value: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](RadioControlValueAccessor, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: 'input[type=radio][formControlName],input[type=radio][formControl],input[type=radio][ngModel]',
          host: {
            '(change)': 'onChange()',
            '(blur)': 'onTouched()'
          },
          providers: [RADIO_VALUE_ACCESSOR]
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
        }, {
          type: RadioControlRegistry
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injector"]
        }];
      }, {
        name: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }],
        formControlName: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }],
        value: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/range_value_accessor.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var RANGE_VALUE_ACCESSOR = {
      provide: NG_VALUE_ACCESSOR,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return RangeValueAccessor;
      }),
      multi: true
    };
    /**
     * \@description
     * The `ControlValueAccessor` for writing a range value and listening to range input changes.
     * The value accessor is used by the `FormControlDirective`, `FormControlName`, and  `NgModel`
     * directives.
     *
     * \@usageNotes
     *
     * ### Using a range input with a reactive form
     *
     * The following example shows how to use a range input with a reactive form.
     *
     * ```ts
     * const ageControl = new FormControl();
     * ```
     *
     * ```
     * <input type="range" [formControl]="ageControl">
     * ```
     *
     * \@ngModule ReactiveFormsModule
     * \@ngModule FormsModule
     * \@publicApi
     */

    var RangeValueAccessor = /*#__PURE__*/function () {
      /**
       * @param {?} _renderer
       * @param {?} _elementRef
       */
      function RangeValueAccessor(_renderer, _elementRef) {
        _classCallCheck(this, RangeValueAccessor);

        this._renderer = _renderer;
        this._elementRef = _elementRef;
        /**
         * \@description
         * The registered callback function called when a change or input event occurs on the input
         * element.
         */

        this.onChange =
        /**
        * @param {?} _
        * @return {?}
        */
        function (_) {};
        /**
         * \@description
         * The registered callback function called when a blur event occurs on the input element.
         */


        this.onTouched =
        /**
        * @return {?}
        */
        function () {};
      }
      /**
       * Sets the "value" property on the input element.
       *
       * @param {?} value The checked value
       * @return {?}
       */


      _createClass2(RangeValueAccessor, [{
        key: "writeValue",
        value: function writeValue(value) {
          this._renderer.setProperty(this._elementRef.nativeElement, 'value', parseFloat(value));
        }
        /**
         * \@description
         * Registers a function called when the control value changes.
         *
         * @param {?} fn The callback function
         * @return {?}
         */

      }, {
        key: "registerOnChange",
        value: function registerOnChange(fn) {
          this.onChange =
          /**
          * @param {?} value
          * @return {?}
          */
          function (value) {
            fn(value == '' ? null : parseFloat(value));
          };
        }
        /**
         * \@description
         * Registers a function called when the control is touched.
         *
         * @param {?} fn The callback function
         * @return {?}
         */

      }, {
        key: "registerOnTouched",
        value: function registerOnTouched(fn) {
          this.onTouched = fn;
        }
        /**
         * Sets the "disabled" property on the range input element.
         *
         * @param {?} isDisabled The disabled value
         * @return {?}
         */

      }, {
        key: "setDisabledState",
        value: function setDisabledState(isDisabled) {
          this._renderer.setProperty(this._elementRef.nativeElement, 'disabled', isDisabled);
        }
      }]);

      return RangeValueAccessor;
    }();

    RangeValueAccessor.ɵfac = function RangeValueAccessor_Factory(t) {
      return new (t || RangeValueAccessor)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]));
    };

    RangeValueAccessor.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: RangeValueAccessor,
      selectors: [["input", "type", "range", "formControlName", ""], ["input", "type", "range", "formControl", ""], ["input", "type", "range", "ngModel", ""]],
      hostBindings: function RangeValueAccessor_HostBindings(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵlistener"]("change", function RangeValueAccessor_change_HostBindingHandler($event) {
            return ctx.onChange($event.target.value);
          })("input", function RangeValueAccessor_input_HostBindingHandler($event) {
            return ctx.onChange($event.target.value);
          })("blur", function RangeValueAccessor_blur_HostBindingHandler() {
            return ctx.onTouched();
          });
        }
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([RANGE_VALUE_ACCESSOR])]
    });
    /** @nocollapse */

    RangeValueAccessor.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](RangeValueAccessor, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: 'input[type=range][formControlName],input[type=range][formControl],input[type=range][ngModel]',
          host: {
            '(change)': 'onChange($event.target.value)',
            '(input)': 'onChange($event.target.value)',
            '(blur)': 'onTouched()'
          },
          providers: [RANGE_VALUE_ACCESSOR]
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/error_examples.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** @type {?} */


    var FormErrorExamples = {
      formControlName: "\n    <div [formGroup]=\"myGroup\">\n      <input formControlName=\"firstName\">\n    </div>\n\n    In your class:\n\n    this.myGroup = new FormGroup({\n       firstName: new FormControl()\n    });",
      formGroupName: "\n    <div [formGroup]=\"myGroup\">\n       <div formGroupName=\"person\">\n          <input formControlName=\"firstName\">\n       </div>\n    </div>\n\n    In your class:\n\n    this.myGroup = new FormGroup({\n       person: new FormGroup({ firstName: new FormControl() })\n    });",
      formArrayName: "\n    <div [formGroup]=\"myGroup\">\n      <div formArrayName=\"cities\">\n        <div *ngFor=\"let city of cityArray.controls; index as i\">\n          <input [formControlName]=\"i\">\n        </div>\n      </div>\n    </div>\n\n    In your class:\n\n    this.cityArray = new FormArray([new FormControl('SF')]);\n    this.myGroup = new FormGroup({\n      cities: this.cityArray\n    });",
      ngModelGroup: "\n    <form>\n       <div ngModelGroup=\"person\">\n          <input [(ngModel)]=\"person.name\" name=\"firstName\">\n       </div>\n    </form>",
      ngModelWithFormGroup: "\n    <div [formGroup]=\"myGroup\">\n       <input formControlName=\"firstName\">\n       <input [(ngModel)]=\"showMoreControls\" [ngModelOptions]=\"{standalone: true}\">\n    </div>\n  "
    };
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/reactive_errors.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    var ReactiveErrors = /*#__PURE__*/function () {
      function ReactiveErrors() {
        _classCallCheck(this, ReactiveErrors);
      }

      _createClass2(ReactiveErrors, null, [{
        key: "controlParentException",

        /**
         * @return {?}
         */
        value: function controlParentException() {
          throw new Error("formControlName must be used with a parent formGroup directive.  You'll want to add a formGroup\n       directive and pass it an existing FormGroup instance (you can create one in your class).\n\n      Example:\n\n      ".concat(FormErrorExamples.formControlName));
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngModelGroupException",
        value: function ngModelGroupException() {
          throw new Error("formControlName cannot be used with an ngModelGroup parent. It is only compatible with parents\n       that also have a \"form\" prefix: formGroupName, formArrayName, or formGroup.\n\n       Option 1:  Update the parent to be formGroupName (reactive form strategy)\n\n        ".concat(FormErrorExamples.formGroupName, "\n\n        Option 2: Use ngModel instead of formControlName (template-driven strategy)\n\n        ").concat(FormErrorExamples.ngModelGroup));
        }
        /**
         * @return {?}
         */

      }, {
        key: "missingFormException",
        value: function missingFormException() {
          throw new Error("formGroup expects a FormGroup instance. Please pass one in.\n\n       Example:\n\n       ".concat(FormErrorExamples.formControlName));
        }
        /**
         * @return {?}
         */

      }, {
        key: "groupParentException",
        value: function groupParentException() {
          throw new Error("formGroupName must be used with a parent formGroup directive.  You'll want to add a formGroup\n      directive and pass it an existing FormGroup instance (you can create one in your class).\n\n      Example:\n\n      ".concat(FormErrorExamples.formGroupName));
        }
        /**
         * @return {?}
         */

      }, {
        key: "arrayParentException",
        value: function arrayParentException() {
          throw new Error("formArrayName must be used with a parent formGroup directive.  You'll want to add a formGroup\n       directive and pass it an existing FormGroup instance (you can create one in your class).\n\n        Example:\n\n        ".concat(FormErrorExamples.formArrayName));
        }
        /**
         * @return {?}
         */

      }, {
        key: "disabledAttrWarning",
        value: function disabledAttrWarning() {
          console.warn("\n      It looks like you're using the disabled attribute with a reactive form directive. If you set disabled to true\n      when you set up this control in your component class, the disabled attribute will actually be set in the DOM for\n      you. We recommend using this approach to avoid 'changed after checked' errors.\n       \n      Example: \n      form = new FormGroup({\n        first: new FormControl({value: 'Nancy', disabled: true}, Validators.required),\n        last: new FormControl('Drew', Validators.required)\n      });\n    ");
        }
        /**
         * @param {?} directiveName
         * @return {?}
         */

      }, {
        key: "ngModelWarning",
        value: function ngModelWarning(directiveName) {
          console.warn("\n    It looks like you're using ngModel on the same form field as ".concat(directiveName, ". \n    Support for using the ngModel input property and ngModelChange event with \n    reactive form directives has been deprecated in Angular v6 and will be removed \n    in Angular v7.\n    \n    For more information on this, see our API docs here:\n    https://angular.io/api/forms/").concat(directiveName === 'formControl' ? 'FormControlDirective' : 'FormControlName', "#use-with-ngmodel\n    "));
        }
      }]);

      return ReactiveErrors;
    }();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/select_control_value_accessor.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var SELECT_VALUE_ACCESSOR = {
      provide: NG_VALUE_ACCESSOR,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return SelectControlValueAccessor;
      }),
      multi: true
    };
    /**
     * @param {?} id
     * @param {?} value
     * @return {?}
     */

    function _buildValueString(id, value) {
      if (id == null) return "".concat(value);
      if (value && typeof value === 'object') value = 'Object';
      return "".concat(id, ": ").concat(value).slice(0, 50);
    }
    /**
     * @param {?} valueString
     * @return {?}
     */


    function _extractId(valueString) {
      return valueString.split(':')[0];
    }
    /**
     * \@description
     * The `ControlValueAccessor` for writing select control values and listening to select control
     * changes. The value accessor is used by the `FormControlDirective`, `FormControlName`, and
     * `NgModel` directives.
     *
     * \@usageNotes
     *
     * ### Using select controls in a reactive form
     *
     * The following examples show how to use a select control in a reactive form.
     *
     * {\@example forms/ts/reactiveSelectControl/reactive_select_control_example.ts region='Component'}
     *
     * ### Using select controls in a template-driven form
     *
     * To use a select in a template-driven form, simply add an `ngModel` and a `name`
     * attribute to the main `<select>` tag.
     *
     * {\@example forms/ts/selectControl/select_control_example.ts region='Component'}
     *
     * ### Customizing option selection
     *
     * Angular uses object identity to select option. It's possible for the identities of items
     * to change while the data does not. This can happen, for example, if the items are produced
     * from an RPC to the server, and that RPC is re-run. Even if the data hasn't changed, the
     * second response will produce objects with different identities.
     *
     * To customize the default option comparison algorithm, `<select>` supports `compareWith` input.
     * `compareWith` takes a **function** which has two arguments: `option1` and `option2`.
     * If `compareWith` is given, Angular selects option by the return value of the function.
     *
     * ```ts
     * const selectedCountriesControl = new FormControl();
     * ```
     *
     * ```
     * <select [compareWith]="compareFn"  [formControl]="selectedCountriesControl">
     *     <option *ngFor="let country of countries" [ngValue]="country">
     *         {{country.name}}
     *     </option>
     * </select>
     *
     * compareFn(c1: Country, c2: Country): boolean {
     *     return c1 && c2 ? c1.id === c2.id : c1 === c2;
     * }
     * ```
     *
     * **Note:** We listen to the 'change' event because 'input' events aren't fired
     * for selects in Firefox and IE:
     * https://bugzilla.mozilla.org/show_bug.cgi?id=1024350
     * https://developer.microsoft.com/en-us/microsoft-edge/platform/issues/4660045/
     *
     * \@ngModule ReactiveFormsModule
     * \@ngModule FormsModule
     * \@publicApi
     */


    var SelectControlValueAccessor = /*#__PURE__*/function () {
      /**
       * @param {?} _renderer
       * @param {?} _elementRef
       */
      function SelectControlValueAccessor(_renderer, _elementRef) {
        _classCallCheck(this, SelectControlValueAccessor);

        this._renderer = _renderer;
        this._elementRef = _elementRef;
        /**
         * \@internal
         */

        this._optionMap = new Map();
        /**
         * \@internal
         */

        this._idCounter = 0;
        /**
         * \@description
         * The registered callback function called when a change event occurs on the input element.
         */

        this.onChange =
        /**
        * @param {?} _
        * @return {?}
        */
        function (_) {};
        /**
         * \@description
         * The registered callback function called when a blur event occurs on the input element.
         */


        this.onTouched =
        /**
        * @return {?}
        */
        function () {};

        this._compareWith = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵlooseIdentical"];
      }
      /**
       * \@description
       * Tracks the option comparison algorithm for tracking identities when
       * checking for changes.
       * @param {?} fn
       * @return {?}
       */


      _createClass2(SelectControlValueAccessor, [{
        key: "writeValue",

        /**
         * Sets the "value" property on the input element. The "selectedIndex"
         * property is also set if an ID is provided on the option element.
         *
         * @param {?} value The checked value
         * @return {?}
         */
        value: function writeValue(value) {
          this.value = value;
          /** @type {?} */

          var id = this._getOptionId(value);

          if (id == null) {
            this._renderer.setProperty(this._elementRef.nativeElement, 'selectedIndex', -1);
          }
          /** @type {?} */


          var valueString = _buildValueString(id, value);

          this._renderer.setProperty(this._elementRef.nativeElement, 'value', valueString);
        }
        /**
         * \@description
         * Registers a function called when the control value changes.
         *
         * @param {?} fn The callback function
         * @return {?}
         */

      }, {
        key: "registerOnChange",
        value: function registerOnChange(fn) {
          var _this187 = this;

          this.onChange =
          /**
          * @param {?} valueString
          * @return {?}
          */
          function (valueString) {
            _this187.value = _this187._getOptionValue(valueString);
            fn(_this187.value);
          };
        }
        /**
         * \@description
         * Registers a function called when the control is touched.
         *
         * @param {?} fn The callback function
         * @return {?}
         */

      }, {
        key: "registerOnTouched",
        value: function registerOnTouched(fn) {
          this.onTouched = fn;
        }
        /**
         * Sets the "disabled" property on the select input element.
         *
         * @param {?} isDisabled The disabled value
         * @return {?}
         */

      }, {
        key: "setDisabledState",
        value: function setDisabledState(isDisabled) {
          this._renderer.setProperty(this._elementRef.nativeElement, 'disabled', isDisabled);
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_registerOption",
        value: function _registerOption() {
          return (this._idCounter++).toString();
        }
        /**
         * \@internal
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "_getOptionId",
        value: function _getOptionId(value) {
          for (var _i26 = 0, _Array$from = Array.from(this._optionMap.keys()); _i26 < _Array$from.length; _i26++) {
            var id = _Array$from[_i26];
            if (this._compareWith(this._optionMap.get(id), value)) return id;
          }

          return null;
        }
        /**
         * \@internal
         * @param {?} valueString
         * @return {?}
         */

      }, {
        key: "_getOptionValue",
        value: function _getOptionValue(valueString) {
          /** @type {?} */
          var id = _extractId(valueString);

          return this._optionMap.has(id) ? this._optionMap.get(id) : valueString;
        }
      }, {
        key: "compareWith",
        set: function set(fn) {
          if (typeof fn !== 'function') {
            throw new Error("compareWith must be a function, but received ".concat(JSON.stringify(fn)));
          }

          this._compareWith = fn;
        }
      }]);

      return SelectControlValueAccessor;
    }();

    SelectControlValueAccessor.ɵfac = function SelectControlValueAccessor_Factory(t) {
      return new (t || SelectControlValueAccessor)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]));
    };

    SelectControlValueAccessor.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: SelectControlValueAccessor,
      selectors: [["select", "formControlName", "", 3, "multiple", ""], ["select", "formControl", "", 3, "multiple", ""], ["select", "ngModel", "", 3, "multiple", ""]],
      hostBindings: function SelectControlValueAccessor_HostBindings(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵlistener"]("change", function SelectControlValueAccessor_change_HostBindingHandler($event) {
            return ctx.onChange($event.target.value);
          })("blur", function SelectControlValueAccessor_blur_HostBindingHandler() {
            return ctx.onTouched();
          });
        }
      },
      inputs: {
        compareWith: "compareWith"
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([SELECT_VALUE_ACCESSOR])]
    });
    /** @nocollapse */

    SelectControlValueAccessor.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
      }];
    };

    SelectControlValueAccessor.propDecorators = {
      compareWith: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](SelectControlValueAccessor, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: 'select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]',
          host: {
            '(change)': 'onChange($event.target.value)',
            '(blur)': 'onTouched()'
          },
          providers: [SELECT_VALUE_ACCESSOR]
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
        }];
      }, {
        compareWith: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * \@description
     * Marks `<option>` as dynamic, so Angular can be notified when options change.
     *
     * @see `SelectControlValueAccessor`
     *
     * \@ngModule ReactiveFormsModule
     * \@ngModule FormsModule
     * \@publicApi
     */


    var NgSelectOption = /*#__PURE__*/function () {
      /**
       * @param {?} _element
       * @param {?} _renderer
       * @param {?} _select
       */
      function NgSelectOption(_element, _renderer, _select) {
        _classCallCheck(this, NgSelectOption);

        this._element = _element;
        this._renderer = _renderer;
        this._select = _select;
        if (this._select) this.id = this._select._registerOption();
      }
      /**
       * \@description
       * Tracks the value bound to the option element. Unlike the value binding,
       * ngValue supports binding to objects.
       * @param {?} value
       * @return {?}
       */


      _createClass2(NgSelectOption, [{
        key: "_setElementValue",

        /**
         * \@internal
         * @param {?} value
         * @return {?}
         */
        value: function _setElementValue(value) {
          this._renderer.setProperty(this._element.nativeElement, 'value', value);
        }
        /**
         * \@description
         * Lifecycle method called before the directive's instance is destroyed. For internal use only.
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          if (this._select) {
            this._select._optionMap["delete"](this.id);

            this._select.writeValue(this._select.value);
          }
        }
      }, {
        key: "ngValue",
        set: function set(value) {
          if (this._select == null) return;

          this._select._optionMap.set(this.id, value);

          this._setElementValue(_buildValueString(this.id, value));

          this._select.writeValue(this._select.value);
        }
        /**
         * \@description
         * Tracks simple string values bound to the option element.
         * For objects, use the `ngValue` input binding.
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "value",
        set: function set(value) {
          this._setElementValue(value);

          if (this._select) this._select.writeValue(this._select.value);
        }
      }]);

      return NgSelectOption;
    }();

    NgSelectOption.ɵfac = function NgSelectOption_Factory(t) {
      return new (t || NgSelectOption)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](SelectControlValueAccessor, 9));
    };

    NgSelectOption.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: NgSelectOption,
      selectors: [["option"]],
      inputs: {
        ngValue: "ngValue",
        value: "value"
      }
    });
    /** @nocollapse */

    NgSelectOption.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
      }, {
        type: SelectControlValueAccessor,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"]
        }]
      }];
    };

    NgSelectOption.propDecorators = {
      ngValue: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['ngValue']
      }],
      value: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['value']
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NgSelectOption, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: 'option'
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
        }, {
          type: SelectControlValueAccessor,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"]
          }]
        }];
      }, {
        ngValue: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['ngValue']
        }],
        value: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['value']
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/select_multiple_control_value_accessor.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var SELECT_MULTIPLE_VALUE_ACCESSOR = {
      provide: NG_VALUE_ACCESSOR,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return SelectMultipleControlValueAccessor;
      }),
      multi: true
    };
    /**
     * @param {?} id
     * @param {?} value
     * @return {?}
     */

    function _buildValueString$1(id, value) {
      if (id == null) return "".concat(value);
      if (typeof value === 'string') value = "'".concat(value, "'");
      if (value && typeof value === 'object') value = 'Object';
      return "".concat(id, ": ").concat(value).slice(0, 50);
    }
    /**
     * @param {?} valueString
     * @return {?}
     */


    function _extractId$1(valueString) {
      return valueString.split(':')[0];
    }
    /**
     * Mock interface for HTML Options
     * @record
     */


    function HTMLOption() {}

    if (false) {}
    /**
     * Mock interface for HTMLCollection
     * @abstract
     */


    var HTMLCollection = function HTMLCollection() {
      _classCallCheck(this, HTMLCollection);
    };

    if (false) {}
    /**
     * \@description
     * The `ControlValueAccessor` for writing multi-select control values and listening to multi-select
     * control changes. The value accessor is used by the `FormControlDirective`, `FormControlName`, and
     * `NgModel` directives.
     *
     * @see `SelectControlValueAccessor`
     *
     * \@usageNotes
     *
     * ### Using a multi-select control
     *
     * The follow example shows you how to use a multi-select control with a reactive form.
     *
     * ```ts
     * const countryControl = new FormControl();
     * ```
     *
     * ```
     * <select multiple name="countries" [formControl]="countryControl">
     *   <option *ngFor="let country of countries" [ngValue]="country">
     *     {{ country.name }}
     *   </option>
     * </select>
     * ```
     *
     * ### Customizing option selection
     *
     * To customize the default option comparison algorithm, `<select>` supports `compareWith` input.
     * See the `SelectControlValueAccessor` for usage.
     *
     * \@ngModule ReactiveFormsModule
     * \@ngModule FormsModule
     * \@publicApi
     */


    var SelectMultipleControlValueAccessor = /*#__PURE__*/function () {
      /**
       * @param {?} _renderer
       * @param {?} _elementRef
       */
      function SelectMultipleControlValueAccessor(_renderer, _elementRef) {
        _classCallCheck(this, SelectMultipleControlValueAccessor);

        this._renderer = _renderer;
        this._elementRef = _elementRef;
        /**
         * \@internal
         */

        this._optionMap = new Map();
        /**
         * \@internal
         */

        this._idCounter = 0;
        /**
         * \@description
         * The registered callback function called when a change event occurs on the input element.
         */

        this.onChange =
        /**
        * @param {?} _
        * @return {?}
        */
        function (_) {};
        /**
         * \@description
         * The registered callback function called when a blur event occurs on the input element.
         */


        this.onTouched =
        /**
        * @return {?}
        */
        function () {};

        this._compareWith = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵlooseIdentical"];
      }
      /**
       * \@description
       * Tracks the option comparison algorithm for tracking identities when
       * checking for changes.
       * @param {?} fn
       * @return {?}
       */


      _createClass2(SelectMultipleControlValueAccessor, [{
        key: "writeValue",

        /**
         * \@description
         * Sets the "value" property on one or of more
         * of the select's options.
         *
         * @param {?} value The value
         * @return {?}
         */
        value: function writeValue(value) {
          var _this188 = this;

          this.value = value;
          /** @type {?} */

          var optionSelectedStateSetter;

          if (Array.isArray(value)) {
            // convert values to ids

            /** @type {?} */
            var ids = value.map(
            /**
            * @param {?} v
            * @return {?}
            */
            function (v) {
              return _this188._getOptionId(v);
            });

            optionSelectedStateSetter =
            /**
            * @param {?} opt
            * @param {?} o
            * @return {?}
            */
            function optionSelectedStateSetter(opt, o) {
              opt._setSelected(ids.indexOf(o.toString()) > -1);
            };
          } else {
            optionSelectedStateSetter =
            /**
            * @param {?} opt
            * @param {?} o
            * @return {?}
            */
            function optionSelectedStateSetter(opt, o) {
              opt._setSelected(false);
            };
          }

          this._optionMap.forEach(optionSelectedStateSetter);
        }
        /**
         * \@description
         * Registers a function called when the control value changes
         * and writes an array of the selected options.
         *
         * @param {?} fn The callback function
         * @return {?}
         */

      }, {
        key: "registerOnChange",
        value: function registerOnChange(fn) {
          var _this189 = this;

          this.onChange =
          /**
          * @param {?} _
          * @return {?}
          */
          function (_) {
            /** @type {?} */
            var selected = [];

            if (_.hasOwnProperty('selectedOptions')) {
              /** @type {?} */
              var options = _.selectedOptions;

              for (var i = 0; i < options.length; i++) {
                /** @type {?} */
                var opt = options.item(i);
                /** @type {?} */

                var val = _this189._getOptionValue(opt.value);

                selected.push(val);
              }
            } // Degrade on IE
            else {
                /** @type {?} */
                var _options2 =
                /** @type {?} */
                _.options;

                for (var _i27 = 0; _i27 < _options2.length; _i27++) {
                  /** @type {?} */
                  var _opt = _options2.item(_i27);

                  if (_opt.selected) {
                    /** @type {?} */
                    var _val = _this189._getOptionValue(_opt.value);

                    selected.push(_val);
                  }
                }
              }

            _this189.value = selected;
            fn(selected);
          };
        }
        /**
         * \@description
         * Registers a function called when the control is touched.
         *
         * @param {?} fn The callback function
         * @return {?}
         */

      }, {
        key: "registerOnTouched",
        value: function registerOnTouched(fn) {
          this.onTouched = fn;
        }
        /**
         * Sets the "disabled" property on the select input element.
         *
         * @param {?} isDisabled The disabled value
         * @return {?}
         */

      }, {
        key: "setDisabledState",
        value: function setDisabledState(isDisabled) {
          this._renderer.setProperty(this._elementRef.nativeElement, 'disabled', isDisabled);
        }
        /**
         * \@internal
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "_registerOption",
        value: function _registerOption(value) {
          /** @type {?} */
          var id = (this._idCounter++).toString();

          this._optionMap.set(id, value);

          return id;
        }
        /**
         * \@internal
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "_getOptionId",
        value: function _getOptionId(value) {
          for (var _i28 = 0, _Array$from2 = Array.from(this._optionMap.keys()); _i28 < _Array$from2.length; _i28++) {
            var id = _Array$from2[_i28];
            if (this._compareWith(
            /** @type {?} */
            this._optionMap.get(id)._value, value)) return id;
          }

          return null;
        }
        /**
         * \@internal
         * @param {?} valueString
         * @return {?}
         */

      }, {
        key: "_getOptionValue",
        value: function _getOptionValue(valueString) {
          /** @type {?} */
          var id = _extractId$1(valueString);

          return this._optionMap.has(id) ?
          /** @type {?} */
          this._optionMap.get(id)._value : valueString;
        }
      }, {
        key: "compareWith",
        set: function set(fn) {
          if (typeof fn !== 'function') {
            throw new Error("compareWith must be a function, but received ".concat(JSON.stringify(fn)));
          }

          this._compareWith = fn;
        }
      }]);

      return SelectMultipleControlValueAccessor;
    }();

    SelectMultipleControlValueAccessor.ɵfac = function SelectMultipleControlValueAccessor_Factory(t) {
      return new (t || SelectMultipleControlValueAccessor)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]));
    };

    SelectMultipleControlValueAccessor.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: SelectMultipleControlValueAccessor,
      selectors: [["select", "multiple", "", "formControlName", ""], ["select", "multiple", "", "formControl", ""], ["select", "multiple", "", "ngModel", ""]],
      hostBindings: function SelectMultipleControlValueAccessor_HostBindings(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵlistener"]("change", function SelectMultipleControlValueAccessor_change_HostBindingHandler($event) {
            return ctx.onChange($event.target);
          })("blur", function SelectMultipleControlValueAccessor_blur_HostBindingHandler() {
            return ctx.onTouched();
          });
        }
      },
      inputs: {
        compareWith: "compareWith"
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([SELECT_MULTIPLE_VALUE_ACCESSOR])]
    });
    /** @nocollapse */

    SelectMultipleControlValueAccessor.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
      }];
    };

    SelectMultipleControlValueAccessor.propDecorators = {
      compareWith: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](SelectMultipleControlValueAccessor, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: 'select[multiple][formControlName],select[multiple][formControl],select[multiple][ngModel]',
          host: {
            '(change)': 'onChange($event.target)',
            '(blur)': 'onTouched()'
          },
          providers: [SELECT_MULTIPLE_VALUE_ACCESSOR]
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
        }];
      }, {
        compareWith: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * \@description
     * Marks `<option>` as dynamic, so Angular can be notified when options change.
     *
     * @see `SelectMultipleControlValueAccessor`
     *
     * \@ngModule ReactiveFormsModule
     * \@ngModule FormsModule
     * \@publicApi
     */


    var ɵNgSelectMultipleOption = /*#__PURE__*/function () {
      /**
       * @param {?} _element
       * @param {?} _renderer
       * @param {?} _select
       */
      function ɵNgSelectMultipleOption(_element, _renderer, _select) {
        _classCallCheck(this, ɵNgSelectMultipleOption);

        this._element = _element;
        this._renderer = _renderer;
        this._select = _select;

        if (this._select) {
          this.id = this._select._registerOption(this);
        }
      }
      /**
       * \@description
       * Tracks the value bound to the option element. Unlike the value binding,
       * ngValue supports binding to objects.
       * @param {?} value
       * @return {?}
       */


      _createClass2(ɵNgSelectMultipleOption, [{
        key: "_setElementValue",

        /**
         * \@internal
         * @param {?} value
         * @return {?}
         */
        value: function _setElementValue(value) {
          this._renderer.setProperty(this._element.nativeElement, 'value', value);
        }
        /**
         * \@internal
         * @param {?} selected
         * @return {?}
         */

      }, {
        key: "_setSelected",
        value: function _setSelected(selected) {
          this._renderer.setProperty(this._element.nativeElement, 'selected', selected);
        }
        /**
         * \@description
         * Lifecycle method called before the directive's instance is destroyed. For internal use only.
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          if (this._select) {
            this._select._optionMap["delete"](this.id);

            this._select.writeValue(this._select.value);
          }
        }
      }, {
        key: "ngValue",
        set: function set(value) {
          if (this._select == null) return;
          this._value = value;

          this._setElementValue(_buildValueString$1(this.id, value));

          this._select.writeValue(this._select.value);
        }
        /**
         * \@description
         * Tracks simple string values bound to the option element.
         * For objects, use the `ngValue` input binding.
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "value",
        set: function set(value) {
          if (this._select) {
            this._value = value;

            this._setElementValue(_buildValueString$1(this.id, value));

            this._select.writeValue(this._select.value);
          } else {
            this._setElementValue(value);
          }
        }
      }]);

      return ɵNgSelectMultipleOption;
    }();

    ɵNgSelectMultipleOption.ɵfac = function ɵNgSelectMultipleOption_Factory(t) {
      return new (t || ɵNgSelectMultipleOption)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](SelectMultipleControlValueAccessor, 9));
    };

    ɵNgSelectMultipleOption.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: ɵNgSelectMultipleOption,
      selectors: [["option"]],
      inputs: {
        ngValue: "ngValue",
        value: "value"
      }
    });
    /** @nocollapse */

    ɵNgSelectMultipleOption.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
      }, {
        type: SelectMultipleControlValueAccessor,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"]
        }]
      }];
    };

    ɵNgSelectMultipleOption.propDecorators = {
      ngValue: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['ngValue']
      }],
      value: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['value']
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](ɵNgSelectMultipleOption, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: 'option'
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Renderer2"]
        }, {
          type: SelectMultipleControlValueAccessor,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"]
          }]
        }];
      }, {
        ngValue: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['ngValue']
        }],
        value: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['value']
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/shared.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} name
     * @param {?} parent
     * @return {?}
     */


    function controlPath(name, parent) {
      return [].concat(_toConsumableArray(
      /** @type {?} */
      parent.path), [
      /** @type {?} */
      name]);
    }
    /**
     * @param {?} control
     * @param {?} dir
     * @return {?}
     */


    function setUpControl(control, dir) {
      if (!control) _throwError(dir, 'Cannot find control with');
      if (!dir.valueAccessor) _throwError(dir, 'No value accessor for form control with');
      control.validator = Validators.compose([
      /** @type {?} */
      control.validator, dir.validator]);
      control.asyncValidator = Validators.composeAsync([
      /** @type {?} */
      control.asyncValidator, dir.asyncValidator]);

      /** @type {?} */
      dir.valueAccessor.writeValue(control.value);
      setUpViewChangePipeline(control, dir);
      setUpModelChangePipeline(control, dir);
      setUpBlurPipeline(control, dir);

      if (
      /** @type {?} */
      dir.valueAccessor.setDisabledState) {
        control.registerOnDisabledChange(
        /**
        * @param {?} isDisabled
        * @return {?}
        */
        function (isDisabled) {
          /** @type {?} */

          /** @type {?} */
          dir.valueAccessor.setDisabledState(isDisabled);
        });
      } // re-run validation when validator binding changes, e.g. minlength=3 -> minlength=4


      dir._rawValidators.forEach(
      /**
      * @param {?} validator
      * @return {?}
      */
      function (validator) {
        if (
        /** @type {?} */
        validator.registerOnValidatorChange)
        /** @type {?} */

        /** @type {?} */
        validator.registerOnValidatorChange(
        /**
        * @return {?}
        */
        function () {
          return control.updateValueAndValidity();
        });
      });

      dir._rawAsyncValidators.forEach(
      /**
      * @param {?} validator
      * @return {?}
      */
      function (validator) {
        if (
        /** @type {?} */
        validator.registerOnValidatorChange)
        /** @type {?} */

        /** @type {?} */
        validator.registerOnValidatorChange(
        /**
        * @return {?}
        */
        function () {
          return control.updateValueAndValidity();
        });
      });
    }
    /**
     * @param {?} control
     * @param {?} dir
     * @return {?}
     */


    function cleanUpControl(control, dir) {
      /** @type {?} */
      dir.valueAccessor.registerOnChange(
      /**
      * @return {?}
      */
      function () {
        return _noControlError(dir);
      });

      /** @type {?} */
      dir.valueAccessor.registerOnTouched(
      /**
      * @return {?}
      */
      function () {
        return _noControlError(dir);
      });

      dir._rawValidators.forEach(
      /**
      * @param {?} validator
      * @return {?}
      */
      function (validator) {
        if (validator.registerOnValidatorChange) {
          validator.registerOnValidatorChange(null);
        }
      });

      dir._rawAsyncValidators.forEach(
      /**
      * @param {?} validator
      * @return {?}
      */
      function (validator) {
        if (validator.registerOnValidatorChange) {
          validator.registerOnValidatorChange(null);
        }
      });

      if (control) control._clearChangeFns();
    }
    /**
     * @param {?} control
     * @param {?} dir
     * @return {?}
     */


    function setUpViewChangePipeline(control, dir) {
      /** @type {?} */
      dir.valueAccessor.registerOnChange(
      /**
      * @param {?} newValue
      * @return {?}
      */
      function (newValue) {
        control._pendingValue = newValue;
        control._pendingChange = true;
        control._pendingDirty = true;
        if (control.updateOn === 'change') updateControl(control, dir);
      });
    }
    /**
     * @param {?} control
     * @param {?} dir
     * @return {?}
     */


    function setUpBlurPipeline(control, dir) {
      /** @type {?} */
      dir.valueAccessor.registerOnTouched(
      /**
      * @return {?}
      */
      function () {
        control._pendingTouched = true;
        if (control.updateOn === 'blur' && control._pendingChange) updateControl(control, dir);
        if (control.updateOn !== 'submit') control.markAsTouched();
      });
    }
    /**
     * @param {?} control
     * @param {?} dir
     * @return {?}
     */


    function updateControl(control, dir) {
      if (control._pendingDirty) control.markAsDirty();
      control.setValue(control._pendingValue, {
        emitModelToViewChange: false
      });
      dir.viewToModelUpdate(control._pendingValue);
      control._pendingChange = false;
    }
    /**
     * @param {?} control
     * @param {?} dir
     * @return {?}
     */


    function setUpModelChangePipeline(control, dir) {
      control.registerOnChange(
      /**
      * @param {?} newValue
      * @param {?} emitModelEvent
      * @return {?}
      */
      function (newValue, emitModelEvent) {
        // control -> view

        /** @type {?} */
        dir.valueAccessor.writeValue(newValue); // control -> ngModel

        if (emitModelEvent) dir.viewToModelUpdate(newValue);
      });
    }
    /**
     * @param {?} control
     * @param {?} dir
     * @return {?}
     */


    function setUpFormContainer(control, dir) {
      if (control == null) _throwError(dir, 'Cannot find control with');
      control.validator = Validators.compose([control.validator, dir.validator]);
      control.asyncValidator = Validators.composeAsync([control.asyncValidator, dir.asyncValidator]);
    }
    /**
     * @param {?} dir
     * @return {?}
     */


    function _noControlError(dir) {
      return _throwError(dir, 'There is no FormControl instance attached to form control element with');
    }
    /**
     * @param {?} dir
     * @param {?} message
     * @return {?}
     */


    function _throwError(dir, message) {
      /** @type {?} */
      var messageEnd;

      if (
      /** @type {?} */
      dir.path.length > 1) {
        messageEnd = "path: '".concat(
        /** @type {?} */
        dir.path.join(' -> '), "'");
      } else if (
      /** @type {?} */
      dir.path[0]) {
        messageEnd = "name: '".concat(dir.path, "'");
      } else {
        messageEnd = 'unspecified name attribute';
      }

      throw new Error("".concat(message, " ").concat(messageEnd));
    }
    /**
     * @param {?} validators
     * @return {?}
     */


    function composeValidators(validators) {
      return validators != null ? Validators.compose(validators.map(normalizeValidator)) : null;
    }
    /**
     * @param {?} validators
     * @return {?}
     */


    function composeAsyncValidators(validators) {
      return validators != null ? Validators.composeAsync(validators.map(normalizeAsyncValidator)) : null;
    }
    /**
     * @param {?} changes
     * @param {?} viewModel
     * @return {?}
     */


    function isPropertyUpdated(changes, viewModel) {
      if (!changes.hasOwnProperty('model')) return false;
      /** @type {?} */

      var change = changes['model'];
      if (change.isFirstChange()) return true;
      return !Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵlooseIdentical"])(viewModel, change.currentValue);
    }
    /** @type {?} */


    var BUILTIN_ACCESSORS = [CheckboxControlValueAccessor, RangeValueAccessor, NumberValueAccessor, SelectControlValueAccessor, SelectMultipleControlValueAccessor, RadioControlValueAccessor];
    /**
     * @param {?} valueAccessor
     * @return {?}
     */

    function isBuiltInAccessor(valueAccessor) {
      return BUILTIN_ACCESSORS.some(
      /**
      * @param {?} a
      * @return {?}
      */
      function (a) {
        return valueAccessor.constructor === a;
      });
    }
    /**
     * @param {?} form
     * @param {?} directives
     * @return {?}
     */


    function syncPendingControls(form, directives) {
      form._syncPendingControls();

      directives.forEach(
      /**
      * @param {?} dir
      * @return {?}
      */
      function (dir) {
        /** @type {?} */
        var control =
        /** @type {?} */
        dir.control;

        if (control.updateOn === 'submit' && control._pendingChange) {
          dir.viewToModelUpdate(control._pendingValue);
          control._pendingChange = false;
        }
      });
    } // TODO: vsavkin remove it once https://github.com/angular/angular/issues/3011 is implemented

    /**
     * @param {?} dir
     * @param {?} valueAccessors
     * @return {?}
     */


    function selectValueAccessor(dir, valueAccessors) {
      if (!valueAccessors) return null;
      if (!Array.isArray(valueAccessors)) _throwError(dir, 'Value accessor was not provided as an array for form control with');
      /** @type {?} */

      var defaultAccessor = undefined;
      /** @type {?} */

      var builtinAccessor = undefined;
      /** @type {?} */

      var customAccessor = undefined;
      valueAccessors.forEach(
      /**
      * @param {?} v
      * @return {?}
      */
      function (v) {
        if (v.constructor === DefaultValueAccessor) {
          defaultAccessor = v;
        } else if (isBuiltInAccessor(v)) {
          if (builtinAccessor) _throwError(dir, 'More than one built-in value accessor matches form control with');
          builtinAccessor = v;
        } else {
          if (customAccessor) _throwError(dir, 'More than one custom value accessor matches form control with');
          customAccessor = v;
        }
      });
      if (customAccessor) return customAccessor;
      if (builtinAccessor) return builtinAccessor;
      if (defaultAccessor) return defaultAccessor;

      _throwError(dir, 'No valid value accessor for form control with');

      return null;
    }
    /**
     * @template T
     * @param {?} list
     * @param {?} el
     * @return {?}
     */


    function removeDir(list, el) {
      /** @type {?} */
      var index = list.indexOf(el);
      if (index > -1) list.splice(index, 1);
    } // TODO(kara): remove after deprecation period

    /**
     * @param {?} name
     * @param {?} type
     * @param {?} instance
     * @param {?} warningConfig
     * @return {?}
     */


    function _ngModelWarning(name, type, instance, warningConfig) {
      if (!Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["isDevMode"])() || warningConfig === 'never') return;

      if ((warningConfig === null || warningConfig === 'once') && !type._ngModelWarningSentOnce || warningConfig === 'always' && !instance._ngModelWarningSent) {
        ReactiveErrors.ngModelWarning(name);
        type._ngModelWarningSentOnce = true;
        instance._ngModelWarningSent = true;
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/model.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Reports that a FormControl is valid, meaning that no errors exist in the input value.
     *
     * @see `status`
     * @type {?}
     */


    var VALID = 'VALID';
    /**
     * Reports that a FormControl is invalid, meaning that an error exists in the input value.
     *
     * @see `status`
     * @type {?}
     */

    var INVALID = 'INVALID';
    /**
     * Reports that a FormControl is pending, meaning that that async validation is occurring and
     * errors are not yet available for the input value.
     *
     * @see `markAsPending`
     * @see `status`
     * @type {?}
     */

    var PENDING = 'PENDING';
    /**
     * Reports that a FormControl is disabled, meaning that the control is exempt from ancestor
     * calculations of validity or value.
     *
     * @see `markAsDisabled`
     * @see `status`
     * @type {?}
     */

    var DISABLED = 'DISABLED';
    /**
     * @param {?} control
     * @param {?} path
     * @param {?} delimiter
     * @return {?}
     */

    function _find(control, path, delimiter) {
      if (path == null) return null;

      if (!Array.isArray(path)) {
        path = path.split(delimiter);
      }

      if (Array.isArray(path) && path.length === 0) return null; // Not using Array.reduce here due to a Chrome 80 bug
      // https://bugs.chromium.org/p/chromium/issues/detail?id=1049982

      /** @type {?} */

      var controlToFind = control;
      path.forEach(
      /**
      * @param {?} name
      * @return {?}
      */
      function (name) {
        if (controlToFind instanceof FormGroup) {
          controlToFind = controlToFind.controls.hasOwnProperty(
          /** @type {?} */
          name) ? controlToFind.controls[name] : null;
        } else if (controlToFind instanceof FormArray) {
          controlToFind = controlToFind.at(
          /** @type {?} */
          name) || null;
        } else {
          controlToFind = null;
        }
      });
      return controlToFind;
    }
    /**
     * @param {?=} validatorOrOpts
     * @return {?}
     */


    function coerceToValidator(validatorOrOpts) {
      /** @type {?} */
      var validator =
      /** @type {?} */
      isOptionsObj(validatorOrOpts) ?
      /** @type {?} */
      validatorOrOpts.validators : validatorOrOpts;
      return Array.isArray(validator) ? composeValidators(validator) : validator || null;
    }
    /**
     * @param {?=} asyncValidator
     * @param {?=} validatorOrOpts
     * @return {?}
     */


    function coerceToAsyncValidator(asyncValidator, validatorOrOpts) {
      /** @type {?} */
      var origAsyncValidator =
      /** @type {?} */
      isOptionsObj(validatorOrOpts) ?
      /** @type {?} */
      validatorOrOpts.asyncValidators : asyncValidator;
      return Array.isArray(origAsyncValidator) ? composeAsyncValidators(origAsyncValidator) : origAsyncValidator || null;
    }
    /**
     * Interface for options provided to an `AbstractControl`.
     *
     * \@publicApi
     * @record
     */


    function AbstractControlOptions() {}

    if (false) {}
    /**
     * @param {?=} validatorOrOpts
     * @return {?}
     */


    function isOptionsObj(validatorOrOpts) {
      return validatorOrOpts != null && !Array.isArray(validatorOrOpts) && typeof validatorOrOpts === 'object';
    }
    /**
     * This is the base class for `FormControl`, `FormGroup`, and `FormArray`.
     *
     * It provides some of the shared behavior that all controls and groups of controls have, like
     * running validators, calculating status, and resetting state. It also defines the properties
     * that are shared between all sub-classes, like `value`, `valid`, and `dirty`. It shouldn't be
     * instantiated directly.
     *
     * @see [Forms Guide](/guide/forms)
     * @see [Reactive Forms Guide](/guide/reactive-forms)
     * @see [Dynamic Forms Guide](/guide/dynamic-form)
     *
     * \@publicApi
     * @abstract
     */


    var AbstractControl = /*#__PURE__*/function () {
      /**
       * Initialize the AbstractControl instance.
       *
       * @param {?} validator The function that determines the synchronous validity of this control.
       * @param {?} asyncValidator The function that determines the asynchronous validity of this
       * control.
       */
      function AbstractControl(validator, asyncValidator) {
        _classCallCheck(this, AbstractControl);

        this.validator = validator;
        this.asyncValidator = asyncValidator;
        /**
         * \@internal
         */

        this._onCollectionChange =
        /**
        * @return {?}
        */
        function () {};
        /**
         * A control is `pristine` if the user has not yet changed
         * the value in the UI.
         *
         * @return True if the user has not yet changed the value in the UI; compare `dirty`.
         * Programmatic changes to a control's value do not mark it dirty.
         */


        this.pristine = true;
        /**
         * True if the control is marked as `touched`.
         *
         * A control is marked `touched` once the user has triggered
         * a `blur` event on it.
         */

        this.touched = false;
        /**
         * \@internal
         */

        this._onDisabledChange = [];
      }
      /**
       * The parent control.
       * @return {?}
       */


      _createClass2(AbstractControl, [{
        key: "setValidators",

        /**
         * Sets the synchronous validators that are active on this control.  Calling
         * this overwrites any existing sync validators.
         *
         * When you add or remove a validator at run time, you must call
         * `updateValueAndValidity()` for the new validation to take effect.
         *
         * @param {?} newValidator
         * @return {?}
         */
        value: function setValidators(newValidator) {
          this.validator = coerceToValidator(newValidator);
        }
        /**
         * Sets the async validators that are active on this control. Calling this
         * overwrites any existing async validators.
         *
         * When you add or remove a validator at run time, you must call
         * `updateValueAndValidity()` for the new validation to take effect.
         *
         * @param {?} newValidator
         * @return {?}
         */

      }, {
        key: "setAsyncValidators",
        value: function setAsyncValidators(newValidator) {
          this.asyncValidator = coerceToAsyncValidator(newValidator);
        }
        /**
         * Empties out the sync validator list.
         *
         * When you add or remove a validator at run time, you must call
         * `updateValueAndValidity()` for the new validation to take effect.
         *
         * @return {?}
         */

      }, {
        key: "clearValidators",
        value: function clearValidators() {
          this.validator = null;
        }
        /**
         * Empties out the async validator list.
         *
         * When you add or remove a validator at run time, you must call
         * `updateValueAndValidity()` for the new validation to take effect.
         *
         * @return {?}
         */

      }, {
        key: "clearAsyncValidators",
        value: function clearAsyncValidators() {
          this.asyncValidator = null;
        }
        /**
         * Marks the control as `touched`. A control is touched by focus and
         * blur events that do not change the value.
         *
         * @see `markAsUntouched()` / `markAsDirty()` / `markAsPristine()`
         *
         * @param {?=} opts Configuration options that determine how the control propagates changes
         * and emits events after marking is applied.
         * * `onlySelf`: When true, mark only this control. When false or not supplied,
         * marks all direct ancestors. Default is false.
         * @return {?}
         */

      }, {
        key: "markAsTouched",
        value: function markAsTouched() {
          var opts = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};

          /** @type {?} */
          this.touched = true;

          if (this._parent && !opts.onlySelf) {
            this._parent.markAsTouched(opts);
          }
        }
        /**
         * Marks the control and all its descendant controls as `touched`.
         * @see `markAsTouched()`
         * @return {?}
         */

      }, {
        key: "markAllAsTouched",
        value: function markAllAsTouched() {
          this.markAsTouched({
            onlySelf: true
          });

          this._forEachChild(
          /**
          * @param {?} control
          * @return {?}
          */
          function (control) {
            return control.markAllAsTouched();
          });
        }
        /**
         * Marks the control as `untouched`.
         *
         * If the control has any children, also marks all children as `untouched`
         * and recalculates the `touched` status of all parent controls.
         *
         * @see `markAsTouched()` / `markAsDirty()` / `markAsPristine()`
         *
         * @param {?=} opts Configuration options that determine how the control propagates changes
         * and emits events after the marking is applied.
         * * `onlySelf`: When true, mark only this control. When false or not supplied,
         * marks all direct ancestors. Default is false.
         * @return {?}
         */

      }, {
        key: "markAsUntouched",
        value: function markAsUntouched() {
          var opts = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};

          /** @type {?} */
          this.touched = false;
          this._pendingTouched = false;

          this._forEachChild(
          /**
          * @param {?} control
          * @return {?}
          */
          function (control) {
            control.markAsUntouched({
              onlySelf: true
            });
          });

          if (this._parent && !opts.onlySelf) {
            this._parent._updateTouched(opts);
          }
        }
        /**
         * Marks the control as `dirty`. A control becomes dirty when
         * the control's value is changed through the UI; compare `markAsTouched`.
         *
         * @see `markAsTouched()` / `markAsUntouched()` / `markAsPristine()`
         *
         * @param {?=} opts Configuration options that determine how the control propagates changes
         * and emits events after marking is applied.
         * * `onlySelf`: When true, mark only this control. When false or not supplied,
         * marks all direct ancestors. Default is false.
         * @return {?}
         */

      }, {
        key: "markAsDirty",
        value: function markAsDirty() {
          var opts = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};

          /** @type {?} */
          this.pristine = false;

          if (this._parent && !opts.onlySelf) {
            this._parent.markAsDirty(opts);
          }
        }
        /**
         * Marks the control as `pristine`.
         *
         * If the control has any children, marks all children as `pristine`,
         * and recalculates the `pristine` status of all parent
         * controls.
         *
         * @see `markAsTouched()` / `markAsUntouched()` / `markAsDirty()`
         *
         * @param {?=} opts Configuration options that determine how the control emits events after
         * marking is applied.
         * * `onlySelf`: When true, mark only this control. When false or not supplied,
         * marks all direct ancestors. Default is false.
         * @return {?}
         */

      }, {
        key: "markAsPristine",
        value: function markAsPristine() {
          var opts = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};

          /** @type {?} */
          this.pristine = true;
          this._pendingDirty = false;

          this._forEachChild(
          /**
          * @param {?} control
          * @return {?}
          */
          function (control) {
            control.markAsPristine({
              onlySelf: true
            });
          });

          if (this._parent && !opts.onlySelf) {
            this._parent._updatePristine(opts);
          }
        }
        /**
         * Marks the control as `pending`.
         *
         * A control is pending while the control performs async validation.
         *
         * @see {\@link AbstractControl.status}
         *
         * @param {?=} opts Configuration options that determine how the control propagates changes and
         * emits events after marking is applied.
         * * `onlySelf`: When true, mark only this control. When false or not supplied,
         * marks all direct ancestors. Default is false.
         * * `emitEvent`: When true or not supplied (the default), the `statusChanges`
         * observable emits an event with the latest status the control is marked pending.
         * When false, no events are emitted.
         *
         * @return {?}
         */

      }, {
        key: "markAsPending",
        value: function markAsPending() {
          var opts = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};

          /** @type {?} */
          this.status = PENDING;

          if (opts.emitEvent !== false) {
            /** @type {?} */
            this.statusChanges.emit(this.status);
          }

          if (this._parent && !opts.onlySelf) {
            this._parent.markAsPending(opts);
          }
        }
        /**
         * Disables the control. This means the control is exempt from validation checks and
         * excluded from the aggregate value of any parent. Its status is `DISABLED`.
         *
         * If the control has children, all children are also disabled.
         *
         * @see {\@link AbstractControl.status}
         *
         * @param {?=} opts Configuration options that determine how the control propagates
         * changes and emits events after the control is disabled.
         * * `onlySelf`: When true, mark only this control. When false or not supplied,
         * marks all direct ancestors. Default is false.
         * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
         * `valueChanges`
         * observables emit events with the latest status and value when the control is disabled.
         * When false, no events are emitted.
         * @return {?}
         */

      }, {
        key: "disable",
        value: function disable() {
          var opts = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};

          // If parent has been marked artificially dirty we don't want to re-calculate the
          // parent's dirtiness based on the children.

          /** @type {?} */
          var skipPristineCheck = this._parentMarkedDirty(opts.onlySelf);

          /** @type {?} */
          this.status = DISABLED;

          /** @type {?} */
          this.errors = null;

          this._forEachChild(
          /**
          * @param {?} control
          * @return {?}
          */
          function (control) {
            control.disable(Object.assign(Object.assign({}, opts), {
              onlySelf: true
            }));
          });

          this._updateValue();

          if (opts.emitEvent !== false) {
            /** @type {?} */
            this.valueChanges.emit(this.value);

            /** @type {?} */
            this.statusChanges.emit(this.status);
          }

          this._updateAncestors(Object.assign(Object.assign({}, opts), {
            skipPristineCheck: skipPristineCheck
          }));

          this._onDisabledChange.forEach(
          /**
          * @param {?} changeFn
          * @return {?}
          */
          function (changeFn) {
            return changeFn(true);
          });
        }
        /**
         * Enables the control. This means the control is included in validation checks and
         * the aggregate value of its parent. Its status recalculates based on its value and
         * its validators.
         *
         * By default, if the control has children, all children are enabled.
         *
         * @see {\@link AbstractControl.status}
         *
         * @param {?=} opts Configure options that control how the control propagates changes and
         * emits events when marked as untouched
         * * `onlySelf`: When true, mark only this control. When false or not supplied,
         * marks all direct ancestors. Default is false.
         * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
         * `valueChanges`
         * observables emit events with the latest status and value when the control is enabled.
         * When false, no events are emitted.
         * @return {?}
         */

      }, {
        key: "enable",
        value: function enable() {
          var opts = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};

          // If parent has been marked artificially dirty we don't want to re-calculate the
          // parent's dirtiness based on the children.

          /** @type {?} */
          var skipPristineCheck = this._parentMarkedDirty(opts.onlySelf);

          /** @type {?} */
          this.status = VALID;

          this._forEachChild(
          /**
          * @param {?} control
          * @return {?}
          */
          function (control) {
            control.enable(Object.assign(Object.assign({}, opts), {
              onlySelf: true
            }));
          });

          this.updateValueAndValidity({
            onlySelf: true,
            emitEvent: opts.emitEvent
          });

          this._updateAncestors(Object.assign(Object.assign({}, opts), {
            skipPristineCheck: skipPristineCheck
          }));

          this._onDisabledChange.forEach(
          /**
          * @param {?} changeFn
          * @return {?}
          */
          function (changeFn) {
            return changeFn(false);
          });
        }
        /**
         * @private
         * @param {?} opts
         * @return {?}
         */

      }, {
        key: "_updateAncestors",
        value: function _updateAncestors(opts) {
          if (this._parent && !opts.onlySelf) {
            this._parent.updateValueAndValidity(opts);

            if (!opts.skipPristineCheck) {
              this._parent._updatePristine();
            }

            this._parent._updateTouched();
          }
        }
        /**
         * @param {?} parent Sets the parent of the control
         * @return {?}
         */

      }, {
        key: "setParent",
        value: function setParent(parent) {
          this._parent = parent;
        }
        /**
         * Recalculates the value and validation status of the control.
         *
         * By default, it also updates the value and validity of its ancestors.
         *
         * @param {?=} opts Configuration options determine how the control propagates changes and emits events
         * after updates and validity checks are applied.
         * * `onlySelf`: When true, only update this control. When false or not supplied,
         * update all direct ancestors. Default is false.
         * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
         * `valueChanges`
         * observables emit events with the latest status and value when the control is updated.
         * When false, no events are emitted.
         * @return {?}
         */

      }, {
        key: "updateValueAndValidity",
        value: function updateValueAndValidity() {
          var opts = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};

          this._setInitialStatus();

          this._updateValue();

          if (this.enabled) {
            this._cancelExistingSubscription();

            /** @type {?} */
            this.errors = this._runValidator();

            /** @type {?} */
            this.status = this._calculateStatus();

            if (this.status === VALID || this.status === PENDING) {
              this._runAsyncValidator(opts.emitEvent);
            }
          }

          if (opts.emitEvent !== false) {
            /** @type {?} */
            this.valueChanges.emit(this.value);

            /** @type {?} */
            this.statusChanges.emit(this.status);
          }

          if (this._parent && !opts.onlySelf) {
            this._parent.updateValueAndValidity(opts);
          }
        }
        /**
         * \@internal
         * @param {?=} opts
         * @return {?}
         */

      }, {
        key: "_updateTreeValidity",
        value: function _updateTreeValidity() {
          var opts = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {
            emitEvent: true
          };

          this._forEachChild(
          /**
          * @param {?} ctrl
          * @return {?}
          */
          function (ctrl) {
            return ctrl._updateTreeValidity(opts);
          });

          this.updateValueAndValidity({
            onlySelf: true,
            emitEvent: opts.emitEvent
          });
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_setInitialStatus",
        value: function _setInitialStatus() {
          /** @type {?} */
          this.status = this._allControlsDisabled() ? DISABLED : VALID;
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_runValidator",
        value: function _runValidator() {
          return this.validator ? this.validator(this) : null;
        }
        /**
         * @private
         * @param {?=} emitEvent
         * @return {?}
         */

      }, {
        key: "_runAsyncValidator",
        value: function _runAsyncValidator(emitEvent) {
          var _this190 = this;

          if (this.asyncValidator) {
            /** @type {?} */
            this.status = PENDING;
            /** @type {?} */

            var obs = toObservable(this.asyncValidator(this));
            this._asyncValidationSubscription = obs.subscribe(
            /**
            * @param {?} errors
            * @return {?}
            */
            function (errors) {
              return _this190.setErrors(errors, {
                emitEvent: emitEvent
              });
            });
          }
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_cancelExistingSubscription",
        value: function _cancelExistingSubscription() {
          if (this._asyncValidationSubscription) {
            this._asyncValidationSubscription.unsubscribe();
          }
        }
        /**
         * Sets errors on a form control when running validations manually, rather than automatically.
         *
         * Calling `setErrors` also updates the validity of the parent control.
         *
         * \@usageNotes
         *
         * ### Manually set the errors for a control
         *
         * ```
         * const login = new FormControl('someLogin');
         * login.setErrors({
         *   notUnique: true
         * });
         *
         * expect(login.valid).toEqual(false);
         * expect(login.errors).toEqual({ notUnique: true });
         *
         * login.setValue('someOtherLogin');
         *
         * expect(login.valid).toEqual(true);
         * ```
         * @param {?} errors
         * @param {?=} opts
         * @return {?}
         */

      }, {
        key: "setErrors",
        value: function setErrors(errors) {
          var opts = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};

          /** @type {?} */
          this.errors = errors;

          this._updateControlsErrors(opts.emitEvent !== false);
        }
        /**
         * Retrieves a child control given the control's name or path.
         *
         * \@usageNotes
         * ### Retrieve a nested control
         *
         * For example, to get a `name` control nested within a `person` sub-group:
         *
         * * `this.form.get('person.name');`
         *
         * -OR-
         *
         * * `this.form.get(['person', 'name']);`
         * @param {?} path A dot-delimited string or array of string/number values that define the path to the
         * control.
         *
         * @return {?}
         */

      }, {
        key: "get",
        value: function get(path) {
          return _find(this, path, '.');
        }
        /**
         * \@description
         * Reports error data for the control with the given path.
         *
         * \@usageNotes
         * For example, for the following `FormGroup`:
         *
         * ```
         * form = new FormGroup({
         *   address: new FormGroup({ street: new FormControl() })
         * });
         * ```
         *
         * The path to the 'street' control from the root form would be 'address' -> 'street'.
         *
         * It can be provided to this method in one of two formats:
         *
         * 1. An array of string control names, e.g. `['address', 'street']`
         * 1. A period-delimited list of control names in one string, e.g. `'address.street'`
         *
         * @param {?} errorCode The code of the error to check
         * @param {?=} path A list of control names that designates how to move from the current control
         * to the control that should be queried for errors.
         *
         * @return {?} error data for that particular error. If the control or error is not present,
         * null is returned.
         */

      }, {
        key: "getError",
        value: function getError(errorCode, path) {
          /** @type {?} */
          var control = path ? this.get(path) : this;
          return control && control.errors ? control.errors[errorCode] : null;
        }
        /**
         * \@description
         * Reports whether the control with the given path has the error specified.
         *
         * \@usageNotes
         * For example, for the following `FormGroup`:
         *
         * ```
         * form = new FormGroup({
         *   address: new FormGroup({ street: new FormControl() })
         * });
         * ```
         *
         * The path to the 'street' control from the root form would be 'address' -> 'street'.
         *
         * It can be provided to this method in one of two formats:
         *
         * 1. An array of string control names, e.g. `['address', 'street']`
         * 1. A period-delimited list of control names in one string, e.g. `'address.street'`
         *
         * If no path is given, this method checks for the error on the current control.
         *
         * @param {?} errorCode The code of the error to check
         * @param {?=} path A list of control names that designates how to move from the current control
         * to the control that should be queried for errors.
         *
         * @return {?} whether the given error is present in the control at the given path.
         *
         * If the control is not present, false is returned.
         */

      }, {
        key: "hasError",
        value: function hasError(errorCode, path) {
          return !!this.getError(errorCode, path);
        }
        /**
         * Retrieves the top-level ancestor of this control.
         * @return {?}
         */

      }, {
        key: "_updateControlsErrors",

        /**
         * \@internal
         * @param {?} emitEvent
         * @return {?}
         */
        value: function _updateControlsErrors(emitEvent) {
          /** @type {?} */
          this.status = this._calculateStatus();

          if (emitEvent) {
            /** @type {?} */
            this.statusChanges.emit(this.status);
          }

          if (this._parent) {
            this._parent._updateControlsErrors(emitEvent);
          }
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_initObservables",
        value: function _initObservables() {
          /** @type {?} */
          this.valueChanges = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"]();

          /** @type {?} */
          this.statusChanges = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"]();
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_calculateStatus",
        value: function _calculateStatus() {
          if (this._allControlsDisabled()) return DISABLED;
          if (this.errors) return INVALID;
          if (this._anyControlsHaveStatus(PENDING)) return PENDING;
          if (this._anyControlsHaveStatus(INVALID)) return INVALID;
          return VALID;
        }
        /**
         * \@internal
         * @param {?} status
         * @return {?}
         */

      }, {
        key: "_anyControlsHaveStatus",
        value: function _anyControlsHaveStatus(status) {
          return this._anyControls(
          /**
          * @param {?} control
          * @return {?}
          */
          function (control) {
            return control.status === status;
          });
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_anyControlsDirty",
        value: function _anyControlsDirty() {
          return this._anyControls(
          /**
          * @param {?} control
          * @return {?}
          */
          function (control) {
            return control.dirty;
          });
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_anyControlsTouched",
        value: function _anyControlsTouched() {
          return this._anyControls(
          /**
          * @param {?} control
          * @return {?}
          */
          function (control) {
            return control.touched;
          });
        }
        /**
         * \@internal
         * @param {?=} opts
         * @return {?}
         */

      }, {
        key: "_updatePristine",
        value: function _updatePristine() {
          var opts = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};

          /** @type {?} */
          this.pristine = !this._anyControlsDirty();

          if (this._parent && !opts.onlySelf) {
            this._parent._updatePristine(opts);
          }
        }
        /**
         * \@internal
         * @param {?=} opts
         * @return {?}
         */

      }, {
        key: "_updateTouched",
        value: function _updateTouched() {
          var opts = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};

          /** @type {?} */
          this.touched = this._anyControlsTouched();

          if (this._parent && !opts.onlySelf) {
            this._parent._updateTouched(opts);
          }
        }
        /**
         * \@internal
         * @param {?} formState
         * @return {?}
         */

      }, {
        key: "_isBoxedValue",
        value: function _isBoxedValue(formState) {
          return typeof formState === 'object' && formState !== null && Object.keys(formState).length === 2 && 'value' in formState && 'disabled' in formState;
        }
        /**
         * \@internal
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "_registerOnCollectionChange",
        value: function _registerOnCollectionChange(fn) {
          this._onCollectionChange = fn;
        }
        /**
         * \@internal
         * @param {?=} opts
         * @return {?}
         */

      }, {
        key: "_setUpdateStrategy",
        value: function _setUpdateStrategy(opts) {
          if (isOptionsObj(opts) &&
          /** @type {?} */
          opts.updateOn != null) {
            this._updateOn =
            /** @type {?} */

            /** @type {?} */
            opts.updateOn;
          }
        }
        /**
         * Check to see if parent has been marked artificially dirty.
         *
         * \@internal
         * @private
         * @param {?=} onlySelf
         * @return {?}
         */

      }, {
        key: "_parentMarkedDirty",
        value: function _parentMarkedDirty(onlySelf) {
          /** @type {?} */
          var parentDirty = this._parent && this._parent.dirty;
          return !onlySelf && parentDirty && !this._parent._anyControlsDirty();
        }
      }, {
        key: "parent",
        get: function get() {
          return this._parent;
        }
        /**
         * A control is `valid` when its `status` is `VALID`.
         *
         * @see {\@link AbstractControl.status}
         *
         * @return {?} True if the control has passed all of its validation tests,
         * false otherwise.
         */

      }, {
        key: "valid",
        get: function get() {
          return this.status === VALID;
        }
        /**
         * A control is `invalid` when its `status` is `INVALID`.
         *
         * @see {\@link AbstractControl.status}
         *
         * @return {?} True if this control has failed one or more of its validation checks,
         * false otherwise.
         */

      }, {
        key: "invalid",
        get: function get() {
          return this.status === INVALID;
        }
        /**
         * A control is `pending` when its `status` is `PENDING`.
         *
         * @see {\@link AbstractControl.status}
         *
         * @return {?} True if this control is in the process of conducting a validation check,
         * false otherwise.
         */

      }, {
        key: "pending",
        get: function get() {
          return this.status == PENDING;
        }
        /**
         * A control is `disabled` when its `status` is `DISABLED`.
         *
         * Disabled controls are exempt from validation checks and
         * are not included in the aggregate value of their ancestor
         * controls.
         *
         * @see {\@link AbstractControl.status}
         *
         * @return {?} True if the control is disabled, false otherwise.
         */

      }, {
        key: "disabled",
        get: function get() {
          return this.status === DISABLED;
        }
        /**
         * A control is `enabled` as long as its `status` is not `DISABLED`.
         *
         * @see {\@link AbstractControl.status}
         *
         * @return {?} True if the control has any status other than 'DISABLED',
         * false if the status is 'DISABLED'.
         *
         */

      }, {
        key: "enabled",
        get: function get() {
          return this.status !== DISABLED;
        }
        /**
         * A control is `dirty` if the user has changed the value
         * in the UI.
         *
         * @return {?} True if the user has changed the value of this control in the UI; compare `pristine`.
         * Programmatic changes to a control's value do not mark it dirty.
         */

      }, {
        key: "dirty",
        get: function get() {
          return !this.pristine;
        }
        /**
         * True if the control has not been marked as touched
         *
         * A control is `untouched` if the user has not yet triggered
         * a `blur` event on it.
         * @return {?}
         */

      }, {
        key: "untouched",
        get: function get() {
          return !this.touched;
        }
        /**
         * Reports the update strategy of the `AbstractControl` (meaning
         * the event on which the control updates itself).
         * Possible values: `'change'` | `'blur'` | `'submit'`
         * Default value: `'change'`
         * @return {?}
         */

      }, {
        key: "updateOn",
        get: function get() {
          return this._updateOn ? this._updateOn : this.parent ? this.parent.updateOn : 'change';
        }
      }, {
        key: "root",
        get: function get() {
          /** @type {?} */
          var x = this;

          while (x._parent) {
            x = x._parent;
          }

          return x;
        }
      }]);

      return AbstractControl;
    }();

    if (false) {}
    /**
     * Tracks the value and validation status of an individual form control.
     *
     * This is one of the three fundamental building blocks of Angular forms, along with
     * `FormGroup` and `FormArray`. It extends the `AbstractControl` class that
     * implements most of the base functionality for accessing the value, validation status,
     * user interactions and events. See [usage examples below](#usage-notes).
     *
     * @see `AbstractControl`
     * @see [Reactive Forms Guide](guide/reactive-forms)
     * @see [Usage Notes](#usage-notes)
     *
     * \@usageNotes
     *
     * ### Initializing Form Controls
     *
     * Instantiate a `FormControl`, with an initial value.
     *
     * ```ts
     * const control = new FormControl('some value');
     * console.log(control.value);     // 'some value'
     * ```
     *
     * The following example initializes the control with a form state object. The `value`
     * and `disabled` keys are required in this case.
     *
     * ```ts
     * const control = new FormControl({ value: 'n/a', disabled: true });
     * console.log(control.value);     // 'n/a'
     * console.log(control.status);    // 'DISABLED'
     * ```
     *
     * The following example initializes the control with a sync validator.
     *
     * ```ts
     * const control = new FormControl('', Validators.required);
     * console.log(control.value);      // ''
     * console.log(control.status);     // 'INVALID'
     * ```
     *
     * The following example initializes the control using an options object.
     *
     * ```ts
     * const control = new FormControl('', {
     *    validators: Validators.required,
     *    asyncValidators: myAsyncValidator
     * });
     * ```
     *
     * ### Configure the control to update on a blur event
     *
     * Set the `updateOn` option to `'blur'` to update on the blur `event`.
     *
     * ```ts
     * const control = new FormControl('', { updateOn: 'blur' });
     * ```
     *
     * ### Configure the control to update on a submit event
     *
     * Set the `updateOn` option to `'submit'` to update on a submit `event`.
     *
     * ```ts
     * const control = new FormControl('', { updateOn: 'submit' });
     * ```
     *
     * ### Reset the control back to an initial value
     *
     * You reset to a specific form state by passing through a standalone
     * value or a form state object that contains both a value and a disabled state
     * (these are the only two properties that cannot be calculated).
     *
     * ```ts
     * const control = new FormControl('Nancy');
     *
     * console.log(control.value); // 'Nancy'
     *
     * control.reset('Drew');
     *
     * console.log(control.value); // 'Drew'
     * ```
     *
     * ### Reset the control back to an initial value and disabled
     *
     * ```
     * const control = new FormControl('Nancy');
     *
     * console.log(control.value); // 'Nancy'
     * console.log(control.status); // 'VALID'
     *
     * control.reset({ value: 'Drew', disabled: true });
     *
     * console.log(control.value); // 'Drew'
     * console.log(control.status); // 'DISABLED'
     * ```
     *
     * \@publicApi
     */


    var FormControl = /*#__PURE__*/function (_AbstractControl) {
      _inherits(FormControl, _AbstractControl);

      var _super55 = _createSuper(FormControl);

      /**
       * Creates a new `FormControl` instance.
       *
       * @param {?=} formState Initializes the control with an initial value,
       * or an object that defines the initial value and disabled state.
       *
       * @param {?=} validatorOrOpts A synchronous validator function, or an array of
       * such functions, or an `AbstractControlOptions` object that contains validation functions
       * and a validation trigger.
       *
       * @param {?=} asyncValidator A single async validator or array of async validator functions
       *
       */
      function FormControl() {
        var _this191;

        var formState = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
        var validatorOrOpts = arguments.length > 1 ? arguments[1] : undefined;
        var asyncValidator = arguments.length > 2 ? arguments[2] : undefined;

        _classCallCheck(this, FormControl);

        _this191 = _super55.call(this, coerceToValidator(validatorOrOpts), coerceToAsyncValidator(asyncValidator, validatorOrOpts));
        /**
         * \@internal
         */

        _this191._onChange = [];

        _this191._applyFormState(formState);

        _this191._setUpdateStrategy(validatorOrOpts);

        _this191.updateValueAndValidity({
          onlySelf: true,
          emitEvent: false
        });

        _this191._initObservables();

        return _this191;
      }
      /**
       * Sets a new value for the form control.
       *
       * @param {?} value The new value for the control.
       * @param {?=} options Configuration options that determine how the control propagates changes
       * and emits events when the value changes.
       * The configuration options are passed to the {\@link AbstractControl#updateValueAndValidity
       * updateValueAndValidity} method.
       *
       * * `onlySelf`: When true, each change only affects this control, and not its parent. Default is
       * false.
       * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
       * `valueChanges`
       * observables emit events with the latest status and value when the control value is updated.
       * When false, no events are emitted.
       * * `emitModelToViewChange`: When true or not supplied  (the default), each change triggers an
       * `onChange` event to
       * update the view.
       * * `emitViewToModelChange`: When true or not supplied (the default), each change triggers an
       * `ngModelChange`
       * event to update the model.
       *
       * @return {?}
       */


      _createClass2(FormControl, [{
        key: "setValue",
        value: function setValue(value) {
          var _this192 = this;

          var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};

          /** @type {?} */
          this.value = this._pendingValue = value;

          if (this._onChange.length && options.emitModelToViewChange !== false) {
            this._onChange.forEach(
            /**
            * @param {?} changeFn
            * @return {?}
            */
            function (changeFn) {
              return changeFn(_this192.value, options.emitViewToModelChange !== false);
            });
          }

          this.updateValueAndValidity(options);
        }
        /**
         * Patches the value of a control.
         *
         * This function is functionally the same as {\@link FormControl#setValue setValue} at this level.
         * It exists for symmetry with {\@link FormGroup#patchValue patchValue} on `FormGroups` and
         * `FormArrays`, where it does behave differently.
         *
         * @see `setValue` for options
         * @param {?} value
         * @param {?=} options
         * @return {?}
         */

      }, {
        key: "patchValue",
        value: function patchValue(value) {
          var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
          this.setValue(value, options);
        }
        /**
         * Resets the form control, marking it `pristine` and `untouched`, and setting
         * the value to null.
         *
         * @param {?=} formState Resets the control with an initial value,
         * or an object that defines the initial value and disabled state.
         *
         * @param {?=} options Configuration options that determine how the control propagates changes
         * and emits events after the value changes.
         *
         * * `onlySelf`: When true, each change only affects this control, and not its parent. Default is
         * false.
         * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
         * `valueChanges`
         * observables emit events with the latest status and value when the control is reset.
         * When false, no events are emitted.
         *
         * @return {?}
         */

      }, {
        key: "reset",
        value: function reset() {
          var formState = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
          var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};

          this._applyFormState(formState);

          this.markAsPristine(options);
          this.markAsUntouched(options);
          this.setValue(this.value, options);
          this._pendingChange = false;
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_updateValue",
        value: function _updateValue() {}
        /**
         * \@internal
         * @param {?} condition
         * @return {?}
         */

      }, {
        key: "_anyControls",
        value: function _anyControls(condition) {
          return false;
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_allControlsDisabled",
        value: function _allControlsDisabled() {
          return this.disabled;
        }
        /**
         * Register a listener for change events.
         *
         * @param {?} fn The method that is called when the value changes
         * @return {?}
         */

      }, {
        key: "registerOnChange",
        value: function registerOnChange(fn) {
          this._onChange.push(fn);
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_clearChangeFns",
        value: function _clearChangeFns() {
          this._onChange = [];
          this._onDisabledChange = [];

          this._onCollectionChange =
          /**
          * @return {?}
          */
          function () {};
        }
        /**
         * Register a listener for disabled events.
         *
         * @param {?} fn The method that is called when the disabled status changes.
         * @return {?}
         */

      }, {
        key: "registerOnDisabledChange",
        value: function registerOnDisabledChange(fn) {
          this._onDisabledChange.push(fn);
        }
        /**
         * \@internal
         * @param {?} cb
         * @return {?}
         */

      }, {
        key: "_forEachChild",
        value: function _forEachChild(cb) {}
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_syncPendingControls",
        value: function _syncPendingControls() {
          if (this.updateOn === 'submit') {
            if (this._pendingDirty) this.markAsDirty();
            if (this._pendingTouched) this.markAsTouched();

            if (this._pendingChange) {
              this.setValue(this._pendingValue, {
                onlySelf: true,
                emitModelToViewChange: false
              });
              return true;
            }
          }

          return false;
        }
        /**
         * @private
         * @param {?} formState
         * @return {?}
         */

      }, {
        key: "_applyFormState",
        value: function _applyFormState(formState) {
          if (this._isBoxedValue(formState)) {
            /** @type {?} */
            this.value = this._pendingValue = formState.value;
            formState.disabled ? this.disable({
              onlySelf: true,
              emitEvent: false
            }) : this.enable({
              onlySelf: true,
              emitEvent: false
            });
          } else {
            /** @type {?} */
            this.value = this._pendingValue = formState;
          }
        }
      }]);

      return FormControl;
    }(AbstractControl);

    if (false) {}
    /**
     * Tracks the value and validity state of a group of `FormControl` instances.
     *
     * A `FormGroup` aggregates the values of each child `FormControl` into one object,
     * with each control name as the key.  It calculates its status by reducing the status values
     * of its children. For example, if one of the controls in a group is invalid, the entire
     * group becomes invalid.
     *
     * `FormGroup` is one of the three fundamental building blocks used to define forms in Angular,
     * along with `FormControl` and `FormArray`.
     *
     * When instantiating a `FormGroup`, pass in a collection of child controls as the first
     * argument. The key for each child registers the name for the control.
     *
     * \@usageNotes
     *
     * ### Create a form group with 2 controls
     *
     * ```
     * const form = new FormGroup({
     *   first: new FormControl('Nancy', Validators.minLength(2)),
     *   last: new FormControl('Drew'),
     * });
     *
     * console.log(form.value);   // {first: 'Nancy', last; 'Drew'}
     * console.log(form.status);  // 'VALID'
     * ```
     *
     * ### Create a form group with a group-level validator
     *
     * You include group-level validators as the second arg, or group-level async
     * validators as the third arg. These come in handy when you want to perform validation
     * that considers the value of more than one child control.
     *
     * ```
     * const form = new FormGroup({
     *   password: new FormControl('', Validators.minLength(2)),
     *   passwordConfirm: new FormControl('', Validators.minLength(2)),
     * }, passwordMatchValidator);
     *
     *
     * function passwordMatchValidator(g: FormGroup) {
     *    return g.get('password').value === g.get('passwordConfirm').value
     *       ? null : {'mismatch': true};
     * }
     * ```
     *
     * Like `FormControl` instances, you choose to pass in
     * validators and async validators as part of an options object.
     *
     * ```
     * const form = new FormGroup({
     *   password: new FormControl('')
     *   passwordConfirm: new FormControl('')
     * }, { validators: passwordMatchValidator, asyncValidators: otherValidator });
     * ```
     *
     * ### Set the updateOn property for all controls in a form group
     *
     * The options object is used to set a default value for each child
     * control's `updateOn` property. If you set `updateOn` to `'blur'` at the
     * group level, all child controls default to 'blur', unless the child
     * has explicitly specified a different `updateOn` value.
     *
     * ```ts
     * const c = new FormGroup({
     *   one: new FormControl()
     * }, { updateOn: 'blur' });
     * ```
     *
     * \@publicApi
     */


    var FormGroup = /*#__PURE__*/function (_AbstractControl2) {
      _inherits(FormGroup, _AbstractControl2);

      var _super56 = _createSuper(FormGroup);

      /**
       * Creates a new `FormGroup` instance.
       *
       * @param {?} controls A collection of child controls. The key for each child is the name
       * under which it is registered.
       *
       * @param {?=} validatorOrOpts A synchronous validator function, or an array of
       * such functions, or an `AbstractControlOptions` object that contains validation functions
       * and a validation trigger.
       *
       * @param {?=} asyncValidator A single async validator or array of async validator functions
       *
       */
      function FormGroup(controls, validatorOrOpts, asyncValidator) {
        var _this193;

        _classCallCheck(this, FormGroup);

        _this193 = _super56.call(this, coerceToValidator(validatorOrOpts), coerceToAsyncValidator(asyncValidator, validatorOrOpts));
        _this193.controls = controls;

        _this193._initObservables();

        _this193._setUpdateStrategy(validatorOrOpts);

        _this193._setUpControls();

        _this193.updateValueAndValidity({
          onlySelf: true,
          emitEvent: false
        });

        return _this193;
      }
      /**
       * Registers a control with the group's list of controls.
       *
       * This method does not update the value or validity of the control.
       * Use {\@link FormGroup#addControl addControl} instead.
       *
       * @param {?} name The control name to register in the collection
       * @param {?} control Provides the control for the given name
       * @return {?}
       */


      _createClass2(FormGroup, [{
        key: "registerControl",
        value: function registerControl(name, control) {
          if (this.controls[name]) return this.controls[name];
          this.controls[name] = control;
          control.setParent(this);

          control._registerOnCollectionChange(this._onCollectionChange);

          return control;
        }
        /**
         * Add a control to this group.
         *
         * This method also updates the value and validity of the control.
         *
         * @param {?} name The control name to add to the collection
         * @param {?} control Provides the control for the given name
         * @return {?}
         */

      }, {
        key: "addControl",
        value: function addControl(name, control) {
          this.registerControl(name, control);
          this.updateValueAndValidity();

          this._onCollectionChange();
        }
        /**
         * Remove a control from this group.
         *
         * @param {?} name The control name to remove from the collection
         * @return {?}
         */

      }, {
        key: "removeControl",
        value: function removeControl(name) {
          if (this.controls[name]) this.controls[name]._registerOnCollectionChange(
          /**
          * @return {?}
          */
          function () {});
          delete this.controls[name];
          this.updateValueAndValidity();

          this._onCollectionChange();
        }
        /**
         * Replace an existing control.
         *
         * @param {?} name The control name to replace in the collection
         * @param {?} control Provides the control for the given name
         * @return {?}
         */

      }, {
        key: "setControl",
        value: function setControl(name, control) {
          if (this.controls[name]) this.controls[name]._registerOnCollectionChange(
          /**
          * @return {?}
          */
          function () {});
          delete this.controls[name];
          if (control) this.registerControl(name, control);
          this.updateValueAndValidity();

          this._onCollectionChange();
        }
        /**
         * Check whether there is an enabled control with the given name in the group.
         *
         * Reports false for disabled controls. If you'd like to check for existence in the group
         * only, use {\@link AbstractControl#get get} instead.
         *
         * @param {?} controlName The control name to check for existence in the collection
         *
         * @return {?} false for disabled controls, true otherwise.
         */

      }, {
        key: "contains",
        value: function contains(controlName) {
          return this.controls.hasOwnProperty(controlName) && this.controls[controlName].enabled;
        }
        /**
         * Sets the value of the `FormGroup`. It accepts an object that matches
         * the structure of the group, with control names as keys.
         *
         * \@usageNotes
         * ### Set the complete value for the form group
         *
         * ```
         * const form = new FormGroup({
         *   first: new FormControl(),
         *   last: new FormControl()
         * });
         *
         * console.log(form.value);   // {first: null, last: null}
         *
         * form.setValue({first: 'Nancy', last: 'Drew'});
         * console.log(form.value);   // {first: 'Nancy', last: 'Drew'}
         * ```
         *
         * @throws When strict checks fail, such as setting the value of a control
         * that doesn't exist or if you exclude a value of a control that does exist.
         *
         * @param {?} value The new value for the control that matches the structure of the group.
         * @param {?=} options Configuration options that determine how the control propagates changes
         * and emits events after the value changes.
         * The configuration options are passed to the {\@link AbstractControl#updateValueAndValidity
         * updateValueAndValidity} method.
         *
         * * `onlySelf`: When true, each change only affects this control, and not its parent. Default is
         * false.
         * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
         * `valueChanges`
         * observables emit events with the latest status and value when the control value is updated.
         * When false, no events are emitted.
         * @return {?}
         */

      }, {
        key: "setValue",
        value: function setValue(value) {
          var _this194 = this;

          var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};

          this._checkAllValuesPresent(value);

          Object.keys(value).forEach(
          /**
          * @param {?} name
          * @return {?}
          */
          function (name) {
            _this194._throwIfControlMissing(name);

            _this194.controls[name].setValue(value[name], {
              onlySelf: true,
              emitEvent: options.emitEvent
            });
          });
          this.updateValueAndValidity(options);
        }
        /**
         * Patches the value of the `FormGroup`. It accepts an object with control
         * names as keys, and does its best to match the values to the correct controls
         * in the group.
         *
         * It accepts both super-sets and sub-sets of the group without throwing an error.
         *
         * \@usageNotes
         * ### Patch the value for a form group
         *
         * ```
         * const form = new FormGroup({
         *    first: new FormControl(),
         *    last: new FormControl()
         * });
         * console.log(form.value);   // {first: null, last: null}
         *
         * form.patchValue({first: 'Nancy'});
         * console.log(form.value);   // {first: 'Nancy', last: null}
         * ```
         *
         * @param {?} value The object that matches the structure of the group.
         * @param {?=} options Configuration options that determine how the control propagates changes and
         * emits events after the value is patched.
         * * `onlySelf`: When true, each change only affects this control and not its parent. Default is
         * true.
         * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
         * `valueChanges`
         * observables emit events with the latest status and value when the control value is updated.
         * When false, no events are emitted.
         * The configuration options are passed to the {\@link AbstractControl#updateValueAndValidity
         * updateValueAndValidity} method.
         * @return {?}
         */

      }, {
        key: "patchValue",
        value: function patchValue(value) {
          var _this195 = this;

          var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
          Object.keys(value).forEach(
          /**
          * @param {?} name
          * @return {?}
          */
          function (name) {
            if (_this195.controls[name]) {
              _this195.controls[name].patchValue(value[name], {
                onlySelf: true,
                emitEvent: options.emitEvent
              });
            }
          });
          this.updateValueAndValidity(options);
        }
        /**
         * Resets the `FormGroup`, marks all descendants are marked `pristine` and `untouched`, and
         * the value of all descendants to null.
         *
         * You reset to a specific form state by passing in a map of states
         * that matches the structure of your form, with control names as keys. The state
         * is a standalone value or a form state object with both a value and a disabled
         * status.
         *
         * \@usageNotes
         *
         * ### Reset the form group values
         *
         * ```ts
         * const form = new FormGroup({
         *   first: new FormControl('first name'),
         *   last: new FormControl('last name')
         * });
         *
         * console.log(form.value);  // {first: 'first name', last: 'last name'}
         *
         * form.reset({ first: 'name', last: 'last name' });
         *
         * console.log(form.value);  // {first: 'name', last: 'last name'}
         * ```
         *
         * ### Reset the form group values and disabled status
         *
         * ```
         * const form = new FormGroup({
         *   first: new FormControl('first name'),
         *   last: new FormControl('last name')
         * });
         *
         * form.reset({
         *   first: {value: 'name', disabled: true},
         *   last: 'last'
         * });
         *
         * console.log(this.form.value);  // {first: 'name', last: 'last name'}
         * console.log(this.form.get('first').status);  // 'DISABLED'
         * ```
         * @param {?=} value Resets the control with an initial value,
         * or an object that defines the initial value and disabled state.
         *
         * @param {?=} options Configuration options that determine how the control propagates changes
         * and emits events when the group is reset.
         * * `onlySelf`: When true, each change only affects this control, and not its parent. Default is
         * false.
         * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
         * `valueChanges`
         * observables emit events with the latest status and value when the control is reset.
         * When false, no events are emitted.
         * The configuration options are passed to the {\@link AbstractControl#updateValueAndValidity
         * updateValueAndValidity} method.
         *
         * @return {?}
         */

      }, {
        key: "reset",
        value: function reset() {
          var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
          var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};

          this._forEachChild(
          /**
          * @param {?} control
          * @param {?} name
          * @return {?}
          */
          function (control, name) {
            control.reset(value[name], {
              onlySelf: true,
              emitEvent: options.emitEvent
            });
          });

          this._updatePristine(options);

          this._updateTouched(options);

          this.updateValueAndValidity(options);
        }
        /**
         * The aggregate value of the `FormGroup`, including any disabled controls.
         *
         * Retrieves all values regardless of disabled status.
         * The `value` property is the best way to get the value of the group, because
         * it excludes disabled controls in the `FormGroup`.
         * @return {?}
         */

      }, {
        key: "getRawValue",
        value: function getRawValue() {
          return this._reduceChildren({},
          /**
          * @param {?} acc
          * @param {?} control
          * @param {?} name
          * @return {?}
          */
          function (acc, control, name) {
            acc[name] = control instanceof FormControl ? control.value :
            /** @type {?} */
            control.getRawValue();
            return acc;
          });
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_syncPendingControls",
        value: function _syncPendingControls() {
          /** @type {?} */
          var subtreeUpdated = this._reduceChildren(false,
          /**
          * @param {?} updated
          * @param {?} child
          * @return {?}
          */
          function (updated, child) {
            return child._syncPendingControls() ? true : updated;
          });

          if (subtreeUpdated) this.updateValueAndValidity({
            onlySelf: true
          });
          return subtreeUpdated;
        }
        /**
         * \@internal
         * @param {?} name
         * @return {?}
         */

      }, {
        key: "_throwIfControlMissing",
        value: function _throwIfControlMissing(name) {
          if (!Object.keys(this.controls).length) {
            throw new Error("\n        There are no form controls registered with this group yet.  If you're using ngModel,\n        you may want to check next tick (e.g. use setTimeout).\n      ");
          }

          if (!this.controls[name]) {
            throw new Error("Cannot find form control with name: ".concat(name, "."));
          }
        }
        /**
         * \@internal
         * @param {?} cb
         * @return {?}
         */

      }, {
        key: "_forEachChild",
        value: function _forEachChild(cb) {
          var _this196 = this;

          Object.keys(this.controls).forEach(
          /**
          * @param {?} k
          * @return {?}
          */
          function (k) {
            return cb(_this196.controls[k], k);
          });
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_setUpControls",
        value: function _setUpControls() {
          var _this197 = this;

          this._forEachChild(
          /**
          * @param {?} control
          * @return {?}
          */
          function (control) {
            control.setParent(_this197);

            control._registerOnCollectionChange(_this197._onCollectionChange);
          });
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_updateValue",
        value: function _updateValue() {
          /** @type {?} */
          this.value = this._reduceValue();
        }
        /**
         * \@internal
         * @param {?} condition
         * @return {?}
         */

      }, {
        key: "_anyControls",
        value: function _anyControls(condition) {
          var _this198 = this;

          /** @type {?} */
          var res = false;

          this._forEachChild(
          /**
          * @param {?} control
          * @param {?} name
          * @return {?}
          */
          function (control, name) {
            res = res || _this198.contains(name) && condition(control);
          });

          return res;
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_reduceValue",
        value: function _reduceValue() {
          var _this199 = this;

          return this._reduceChildren({},
          /**
          * @param {?} acc
          * @param {?} control
          * @param {?} name
          * @return {?}
          */
          function (acc, control, name) {
            if (control.enabled || _this199.disabled) {
              acc[name] = control.value;
            }

            return acc;
          });
        }
        /**
         * \@internal
         * @param {?} initValue
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "_reduceChildren",
        value: function _reduceChildren(initValue, fn) {
          /** @type {?} */
          var res = initValue;

          this._forEachChild(
          /**
          * @param {?} control
          * @param {?} name
          * @return {?}
          */
          function (control, name) {
            res = fn(res, control, name);
          });

          return res;
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_allControlsDisabled",
        value: function _allControlsDisabled() {
          for (var _i29 = 0, _Object$keys2 = Object.keys(this.controls); _i29 < _Object$keys2.length; _i29++) {
            var controlName = _Object$keys2[_i29];

            if (this.controls[controlName].enabled) {
              return false;
            }
          }

          return Object.keys(this.controls).length > 0 || this.disabled;
        }
        /**
         * \@internal
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "_checkAllValuesPresent",
        value: function _checkAllValuesPresent(value) {
          this._forEachChild(
          /**
          * @param {?} control
          * @param {?} name
          * @return {?}
          */
          function (control, name) {
            if (value[name] === undefined) {
              throw new Error("Must supply a value for form control with name: '".concat(name, "'."));
            }
          });
        }
      }]);

      return FormGroup;
    }(AbstractControl);

    if (false) {}
    /**
     * Tracks the value and validity state of an array of `FormControl`,
     * `FormGroup` or `FormArray` instances.
     *
     * A `FormArray` aggregates the values of each child `FormControl` into an array.
     * It calculates its status by reducing the status values of its children. For example, if one of
     * the controls in a `FormArray` is invalid, the entire array becomes invalid.
     *
     * `FormArray` is one of the three fundamental building blocks used to define forms in Angular,
     * along with `FormControl` and `FormGroup`.
     *
     * \@usageNotes
     *
     * ### Create an array of form controls
     *
     * ```
     * const arr = new FormArray([
     *   new FormControl('Nancy', Validators.minLength(2)),
     *   new FormControl('Drew'),
     * ]);
     *
     * console.log(arr.value);   // ['Nancy', 'Drew']
     * console.log(arr.status);  // 'VALID'
     * ```
     *
     * ### Create a form array with array-level validators
     *
     * You include array-level validators and async validators. These come in handy
     * when you want to perform validation that considers the value of more than one child
     * control.
     *
     * The two types of validators are passed in separately as the second and third arg
     * respectively, or together as part of an options object.
     *
     * ```
     * const arr = new FormArray([
     *   new FormControl('Nancy'),
     *   new FormControl('Drew')
     * ], {validators: myValidator, asyncValidators: myAsyncValidator});
     * ```
     *
     * ### Set the updateOn property for all controls in a form array
     *
     * The options object is used to set a default value for each child
     * control's `updateOn` property. If you set `updateOn` to `'blur'` at the
     * array level, all child controls default to 'blur', unless the child
     * has explicitly specified a different `updateOn` value.
     *
     * ```ts
     * const arr = new FormArray([
     *    new FormControl()
     * ], {updateOn: 'blur'});
     * ```
     *
     * ### Adding or removing controls from a form array
     *
     * To change the controls in the array, use the `push`, `insert`, `removeAt` or `clear` methods
     * in `FormArray` itself. These methods ensure the controls are properly tracked in the
     * form's hierarchy. Do not modify the array of `AbstractControl`s used to instantiate
     * the `FormArray` directly, as that result in strange and unexpected behavior such
     * as broken change detection.
     *
     * \@publicApi
     */


    var FormArray = /*#__PURE__*/function (_AbstractControl3) {
      _inherits(FormArray, _AbstractControl3);

      var _super57 = _createSuper(FormArray);

      /**
       * Creates a new `FormArray` instance.
       *
       * @param {?} controls An array of child controls. Each child control is given an index
       * where it is registered.
       *
       * @param {?=} validatorOrOpts A synchronous validator function, or an array of
       * such functions, or an `AbstractControlOptions` object that contains validation functions
       * and a validation trigger.
       *
       * @param {?=} asyncValidator A single async validator or array of async validator functions
       *
       */
      function FormArray(controls, validatorOrOpts, asyncValidator) {
        var _this200;

        _classCallCheck(this, FormArray);

        _this200 = _super57.call(this, coerceToValidator(validatorOrOpts), coerceToAsyncValidator(asyncValidator, validatorOrOpts));
        _this200.controls = controls;

        _this200._initObservables();

        _this200._setUpdateStrategy(validatorOrOpts);

        _this200._setUpControls();

        _this200.updateValueAndValidity({
          onlySelf: true,
          emitEvent: false
        });

        return _this200;
      }
      /**
       * Get the `AbstractControl` at the given `index` in the array.
       *
       * @param {?} index Index in the array to retrieve the control
       * @return {?}
       */


      _createClass2(FormArray, [{
        key: "at",
        value: function at(index) {
          return this.controls[index];
        }
        /**
         * Insert a new `AbstractControl` at the end of the array.
         *
         * @param {?} control Form control to be inserted
         * @return {?}
         */

      }, {
        key: "push",
        value: function push(control) {
          this.controls.push(control);

          this._registerControl(control);

          this.updateValueAndValidity();

          this._onCollectionChange();
        }
        /**
         * Insert a new `AbstractControl` at the given `index` in the array.
         *
         * @param {?} index Index in the array to insert the control
         * @param {?} control Form control to be inserted
         * @return {?}
         */

      }, {
        key: "insert",
        value: function insert(index, control) {
          this.controls.splice(index, 0, control);

          this._registerControl(control);

          this.updateValueAndValidity();
        }
        /**
         * Remove the control at the given `index` in the array.
         *
         * @param {?} index Index in the array to remove the control
         * @return {?}
         */

      }, {
        key: "removeAt",
        value: function removeAt(index) {
          if (this.controls[index]) this.controls[index]._registerOnCollectionChange(
          /**
          * @return {?}
          */
          function () {});
          this.controls.splice(index, 1);
          this.updateValueAndValidity();
        }
        /**
         * Replace an existing control.
         *
         * @param {?} index Index in the array to replace the control
         * @param {?} control The `AbstractControl` control to replace the existing control
         * @return {?}
         */

      }, {
        key: "setControl",
        value: function setControl(index, control) {
          if (this.controls[index]) this.controls[index]._registerOnCollectionChange(
          /**
          * @return {?}
          */
          function () {});
          this.controls.splice(index, 1);

          if (control) {
            this.controls.splice(index, 0, control);

            this._registerControl(control);
          }

          this.updateValueAndValidity();

          this._onCollectionChange();
        }
        /**
         * Length of the control array.
         * @return {?}
         */

      }, {
        key: "setValue",

        /**
         * Sets the value of the `FormArray`. It accepts an array that matches
         * the structure of the control.
         *
         * This method performs strict checks, and throws an error if you try
         * to set the value of a control that doesn't exist or if you exclude the
         * value of a control.
         *
         * \@usageNotes
         * ### Set the values for the controls in the form array
         *
         * ```
         * const arr = new FormArray([
         *   new FormControl(),
         *   new FormControl()
         * ]);
         * console.log(arr.value);   // [null, null]
         *
         * arr.setValue(['Nancy', 'Drew']);
         * console.log(arr.value);   // ['Nancy', 'Drew']
         * ```
         *
         * @param {?} value Array of values for the controls
         * @param {?=} options Configure options that determine how the control propagates changes and
         * emits events after the value changes
         *
         * * `onlySelf`: When true, each change only affects this control, and not its parent. Default
         * is false.
         * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
         * `valueChanges`
         * observables emit events with the latest status and value when the control value is updated.
         * When false, no events are emitted.
         * The configuration options are passed to the {\@link AbstractControl#updateValueAndValidity
         * updateValueAndValidity} method.
         * @return {?}
         */
        value: function setValue(value) {
          var _this201 = this;

          var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};

          this._checkAllValuesPresent(value);

          value.forEach(
          /**
          * @param {?} newValue
          * @param {?} index
          * @return {?}
          */
          function (newValue, index) {
            _this201._throwIfControlMissing(index);

            _this201.at(index).setValue(newValue, {
              onlySelf: true,
              emitEvent: options.emitEvent
            });
          });
          this.updateValueAndValidity(options);
        }
        /**
         * Patches the value of the `FormArray`. It accepts an array that matches the
         * structure of the control, and does its best to match the values to the correct
         * controls in the group.
         *
         * It accepts both super-sets and sub-sets of the array without throwing an error.
         *
         * \@usageNotes
         * ### Patch the values for controls in a form array
         *
         * ```
         * const arr = new FormArray([
         *    new FormControl(),
         *    new FormControl()
         * ]);
         * console.log(arr.value);   // [null, null]
         *
         * arr.patchValue(['Nancy']);
         * console.log(arr.value);   // ['Nancy', null]
         * ```
         *
         * @param {?} value Array of latest values for the controls
         * @param {?=} options Configure options that determine how the control propagates changes and
         * emits events after the value changes
         *
         * * `onlySelf`: When true, each change only affects this control, and not its parent. Default
         * is false.
         * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
         * `valueChanges`
         * observables emit events with the latest status and value when the control value is updated.
         * When false, no events are emitted.
         * The configuration options are passed to the {\@link AbstractControl#updateValueAndValidity
         * updateValueAndValidity} method.
         * @return {?}
         */

      }, {
        key: "patchValue",
        value: function patchValue(value) {
          var _this202 = this;

          var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
          value.forEach(
          /**
          * @param {?} newValue
          * @param {?} index
          * @return {?}
          */
          function (newValue, index) {
            if (_this202.at(index)) {
              _this202.at(index).patchValue(newValue, {
                onlySelf: true,
                emitEvent: options.emitEvent
              });
            }
          });
          this.updateValueAndValidity(options);
        }
        /**
         * Resets the `FormArray` and all descendants are marked `pristine` and `untouched`, and the
         * value of all descendants to null or null maps.
         *
         * You reset to a specific form state by passing in an array of states
         * that matches the structure of the control. The state is a standalone value
         * or a form state object with both a value and a disabled status.
         *
         * \@usageNotes
         * ### Reset the values in a form array
         *
         * ```ts
         * const arr = new FormArray([
         *    new FormControl(),
         *    new FormControl()
         * ]);
         * arr.reset(['name', 'last name']);
         *
         * console.log(this.arr.value);  // ['name', 'last name']
         * ```
         *
         * ### Reset the values in a form array and the disabled status for the first control
         *
         * ```
         * this.arr.reset([
         *   {value: 'name', disabled: true},
         *   'last'
         * ]);
         *
         * console.log(this.arr.value);  // ['name', 'last name']
         * console.log(this.arr.get(0).status);  // 'DISABLED'
         * ```
         *
         * @param {?=} value Array of values for the controls
         * @param {?=} options Configure options that determine how the control propagates changes and
         * emits events after the value changes
         *
         * * `onlySelf`: When true, each change only affects this control, and not its parent. Default
         * is false.
         * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and
         * `valueChanges`
         * observables emit events with the latest status and value when the control is reset.
         * When false, no events are emitted.
         * The configuration options are passed to the {\@link AbstractControl#updateValueAndValidity
         * updateValueAndValidity} method.
         * @return {?}
         */

      }, {
        key: "reset",
        value: function reset() {
          var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
          var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};

          this._forEachChild(
          /**
          * @param {?} control
          * @param {?} index
          * @return {?}
          */
          function (control, index) {
            control.reset(value[index], {
              onlySelf: true,
              emitEvent: options.emitEvent
            });
          });

          this._updatePristine(options);

          this._updateTouched(options);

          this.updateValueAndValidity(options);
        }
        /**
         * The aggregate value of the array, including any disabled controls.
         *
         * Reports all values regardless of disabled status.
         * For enabled controls only, the `value` property is the best way to get the value of the array.
         * @return {?}
         */

      }, {
        key: "getRawValue",
        value: function getRawValue() {
          return this.controls.map(
          /**
          * @param {?} control
          * @return {?}
          */
          function (control) {
            return control instanceof FormControl ? control.value :
            /** @type {?} */
            control.getRawValue();
          });
        }
        /**
         * Remove all controls in the `FormArray`.
         *
         * \@usageNotes
         * ### Remove all elements from a FormArray
         *
         * ```ts
         * const arr = new FormArray([
         *    new FormControl(),
         *    new FormControl()
         * ]);
         * console.log(arr.length);  // 2
         *
         * arr.clear();
         * console.log(arr.length);  // 0
         * ```
         *
         * It's a simpler and more efficient alternative to removing all elements one by one:
         *
         * ```ts
         * const arr = new FormArray([
         *    new FormControl(),
         *    new FormControl()
         * ]);
         *
         * while (arr.length) {
         *    arr.removeAt(0);
         * }
         * ```
         * @return {?}
         */

      }, {
        key: "clear",
        value: function clear() {
          if (this.controls.length < 1) return;

          this._forEachChild(
          /**
          * @param {?} control
          * @return {?}
          */
          function (control) {
            return control._registerOnCollectionChange(
            /**
            * @return {?}
            */
            function () {});
          });

          this.controls.splice(0);
          this.updateValueAndValidity();
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_syncPendingControls",
        value: function _syncPendingControls() {
          /** @type {?} */
          var subtreeUpdated = this.controls.reduce(
          /**
          * @param {?} updated
          * @param {?} child
          * @return {?}
          */
          function (updated, child) {
            return child._syncPendingControls() ? true : updated;
          }, false);
          if (subtreeUpdated) this.updateValueAndValidity({
            onlySelf: true
          });
          return subtreeUpdated;
        }
        /**
         * \@internal
         * @param {?} index
         * @return {?}
         */

      }, {
        key: "_throwIfControlMissing",
        value: function _throwIfControlMissing(index) {
          if (!this.controls.length) {
            throw new Error("\n        There are no form controls registered with this array yet.  If you're using ngModel,\n        you may want to check next tick (e.g. use setTimeout).\n      ");
          }

          if (!this.at(index)) {
            throw new Error("Cannot find form control at index ".concat(index));
          }
        }
        /**
         * \@internal
         * @param {?} cb
         * @return {?}
         */

      }, {
        key: "_forEachChild",
        value: function _forEachChild(cb) {
          this.controls.forEach(
          /**
          * @param {?} control
          * @param {?} index
          * @return {?}
          */
          function (control, index) {
            cb(control, index);
          });
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_updateValue",
        value: function _updateValue() {
          var _this203 = this;

          /** @type {?} */
          this.value = this.controls.filter(
          /**
          * @param {?} control
          * @return {?}
          */
          function (control) {
            return control.enabled || _this203.disabled;
          }).map(
          /**
          * @param {?} control
          * @return {?}
          */
          function (control) {
            return control.value;
          });
        }
        /**
         * \@internal
         * @param {?} condition
         * @return {?}
         */

      }, {
        key: "_anyControls",
        value: function _anyControls(condition) {
          return this.controls.some(
          /**
          * @param {?} control
          * @return {?}
          */
          function (control) {
            return control.enabled && condition(control);
          });
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_setUpControls",
        value: function _setUpControls() {
          var _this204 = this;

          this._forEachChild(
          /**
          * @param {?} control
          * @return {?}
          */
          function (control) {
            return _this204._registerControl(control);
          });
        }
        /**
         * \@internal
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "_checkAllValuesPresent",
        value: function _checkAllValuesPresent(value) {
          this._forEachChild(
          /**
          * @param {?} control
          * @param {?} i
          * @return {?}
          */
          function (control, i) {
            if (value[i] === undefined) {
              throw new Error("Must supply a value for form control at index: ".concat(i, "."));
            }
          });
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_allControlsDisabled",
        value: function _allControlsDisabled() {
          var _iterator15 = _createForOfIteratorHelper(this.controls),
              _step15;

          try {
            for (_iterator15.s(); !(_step15 = _iterator15.n()).done;) {
              var control = _step15.value;
              if (control.enabled) return false;
            }
          } catch (err) {
            _iterator15.e(err);
          } finally {
            _iterator15.f();
          }

          return this.controls.length > 0 || this.disabled;
        }
        /**
         * @private
         * @param {?} control
         * @return {?}
         */

      }, {
        key: "_registerControl",
        value: function _registerControl(control) {
          control.setParent(this);

          control._registerOnCollectionChange(this._onCollectionChange);
        }
      }, {
        key: "length",
        get: function get() {
          return this.controls.length;
        }
      }]);

      return FormArray;
    }(AbstractControl);

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/ng_form.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var formDirectiveProvider = {
      provide: ControlContainer,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return NgForm;
      })
    };

    var ɵ0 =
    /**
    * @return {?}
    */
    function ɵ0() {
      return Promise.resolve(null);
    };
    /** @type {?} */


    var resolvedPromise = ɵ0();
    /**
     * \@description
     * Creates a top-level `FormGroup` instance and binds it to a form
     * to track aggregate form value and validation status.
     *
     * As soon as you import the `FormsModule`, this directive becomes active by default on
     * all `<form>` tags.  You don't need to add a special selector.
     *
     * You optionally export the directive into a local template variable using `ngForm` as the key
     * (ex: `#myForm="ngForm"`). This is optional, but useful.  Many properties from the underlying
     * `FormGroup` instance are duplicated on the directive itself, so a reference to it
     * gives you access to the aggregate value and validity status of the form, as well as
     * user interaction properties like `dirty` and `touched`.
     *
     * To register child controls with the form, use `NgModel` with a `name`
     * attribute. You may use `NgModelGroup` to create sub-groups within the form.
     *
     * If necessary, listen to the directive's `ngSubmit` event to be notified when the user has
     * triggered a form submission. The `ngSubmit` event emits the original form
     * submission event.
     *
     * In template driven forms, all `<form>` tags are automatically tagged as `NgForm`.
     * To import the `FormsModule` but skip its usage in some forms,
     * for example, to use native HTML5 validation, add the `ngNoForm` and the `<form>`
     * tags won't create an `NgForm` directive. In reactive forms, using `ngNoForm` is
     * unnecessary because the `<form>` tags are inert. In that case, you would
     * refrain from using the `formGroup` directive.
     *
     * \@usageNotes
     *
     * ### Listening for form submission
     *
     * The following example shows how to capture the form values from the "ngSubmit" event.
     *
     * {\@example forms/ts/simpleForm/simple_form_example.ts region='Component'}
     *
     * ### Setting the update options
     *
     * The following example shows you how to change the "updateOn" option from its default using
     * ngFormOptions.
     *
     * ```html
     * <form [ngFormOptions]="{updateOn: 'blur'}">
     *    <input name="one" ngModel>  <!-- this ngModel will update on blur -->
     * </form>
     * ```
     *
     * ### Native DOM validation UI
     *
     * In order to prevent the native DOM form validation UI from interfering with Angular's form
     * validation, Angular automatically adds the `novalidate` attribute on any `<form>` whenever
     * `FormModule` or `ReactiveFormModule` are imported into the application.
     * If you want to explicitly enable native DOM validation UI with Angular forms, you can add the
     * `ngNativeValidate` attribute to the `<form>` element:
     *
     * ```html
     * <form ngNativeValidate>
     *   ...
     * </form>
     * ```
     *
     * \@ngModule FormsModule
     * \@publicApi
     */

    var NgForm = /*#__PURE__*/function (_ControlContainer) {
      _inherits(NgForm, _ControlContainer);

      var _super58 = _createSuper(NgForm);

      /**
       * @param {?} validators
       * @param {?} asyncValidators
       */
      function NgForm(validators, asyncValidators) {
        var _this205;

        _classCallCheck(this, NgForm);

        _this205 = _super58.call(this);
        /**
         * \@description
         * Returns whether the form submission has been triggered.
         */

        _this205.submitted = false;
        _this205._directives = [];
        /**
         * \@description
         * Event emitter for the "ngSubmit" event
         */

        _this205.ngSubmit = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"]();
        _this205.form = new FormGroup({}, composeValidators(validators), composeAsyncValidators(asyncValidators));
        return _this205;
      }
      /**
       * \@description
       * Lifecycle method called after the view is initialized. For internal use only.
       * @return {?}
       */


      _createClass2(NgForm, [{
        key: "ngAfterViewInit",
        value: function ngAfterViewInit() {
          this._setUpdateStrategy();
        }
        /**
         * \@description
         * The directive instance.
         * @return {?}
         */

      }, {
        key: "addControl",

        /**
         * \@description
         * Method that sets up the control directive in this group, re-calculates its value
         * and validity, and adds the instance to the internal list of directives.
         *
         * @param {?} dir The `NgModel` directive instance.
         * @return {?}
         */
        value: function addControl(dir) {
          var _this206 = this;

          resolvedPromise.then(
          /**
          * @return {?}
          */
          function () {
            /** @type {?} */
            var container = _this206._findContainer(dir.path);

            /** @type {?} */
            dir.control =
            /** @type {?} */
            container.registerControl(dir.name, dir.control);
            setUpControl(dir.control, dir);
            dir.control.updateValueAndValidity({
              emitEvent: false
            });

            _this206._directives.push(dir);
          });
        }
        /**
         * \@description
         * Retrieves the `FormControl` instance from the provided `NgModel` directive.
         *
         * @param {?} dir The `NgModel` directive instance.
         * @return {?}
         */

      }, {
        key: "getControl",
        value: function getControl(dir) {
          return (
            /** @type {?} */
            this.form.get(dir.path)
          );
        }
        /**
         * \@description
         * Removes the `NgModel` instance from the internal list of directives
         *
         * @param {?} dir The `NgModel` directive instance.
         * @return {?}
         */

      }, {
        key: "removeControl",
        value: function removeControl(dir) {
          var _this207 = this;

          resolvedPromise.then(
          /**
          * @return {?}
          */
          function () {
            /** @type {?} */
            var container = _this207._findContainer(dir.path);

            if (container) {
              container.removeControl(dir.name);
            }

            removeDir(_this207._directives, dir);
          });
        }
        /**
         * \@description
         * Adds a new `NgModelGroup` directive instance to the form.
         *
         * @param {?} dir The `NgModelGroup` directive instance.
         * @return {?}
         */

      }, {
        key: "addFormGroup",
        value: function addFormGroup(dir) {
          var _this208 = this;

          resolvedPromise.then(
          /**
          * @return {?}
          */
          function () {
            /** @type {?} */
            var container = _this208._findContainer(dir.path);
            /** @type {?} */


            var group = new FormGroup({});
            setUpFormContainer(group, dir);
            container.registerControl(dir.name, group);
            group.updateValueAndValidity({
              emitEvent: false
            });
          });
        }
        /**
         * \@description
         * Removes the `NgModelGroup` directive instance from the form.
         *
         * @param {?} dir The `NgModelGroup` directive instance.
         * @return {?}
         */

      }, {
        key: "removeFormGroup",
        value: function removeFormGroup(dir) {
          var _this209 = this;

          resolvedPromise.then(
          /**
          * @return {?}
          */
          function () {
            /** @type {?} */
            var container = _this209._findContainer(dir.path);

            if (container) {
              container.removeControl(dir.name);
            }
          });
        }
        /**
         * \@description
         * Retrieves the `FormGroup` for a provided `NgModelGroup` directive instance
         *
         * @param {?} dir The `NgModelGroup` directive instance.
         * @return {?}
         */

      }, {
        key: "getFormGroup",
        value: function getFormGroup(dir) {
          return (
            /** @type {?} */
            this.form.get(dir.path)
          );
        }
        /**
         * Sets the new value for the provided `NgControl` directive.
         *
         * @param {?} dir The `NgControl` directive instance.
         * @param {?} value The new value for the directive's control.
         * @return {?}
         */

      }, {
        key: "updateModel",
        value: function updateModel(dir, value) {
          var _this210 = this;

          resolvedPromise.then(
          /**
          * @return {?}
          */
          function () {
            /** @type {?} */
            var ctrl =
            /** @type {?} */
            _this210.form.get(
            /** @type {?} */
            dir.path);

            ctrl.setValue(value);
          });
        }
        /**
         * \@description
         * Sets the value for this `FormGroup`.
         *
         * @param {?} value The new value
         * @return {?}
         */

      }, {
        key: "setValue",
        value: function setValue(value) {
          this.control.setValue(value);
        }
        /**
         * \@description
         * Method called when the "submit" event is triggered on the form.
         * Triggers the `ngSubmit` emitter to emit the "submit" event as its payload.
         *
         * @param {?} $event The "submit" event object
         * @return {?}
         */

      }, {
        key: "onSubmit",
        value: function onSubmit($event) {
          /** @type {?} */
          this.submitted = true;
          syncPendingControls(this.form, this._directives);
          this.ngSubmit.emit($event);
          return false;
        }
        /**
         * \@description
         * Method called when the "reset" event is triggered on the form.
         * @return {?}
         */

      }, {
        key: "onReset",
        value: function onReset() {
          this.resetForm();
        }
        /**
         * \@description
         * Resets the form to an initial value and resets its submitted status.
         *
         * @param {?=} value The new value for the form.
         * @return {?}
         */

      }, {
        key: "resetForm",
        value: function resetForm() {
          var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : undefined;
          this.form.reset(value);

          /** @type {?} */
          this.submitted = false;
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_setUpdateStrategy",
        value: function _setUpdateStrategy() {
          if (this.options && this.options.updateOn != null) {
            this.form._updateOn = this.options.updateOn;
          }
        }
        /**
         * \@internal
         * @param {?} path
         * @return {?}
         */

      }, {
        key: "_findContainer",
        value: function _findContainer(path) {
          path.pop();
          return path.length ?
          /** @type {?} */
          this.form.get(path) : this.form;
        }
      }, {
        key: "formDirective",
        get: function get() {
          return this;
        }
        /**
         * \@description
         * The internal `FormGroup` instance.
         * @return {?}
         */

      }, {
        key: "control",
        get: function get() {
          return this.form;
        }
        /**
         * \@description
         * Returns an array representing the path to this group. Because this directive
         * always lives at the top level of a form, it is always an empty array.
         * @return {?}
         */

      }, {
        key: "path",
        get: function get() {
          return [];
        }
        /**
         * \@description
         * Returns a map of the controls in this group.
         * @return {?}
         */

      }, {
        key: "controls",
        get: function get() {
          return this.form.controls;
        }
      }]);

      return NgForm;
    }(ControlContainer);

    NgForm.ɵfac = function NgForm_Factory(t) {
      return new (t || NgForm)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_VALIDATORS, 10), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_ASYNC_VALIDATORS, 10));
    };

    NgForm.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: NgForm,
      selectors: [["form", 3, "ngNoForm", "", 3, "formGroup", ""], ["ng-form"], ["", "ngForm", ""]],
      hostBindings: function NgForm_HostBindings(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵlistener"]("submit", function NgForm_submit_HostBindingHandler($event) {
            return ctx.onSubmit($event);
          })("reset", function NgForm_reset_HostBindingHandler() {
            return ctx.onReset();
          });
        }
      },
      inputs: {
        options: ["ngFormOptions", "options"]
      },
      outputs: {
        ngSubmit: "ngSubmit"
      },
      exportAs: ["ngForm"],
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([formDirectiveProvider]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]]
    });
    /** @nocollapse */

    NgForm.ctorParameters = function () {
      return [{
        type: Array,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_VALIDATORS]
        }]
      }, {
        type: Array,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_ASYNC_VALIDATORS]
        }]
      }];
    };

    NgForm.propDecorators = {
      options: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['ngFormOptions']
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NgForm, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: 'form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]',
          providers: [formDirectiveProvider],
          host: {
            '(submit)': 'onSubmit($event)',
            '(reset)': 'onReset()'
          },
          outputs: ['ngSubmit'],
          exportAs: 'ngForm'
        }]
      }], function () {
        return [{
          type: Array,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_VALIDATORS]
          }]
        }, {
          type: Array,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_ASYNC_VALIDATORS]
          }]
        }];
      }, {
        options: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['ngFormOptions']
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/abstract_form_group_directive.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@description
     * A base class for code shared between the `NgModelGroup` and `FormGroupName` directives.
     *
     * \@publicApi
     */


    var AbstractFormGroupDirective = /*#__PURE__*/function (_ControlContainer2) {
      _inherits(AbstractFormGroupDirective, _ControlContainer2);

      var _super59 = _createSuper(AbstractFormGroupDirective);

      function AbstractFormGroupDirective() {
        _classCallCheck(this, AbstractFormGroupDirective);

        return _super59.apply(this, arguments);
      }

      _createClass2(AbstractFormGroupDirective, [{
        key: "ngOnInit",

        /**
         * \@description
         * An internal callback method triggered on the instance after the inputs are set.
         * Registers the group with its parent group.
         * @return {?}
         */
        value: function ngOnInit() {
          this._checkParentType();

          /** @type {?} */
          this.formDirective.addFormGroup(this);
        }
        /**
         * \@description
         * An internal callback method triggered before the instance is destroyed.
         * Removes the group from its parent group.
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          if (this.formDirective) {
            this.formDirective.removeFormGroup(this);
          }
        }
        /**
         * \@description
         * The `FormGroup` bound to this directive.
         * @return {?}
         */

      }, {
        key: "_checkParentType",

        /**
         * \@internal
         * @return {?}
         */
        value: function _checkParentType() {}
      }, {
        key: "control",
        get: function get() {
          return (
            /** @type {?} */
            this.formDirective.getFormGroup(this)
          );
        }
        /**
         * \@description
         * The path to this group from the top-level directive.
         * @return {?}
         */

      }, {
        key: "path",
        get: function get() {
          return controlPath(this.name == null ? this.name : this.name.toString(), this._parent);
        }
        /**
         * \@description
         * The top-level directive for this group if present, otherwise null.
         * @return {?}
         */

      }, {
        key: "formDirective",
        get: function get() {
          return this._parent ? this._parent.formDirective : null;
        }
        /**
         * \@description
         * The synchronous validators registered with this group.
         * @return {?}
         */

      }, {
        key: "validator",
        get: function get() {
          return composeValidators(this._validators);
        }
        /**
         * \@description
         * The async validators registered with this group.
         * @return {?}
         */

      }, {
        key: "asyncValidator",
        get: function get() {
          return composeAsyncValidators(this._asyncValidators);
        }
      }]);

      return AbstractFormGroupDirective;
    }(ControlContainer);

    AbstractFormGroupDirective.ɵfac = function AbstractFormGroupDirective_Factory(t) {
      return ɵAbstractFormGroupDirective_BaseFactory(t || AbstractFormGroupDirective);
    };

    AbstractFormGroupDirective.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: AbstractFormGroupDirective,
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]]
    });

    var ɵAbstractFormGroupDirective_BaseFactory = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵgetInheritedFactory"](AbstractFormGroupDirective);

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/template_driven_errors.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var TemplateDrivenErrors = /*#__PURE__*/function () {
      function TemplateDrivenErrors() {
        _classCallCheck(this, TemplateDrivenErrors);
      }

      _createClass2(TemplateDrivenErrors, null, [{
        key: "modelParentException",

        /**
         * @return {?}
         */
        value: function modelParentException() {
          throw new Error("\n      ngModel cannot be used to register form controls with a parent formGroup directive.  Try using\n      formGroup's partner directive \"formControlName\" instead.  Example:\n\n      ".concat(FormErrorExamples.formControlName, "\n\n      Or, if you'd like to avoid registering this form control, indicate that it's standalone in ngModelOptions:\n\n      Example:\n\n      ").concat(FormErrorExamples.ngModelWithFormGroup));
        }
        /**
         * @return {?}
         */

      }, {
        key: "formGroupNameException",
        value: function formGroupNameException() {
          throw new Error("\n      ngModel cannot be used to register form controls with a parent formGroupName or formArrayName directive.\n\n      Option 1: Use formControlName instead of ngModel (reactive strategy):\n\n      ".concat(FormErrorExamples.formGroupName, "\n\n      Option 2:  Update ngModel's parent be ngModelGroup (template-driven strategy):\n\n      ").concat(FormErrorExamples.ngModelGroup));
        }
        /**
         * @return {?}
         */

      }, {
        key: "missingNameException",
        value: function missingNameException() {
          throw new Error("If ngModel is used within a form tag, either the name attribute must be set or the form\n      control must be defined as 'standalone' in ngModelOptions.\n\n      Example 1: <input [(ngModel)]=\"person.firstName\" name=\"first\">\n      Example 2: <input [(ngModel)]=\"person.firstName\" [ngModelOptions]=\"{standalone: true}\">");
        }
        /**
         * @return {?}
         */

      }, {
        key: "modelGroupParentException",
        value: function modelGroupParentException() {
          throw new Error("\n      ngModelGroup cannot be used with a parent formGroup directive.\n\n      Option 1: Use formGroupName instead of ngModelGroup (reactive strategy):\n\n      ".concat(FormErrorExamples.formGroupName, "\n\n      Option 2:  Use a regular form tag instead of the formGroup directive (template-driven strategy):\n\n      ").concat(FormErrorExamples.ngModelGroup));
        }
      }]);

      return TemplateDrivenErrors;
    }();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/ng_model_group.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var modelGroupProvider = {
      provide: ControlContainer,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return NgModelGroup;
      })
    };
    /**
     * \@description
     * Creates and binds a `FormGroup` instance to a DOM element.
     *
     * This directive can only be used as a child of `NgForm` (within `<form>` tags).
     *
     * Use this directive to validate a sub-group of your form separately from the
     * rest of your form, or if some values in your domain model make more sense
     * to consume together in a nested object.
     *
     * Provide a name for the sub-group and it will become the key
     * for the sub-group in the form's full value. If you need direct access, export the directive into
     * a local template variable using `ngModelGroup` (ex: `#myGroup="ngModelGroup"`).
     *
     * \@usageNotes
     *
     * ### Consuming controls in a grouping
     *
     * The following example shows you how to combine controls together in a sub-group
     * of the form.
     *
     * {\@example forms/ts/ngModelGroup/ng_model_group_example.ts region='Component'}
     *
     * \@ngModule FormsModule
     * \@publicApi
     */

    var NgModelGroup = /*#__PURE__*/function (_AbstractFormGroupDir) {
      _inherits(NgModelGroup, _AbstractFormGroupDir);

      var _super60 = _createSuper(NgModelGroup);

      /**
       * @param {?} parent
       * @param {?} validators
       * @param {?} asyncValidators
       */
      function NgModelGroup(parent, validators, asyncValidators) {
        var _this211;

        _classCallCheck(this, NgModelGroup);

        _this211 = _super60.call(this);
        _this211._parent = parent;
        _this211._validators = validators;
        _this211._asyncValidators = asyncValidators;
        return _this211;
      }
      /**
       * \@internal
       * @return {?}
       */


      _createClass2(NgModelGroup, [{
        key: "_checkParentType",
        value: function _checkParentType() {
          if (!(this._parent instanceof NgModelGroup) && !(this._parent instanceof NgForm)) {
            TemplateDrivenErrors.modelGroupParentException();
          }
        }
      }]);

      return NgModelGroup;
    }(AbstractFormGroupDirective);

    NgModelGroup.ɵfac = function NgModelGroup_Factory(t) {
      return new (t || NgModelGroup)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](ControlContainer, 5), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_VALIDATORS, 10), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_ASYNC_VALIDATORS, 10));
    };

    NgModelGroup.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: NgModelGroup,
      selectors: [["", "ngModelGroup", ""]],
      inputs: {
        name: ["ngModelGroup", "name"]
      },
      exportAs: ["ngModelGroup"],
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([modelGroupProvider]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]]
    });
    /** @nocollapse */

    NgModelGroup.ctorParameters = function () {
      return [{
        type: ControlContainer,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["SkipSelf"]
        }]
      }, {
        type: Array,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_VALIDATORS]
        }]
      }, {
        type: Array,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_ASYNC_VALIDATORS]
        }]
      }];
    };

    NgModelGroup.propDecorators = {
      name: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['ngModelGroup']
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NgModelGroup, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[ngModelGroup]',
          providers: [modelGroupProvider],
          exportAs: 'ngModelGroup'
        }]
      }], function () {
        return [{
          type: ControlContainer,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["SkipSelf"]
          }]
        }, {
          type: Array,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_VALIDATORS]
          }]
        }, {
          type: Array,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_ASYNC_VALIDATORS]
          }]
        }];
      }, {
        name: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['ngModelGroup']
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/ng_model.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var formControlBinding = {
      provide: NgControl,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return NgModel;
      })
    };

    var ɵ0$1 =
    /**
    * @return {?}
    */
    function ɵ0$1() {
      return Promise.resolve(null);
    };
    /**
     * `ngModel` forces an additional change detection run when its inputs change:
     * E.g.:
     * ```
     * <div>{{myModel.valid}}</div>
     * <input [(ngModel)]="myValue" #myModel="ngModel">
     * ```
     * I.e. `ngModel` can export itself on the element and then be used in the template.
     * Normally, this would result in expressions before the `input` that use the exported directive
     * to have and old value as they have been
     * dirty checked before. As this is a very common case for `ngModel`, we added this second change
     * detection run.
     *
     * Notes:
     * - this is just one extra run no matter how many `ngModel` have been changed.
     * - this is a general problem when using `exportAs` for directives!
     * @type {?}
     */


    var resolvedPromise$1 = ɵ0$1();
    /**
     * \@description
     * Creates a `FormControl` instance from a domain model and binds it
     * to a form control element.
     *
     * The `FormControl` instance tracks the value, user interaction, and
     * validation status of the control and keeps the view synced with the model. If used
     * within a parent form, the directive also registers itself with the form as a child
     * control.
     *
     * This directive is used by itself or as part of a larger form. Use the
     * `ngModel` selector to activate it.
     *
     * It accepts a domain model as an optional `Input`. If you have a one-way binding
     * to `ngModel` with `[]` syntax, changing the value of the domain model in the component
     * class sets the value in the view. If you have a two-way binding with `[()]` syntax
     * (also known as 'banana-box syntax'), the value in the UI always syncs back to
     * the domain model in your class.
     *
     * To inspect the properties of the associated `FormControl` (like validity state),
     * export the directive into a local template variable using `ngModel` as the key (ex:
     * `#myVar="ngModel"`). You then access the control using the directive's `control` property, but
     * most properties used (like `valid` and `dirty`) fall through to the control anyway for direct
     * access. See a full list of properties directly available in `AbstractControlDirective`.
     *
     * @see `RadioControlValueAccessor`
     * @see `SelectControlValueAccessor`
     *
     * \@usageNotes
     *
     * ### Using ngModel on a standalone control
     *
     * The following examples show a simple standalone control using `ngModel`:
     *
     * {\@example forms/ts/simpleNgModel/simple_ng_model_example.ts region='Component'}
     *
     * When using the `ngModel` within `<form>` tags, you'll also need to supply a `name` attribute
     * so that the control can be registered with the parent form under that name.
     *
     * In the context of a parent form, it's often unnecessary to include one-way or two-way binding,
     * as the parent form syncs the value for you. You access its properties by exporting it into a
     * local template variable using `ngForm` such as (`#f="ngForm"`). Use the variable where
     * needed on form submission.
     *
     * If you do need to populate initial values into your form, using a one-way binding for
     * `ngModel` tends to be sufficient as long as you use the exported form's value rather
     * than the domain model's value on submit.
     *
     * ### Using ngModel within a form
     *
     * The following example shows controls using `ngModel` within a form:
     *
     * {\@example forms/ts/simpleForm/simple_form_example.ts region='Component'}
     *
     * ### Using a standalone ngModel within a group
     *
     * The following example shows you how to use a standalone ngModel control
     * within a form. This controls the display of the form, but doesn't contain form data.
     *
     * ```html
     * <form>
     *   <input name="login" ngModel placeholder="Login">
     *   <input type="checkbox" ngModel [ngModelOptions]="{standalone: true}"> Show more options?
     * </form>
     * <!-- form value: {login: ''} -->
     * ```
     *
     * ### Setting the ngModel name attribute through options
     *
     * The following example shows you an alternate way to set the name attribute. The name attribute is
     * used within a custom form component, and the name `\@Input` property serves a different purpose.
     *
     * ```html
     * <form>
     *   <my-person-control name="Nancy" ngModel [ngModelOptions]="{name: 'user'}">
     *   </my-person-control>
     * </form>
     * <!-- form value: {user: ''} -->
     * ```
     *
     * \@ngModule FormsModule
     * \@publicApi
     */

    var NgModel = /*#__PURE__*/function (_NgControl) {
      _inherits(NgModel, _NgControl);

      var _super61 = _createSuper(NgModel);

      /**
       * @param {?} parent
       * @param {?} validators
       * @param {?} asyncValidators
       * @param {?} valueAccessors
       */
      function NgModel(parent, validators, asyncValidators, valueAccessors) {
        var _this212;

        _classCallCheck(this, NgModel);

        _this212 = _super61.call(this);
        _this212.control = new FormControl();
        /**
         * \@internal
         */

        _this212._registered = false;
        /**
         * \@description
         * Event emitter for producing the `ngModelChange` event after
         * the view model updates.
         */

        _this212.update = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"]();
        _this212._parent = parent;
        _this212._rawValidators = validators || [];
        _this212._rawAsyncValidators = asyncValidators || [];
        _this212.valueAccessor = selectValueAccessor(_assertThisInitialized(_this212), valueAccessors);
        return _this212;
      }
      /**
       * \@description
       * A lifecycle method called when the directive's inputs change. For internal use
       * only.
       *
       * @param {?} changes A object of key/value pairs for the set of changed inputs.
       * @return {?}
       */


      _createClass2(NgModel, [{
        key: "ngOnChanges",
        value: function ngOnChanges(changes) {
          this._checkForErrors();

          if (!this._registered) this._setUpControl();

          if ('isDisabled' in changes) {
            this._updateDisabled(changes);
          }

          if (isPropertyUpdated(changes, this.viewModel)) {
            this._updateValue(this.model);

            this.viewModel = this.model;
          }
        }
        /**
         * \@description
         * Lifecycle method called before the directive's instance is destroyed. For internal
         * use only.
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this.formDirective && this.formDirective.removeControl(this);
        }
        /**
         * \@description
         * Returns an array that represents the path from the top-level form to this control.
         * Each index is the string name of the control on that level.
         * @return {?}
         */

      }, {
        key: "viewToModelUpdate",

        /**
         * \@description
         * Sets the new value for the view model and emits an `ngModelChange` event.
         *
         * @param {?} newValue The new value emitted by `ngModelChange`.
         * @return {?}
         */
        value: function viewToModelUpdate(newValue) {
          this.viewModel = newValue;
          this.update.emit(newValue);
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_setUpControl",
        value: function _setUpControl() {
          this._setUpdateStrategy();

          this._isStandalone() ? this._setUpStandalone() : this.formDirective.addControl(this);
          this._registered = true;
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_setUpdateStrategy",
        value: function _setUpdateStrategy() {
          if (this.options && this.options.updateOn != null) {
            this.control._updateOn = this.options.updateOn;
          }
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_isStandalone",
        value: function _isStandalone() {
          return !this._parent || !!(this.options && this.options.standalone);
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_setUpStandalone",
        value: function _setUpStandalone() {
          setUpControl(this.control, this);
          this.control.updateValueAndValidity({
            emitEvent: false
          });
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_checkForErrors",
        value: function _checkForErrors() {
          if (!this._isStandalone()) {
            this._checkParentType();
          }

          this._checkName();
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_checkParentType",
        value: function _checkParentType() {
          if (!(this._parent instanceof NgModelGroup) && this._parent instanceof AbstractFormGroupDirective) {
            TemplateDrivenErrors.formGroupNameException();
          } else if (!(this._parent instanceof NgModelGroup) && !(this._parent instanceof NgForm)) {
            TemplateDrivenErrors.modelParentException();
          }
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_checkName",
        value: function _checkName() {
          if (this.options && this.options.name) this.name = this.options.name;

          if (!this._isStandalone() && !this.name) {
            TemplateDrivenErrors.missingNameException();
          }
        }
        /**
         * @private
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "_updateValue",
        value: function _updateValue(value) {
          var _this213 = this;

          resolvedPromise$1.then(
          /**
          * @return {?}
          */
          function () {
            _this213.control.setValue(value, {
              emitViewToModelChange: false
            });
          });
        }
        /**
         * @private
         * @param {?} changes
         * @return {?}
         */

      }, {
        key: "_updateDisabled",
        value: function _updateDisabled(changes) {
          var _this214 = this;

          /** @type {?} */
          var disabledValue = changes['isDisabled'].currentValue;
          /** @type {?} */

          var isDisabled = disabledValue === '' || disabledValue && disabledValue !== 'false';
          resolvedPromise$1.then(
          /**
          * @return {?}
          */
          function () {
            if (isDisabled && !_this214.control.disabled) {
              _this214.control.disable();
            } else if (!isDisabled && _this214.control.disabled) {
              _this214.control.enable();
            }
          });
        }
      }, {
        key: "path",
        get: function get() {
          return this._parent ? controlPath(this.name, this._parent) : [this.name];
        }
        /**
         * \@description
         * The top-level directive for this control if present, otherwise null.
         * @return {?}
         */

      }, {
        key: "formDirective",
        get: function get() {
          return this._parent ? this._parent.formDirective : null;
        }
        /**
         * \@description
         * Synchronous validator function composed of all the synchronous validators
         * registered with this directive.
         * @return {?}
         */

      }, {
        key: "validator",
        get: function get() {
          return composeValidators(this._rawValidators);
        }
        /**
         * \@description
         * Async validator function composed of all the async validators registered with this
         * directive.
         * @return {?}
         */

      }, {
        key: "asyncValidator",
        get: function get() {
          return composeAsyncValidators(this._rawAsyncValidators);
        }
      }]);

      return NgModel;
    }(NgControl);

    NgModel.ɵfac = function NgModel_Factory(t) {
      return new (t || NgModel)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](ControlContainer, 9), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_VALIDATORS, 10), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_ASYNC_VALIDATORS, 10), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_VALUE_ACCESSOR, 10));
    };

    NgModel.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: NgModel,
      selectors: [["", "ngModel", "", 3, "formControlName", "", 3, "formControl", ""]],
      inputs: {
        name: "name",
        isDisabled: ["disabled", "isDisabled"],
        model: ["ngModel", "model"],
        options: ["ngModelOptions", "options"]
      },
      outputs: {
        update: "ngModelChange"
      },
      exportAs: ["ngModel"],
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([formControlBinding]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"], _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵNgOnChangesFeature"]]
    });
    /** @nocollapse */

    NgModel.ctorParameters = function () {
      return [{
        type: ControlContainer,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"]
        }]
      }, {
        type: Array,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_VALIDATORS]
        }]
      }, {
        type: Array,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_ASYNC_VALIDATORS]
        }]
      }, {
        type: Array,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_VALUE_ACCESSOR]
        }]
      }];
    };

    NgModel.propDecorators = {
      name: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }],
      isDisabled: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['disabled']
      }],
      model: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['ngModel']
      }],
      options: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['ngModelOptions']
      }],
      update: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Output"],
        args: ['ngModelChange']
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NgModel, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[ngModel]:not([formControlName]):not([formControl])',
          providers: [formControlBinding],
          exportAs: 'ngModel'
        }]
      }], function () {
        return [{
          type: ControlContainer,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"]
          }]
        }, {
          type: Array,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_VALIDATORS]
          }]
        }, {
          type: Array,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_ASYNC_VALIDATORS]
          }]
        }, {
          type: Array,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_VALUE_ACCESSOR]
          }]
        }];
      }, {
        update: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Output"],
          args: ['ngModelChange']
        }],
        name: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }],
        isDisabled: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['disabled']
        }],
        model: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['ngModel']
        }],
        options: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['ngModelOptions']
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/ng_no_validate_directive.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@description
     *
     * Adds `novalidate` attribute to all forms by default.
     *
     * `novalidate` is used to disable browser's native form validation.
     *
     * If you want to use native validation with Angular forms, just add `ngNativeValidate` attribute:
     *
     * ```
     * <form ngNativeValidate></form>
     * ```
     *
     * \@publicApi
     * \@ngModule ReactiveFormsModule
     * \@ngModule FormsModule
     */


    var ɵNgNoValidate = function ɵNgNoValidate() {
      _classCallCheck(this, ɵNgNoValidate);
    };

    ɵNgNoValidate.ɵfac = function ɵNgNoValidate_Factory(t) {
      return new (t || ɵNgNoValidate)();
    };

    ɵNgNoValidate.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: ɵNgNoValidate,
      selectors: [["form", 3, "ngNoForm", "", 3, "ngNativeValidate", ""]],
      hostAttrs: ["novalidate", ""]
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](ɵNgNoValidate, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: 'form:not([ngNoForm]):not([ngNativeValidate])',
          host: {
            'novalidate': ''
          }
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/reactive_directives/form_control_directive.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Token to provide to turn off the ngModel warning on formControl and formControlName.
     * @type {?}
     */


    var NG_MODEL_WITH_FORM_CONTROL_WARNING = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('NgModelWithFormControlWarning');
    /** @type {?} */

    var formControlBinding$1 = {
      provide: NgControl,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return FormControlDirective;
      })
    };
    /**
     * \@description
     * Synchronizes a standalone `FormControl` instance to a form control element.
     *
     * Note that support for using the `ngModel` input property and `ngModelChange` event with reactive
     * form directives was deprecated in Angular v6 and is scheduled for removal in
     * a future version of Angular.
     * For details, see [Deprecated features](guide/deprecations#ngmodel-with-reactive-forms).
     *
     * @see [Reactive Forms Guide](guide/reactive-forms)
     * @see `FormControl`
     * @see `AbstractControl`
     *
     * \@usageNotes
     *
     * The following example shows how to register a standalone control and set its value.
     *
     * {\@example forms/ts/simpleFormControl/simple_form_control_example.ts region='Component'}
     *
     * \@ngModule ReactiveFormsModule
     * \@publicApi
     */

    var FormControlDirective = /*#__PURE__*/function (_NgControl2) {
      _inherits(FormControlDirective, _NgControl2);

      var _super62 = _createSuper(FormControlDirective);

      /**
       * @param {?} validators
       * @param {?} asyncValidators
       * @param {?} valueAccessors
       * @param {?} _ngModelWarningConfig
       */
      function FormControlDirective(validators, asyncValidators, valueAccessors, _ngModelWarningConfig) {
        var _this215;

        _classCallCheck(this, FormControlDirective);

        _this215 = _super62.call(this);
        _this215._ngModelWarningConfig = _ngModelWarningConfig;
        /**
         * @deprecated as of v6
         */

        _this215.update = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"]();
        /**
         * \@description
         * Instance property used to track whether an ngModel warning has been sent out for this
         * particular `FormControlDirective` instance. Used to support warning config of "always".
         *
         * \@internal
         */

        _this215._ngModelWarningSent = false;
        _this215._rawValidators = validators || [];
        _this215._rawAsyncValidators = asyncValidators || [];
        _this215.valueAccessor = selectValueAccessor(_assertThisInitialized(_this215), valueAccessors);
        return _this215;
      }
      /**
       * \@description
       * Triggers a warning that this input should not be used with reactive forms.
       * @param {?} isDisabled
       * @return {?}
       */


      _createClass2(FormControlDirective, [{
        key: "ngOnChanges",

        /**
         * \@description
         * A lifecycle method called when the directive's inputs change. For internal use
         * only.
         *
         * @param {?} changes A object of key/value pairs for the set of changed inputs.
         * @return {?}
         */
        value: function ngOnChanges(changes) {
          if (this._isControlChanged(changes)) {
            setUpControl(this.form, this);

            if (this.control.disabled &&
            /** @type {?} */
            this.valueAccessor.setDisabledState) {
              /** @type {?} */

              /** @type {?} */
              this.valueAccessor.setDisabledState(true);
            }

            this.form.updateValueAndValidity({
              emitEvent: false
            });
          }

          if (isPropertyUpdated(changes, this.viewModel)) {
            _ngModelWarning('formControl', FormControlDirective, this, this._ngModelWarningConfig);

            this.form.setValue(this.model);
            this.viewModel = this.model;
          }
        }
        /**
         * \@description
         * Returns an array that represents the path from the top-level form to this control.
         * Each index is the string name of the control on that level.
         * @return {?}
         */

      }, {
        key: "viewToModelUpdate",

        /**
         * \@description
         * Sets the new value for the view model and emits an `ngModelChange` event.
         *
         * @param {?} newValue The new value for the view model.
         * @return {?}
         */
        value: function viewToModelUpdate(newValue) {
          this.viewModel = newValue;
          this.update.emit(newValue);
        }
        /**
         * @private
         * @param {?} changes
         * @return {?}
         */

      }, {
        key: "_isControlChanged",
        value: function _isControlChanged(changes) {
          return changes.hasOwnProperty('form');
        }
      }, {
        key: "isDisabled",
        set: function set(isDisabled) {
          ReactiveErrors.disabledAttrWarning();
        }
      }, {
        key: "path",
        get: function get() {
          return [];
        }
        /**
         * \@description
         * Synchronous validator function composed of all the synchronous validators
         * registered with this directive.
         * @return {?}
         */

      }, {
        key: "validator",
        get: function get() {
          return composeValidators(this._rawValidators);
        }
        /**
         * \@description
         * Async validator function composed of all the async validators registered with this
         * directive.
         * @return {?}
         */

      }, {
        key: "asyncValidator",
        get: function get() {
          return composeAsyncValidators(this._rawAsyncValidators);
        }
        /**
         * \@description
         * The `FormControl` bound to this directive.
         * @return {?}
         */

      }, {
        key: "control",
        get: function get() {
          return this.form;
        }
      }]);

      return FormControlDirective;
    }(NgControl);

    FormControlDirective.ɵfac = function FormControlDirective_Factory(t) {
      return new (t || FormControlDirective)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_VALIDATORS, 10), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_ASYNC_VALIDATORS, 10), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_VALUE_ACCESSOR, 10), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_MODEL_WITH_FORM_CONTROL_WARNING, 8));
    };

    FormControlDirective.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: FormControlDirective,
      selectors: [["", "formControl", ""]],
      inputs: {
        isDisabled: ["disabled", "isDisabled"],
        form: ["formControl", "form"],
        model: ["ngModel", "model"]
      },
      outputs: {
        update: "ngModelChange"
      },
      exportAs: ["ngForm"],
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([formControlBinding$1]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"], _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵNgOnChangesFeature"]]
    });
    /**
     * \@description
     * Static property used to track whether any ngModel warnings have been sent across
     * all instances of FormControlDirective. Used to support warning config of "once".
     *
     * \@internal
     */

    FormControlDirective._ngModelWarningSentOnce = false;
    /** @nocollapse */

    FormControlDirective.ctorParameters = function () {
      return [{
        type: Array,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_VALIDATORS]
        }]
      }, {
        type: Array,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_ASYNC_VALIDATORS]
        }]
      }, {
        type: Array,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_VALUE_ACCESSOR]
        }]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_MODEL_WITH_FORM_CONTROL_WARNING]
        }]
      }];
    };

    FormControlDirective.propDecorators = {
      form: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['formControl']
      }],
      isDisabled: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['disabled']
      }],
      model: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['ngModel']
      }],
      update: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Output"],
        args: ['ngModelChange']
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](FormControlDirective, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[formControl]',
          providers: [formControlBinding$1],
          exportAs: 'ngForm'
        }]
      }], function () {
        return [{
          type: Array,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_VALIDATORS]
          }]
        }, {
          type: Array,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_ASYNC_VALIDATORS]
          }]
        }, {
          type: Array,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_VALUE_ACCESSOR]
          }]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_MODEL_WITH_FORM_CONTROL_WARNING]
          }]
        }];
      }, {
        update: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Output"],
          args: ['ngModelChange']
        }],
        isDisabled: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['disabled']
        }],
        form: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['formControl']
        }],
        model: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['ngModel']
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/reactive_directives/form_group_directive.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var formDirectiveProvider$1 = {
      provide: ControlContainer,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return FormGroupDirective;
      })
    };
    /**
     * \@description
     *
     * Binds an existing `FormGroup` to a DOM element.
     *
     * This directive accepts an existing `FormGroup` instance. It will then use this
     * `FormGroup` instance to match any child `FormControl`, `FormGroup`,
     * and `FormArray` instances to child `FormControlName`, `FormGroupName`,
     * and `FormArrayName` directives.
     *
     * @see [Reactive Forms Guide](guide/reactive-forms)
     * @see `AbstractControl`
     *
     * ### Register Form Group
     *
     * The following example registers a `FormGroup` with first name and last name controls,
     * and listens for the *ngSubmit* event when the button is clicked.
     *
     * {\@example forms/ts/simpleFormGroup/simple_form_group_example.ts region='Component'}
     *
     * \@ngModule ReactiveFormsModule
     * \@publicApi
     */

    var FormGroupDirective = /*#__PURE__*/function (_ControlContainer3) {
      _inherits(FormGroupDirective, _ControlContainer3);

      var _super63 = _createSuper(FormGroupDirective);

      /**
       * @param {?} _validators
       * @param {?} _asyncValidators
       */
      function FormGroupDirective(_validators, _asyncValidators) {
        var _this216;

        _classCallCheck(this, FormGroupDirective);

        _this216 = _super63.call(this);
        _this216._validators = _validators;
        _this216._asyncValidators = _asyncValidators;
        /**
         * \@description
         * Reports whether the form submission has been triggered.
         */

        _this216.submitted = false;
        /**
         * \@description
         * Tracks the list of added `FormControlName` instances
         */

        _this216.directives = [];
        /**
         * \@description
         * Tracks the `FormGroup` bound to this directive.
         */

        _this216.form =
        /** @type {?} */
        null;
        /**
         * \@description
         * Emits an event when the form submission has been triggered.
         */

        _this216.ngSubmit = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"]();
        return _this216;
      }
      /**
       * \@description
       * A lifecycle method called when the directive's inputs change. For internal use only.
       *
       * @param {?} changes A object of key/value pairs for the set of changed inputs.
       * @return {?}
       */


      _createClass2(FormGroupDirective, [{
        key: "ngOnChanges",
        value: function ngOnChanges(changes) {
          this._checkFormPresent();

          if (changes.hasOwnProperty('form')) {
            this._updateValidators();

            this._updateDomValue();

            this._updateRegistrations();
          }
        }
        /**
         * \@description
         * Returns this directive's instance.
         * @return {?}
         */

      }, {
        key: "addControl",

        /**
         * \@description
         * Method that sets up the control directive in this group, re-calculates its value
         * and validity, and adds the instance to the internal list of directives.
         *
         * @param {?} dir The `FormControlName` directive instance.
         * @return {?}
         */
        value: function addControl(dir) {
          /** @type {?} */
          var ctrl = this.form.get(dir.path);
          setUpControl(ctrl, dir);
          ctrl.updateValueAndValidity({
            emitEvent: false
          });
          this.directives.push(dir);
          return ctrl;
        }
        /**
         * \@description
         * Retrieves the `FormControl` instance from the provided `FormControlName` directive
         *
         * @param {?} dir The `FormControlName` directive instance.
         * @return {?}
         */

      }, {
        key: "getControl",
        value: function getControl(dir) {
          return (
            /** @type {?} */
            this.form.get(dir.path)
          );
        }
        /**
         * \@description
         * Removes the `FormControlName` instance from the internal list of directives
         *
         * @param {?} dir The `FormControlName` directive instance.
         * @return {?}
         */

      }, {
        key: "removeControl",
        value: function removeControl(dir) {
          removeDir(this.directives, dir);
        }
        /**
         * Adds a new `FormGroupName` directive instance to the form.
         *
         * @param {?} dir The `FormGroupName` directive instance.
         * @return {?}
         */

      }, {
        key: "addFormGroup",
        value: function addFormGroup(dir) {
          /** @type {?} */
          var ctrl = this.form.get(dir.path);
          setUpFormContainer(ctrl, dir);
          ctrl.updateValueAndValidity({
            emitEvent: false
          });
        }
        /**
         * No-op method to remove the form group.
         *
         * @param {?} dir The `FormGroupName` directive instance.
         * @return {?}
         */

      }, {
        key: "removeFormGroup",
        value: function removeFormGroup(dir) {}
        /**
         * \@description
         * Retrieves the `FormGroup` for a provided `FormGroupName` directive instance
         *
         * @param {?} dir The `FormGroupName` directive instance.
         * @return {?}
         */

      }, {
        key: "getFormGroup",
        value: function getFormGroup(dir) {
          return (
            /** @type {?} */
            this.form.get(dir.path)
          );
        }
        /**
         * Adds a new `FormArrayName` directive instance to the form.
         *
         * @param {?} dir The `FormArrayName` directive instance.
         * @return {?}
         */

      }, {
        key: "addFormArray",
        value: function addFormArray(dir) {
          /** @type {?} */
          var ctrl = this.form.get(dir.path);
          setUpFormContainer(ctrl, dir);
          ctrl.updateValueAndValidity({
            emitEvent: false
          });
        }
        /**
         * No-op method to remove the form array.
         *
         * @param {?} dir The `FormArrayName` directive instance.
         * @return {?}
         */

      }, {
        key: "removeFormArray",
        value: function removeFormArray(dir) {}
        /**
         * \@description
         * Retrieves the `FormArray` for a provided `FormArrayName` directive instance.
         *
         * @param {?} dir The `FormArrayName` directive instance.
         * @return {?}
         */

      }, {
        key: "getFormArray",
        value: function getFormArray(dir) {
          return (
            /** @type {?} */
            this.form.get(dir.path)
          );
        }
        /**
         * Sets the new value for the provided `FormControlName` directive.
         *
         * @param {?} dir The `FormControlName` directive instance.
         * @param {?} value The new value for the directive's control.
         * @return {?}
         */

      }, {
        key: "updateModel",
        value: function updateModel(dir, value) {
          /** @type {?} */
          var ctrl =
          /** @type {?} */
          this.form.get(dir.path);
          ctrl.setValue(value);
        }
        /**
         * \@description
         * Method called with the "submit" event is triggered on the form.
         * Triggers the `ngSubmit` emitter to emit the "submit" event as its payload.
         *
         * @param {?} $event The "submit" event object
         * @return {?}
         */

      }, {
        key: "onSubmit",
        value: function onSubmit($event) {
          /** @type {?} */
          this.submitted = true;
          syncPendingControls(this.form, this.directives);
          this.ngSubmit.emit($event);
          return false;
        }
        /**
         * \@description
         * Method called when the "reset" event is triggered on the form.
         * @return {?}
         */

      }, {
        key: "onReset",
        value: function onReset() {
          this.resetForm();
        }
        /**
         * \@description
         * Resets the form to an initial value and resets its submitted status.
         *
         * @param {?=} value The new value for the form.
         * @return {?}
         */

      }, {
        key: "resetForm",
        value: function resetForm() {
          var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : undefined;
          this.form.reset(value);

          /** @type {?} */
          this.submitted = false;
        }
        /**
         * \@internal
         * @return {?}
         */

      }, {
        key: "_updateDomValue",
        value: function _updateDomValue() {
          var _this217 = this;

          this.directives.forEach(
          /**
          * @param {?} dir
          * @return {?}
          */
          function (dir) {
            /** @type {?} */
            var newCtrl = _this217.form.get(dir.path);

            if (dir.control !== newCtrl) {
              cleanUpControl(dir.control, dir);
              if (newCtrl) setUpControl(newCtrl, dir);

              /** @type {?} */
              dir.control = newCtrl;
            }
          });

          this.form._updateTreeValidity({
            emitEvent: false
          });
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_updateRegistrations",
        value: function _updateRegistrations() {
          var _this218 = this;

          this.form._registerOnCollectionChange(
          /**
          * @return {?}
          */
          function () {
            return _this218._updateDomValue();
          });

          if (this._oldForm) this._oldForm._registerOnCollectionChange(
          /**
          * @return {?}
          */
          function () {});
          this._oldForm = this.form;
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_updateValidators",
        value: function _updateValidators() {
          /** @type {?} */
          var sync = composeValidators(this._validators);
          this.form.validator = Validators.compose([
          /** @type {?} */
          this.form.validator,
          /** @type {?} */
          sync]);
          /** @type {?} */

          var async = composeAsyncValidators(this._asyncValidators);
          this.form.asyncValidator = Validators.composeAsync([
          /** @type {?} */
          this.form.asyncValidator,
          /** @type {?} */
          async]);
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_checkFormPresent",
        value: function _checkFormPresent() {
          if (!this.form) {
            ReactiveErrors.missingFormException();
          }
        }
      }, {
        key: "formDirective",
        get: function get() {
          return this;
        }
        /**
         * \@description
         * Returns the `FormGroup` bound to this directive.
         * @return {?}
         */

      }, {
        key: "control",
        get: function get() {
          return this.form;
        }
        /**
         * \@description
         * Returns an array representing the path to this group. Because this directive
         * always lives at the top level of a form, it always an empty array.
         * @return {?}
         */

      }, {
        key: "path",
        get: function get() {
          return [];
        }
      }]);

      return FormGroupDirective;
    }(ControlContainer);

    FormGroupDirective.ɵfac = function FormGroupDirective_Factory(t) {
      return new (t || FormGroupDirective)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_VALIDATORS, 10), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_ASYNC_VALIDATORS, 10));
    };

    FormGroupDirective.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: FormGroupDirective,
      selectors: [["", "formGroup", ""]],
      hostBindings: function FormGroupDirective_HostBindings(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵlistener"]("submit", function FormGroupDirective_submit_HostBindingHandler($event) {
            return ctx.onSubmit($event);
          })("reset", function FormGroupDirective_reset_HostBindingHandler() {
            return ctx.onReset();
          });
        }
      },
      inputs: {
        form: ["formGroup", "form"]
      },
      outputs: {
        ngSubmit: "ngSubmit"
      },
      exportAs: ["ngForm"],
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([formDirectiveProvider$1]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"], _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵNgOnChangesFeature"]]
    });
    /** @nocollapse */

    FormGroupDirective.ctorParameters = function () {
      return [{
        type: Array,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_VALIDATORS]
        }]
      }, {
        type: Array,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_ASYNC_VALIDATORS]
        }]
      }];
    };

    FormGroupDirective.propDecorators = {
      form: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['formGroup']
      }],
      ngSubmit: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Output"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](FormGroupDirective, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[formGroup]',
          providers: [formDirectiveProvider$1],
          host: {
            '(submit)': 'onSubmit($event)',
            '(reset)': 'onReset()'
          },
          exportAs: 'ngForm'
        }]
      }], function () {
        return [{
          type: Array,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_VALIDATORS]
          }]
        }, {
          type: Array,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_ASYNC_VALIDATORS]
          }]
        }];
      }, {
        form: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['formGroup']
        }],
        ngSubmit: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Output"]
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/reactive_directives/form_group_name.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var formGroupNameProvider = {
      provide: ControlContainer,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return FormGroupName;
      })
    };
    /**
     * \@description
     *
     * Syncs a nested `FormGroup` to a DOM element.
     *
     * This directive can only be used with a parent `FormGroupDirective`.
     *
     * It accepts the string name of the nested `FormGroup` to link, and
     * looks for a `FormGroup` registered with that name in the parent
     * `FormGroup` instance you passed into `FormGroupDirective`.
     *
     * Use nested form groups to validate a sub-group of a
     * form separately from the rest or to group the values of certain
     * controls into their own nested object.
     *
     * @see [Reactive Forms Guide](guide/reactive-forms)
     *
     * \@usageNotes
     *
     * ### Access the group by name
     *
     * The following example uses the {\@link AbstractControl#get get} method to access the
     * associated `FormGroup`
     *
     * ```ts
     *   this.form.get('name');
     * ```
     *
     * ### Access individual controls in the group
     *
     * The following example uses the {\@link AbstractControl#get get} method to access
     * individual controls within the group using dot syntax.
     *
     * ```ts
     *   this.form.get('name.first');
     * ```
     *
     * ### Register a nested `FormGroup`.
     *
     * The following example registers a nested *name* `FormGroup` within an existing `FormGroup`,
     * and provides methods to retrieve the nested `FormGroup` and individual controls.
     *
     * {\@example forms/ts/nestedFormGroup/nested_form_group_example.ts region='Component'}
     *
     * \@ngModule ReactiveFormsModule
     * \@publicApi
     */

    var FormGroupName = /*#__PURE__*/function (_AbstractFormGroupDir2) {
      _inherits(FormGroupName, _AbstractFormGroupDir2);

      var _super64 = _createSuper(FormGroupName);

      /**
       * @param {?} parent
       * @param {?} validators
       * @param {?} asyncValidators
       */
      function FormGroupName(parent, validators, asyncValidators) {
        var _this219;

        _classCallCheck(this, FormGroupName);

        _this219 = _super64.call(this);
        _this219._parent = parent;
        _this219._validators = validators;
        _this219._asyncValidators = asyncValidators;
        return _this219;
      }
      /**
       * \@internal
       * @return {?}
       */


      _createClass2(FormGroupName, [{
        key: "_checkParentType",
        value: function _checkParentType() {
          if (_hasInvalidParent(this._parent)) {
            ReactiveErrors.groupParentException();
          }
        }
      }]);

      return FormGroupName;
    }(AbstractFormGroupDirective);

    FormGroupName.ɵfac = function FormGroupName_Factory(t) {
      return new (t || FormGroupName)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](ControlContainer, 13), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_VALIDATORS, 10), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_ASYNC_VALIDATORS, 10));
    };

    FormGroupName.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: FormGroupName,
      selectors: [["", "formGroupName", ""]],
      inputs: {
        name: ["formGroupName", "name"]
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([formGroupNameProvider]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]]
    });
    /** @nocollapse */

    FormGroupName.ctorParameters = function () {
      return [{
        type: ControlContainer,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["SkipSelf"]
        }]
      }, {
        type: Array,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_VALIDATORS]
        }]
      }, {
        type: Array,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_ASYNC_VALIDATORS]
        }]
      }];
    };

    FormGroupName.propDecorators = {
      name: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['formGroupName']
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](FormGroupName, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[formGroupName]',
          providers: [formGroupNameProvider]
        }]
      }], function () {
        return [{
          type: ControlContainer,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["SkipSelf"]
          }]
        }, {
          type: Array,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_VALIDATORS]
          }]
        }, {
          type: Array,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_ASYNC_VALIDATORS]
          }]
        }];
      }, {
        name: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['formGroupName']
        }]
      });
    })();

    if (false) {}
    /** @type {?} */


    var formArrayNameProvider = {
      provide: ControlContainer,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return FormArrayName;
      })
    };
    /**
     * \@description
     *
     * Syncs a nested `FormArray` to a DOM element.
     *
     * This directive is designed to be used with a parent `FormGroupDirective` (selector:
     * `[formGroup]`).
     *
     * It accepts the string name of the nested `FormArray` you want to link, and
     * will look for a `FormArray` registered with that name in the parent
     * `FormGroup` instance you passed into `FormGroupDirective`.
     *
     * @see [Reactive Forms Guide](guide/reactive-forms)
     * @see `AbstractControl`
     *
     * \@usageNotes
     *
     * ### Example
     *
     * {\@example forms/ts/nestedFormArray/nested_form_array_example.ts region='Component'}
     *
     * \@ngModule ReactiveFormsModule
     * \@publicApi
     */

    var FormArrayName = /*#__PURE__*/function (_ControlContainer4) {
      _inherits(FormArrayName, _ControlContainer4);

      var _super65 = _createSuper(FormArrayName);

      /**
       * @param {?} parent
       * @param {?} validators
       * @param {?} asyncValidators
       */
      function FormArrayName(parent, validators, asyncValidators) {
        var _this220;

        _classCallCheck(this, FormArrayName);

        _this220 = _super65.call(this);
        _this220._parent = parent;
        _this220._validators = validators;
        _this220._asyncValidators = asyncValidators;
        return _this220;
      }
      /**
       * \@description
       * A lifecycle method called when the directive's inputs are initialized. For internal use only.
       *
       * @throws If the directive does not have a valid parent.
       * @return {?}
       */


      _createClass2(FormArrayName, [{
        key: "ngOnInit",
        value: function ngOnInit() {
          this._checkParentType();

          /** @type {?} */
          this.formDirective.addFormArray(this);
        }
        /**
         * \@description
         * A lifecycle method called before the directive's instance is destroyed. For internal use only.
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          if (this.formDirective) {
            this.formDirective.removeFormArray(this);
          }
        }
        /**
         * \@description
         * The `FormArray` bound to this directive.
         * @return {?}
         */

      }, {
        key: "_checkParentType",

        /**
         * @private
         * @return {?}
         */
        value: function _checkParentType() {
          if (_hasInvalidParent(this._parent)) {
            ReactiveErrors.arrayParentException();
          }
        }
      }, {
        key: "control",
        get: function get() {
          return (
            /** @type {?} */
            this.formDirective.getFormArray(this)
          );
        }
        /**
         * \@description
         * The top-level directive for this group if present, otherwise null.
         * @return {?}
         */

      }, {
        key: "formDirective",
        get: function get() {
          return this._parent ?
          /** @type {?} */
          this._parent.formDirective : null;
        }
        /**
         * \@description
         * Returns an array that represents the path from the top-level form to this control.
         * Each index is the string name of the control on that level.
         * @return {?}
         */

      }, {
        key: "path",
        get: function get() {
          return controlPath(this.name == null ? this.name : this.name.toString(), this._parent);
        }
        /**
         * \@description
         * Synchronous validator function composed of all the synchronous validators registered with this
         * directive.
         * @return {?}
         */

      }, {
        key: "validator",
        get: function get() {
          return composeValidators(this._validators);
        }
        /**
         * \@description
         * Async validator function composed of all the async validators registered with this directive.
         * @return {?}
         */

      }, {
        key: "asyncValidator",
        get: function get() {
          return composeAsyncValidators(this._asyncValidators);
        }
      }]);

      return FormArrayName;
    }(ControlContainer);

    FormArrayName.ɵfac = function FormArrayName_Factory(t) {
      return new (t || FormArrayName)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](ControlContainer, 13), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_VALIDATORS, 10), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_ASYNC_VALIDATORS, 10));
    };

    FormArrayName.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: FormArrayName,
      selectors: [["", "formArrayName", ""]],
      inputs: {
        name: ["formArrayName", "name"]
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([formArrayNameProvider]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]]
    });
    /** @nocollapse */

    FormArrayName.ctorParameters = function () {
      return [{
        type: ControlContainer,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["SkipSelf"]
        }]
      }, {
        type: Array,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_VALIDATORS]
        }]
      }, {
        type: Array,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_ASYNC_VALIDATORS]
        }]
      }];
    };

    FormArrayName.propDecorators = {
      name: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['formArrayName']
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](FormArrayName, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[formArrayName]',
          providers: [formArrayNameProvider]
        }]
      }], function () {
        return [{
          type: ControlContainer,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["SkipSelf"]
          }]
        }, {
          type: Array,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_VALIDATORS]
          }]
        }, {
          type: Array,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_ASYNC_VALIDATORS]
          }]
        }];
      }, {
        name: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['formArrayName']
        }]
      });
    })();

    if (false) {}
    /**
     * @param {?} parent
     * @return {?}
     */


    function _hasInvalidParent(parent) {
      return !(parent instanceof FormGroupName) && !(parent instanceof FormGroupDirective) && !(parent instanceof FormArrayName);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/reactive_directives/form_control_name.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var controlNameBinding = {
      provide: NgControl,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return FormControlName;
      })
    };
    /**
     * \@description
     * Syncs a `FormControl` in an existing `FormGroup` to a form control
     * element by name.
     *
     * @see [Reactive Forms Guide](guide/reactive-forms)
     * @see `FormControl`
     * @see `AbstractControl`
     *
     * \@usageNotes
     *
     * ### Register `FormControl` within a group
     *
     * The following example shows how to register multiple form controls within a form group
     * and set their value.
     *
     * {\@example forms/ts/simpleFormGroup/simple_form_group_example.ts region='Component'}
     *
     * To see `formControlName` examples with different form control types, see:
     *
     * * Radio buttons: `RadioControlValueAccessor`
     * * Selects: `SelectControlValueAccessor`
     *
     * ### Use with ngModel is deprecated
     *
     * Support for using the `ngModel` input property and `ngModelChange` event with reactive
     * form directives has been deprecated in Angular v6 and is scheduled for removal in
     * a future version of Angular.
     *
     * For details, see [Deprecated features](guide/deprecations#ngmodel-with-reactive-forms).
     *
     * \@ngModule ReactiveFormsModule
     * \@publicApi
     */

    var FormControlName = /*#__PURE__*/function (_NgControl3) {
      _inherits(FormControlName, _NgControl3);

      var _super66 = _createSuper(FormControlName);

      /**
       * @param {?} parent
       * @param {?} validators
       * @param {?} asyncValidators
       * @param {?} valueAccessors
       * @param {?} _ngModelWarningConfig
       */
      function FormControlName(parent, validators, asyncValidators, valueAccessors, _ngModelWarningConfig) {
        var _this221;

        _classCallCheck(this, FormControlName);

        _this221 = _super66.call(this);
        _this221._ngModelWarningConfig = _ngModelWarningConfig;
        _this221._added = false;
        /**
         * @deprecated as of v6
         */

        _this221.update = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"]();
        /**
         * \@description
         * Instance property used to track whether an ngModel warning has been sent out for this
         * particular FormControlName instance. Used to support warning config of "always".
         *
         * \@internal
         */

        _this221._ngModelWarningSent = false;
        _this221._parent = parent;
        _this221._rawValidators = validators || [];
        _this221._rawAsyncValidators = asyncValidators || [];
        _this221.valueAccessor = selectValueAccessor(_assertThisInitialized(_this221), valueAccessors);
        return _this221;
      }
      /**
       * \@description
       * Triggers a warning that this input should not be used with reactive forms.
       * @param {?} isDisabled
       * @return {?}
       */


      _createClass2(FormControlName, [{
        key: "ngOnChanges",

        /**
         * \@description
         * A lifecycle method called when the directive's inputs change. For internal use only.
         *
         * @param {?} changes A object of key/value pairs for the set of changed inputs.
         * @return {?}
         */
        value: function ngOnChanges(changes) {
          if (!this._added) this._setUpControl();

          if (isPropertyUpdated(changes, this.viewModel)) {
            _ngModelWarning('formControlName', FormControlName, this, this._ngModelWarningConfig);

            this.viewModel = this.model;
            this.formDirective.updateModel(this, this.model);
          }
        }
        /**
         * \@description
         * Lifecycle method called before the directive's instance is destroyed. For internal use only.
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          if (this.formDirective) {
            this.formDirective.removeControl(this);
          }
        }
        /**
         * \@description
         * Sets the new value for the view model and emits an `ngModelChange` event.
         *
         * @param {?} newValue The new value for the view model.
         * @return {?}
         */

      }, {
        key: "viewToModelUpdate",
        value: function viewToModelUpdate(newValue) {
          this.viewModel = newValue;
          this.update.emit(newValue);
        }
        /**
         * \@description
         * Returns an array that represents the path from the top-level form to this control.
         * Each index is the string name of the control on that level.
         * @return {?}
         */

      }, {
        key: "_checkParentType",

        /**
         * @private
         * @return {?}
         */
        value: function _checkParentType() {
          if (!(this._parent instanceof FormGroupName) && this._parent instanceof AbstractFormGroupDirective) {
            ReactiveErrors.ngModelGroupException();
          } else if (!(this._parent instanceof FormGroupName) && !(this._parent instanceof FormGroupDirective) && !(this._parent instanceof FormArrayName)) {
            ReactiveErrors.controlParentException();
          }
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_setUpControl",
        value: function _setUpControl() {
          this._checkParentType();

          /** @type {?} */
          this.control = this.formDirective.addControl(this);

          if (this.control.disabled &&
          /** @type {?} */
          this.valueAccessor.setDisabledState) {
            /** @type {?} */

            /** @type {?} */
            this.valueAccessor.setDisabledState(true);
          }

          this._added = true;
        }
      }, {
        key: "isDisabled",
        set: function set(isDisabled) {
          ReactiveErrors.disabledAttrWarning();
        }
      }, {
        key: "path",
        get: function get() {
          return controlPath(this.name == null ? this.name : this.name.toString(),
          /** @type {?} */
          this._parent);
        }
        /**
         * \@description
         * The top-level directive for this group if present, otherwise null.
         * @return {?}
         */

      }, {
        key: "formDirective",
        get: function get() {
          return this._parent ? this._parent.formDirective : null;
        }
        /**
         * \@description
         * Synchronous validator function composed of all the synchronous validators
         * registered with this directive.
         * @return {?}
         */

      }, {
        key: "validator",
        get: function get() {
          return composeValidators(this._rawValidators);
        }
        /**
         * \@description
         * Async validator function composed of all the async validators registered with this
         * directive.
         * @return {?}
         */

      }, {
        key: "asyncValidator",
        get: function get() {
          return (
            /** @type {?} */
            composeAsyncValidators(this._rawAsyncValidators)
          );
        }
      }]);

      return FormControlName;
    }(NgControl);

    FormControlName.ɵfac = function FormControlName_Factory(t) {
      return new (t || FormControlName)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](ControlContainer, 13), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_VALIDATORS, 10), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_ASYNC_VALIDATORS, 10), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_VALUE_ACCESSOR, 10), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NG_MODEL_WITH_FORM_CONTROL_WARNING, 8));
    };

    FormControlName.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: FormControlName,
      selectors: [["", "formControlName", ""]],
      inputs: {
        isDisabled: ["disabled", "isDisabled"],
        name: ["formControlName", "name"],
        model: ["ngModel", "model"]
      },
      outputs: {
        update: "ngModelChange"
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([controlNameBinding]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"], _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵNgOnChangesFeature"]]
    });
    /**
     * \@description
     * Static property used to track whether any ngModel warnings have been sent across
     * all instances of FormControlName. Used to support warning config of "once".
     *
     * \@internal
     */

    FormControlName._ngModelWarningSentOnce = false;
    /** @nocollapse */

    FormControlName.ctorParameters = function () {
      return [{
        type: ControlContainer,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["SkipSelf"]
        }]
      }, {
        type: Array,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_VALIDATORS]
        }]
      }, {
        type: Array,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_ASYNC_VALIDATORS]
        }]
      }, {
        type: Array,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_VALUE_ACCESSOR]
        }]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [NG_MODEL_WITH_FORM_CONTROL_WARNING]
        }]
      }];
    };

    FormControlName.propDecorators = {
      name: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['formControlName']
      }],
      isDisabled: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['disabled']
      }],
      model: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['ngModel']
      }],
      update: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Output"],
        args: ['ngModelChange']
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](FormControlName, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[formControlName]',
          providers: [controlNameBinding]
        }]
      }], function () {
        return [{
          type: ControlContainer,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Host"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["SkipSelf"]
          }]
        }, {
          type: Array,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_VALIDATORS]
          }]
        }, {
          type: Array,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_ASYNC_VALIDATORS]
          }]
        }, {
          type: Array,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Self"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_VALUE_ACCESSOR]
          }]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [NG_MODEL_WITH_FORM_CONTROL_WARNING]
          }]
        }];
      }, {
        update: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Output"],
          args: ['ngModelChange']
        }],
        isDisabled: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['disabled']
        }],
        name: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['formControlName']
        }],
        model: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['ngModel']
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives/validators.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@description
     * An interface implemented by classes that perform synchronous validation.
     *
     * \@usageNotes
     *
     * ### Provide a custom validator
     *
     * The following example implements the `Validator` interface to create a
     * validator directive with a custom error key.
     *
     * ```typescript
     * \@Directive({
     *   selector: '[customValidator]',
     *   providers: [{provide: NG_VALIDATORS, useExisting: CustomValidatorDirective, multi: true}]
     * })
     * class CustomValidatorDirective implements Validator {
     *   validate(control: AbstractControl): ValidationErrors|null {
     *     return {'custom': true};
     *   }
     * }
     * ```
     *
     * \@publicApi
     * @record
     */


    function Validator() {}

    if (false) {}
    /**
     * \@description
     * An interface implemented by classes that perform asynchronous validation.
     *
     * \@usageNotes
     *
     * ### Provide a custom async validator directive
     *
     * The following example implements the `AsyncValidator` interface to create an
     * async validator directive with a custom error key.
     *
     * ```typescript
     * import { of as observableOf } from 'rxjs';
     *
     * \@Directive({
     *   selector: '[customAsyncValidator]',
     *   providers: [{provide: NG_ASYNC_VALIDATORS, useExisting: CustomAsyncValidatorDirective, multi:
     * true}]
     * })
     * class CustomAsyncValidatorDirective implements AsyncValidator {
     *   validate(control: AbstractControl): Observable<ValidationErrors|null> {
     *     return observableOf({'custom': true});
     *   }
     * }
     * ```
     *
     * \@publicApi
     * @record
     */


    function AsyncValidator() {}

    if (false) {}
    /**
     * \@description
     * Provider which adds `RequiredValidator` to the `NG_VALIDATORS` multi-provider list.
     * @type {?}
     */


    var REQUIRED_VALIDATOR = {
      provide: NG_VALIDATORS,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return RequiredValidator;
      }),
      multi: true
    };
    /**
     * \@description
     * Provider which adds `CheckboxRequiredValidator` to the `NG_VALIDATORS` multi-provider list.
     * @type {?}
     */

    var CHECKBOX_REQUIRED_VALIDATOR = {
      provide: NG_VALIDATORS,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return CheckboxRequiredValidator;
      }),
      multi: true
    };
    /**
     * \@description
     * A directive that adds the `required` validator to any controls marked with the
     * `required` attribute. The directive is provided with the `NG_VALIDATORS` multi-provider list.
     *
     * @see [Form Validation](guide/form-validation)
     *
     * \@usageNotes
     *
     * ### Adding a required validator using template-driven forms
     *
     * ```
     * <input name="fullName" ngModel required>
     * ```
     *
     * \@ngModule FormsModule
     * \@ngModule ReactiveFormsModule
     * \@publicApi
     */

    var RequiredValidator = /*#__PURE__*/function () {
      function RequiredValidator() {
        _classCallCheck(this, RequiredValidator);
      }

      _createClass2(RequiredValidator, [{
        key: "validate",

        /**
         * \@description
         * Method that validates whether the control is empty.
         * Returns the validation result if enabled, otherwise null.
         * @param {?} control
         * @return {?}
         */
        value: function validate(control) {
          return this.required ? Validators.required(control) : null;
        }
        /**
         * \@description
         * Registers a callback function to call when the validator inputs change.
         *
         * @param {?} fn The callback function
         * @return {?}
         */

      }, {
        key: "registerOnValidatorChange",
        value: function registerOnValidatorChange(fn) {
          this._onChange = fn;
        }
      }, {
        key: "required",

        /**
         * \@description
         * Tracks changes to the required attribute bound to this directive.
         * @return {?}
         */
        get: function get() {
          return this._required;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._required = value != null && value !== false && "".concat(value) !== 'false';
          if (this._onChange) this._onChange();
        }
      }]);

      return RequiredValidator;
    }();

    RequiredValidator.ɵfac = function RequiredValidator_Factory(t) {
      return new (t || RequiredValidator)();
    };

    RequiredValidator.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: RequiredValidator,
      selectors: [["", "required", "", "formControlName", "", 3, "type", "checkbox"], ["", "required", "", "formControl", "", 3, "type", "checkbox"], ["", "required", "", "ngModel", "", 3, "type", "checkbox"]],
      hostVars: 1,
      hostBindings: function RequiredValidator_HostBindings(rf, ctx) {
        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵattribute"]("required", ctx.required ? "" : null);
        }
      },
      inputs: {
        required: "required"
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([REQUIRED_VALIDATOR])]
    });
    RequiredValidator.propDecorators = {
      required: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](RequiredValidator, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: ':not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]',
          providers: [REQUIRED_VALIDATOR],
          host: {
            '[attr.required]': 'required ? "" : null'
          }
        }]
      }], null, {
        required: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * A Directive that adds the `required` validator to checkbox controls marked with the
     * `required` attribute. The directive is provided with the `NG_VALIDATORS` multi-provider list.
     *
     * @see [Form Validation](guide/form-validation)
     *
     * \@usageNotes
     *
     * ### Adding a required checkbox validator using template-driven forms
     *
     * The following example shows how to add a checkbox required validator to an input attached to an
     * ngModel binding.
     *
     * ```
     * <input type="checkbox" name="active" ngModel required>
     * ```
     *
     * \@publicApi
     * \@ngModule FormsModule
     * \@ngModule ReactiveFormsModule
     */


    var CheckboxRequiredValidator = /*#__PURE__*/function (_RequiredValidator) {
      _inherits(CheckboxRequiredValidator, _RequiredValidator);

      var _super67 = _createSuper(CheckboxRequiredValidator);

      function CheckboxRequiredValidator() {
        _classCallCheck(this, CheckboxRequiredValidator);

        return _super67.apply(this, arguments);
      }

      _createClass2(CheckboxRequiredValidator, [{
        key: "validate",

        /**
         * \@description
         * Method that validates whether or not the checkbox has been checked.
         * Returns the validation result if enabled, otherwise null.
         * @param {?} control
         * @return {?}
         */
        value: function validate(control) {
          return this.required ? Validators.requiredTrue(control) : null;
        }
      }]);

      return CheckboxRequiredValidator;
    }(RequiredValidator);

    CheckboxRequiredValidator.ɵfac = function CheckboxRequiredValidator_Factory(t) {
      return ɵCheckboxRequiredValidator_BaseFactory(t || CheckboxRequiredValidator);
    };

    CheckboxRequiredValidator.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: CheckboxRequiredValidator,
      selectors: [["input", "type", "checkbox", "required", "", "formControlName", ""], ["input", "type", "checkbox", "required", "", "formControl", ""], ["input", "type", "checkbox", "required", "", "ngModel", ""]],
      hostVars: 1,
      hostBindings: function CheckboxRequiredValidator_HostBindings(rf, ctx) {
        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵattribute"]("required", ctx.required ? "" : null);
        }
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([CHECKBOX_REQUIRED_VALIDATOR]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]]
    });

    var ɵCheckboxRequiredValidator_BaseFactory = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵgetInheritedFactory"](CheckboxRequiredValidator);
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](CheckboxRequiredValidator, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: 'input[type=checkbox][required][formControlName],input[type=checkbox][required][formControl],input[type=checkbox][required][ngModel]',
          providers: [CHECKBOX_REQUIRED_VALIDATOR],
          host: {
            '[attr.required]': 'required ? "" : null'
          }
        }]
      }], null, null);
    })();
    /**
     * \@description
     * Provider which adds `EmailValidator` to the `NG_VALIDATORS` multi-provider list.
     * @type {?}
     */


    var EMAIL_VALIDATOR = {
      provide: NG_VALIDATORS,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return EmailValidator;
      }),
      multi: true
    };
    /**
     * A directive that adds the `email` validator to controls marked with the
     * `email` attribute. The directive is provided with the `NG_VALIDATORS` multi-provider list.
     *
     * @see [Form Validation](guide/form-validation)
     *
     * \@usageNotes
     *
     * ### Adding an email validator
     *
     * The following example shows how to add an email validator to an input attached to an ngModel
     * binding.
     *
     * ```
     * <input type="email" name="email" ngModel email>
     * <input type="email" name="email" ngModel email="true">
     * <input type="email" name="email" ngModel [email]="true">
     * ```
     *
     * \@publicApi
     * \@ngModule FormsModule
     * \@ngModule ReactiveFormsModule
     */

    var EmailValidator = /*#__PURE__*/function () {
      function EmailValidator() {
        _classCallCheck(this, EmailValidator);
      }

      _createClass2(EmailValidator, [{
        key: "validate",

        /**
         * \@description
         * Method that validates whether an email address is valid.
         * Returns the validation result if enabled, otherwise null.
         * @param {?} control
         * @return {?}
         */
        value: function validate(control) {
          return this._enabled ? Validators.email(control) : null;
        }
        /**
         * \@description
         * Registers a callback function to call when the validator inputs change.
         *
         * @param {?} fn The callback function
         * @return {?}
         */

      }, {
        key: "registerOnValidatorChange",
        value: function registerOnValidatorChange(fn) {
          this._onChange = fn;
        }
      }, {
        key: "email",

        /**
         * \@description
         * Tracks changes to the email attribute bound to this directive.
         * @param {?} value
         * @return {?}
         */
        set: function set(value) {
          this._enabled = value === '' || value === true || value === 'true';
          if (this._onChange) this._onChange();
        }
      }]);

      return EmailValidator;
    }();

    EmailValidator.ɵfac = function EmailValidator_Factory(t) {
      return new (t || EmailValidator)();
    };

    EmailValidator.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: EmailValidator,
      selectors: [["", "email", "", "formControlName", ""], ["", "email", "", "formControl", ""], ["", "email", "", "ngModel", ""]],
      inputs: {
        email: "email"
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([EMAIL_VALIDATOR])]
    });
    EmailValidator.propDecorators = {
      email: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](EmailValidator, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[email][formControlName],[email][formControl],[email][ngModel]',
          providers: [EMAIL_VALIDATOR]
        }]
      }], null, {
        email: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * \@description
     * A function that receives a control and synchronously returns a map of
     * validation errors if present, otherwise null.
     *
     * \@publicApi
     * @record
     */


    function ValidatorFn() {}
    /**
     * \@description
     * A function that receives a control and returns a Promise or observable
     * that emits validation errors if present, otherwise null.
     *
     * \@publicApi
     * @record
     */


    function AsyncValidatorFn() {}
    /**
     * \@description
     * Provider which adds `MinLengthValidator` to the `NG_VALIDATORS` multi-provider list.
     * @type {?}
     */


    var MIN_LENGTH_VALIDATOR = {
      provide: NG_VALIDATORS,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return MinLengthValidator;
      }),
      multi: true
    };
    /**
     * A directive that adds minimum length validation to controls marked with the
     * `minlength` attribute. The directive is provided with the `NG_VALIDATORS` multi-provider list.
     *
     * @see [Form Validation](guide/form-validation)
     *
     * \@usageNotes
     *
     * ### Adding a minimum length validator
     *
     * The following example shows how to add a minimum length validator to an input attached to an
     * ngModel binding.
     *
     * ```html
     * <input name="firstName" ngModel minlength="4">
     * ```
     *
     * \@ngModule ReactiveFormsModule
     * \@ngModule FormsModule
     * \@publicApi
     */

    var MinLengthValidator = /*#__PURE__*/function () {
      function MinLengthValidator() {
        _classCallCheck(this, MinLengthValidator);
      }

      _createClass2(MinLengthValidator, [{
        key: "ngOnChanges",

        /**
         * \@description
         * A lifecycle method called when the directive's inputs change. For internal use
         * only.
         *
         * @param {?} changes A object of key/value pairs for the set of changed inputs.
         * @return {?}
         */
        value: function ngOnChanges(changes) {
          if ('minlength' in changes) {
            this._createValidator();

            if (this._onChange) this._onChange();
          }
        }
        /**
         * \@description
         * Method that validates whether the value meets a minimum length
         * requirement. Returns the validation result if enabled, otherwise null.
         * @param {?} control
         * @return {?}
         */

      }, {
        key: "validate",
        value: function validate(control) {
          return this.minlength == null ? null : this._validator(control);
        }
        /**
         * \@description
         * Registers a callback function to call when the validator inputs change.
         *
         * @param {?} fn The callback function
         * @return {?}
         */

      }, {
        key: "registerOnValidatorChange",
        value: function registerOnValidatorChange(fn) {
          this._onChange = fn;
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_createValidator",
        value: function _createValidator() {
          this._validator = Validators.minLength(typeof this.minlength === 'number' ? this.minlength : parseInt(this.minlength, 10));
        }
      }]);

      return MinLengthValidator;
    }();

    MinLengthValidator.ɵfac = function MinLengthValidator_Factory(t) {
      return new (t || MinLengthValidator)();
    };

    MinLengthValidator.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: MinLengthValidator,
      selectors: [["", "minlength", "", "formControlName", ""], ["", "minlength", "", "formControl", ""], ["", "minlength", "", "ngModel", ""]],
      hostVars: 1,
      hostBindings: function MinLengthValidator_HostBindings(rf, ctx) {
        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵattribute"]("minlength", ctx.minlength ? ctx.minlength : null);
        }
      },
      inputs: {
        minlength: "minlength"
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([MIN_LENGTH_VALIDATOR]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵNgOnChangesFeature"]]
    });
    MinLengthValidator.propDecorators = {
      minlength: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MinLengthValidator, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[minlength][formControlName],[minlength][formControl],[minlength][ngModel]',
          providers: [MIN_LENGTH_VALIDATOR],
          host: {
            '[attr.minlength]': 'minlength ? minlength : null'
          }
        }]
      }], null, {
        minlength: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * \@description
     * Provider which adds `MaxLengthValidator` to the `NG_VALIDATORS` multi-provider list.
     * @type {?}
     */


    var MAX_LENGTH_VALIDATOR = {
      provide: NG_VALIDATORS,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return MaxLengthValidator;
      }),
      multi: true
    };
    /**
     * A directive that adds max length validation to controls marked with the
     * `maxlength` attribute. The directive is provided with the `NG_VALIDATORS` multi-provider list.
     *
     * @see [Form Validation](guide/form-validation)
     *
     * \@usageNotes
     *
     * ### Adding a maximum length validator
     *
     * The following example shows how to add a maximum length validator to an input attached to an
     * ngModel binding.
     *
     * ```html
     * <input name="firstName" ngModel maxlength="25">
     * ```
     *
     * \@ngModule ReactiveFormsModule
     * \@ngModule FormsModule
     * \@publicApi
     */

    var MaxLengthValidator = /*#__PURE__*/function () {
      function MaxLengthValidator() {
        _classCallCheck(this, MaxLengthValidator);
      }

      _createClass2(MaxLengthValidator, [{
        key: "ngOnChanges",

        /**
         * \@description
         * A lifecycle method called when the directive's inputs change. For internal use
         * only.
         *
         * @param {?} changes A object of key/value pairs for the set of changed inputs.
         * @return {?}
         */
        value: function ngOnChanges(changes) {
          if ('maxlength' in changes) {
            this._createValidator();

            if (this._onChange) this._onChange();
          }
        }
        /**
         * \@description
         * Method that validates whether the value exceeds
         * the maximum length requirement.
         * @param {?} control
         * @return {?}
         */

      }, {
        key: "validate",
        value: function validate(control) {
          return this.maxlength != null ? this._validator(control) : null;
        }
        /**
         * \@description
         * Registers a callback function to call when the validator inputs change.
         *
         * @param {?} fn The callback function
         * @return {?}
         */

      }, {
        key: "registerOnValidatorChange",
        value: function registerOnValidatorChange(fn) {
          this._onChange = fn;
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_createValidator",
        value: function _createValidator() {
          this._validator = Validators.maxLength(typeof this.maxlength === 'number' ? this.maxlength : parseInt(this.maxlength, 10));
        }
      }]);

      return MaxLengthValidator;
    }();

    MaxLengthValidator.ɵfac = function MaxLengthValidator_Factory(t) {
      return new (t || MaxLengthValidator)();
    };

    MaxLengthValidator.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: MaxLengthValidator,
      selectors: [["", "maxlength", "", "formControlName", ""], ["", "maxlength", "", "formControl", ""], ["", "maxlength", "", "ngModel", ""]],
      hostVars: 1,
      hostBindings: function MaxLengthValidator_HostBindings(rf, ctx) {
        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵattribute"]("maxlength", ctx.maxlength ? ctx.maxlength : null);
        }
      },
      inputs: {
        maxlength: "maxlength"
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([MAX_LENGTH_VALIDATOR]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵNgOnChangesFeature"]]
    });
    MaxLengthValidator.propDecorators = {
      maxlength: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MaxLengthValidator, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]',
          providers: [MAX_LENGTH_VALIDATOR],
          host: {
            '[attr.maxlength]': 'maxlength ? maxlength : null'
          }
        }]
      }], null, {
        maxlength: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * \@description
     * Provider which adds `PatternValidator` to the `NG_VALIDATORS` multi-provider list.
     * @type {?}
     */


    var PATTERN_VALIDATOR = {
      provide: NG_VALIDATORS,
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return PatternValidator;
      }),
      multi: true
    };
    /**
     * \@description
     * A directive that adds regex pattern validation to controls marked with the
     * `pattern` attribute. The regex must match the entire control value.
     * The directive is provided with the `NG_VALIDATORS` multi-provider list.
     *
     * @see [Form Validation](guide/form-validation)
     *
     * \@usageNotes
     *
     * ### Adding a pattern validator
     *
     * The following example shows how to add a pattern validator to an input attached to an
     * ngModel binding.
     *
     * ```html
     * <input name="firstName" ngModel pattern="[a-zA-Z ]*">
     * ```
     *
     * \@ngModule ReactiveFormsModule
     * \@ngModule FormsModule
     * \@publicApi
     */

    var PatternValidator = /*#__PURE__*/function () {
      function PatternValidator() {
        _classCallCheck(this, PatternValidator);
      }

      _createClass2(PatternValidator, [{
        key: "ngOnChanges",

        /**
         * \@description
         * A lifecycle method called when the directive's inputs change. For internal use
         * only.
         *
         * @param {?} changes A object of key/value pairs for the set of changed inputs.
         * @return {?}
         */
        value: function ngOnChanges(changes) {
          if ('pattern' in changes) {
            this._createValidator();

            if (this._onChange) this._onChange();
          }
        }
        /**
         * \@description
         * Method that validates whether the value matches the
         * the pattern requirement.
         * @param {?} control
         * @return {?}
         */

      }, {
        key: "validate",
        value: function validate(control) {
          return this._validator(control);
        }
        /**
         * \@description
         * Registers a callback function to call when the validator inputs change.
         *
         * @param {?} fn The callback function
         * @return {?}
         */

      }, {
        key: "registerOnValidatorChange",
        value: function registerOnValidatorChange(fn) {
          this._onChange = fn;
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_createValidator",
        value: function _createValidator() {
          this._validator = Validators.pattern(this.pattern);
        }
      }]);

      return PatternValidator;
    }();

    PatternValidator.ɵfac = function PatternValidator_Factory(t) {
      return new (t || PatternValidator)();
    };

    PatternValidator.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: PatternValidator,
      selectors: [["", "pattern", "", "formControlName", ""], ["", "pattern", "", "formControl", ""], ["", "pattern", "", "ngModel", ""]],
      hostVars: 1,
      hostBindings: function PatternValidator_HostBindings(rf, ctx) {
        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵattribute"]("pattern", ctx.pattern ? ctx.pattern : null);
        }
      },
      inputs: {
        pattern: "pattern"
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([PATTERN_VALIDATOR]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵNgOnChangesFeature"]]
    });
    PatternValidator.propDecorators = {
      pattern: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](PatternValidator, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[pattern][formControlName],[pattern][formControl],[pattern][ngModel]',
          providers: [PATTERN_VALIDATOR],
          host: {
            '[attr.pattern]': 'pattern ? pattern : null'
          }
        }]
      }], null, {
        pattern: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/directives.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var SHARED_FORM_DIRECTIVES = [ɵNgNoValidate, NgSelectOption, ɵNgSelectMultipleOption, DefaultValueAccessor, NumberValueAccessor, RangeValueAccessor, CheckboxControlValueAccessor, SelectControlValueAccessor, SelectMultipleControlValueAccessor, RadioControlValueAccessor, NgControlStatus, NgControlStatusGroup, RequiredValidator, MinLengthValidator, MaxLengthValidator, PatternValidator, CheckboxRequiredValidator, EmailValidator];
    /** @type {?} */

    var TEMPLATE_DRIVEN_DIRECTIVES = [NgModel, NgModelGroup, NgForm];
    /** @type {?} */

    var REACTIVE_DRIVEN_DIRECTIVES = [FormControlDirective, FormGroupDirective, FormControlName, FormGroupName, FormArrayName];
    /**
     * Internal module used for sharing directives between FormsModule and ReactiveFormsModule
     */

    var ɵInternalFormsSharedModule = function ɵInternalFormsSharedModule() {
      _classCallCheck(this, ɵInternalFormsSharedModule);
    };

    ɵInternalFormsSharedModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: ɵInternalFormsSharedModule
    });
    ɵInternalFormsSharedModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function ɵInternalFormsSharedModule_Factory(t) {
        return new (t || ɵInternalFormsSharedModule)();
      }
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](ɵInternalFormsSharedModule, {
        declarations: [ɵNgNoValidate, NgSelectOption, ɵNgSelectMultipleOption, DefaultValueAccessor, NumberValueAccessor, RangeValueAccessor, CheckboxControlValueAccessor, SelectControlValueAccessor, SelectMultipleControlValueAccessor, RadioControlValueAccessor, NgControlStatus, NgControlStatusGroup, RequiredValidator, MinLengthValidator, MaxLengthValidator, PatternValidator, CheckboxRequiredValidator, EmailValidator],
        exports: [ɵNgNoValidate, NgSelectOption, ɵNgSelectMultipleOption, DefaultValueAccessor, NumberValueAccessor, RangeValueAccessor, CheckboxControlValueAccessor, SelectControlValueAccessor, SelectMultipleControlValueAccessor, RadioControlValueAccessor, NgControlStatus, NgControlStatusGroup, RequiredValidator, MinLengthValidator, MaxLengthValidator, PatternValidator, CheckboxRequiredValidator, EmailValidator]
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](ɵInternalFormsSharedModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{
          declarations: SHARED_FORM_DIRECTIVES,
          exports: SHARED_FORM_DIRECTIVES
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/form_builder.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} options
     * @return {?}
     */


    function isAbstractControlOptions(options) {
      return (
        /** @type {?} */
        options.asyncValidators !== undefined ||
        /** @type {?} */
        options.validators !== undefined ||
        /** @type {?} */
        options.updateOn !== undefined
      );
    }
    /**
     * \@description
     * Creates an `AbstractControl` from a user-specified configuration.
     *
     * The `FormBuilder` provides syntactic sugar that shortens creating instances of a `FormControl`,
     * `FormGroup`, or `FormArray`. It reduces the amount of boilerplate needed to build complex
     * forms.
     *
     * @see [Reactive Forms Guide](/guide/reactive-forms)
     *
     * \@publicApi
     */


    var FormBuilder = /*#__PURE__*/function () {
      function FormBuilder() {
        _classCallCheck(this, FormBuilder);
      }

      _createClass2(FormBuilder, [{
        key: "group",

        /**
         * \@description
         * Construct a new `FormGroup` instance.
         *
         * @param {?} controlsConfig A collection of child controls. The key for each child is the name
         * under which it is registered.
         *
         * @param {?=} options Configuration options object for the `FormGroup`. The object can
         * have two shapes:
         *
         * 1) `AbstractControlOptions` object (preferred), which consists of:
         * * `validators`: A synchronous validator function, or an array of validator functions
         * * `asyncValidators`: A single async validator or array of async validator functions
         * * `updateOn`: The event upon which the control should be updated (options: 'change' | 'blur' |
         * submit')
         *
         * 2) Legacy configuration object, which consists of:
         * * `validator`: A synchronous validator function, or an array of validator functions
         * * `asyncValidator`: A single async validator or array of async validator functions
         *
         * @return {?}
         */
        value: function group(controlsConfig) {
          var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;

          /** @type {?} */
          var controls = this._reduceControls(controlsConfig);
          /** @type {?} */


          var validators = null;
          /** @type {?} */

          var asyncValidators = null;
          /** @type {?} */

          var updateOn = undefined;

          if (options != null) {
            if (isAbstractControlOptions(options)) {
              // `options` are `AbstractControlOptions`
              validators = options.validators != null ? options.validators : null;
              asyncValidators = options.asyncValidators != null ? options.asyncValidators : null;
              updateOn = options.updateOn != null ? options.updateOn : undefined;
            } else {
              // `options` are legacy form group options
              validators = options['validator'] != null ? options['validator'] : null;
              asyncValidators = options['asyncValidator'] != null ? options['asyncValidator'] : null;
            }
          }

          return new FormGroup(controls, {
            asyncValidators: asyncValidators,
            updateOn: updateOn,
            validators: validators
          });
        }
        /**
         * \@description
         * Construct a new `FormControl` with the given state, validators and options.
         *
         * \@usageNotes
         *
         * ### Initialize a control as disabled
         *
         * The following example returns a control with an initial value in a disabled state.
         *
         * <code-example path="forms/ts/formBuilder/form_builder_example.ts" region="disabled-control">
         * </code-example>
         * @param {?} formState Initializes the control with an initial state value, or
         * with an object that contains both a value and a disabled status.
         *
         * @param {?=} validatorOrOpts A synchronous validator function, or an array of
         * such functions, or an `AbstractControlOptions` object that contains
         * validation functions and a validation trigger.
         *
         * @param {?=} asyncValidator A single async validator or array of async validator
         * functions.
         *
         * @return {?}
         */

      }, {
        key: "control",
        value: function control(formState, validatorOrOpts, asyncValidator) {
          return new FormControl(formState, validatorOrOpts, asyncValidator);
        }
        /**
         * Constructs a new `FormArray` from the given array of configurations,
         * validators and options.
         *
         * @param {?} controlsConfig An array of child controls or control configs. Each
         * child control is given an index when it is registered.
         *
         * @param {?=} validatorOrOpts A synchronous validator function, or an array of
         * such functions, or an `AbstractControlOptions` object that contains
         * validation functions and a validation trigger.
         *
         * @param {?=} asyncValidator A single async validator or array of async validator
         * functions.
         * @return {?}
         */

      }, {
        key: "array",
        value: function array(controlsConfig, validatorOrOpts, asyncValidator) {
          var _this222 = this;

          /** @type {?} */
          var controls = controlsConfig.map(
          /**
          * @param {?} c
          * @return {?}
          */
          function (c) {
            return _this222._createControl(c);
          });
          return new FormArray(controls, validatorOrOpts, asyncValidator);
        }
        /**
         * \@internal
         * @param {?} controlsConfig
         * @return {?}
         */

      }, {
        key: "_reduceControls",
        value: function _reduceControls(controlsConfig) {
          var _this223 = this;

          /** @type {?} */
          var controls = {};
          Object.keys(controlsConfig).forEach(
          /**
          * @param {?} controlName
          * @return {?}
          */
          function (controlName) {
            controls[controlName] = _this223._createControl(controlsConfig[controlName]);
          });
          return controls;
        }
        /**
         * \@internal
         * @param {?} controlConfig
         * @return {?}
         */

      }, {
        key: "_createControl",
        value: function _createControl(controlConfig) {
          if (controlConfig instanceof FormControl || controlConfig instanceof FormGroup || controlConfig instanceof FormArray) {
            return controlConfig;
          } else if (Array.isArray(controlConfig)) {
            /** @type {?} */
            var value = controlConfig[0];
            /** @type {?} */

            var validator = controlConfig.length > 1 ? controlConfig[1] : null;
            /** @type {?} */

            var asyncValidator = controlConfig.length > 2 ? controlConfig[2] : null;
            return this.control(value, validator, asyncValidator);
          } else {
            return this.control(controlConfig);
          }
        }
      }]);

      return FormBuilder;
    }();

    FormBuilder.ɵfac = function FormBuilder_Factory(t) {
      return new (t || FormBuilder)();
    };

    FormBuilder.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({
      token: FormBuilder,
      factory: FormBuilder.ɵfac
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](FormBuilder, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/version.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@publicApi
     * @type {?}
     */


    var VERSION = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["Version"]('9.1.4');
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/form_providers.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Exports the required providers and directives for template-driven forms,
     * making them available for import by NgModules that import this module.
     *
     * @see [Forms Overview](/guide/forms-overview)
     * @see [Template-driven Forms Guide](/guide/forms)
     *
     * \@publicApi
     */

    var FormsModule = function FormsModule() {
      _classCallCheck(this, FormsModule);
    };

    FormsModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: FormsModule
    });
    FormsModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function FormsModule_Factory(t) {
        return new (t || FormsModule)();
      },
      providers: [RadioControlRegistry],
      imports: [ɵInternalFormsSharedModule]
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](FormsModule, {
        declarations: [NgModel, NgModelGroup, NgForm],
        exports: [ɵInternalFormsSharedModule, NgModel, NgModelGroup, NgForm]
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](FormsModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{
          declarations: TEMPLATE_DRIVEN_DIRECTIVES,
          providers: [RadioControlRegistry],
          exports: [ɵInternalFormsSharedModule, TEMPLATE_DRIVEN_DIRECTIVES]
        }]
      }], null, null);
    })();
    /**
     * Exports the required infrastructure and directives for reactive forms,
     * making them available for import by NgModules that import this module.
     *
     * @see [Forms Overview](guide/forms-overview)
     * @see [Reactive Forms Guide](guide/reactive-forms)
     *
     * \@publicApi
     */


    var ReactiveFormsModule = /*#__PURE__*/function () {
      function ReactiveFormsModule() {
        _classCallCheck(this, ReactiveFormsModule);
      }

      _createClass2(ReactiveFormsModule, null, [{
        key: "withConfig",

        /**
         * \@description
         * Provides options for configuring the reactive forms module.
         *
         * @param {?} opts An object of configuration options
         * * `warnOnNgModelWithFormControl` Configures when to emit a warning when an `ngModel`
         * binding is used with reactive form directives.
         * @return {?}
         */
        value: function withConfig(opts) {
          return {
            ngModule: ReactiveFormsModule,
            providers: [{
              provide: NG_MODEL_WITH_FORM_CONTROL_WARNING,
              useValue: opts.warnOnNgModelWithFormControl
            }]
          };
        }
      }]);

      return ReactiveFormsModule;
    }();

    ReactiveFormsModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: ReactiveFormsModule
    });
    ReactiveFormsModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function ReactiveFormsModule_Factory(t) {
        return new (t || ReactiveFormsModule)();
      },
      providers: [FormBuilder, RadioControlRegistry],
      imports: [ɵInternalFormsSharedModule]
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](ReactiveFormsModule, {
        declarations: [FormControlDirective, FormGroupDirective, FormControlName, FormGroupName, FormArrayName],
        exports: [ɵInternalFormsSharedModule, FormControlDirective, FormGroupDirective, FormControlName, FormGroupName, FormArrayName]
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](ReactiveFormsModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{
          declarations: [REACTIVE_DRIVEN_DIRECTIVES],
          providers: [FormBuilder, RadioControlRegistry],
          exports: [ɵInternalFormsSharedModule, REACTIVE_DRIVEN_DIRECTIVES]
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/src/forms.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/public_api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/forms/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=forms.js.map

    /***/

  },

  /***/
  "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/button.js":
  /*!************************************************************************!*\
    !*** ./node_modules/@angular/material/__ivy_ngcc__/fesm2015/button.js ***!
    \************************************************************************/

  /*! exports provided: MatAnchor, MatButton, MatButtonModule */

  /***/
  function node_modulesAngularMaterial__ivy_ngcc__Fesm2015ButtonJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatAnchor", function () {
      return MatAnchor;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatButton", function () {
      return MatButton;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatButtonModule", function () {
      return MatButtonModule;
    });
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var _angular_material_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! @angular/material/core */
    "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var _angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! @angular/cdk/a11y */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/a11y.js");
    /* harmony import */


    var _angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! @angular/platform-browser/animations */
    "./node_modules/@angular/platform-browser/__ivy_ngcc__/fesm2015/animations.js");
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/button/button.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Default color palette for round buttons (mat-fab and mat-mini-fab)
     * @type {?}
     */


    var _c0 = ["mat-button", ""];
    var _c1 = ["*"];
    var DEFAULT_ROUND_BUTTON_COLOR = 'accent';
    /**
     * List of classes to add to MatButton instances based on host attributes to
     * style as different variants.
     * @type {?}
     */

    var BUTTON_HOST_ATTRIBUTES = ['mat-button', 'mat-flat-button', 'mat-icon-button', 'mat-raised-button', 'mat-stroked-button', 'mat-mini-fab', 'mat-fab']; // Boilerplate for applying mixins to MatButton.

    /**
     * \@docs-private
     */

    var MatButtonBase =
    /**
     * @param {?} _elementRef
     */
    function MatButtonBase(_elementRef) {
      _classCallCheck(this, MatButtonBase);

      this._elementRef = _elementRef;
    };

    if (false) {}
    /** @type {?} */


    var _MatButtonMixinBase = Object(_angular_material_core__WEBPACK_IMPORTED_MODULE_1__["mixinColor"])(Object(_angular_material_core__WEBPACK_IMPORTED_MODULE_1__["mixinDisabled"])(Object(_angular_material_core__WEBPACK_IMPORTED_MODULE_1__["mixinDisableRipple"])(MatButtonBase)));
    /**
     * Material design button.
     */


    var MatButton = /*#__PURE__*/function (_MatButtonMixinBase2) {
      _inherits(MatButton, _MatButtonMixinBase2);

      var _super68 = _createSuper(MatButton);

      /**
       * @param {?} elementRef
       * @param {?} _focusMonitor
       * @param {?} _animationMode
       */
      function MatButton(elementRef, _focusMonitor, _animationMode) {
        var _this224;

        _classCallCheck(this, MatButton);

        _this224 = _super68.call(this, elementRef);
        _this224._focusMonitor = _focusMonitor;
        _this224._animationMode = _animationMode;
        /**
         * Whether the button is round.
         */

        _this224.isRoundButton = _this224._hasHostAttributes('mat-fab', 'mat-mini-fab');
        /**
         * Whether the button is icon button.
         */

        _this224.isIconButton = _this224._hasHostAttributes('mat-icon-button'); // For each of the variant selectors that is present in the button's host
        // attributes, add the correct corresponding class.

        var _iterator16 = _createForOfIteratorHelper(BUTTON_HOST_ATTRIBUTES),
            _step16;

        try {
          for (_iterator16.s(); !(_step16 = _iterator16.n()).done;) {
            var attr = _step16.value;

            if (_this224._hasHostAttributes(attr)) {
              /** @type {?} */
              _this224._getHostElement().classList.add(attr);
            }
          } // Add a class that applies to all buttons. This makes it easier to target if somebody
          // wants to target all Material buttons. We do it here rather than `host` to ensure that
          // the class is applied to derived classes.

        } catch (err) {
          _iterator16.e(err);
        } finally {
          _iterator16.f();
        }

        elementRef.nativeElement.classList.add('mat-button-base');

        _this224._focusMonitor.monitor(_this224._elementRef, true);

        if (_this224.isRoundButton) {
          _this224.color = DEFAULT_ROUND_BUTTON_COLOR;
        }

        return _this224;
      }
      /**
       * @return {?}
       */


      _createClass2(MatButton, [{
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this._focusMonitor.stopMonitoring(this._elementRef);
        }
        /**
         * Focuses the button.
         * @param {?=} origin
         * @param {?=} options
         * @return {?}
         */

      }, {
        key: "focus",
        value: function focus() {
          var origin = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'program';
          var options = arguments.length > 1 ? arguments[1] : undefined;

          this._focusMonitor.focusVia(this._getHostElement(), origin, options);
        }
        /**
         * @return {?}
         */

      }, {
        key: "_getHostElement",
        value: function _getHostElement() {
          return this._elementRef.nativeElement;
        }
        /**
         * @return {?}
         */

      }, {
        key: "_isRippleDisabled",
        value: function _isRippleDisabled() {
          return this.disableRipple || this.disabled;
        }
        /**
         * Gets whether the button has one of the given attributes.
         * @param {...?} attributes
         * @return {?}
         */

      }, {
        key: "_hasHostAttributes",
        value: function _hasHostAttributes() {
          var _this225 = this;

          for (var _len19 = arguments.length, attributes = new Array(_len19), _key20 = 0; _key20 < _len19; _key20++) {
            attributes[_key20] = arguments[_key20];
          }

          return attributes.some(
          /**
          * @param {?} attribute
          * @return {?}
          */
          function (attribute) {
            return _this225._getHostElement().hasAttribute(attribute);
          });
        }
      }]);

      return MatButton;
    }(_MatButtonMixinBase);

    MatButton.ɵfac = function MatButton_Factory(t) {
      return new (t || MatButton)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_2__["FocusMonitor"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_3__["ANIMATION_MODULE_TYPE"], 8));
    };

    MatButton.ɵcmp = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineComponent"]({
      type: MatButton,
      selectors: [["button", "mat-button", ""], ["button", "mat-raised-button", ""], ["button", "mat-icon-button", ""], ["button", "mat-fab", ""], ["button", "mat-mini-fab", ""], ["button", "mat-stroked-button", ""], ["button", "mat-flat-button", ""]],
      viewQuery: function MatButton_Query(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵviewQuery"](_angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatRipple"], true);
        }

        if (rf & 2) {
          var _t;

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵqueryRefresh"](_t = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵloadQuery"]()) && (ctx.ripple = _t.first);
        }
      },
      hostAttrs: [1, "mat-focus-indicator"],
      hostVars: 3,
      hostBindings: function MatButton_HostBindings(rf, ctx) {
        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵattribute"]("disabled", ctx.disabled || null);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵclassProp"]("_mat-animation-noopable", ctx._animationMode === "NoopAnimations");
        }
      },
      inputs: {
        disabled: "disabled",
        disableRipple: "disableRipple",
        color: "color"
      },
      exportAs: ["matButton"],
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]],
      attrs: _c0,
      ngContentSelectors: _c1,
      decls: 4,
      vars: 5,
      consts: [[1, "mat-button-wrapper"], ["matRipple", "", 1, "mat-button-ripple", 3, "matRippleDisabled", "matRippleCentered", "matRippleTrigger"], [1, "mat-button-focus-overlay"]],
      template: function MatButton_Template(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵprojectionDef"]();

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](0, "span", 0);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵprojection"](1);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"]();

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelement"](2, "div", 1);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelement"](3, "div", 2);
        }

        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](2);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵclassProp"]("mat-button-ripple-round", ctx.isRoundButton || ctx.isIconButton);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("matRippleDisabled", ctx._isRippleDisabled())("matRippleCentered", ctx.isIconButton)("matRippleTrigger", ctx._getHostElement());
        }
      },
      directives: [_angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatRipple"]],
      styles: [".mat-button .mat-button-focus-overlay,.mat-icon-button .mat-button-focus-overlay{opacity:0}.mat-button:hover .mat-button-focus-overlay,.mat-stroked-button:hover .mat-button-focus-overlay{opacity:.04}@media(hover: none){.mat-button:hover .mat-button-focus-overlay,.mat-stroked-button:hover .mat-button-focus-overlay{opacity:0}}.mat-button,.mat-icon-button,.mat-stroked-button,.mat-flat-button{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible}.mat-button::-moz-focus-inner,.mat-icon-button::-moz-focus-inner,.mat-stroked-button::-moz-focus-inner,.mat-flat-button::-moz-focus-inner{border:0}.mat-button[disabled],.mat-icon-button[disabled],.mat-stroked-button[disabled],.mat-flat-button[disabled]{cursor:default}.mat-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-button.cdk-program-focused .mat-button-focus-overlay,.mat-icon-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-icon-button.cdk-program-focused .mat-button-focus-overlay,.mat-stroked-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-stroked-button.cdk-program-focused .mat-button-focus-overlay,.mat-flat-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-flat-button.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-button::-moz-focus-inner,.mat-icon-button::-moz-focus-inner,.mat-stroked-button::-moz-focus-inner,.mat-flat-button::-moz-focus-inner{border:0}.mat-raised-button{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-raised-button::-moz-focus-inner{border:0}.mat-raised-button[disabled]{cursor:default}.mat-raised-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-raised-button.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-raised-button::-moz-focus-inner{border:0}._mat-animation-noopable.mat-raised-button{transition:none;animation:none}.mat-stroked-button{border:1px solid currentColor;padding:0 15px;line-height:34px}.mat-stroked-button .mat-button-ripple.mat-ripple,.mat-stroked-button .mat-button-focus-overlay{top:-1px;left:-1px;right:-1px;bottom:-1px}.mat-fab{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);min-width:0;border-radius:50%;width:56px;height:56px;padding:0;flex-shrink:0}.mat-fab::-moz-focus-inner{border:0}.mat-fab[disabled]{cursor:default}.mat-fab.cdk-keyboard-focused .mat-button-focus-overlay,.mat-fab.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-fab::-moz-focus-inner{border:0}._mat-animation-noopable.mat-fab{transition:none;animation:none}.mat-fab .mat-button-wrapper{padding:16px 0;display:inline-block;line-height:24px}.mat-mini-fab{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);min-width:0;border-radius:50%;width:40px;height:40px;padding:0;flex-shrink:0}.mat-mini-fab::-moz-focus-inner{border:0}.mat-mini-fab[disabled]{cursor:default}.mat-mini-fab.cdk-keyboard-focused .mat-button-focus-overlay,.mat-mini-fab.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-mini-fab::-moz-focus-inner{border:0}._mat-animation-noopable.mat-mini-fab{transition:none;animation:none}.mat-mini-fab .mat-button-wrapper{padding:8px 0;display:inline-block;line-height:24px}.mat-icon-button{padding:0;min-width:0;width:40px;height:40px;flex-shrink:0;line-height:40px;border-radius:50%}.mat-icon-button i,.mat-icon-button .mat-icon{line-height:24px}.mat-button-ripple.mat-ripple,.mat-button-focus-overlay{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-button-ripple.mat-ripple:not(:empty){transform:translateZ(0)}.mat-button-focus-overlay{opacity:0;transition:opacity 200ms cubic-bezier(0.35, 0, 0.25, 1),background-color 200ms cubic-bezier(0.35, 0, 0.25, 1)}._mat-animation-noopable .mat-button-focus-overlay{transition:none}.cdk-high-contrast-active .mat-button-focus-overlay{background-color:#fff}.cdk-high-contrast-black-on-white .mat-button-focus-overlay{background-color:#000}.mat-button-ripple-round{border-radius:50%;z-index:1}.mat-button .mat-button-wrapper>*,.mat-flat-button .mat-button-wrapper>*,.mat-stroked-button .mat-button-wrapper>*,.mat-raised-button .mat-button-wrapper>*,.mat-icon-button .mat-button-wrapper>*,.mat-fab .mat-button-wrapper>*,.mat-mini-fab .mat-button-wrapper>*{vertical-align:middle}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon-button,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon-button{display:block;font-size:inherit;width:2.5em;height:2.5em}.cdk-high-contrast-active .mat-button,.cdk-high-contrast-active .mat-flat-button,.cdk-high-contrast-active .mat-raised-button,.cdk-high-contrast-active .mat-icon-button,.cdk-high-contrast-active .mat-fab,.cdk-high-contrast-active .mat-mini-fab{outline:solid 1px}\n"],
      encapsulation: 2,
      changeDetection: 0
    });
    /** @nocollapse */

    MatButton.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
      }, {
        type: _angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_2__["FocusMonitor"]
      }, {
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [_angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_3__["ANIMATION_MODULE_TYPE"]]
        }]
      }];
    };

    MatButton.propDecorators = {
      ripple: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewChild"],
        args: [_angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatRipple"]]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatButton, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Component"],
        args: [{
          selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button],\n             button[mat-fab], button[mat-mini-fab], button[mat-stroked-button],\n             button[mat-flat-button]",
          exportAs: 'matButton',
          host: {
            '[attr.disabled]': 'disabled || null',
            '[class._mat-animation-noopable]': '_animationMode === "NoopAnimations"',
            'class': 'mat-focus-indicator'
          },
          template: "<span class=\"mat-button-wrapper\"><ng-content></ng-content></span>\n<div matRipple class=\"mat-button-ripple\"\n     [class.mat-button-ripple-round]=\"isRoundButton || isIconButton\"\n     [matRippleDisabled]=\"_isRippleDisabled()\"\n     [matRippleCentered]=\"isIconButton\"\n     [matRippleTrigger]=\"_getHostElement()\"></div>\n<div class=\"mat-button-focus-overlay\"></div>\n",
          inputs: ['disabled', 'disableRipple', 'color'],
          encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewEncapsulation"].None,
          changeDetection: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ChangeDetectionStrategy"].OnPush,
          styles: [".mat-button .mat-button-focus-overlay,.mat-icon-button .mat-button-focus-overlay{opacity:0}.mat-button:hover .mat-button-focus-overlay,.mat-stroked-button:hover .mat-button-focus-overlay{opacity:.04}@media(hover: none){.mat-button:hover .mat-button-focus-overlay,.mat-stroked-button:hover .mat-button-focus-overlay{opacity:0}}.mat-button,.mat-icon-button,.mat-stroked-button,.mat-flat-button{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible}.mat-button::-moz-focus-inner,.mat-icon-button::-moz-focus-inner,.mat-stroked-button::-moz-focus-inner,.mat-flat-button::-moz-focus-inner{border:0}.mat-button[disabled],.mat-icon-button[disabled],.mat-stroked-button[disabled],.mat-flat-button[disabled]{cursor:default}.mat-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-button.cdk-program-focused .mat-button-focus-overlay,.mat-icon-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-icon-button.cdk-program-focused .mat-button-focus-overlay,.mat-stroked-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-stroked-button.cdk-program-focused .mat-button-focus-overlay,.mat-flat-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-flat-button.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-button::-moz-focus-inner,.mat-icon-button::-moz-focus-inner,.mat-stroked-button::-moz-focus-inner,.mat-flat-button::-moz-focus-inner{border:0}.mat-raised-button{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-raised-button::-moz-focus-inner{border:0}.mat-raised-button[disabled]{cursor:default}.mat-raised-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-raised-button.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-raised-button::-moz-focus-inner{border:0}._mat-animation-noopable.mat-raised-button{transition:none;animation:none}.mat-stroked-button{border:1px solid currentColor;padding:0 15px;line-height:34px}.mat-stroked-button .mat-button-ripple.mat-ripple,.mat-stroked-button .mat-button-focus-overlay{top:-1px;left:-1px;right:-1px;bottom:-1px}.mat-fab{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);min-width:0;border-radius:50%;width:56px;height:56px;padding:0;flex-shrink:0}.mat-fab::-moz-focus-inner{border:0}.mat-fab[disabled]{cursor:default}.mat-fab.cdk-keyboard-focused .mat-button-focus-overlay,.mat-fab.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-fab::-moz-focus-inner{border:0}._mat-animation-noopable.mat-fab{transition:none;animation:none}.mat-fab .mat-button-wrapper{padding:16px 0;display:inline-block;line-height:24px}.mat-mini-fab{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);min-width:0;border-radius:50%;width:40px;height:40px;padding:0;flex-shrink:0}.mat-mini-fab::-moz-focus-inner{border:0}.mat-mini-fab[disabled]{cursor:default}.mat-mini-fab.cdk-keyboard-focused .mat-button-focus-overlay,.mat-mini-fab.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-mini-fab::-moz-focus-inner{border:0}._mat-animation-noopable.mat-mini-fab{transition:none;animation:none}.mat-mini-fab .mat-button-wrapper{padding:8px 0;display:inline-block;line-height:24px}.mat-icon-button{padding:0;min-width:0;width:40px;height:40px;flex-shrink:0;line-height:40px;border-radius:50%}.mat-icon-button i,.mat-icon-button .mat-icon{line-height:24px}.mat-button-ripple.mat-ripple,.mat-button-focus-overlay{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-button-ripple.mat-ripple:not(:empty){transform:translateZ(0)}.mat-button-focus-overlay{opacity:0;transition:opacity 200ms cubic-bezier(0.35, 0, 0.25, 1),background-color 200ms cubic-bezier(0.35, 0, 0.25, 1)}._mat-animation-noopable .mat-button-focus-overlay{transition:none}.cdk-high-contrast-active .mat-button-focus-overlay{background-color:#fff}.cdk-high-contrast-black-on-white .mat-button-focus-overlay{background-color:#000}.mat-button-ripple-round{border-radius:50%;z-index:1}.mat-button .mat-button-wrapper>*,.mat-flat-button .mat-button-wrapper>*,.mat-stroked-button .mat-button-wrapper>*,.mat-raised-button .mat-button-wrapper>*,.mat-icon-button .mat-button-wrapper>*,.mat-fab .mat-button-wrapper>*,.mat-mini-fab .mat-button-wrapper>*{vertical-align:middle}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon-button,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon-button{display:block;font-size:inherit;width:2.5em;height:2.5em}.cdk-high-contrast-active .mat-button,.cdk-high-contrast-active .mat-flat-button,.cdk-high-contrast-active .mat-raised-button,.cdk-high-contrast-active .mat-icon-button,.cdk-high-contrast-active .mat-fab,.cdk-high-contrast-active .mat-mini-fab{outline:solid 1px}\n"]
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
        }, {
          type: _angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_2__["FocusMonitor"]
        }, {
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [_angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_3__["ANIMATION_MODULE_TYPE"]]
          }]
        }];
      }, {
        ripple: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewChild"],
          args: [_angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatRipple"]]
        }]
      });
    })();

    if (false) {}
    /**
     * Material design anchor button.
     */


    var MatAnchor = /*#__PURE__*/function (_MatButton) {
      _inherits(MatAnchor, _MatButton);

      var _super69 = _createSuper(MatAnchor);

      /**
       * @param {?} focusMonitor
       * @param {?} elementRef
       * @param {?} animationMode
       */
      function MatAnchor(focusMonitor, elementRef, animationMode) {
        _classCallCheck(this, MatAnchor);

        return _super69.call(this, elementRef, focusMonitor, animationMode);
      }
      /**
       * @param {?} event
       * @return {?}
       */


      _createClass2(MatAnchor, [{
        key: "_haltDisabledEvents",
        value: function _haltDisabledEvents(event) {
          // A disabled button shouldn't apply any actions
          if (this.disabled) {
            event.preventDefault();
            event.stopImmediatePropagation();
          }
        }
      }]);

      return MatAnchor;
    }(MatButton);

    MatAnchor.ɵfac = function MatAnchor_Factory(t) {
      return new (t || MatAnchor)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_2__["FocusMonitor"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_3__["ANIMATION_MODULE_TYPE"], 8));
    };

    MatAnchor.ɵcmp = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineComponent"]({
      type: MatAnchor,
      selectors: [["a", "mat-button", ""], ["a", "mat-raised-button", ""], ["a", "mat-icon-button", ""], ["a", "mat-fab", ""], ["a", "mat-mini-fab", ""], ["a", "mat-stroked-button", ""], ["a", "mat-flat-button", ""]],
      hostAttrs: [1, "mat-focus-indicator"],
      hostVars: 5,
      hostBindings: function MatAnchor_HostBindings(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵlistener"]("click", function MatAnchor_click_HostBindingHandler($event) {
            return ctx._haltDisabledEvents($event);
          });
        }

        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵattribute"]("tabindex", ctx.disabled ? 0 - 1 : ctx.tabIndex || 0)("disabled", ctx.disabled || null)("aria-disabled", ctx.disabled.toString());

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵclassProp"]("_mat-animation-noopable", ctx._animationMode === "NoopAnimations");
        }
      },
      inputs: {
        disabled: "disabled",
        disableRipple: "disableRipple",
        color: "color",
        tabIndex: "tabIndex"
      },
      exportAs: ["matButton", "matAnchor"],
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]],
      attrs: _c0,
      ngContentSelectors: _c1,
      decls: 4,
      vars: 5,
      consts: [[1, "mat-button-wrapper"], ["matRipple", "", 1, "mat-button-ripple", 3, "matRippleDisabled", "matRippleCentered", "matRippleTrigger"], [1, "mat-button-focus-overlay"]],
      template: function MatAnchor_Template(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵprojectionDef"]();

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](0, "span", 0);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵprojection"](1);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"]();

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelement"](2, "div", 1);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelement"](3, "div", 2);
        }

        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](2);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵclassProp"]("mat-button-ripple-round", ctx.isRoundButton || ctx.isIconButton);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("matRippleDisabled", ctx._isRippleDisabled())("matRippleCentered", ctx.isIconButton)("matRippleTrigger", ctx._getHostElement());
        }
      },
      directives: [_angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatRipple"]],
      styles: [".mat-button .mat-button-focus-overlay,.mat-icon-button .mat-button-focus-overlay{opacity:0}.mat-button:hover .mat-button-focus-overlay,.mat-stroked-button:hover .mat-button-focus-overlay{opacity:.04}@media(hover: none){.mat-button:hover .mat-button-focus-overlay,.mat-stroked-button:hover .mat-button-focus-overlay{opacity:0}}.mat-button,.mat-icon-button,.mat-stroked-button,.mat-flat-button{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible}.mat-button::-moz-focus-inner,.mat-icon-button::-moz-focus-inner,.mat-stroked-button::-moz-focus-inner,.mat-flat-button::-moz-focus-inner{border:0}.mat-button[disabled],.mat-icon-button[disabled],.mat-stroked-button[disabled],.mat-flat-button[disabled]{cursor:default}.mat-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-button.cdk-program-focused .mat-button-focus-overlay,.mat-icon-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-icon-button.cdk-program-focused .mat-button-focus-overlay,.mat-stroked-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-stroked-button.cdk-program-focused .mat-button-focus-overlay,.mat-flat-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-flat-button.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-button::-moz-focus-inner,.mat-icon-button::-moz-focus-inner,.mat-stroked-button::-moz-focus-inner,.mat-flat-button::-moz-focus-inner{border:0}.mat-raised-button{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-raised-button::-moz-focus-inner{border:0}.mat-raised-button[disabled]{cursor:default}.mat-raised-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-raised-button.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-raised-button::-moz-focus-inner{border:0}._mat-animation-noopable.mat-raised-button{transition:none;animation:none}.mat-stroked-button{border:1px solid currentColor;padding:0 15px;line-height:34px}.mat-stroked-button .mat-button-ripple.mat-ripple,.mat-stroked-button .mat-button-focus-overlay{top:-1px;left:-1px;right:-1px;bottom:-1px}.mat-fab{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);min-width:0;border-radius:50%;width:56px;height:56px;padding:0;flex-shrink:0}.mat-fab::-moz-focus-inner{border:0}.mat-fab[disabled]{cursor:default}.mat-fab.cdk-keyboard-focused .mat-button-focus-overlay,.mat-fab.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-fab::-moz-focus-inner{border:0}._mat-animation-noopable.mat-fab{transition:none;animation:none}.mat-fab .mat-button-wrapper{padding:16px 0;display:inline-block;line-height:24px}.mat-mini-fab{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);min-width:0;border-radius:50%;width:40px;height:40px;padding:0;flex-shrink:0}.mat-mini-fab::-moz-focus-inner{border:0}.mat-mini-fab[disabled]{cursor:default}.mat-mini-fab.cdk-keyboard-focused .mat-button-focus-overlay,.mat-mini-fab.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-mini-fab::-moz-focus-inner{border:0}._mat-animation-noopable.mat-mini-fab{transition:none;animation:none}.mat-mini-fab .mat-button-wrapper{padding:8px 0;display:inline-block;line-height:24px}.mat-icon-button{padding:0;min-width:0;width:40px;height:40px;flex-shrink:0;line-height:40px;border-radius:50%}.mat-icon-button i,.mat-icon-button .mat-icon{line-height:24px}.mat-button-ripple.mat-ripple,.mat-button-focus-overlay{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-button-ripple.mat-ripple:not(:empty){transform:translateZ(0)}.mat-button-focus-overlay{opacity:0;transition:opacity 200ms cubic-bezier(0.35, 0, 0.25, 1),background-color 200ms cubic-bezier(0.35, 0, 0.25, 1)}._mat-animation-noopable .mat-button-focus-overlay{transition:none}.cdk-high-contrast-active .mat-button-focus-overlay{background-color:#fff}.cdk-high-contrast-black-on-white .mat-button-focus-overlay{background-color:#000}.mat-button-ripple-round{border-radius:50%;z-index:1}.mat-button .mat-button-wrapper>*,.mat-flat-button .mat-button-wrapper>*,.mat-stroked-button .mat-button-wrapper>*,.mat-raised-button .mat-button-wrapper>*,.mat-icon-button .mat-button-wrapper>*,.mat-fab .mat-button-wrapper>*,.mat-mini-fab .mat-button-wrapper>*{vertical-align:middle}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon-button,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon-button{display:block;font-size:inherit;width:2.5em;height:2.5em}.cdk-high-contrast-active .mat-button,.cdk-high-contrast-active .mat-flat-button,.cdk-high-contrast-active .mat-raised-button,.cdk-high-contrast-active .mat-icon-button,.cdk-high-contrast-active .mat-fab,.cdk-high-contrast-active .mat-mini-fab{outline:solid 1px}\n"],
      encapsulation: 2,
      changeDetection: 0
    });
    /** @nocollapse */

    MatAnchor.ctorParameters = function () {
      return [{
        type: _angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_2__["FocusMonitor"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
      }, {
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [_angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_3__["ANIMATION_MODULE_TYPE"]]
        }]
      }];
    };

    MatAnchor.propDecorators = {
      tabIndex: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatAnchor, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Component"],
        args: [{
          selector: "a[mat-button], a[mat-raised-button], a[mat-icon-button], a[mat-fab],\n             a[mat-mini-fab], a[mat-stroked-button], a[mat-flat-button]",
          exportAs: 'matButton, matAnchor',
          host: {
            // Note that we ignore the user-specified tabindex when it's disabled for
            // consistency with the `mat-button` applied on native buttons where even
            // though they have an index, they're not tabbable.
            '[attr.tabindex]': 'disabled ? -1 : (tabIndex || 0)',
            '[attr.disabled]': 'disabled || null',
            '[attr.aria-disabled]': 'disabled.toString()',
            '(click)': '_haltDisabledEvents($event)',
            '[class._mat-animation-noopable]': '_animationMode === "NoopAnimations"',
            'class': 'mat-focus-indicator'
          },
          inputs: ['disabled', 'disableRipple', 'color'],
          template: "<span class=\"mat-button-wrapper\"><ng-content></ng-content></span>\n<div matRipple class=\"mat-button-ripple\"\n     [class.mat-button-ripple-round]=\"isRoundButton || isIconButton\"\n     [matRippleDisabled]=\"_isRippleDisabled()\"\n     [matRippleCentered]=\"isIconButton\"\n     [matRippleTrigger]=\"_getHostElement()\"></div>\n<div class=\"mat-button-focus-overlay\"></div>\n",
          encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewEncapsulation"].None,
          changeDetection: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ChangeDetectionStrategy"].OnPush,
          styles: [".mat-button .mat-button-focus-overlay,.mat-icon-button .mat-button-focus-overlay{opacity:0}.mat-button:hover .mat-button-focus-overlay,.mat-stroked-button:hover .mat-button-focus-overlay{opacity:.04}@media(hover: none){.mat-button:hover .mat-button-focus-overlay,.mat-stroked-button:hover .mat-button-focus-overlay{opacity:0}}.mat-button,.mat-icon-button,.mat-stroked-button,.mat-flat-button{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible}.mat-button::-moz-focus-inner,.mat-icon-button::-moz-focus-inner,.mat-stroked-button::-moz-focus-inner,.mat-flat-button::-moz-focus-inner{border:0}.mat-button[disabled],.mat-icon-button[disabled],.mat-stroked-button[disabled],.mat-flat-button[disabled]{cursor:default}.mat-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-button.cdk-program-focused .mat-button-focus-overlay,.mat-icon-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-icon-button.cdk-program-focused .mat-button-focus-overlay,.mat-stroked-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-stroked-button.cdk-program-focused .mat-button-focus-overlay,.mat-flat-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-flat-button.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-button::-moz-focus-inner,.mat-icon-button::-moz-focus-inner,.mat-stroked-button::-moz-focus-inner,.mat-flat-button::-moz-focus-inner{border:0}.mat-raised-button{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1)}.mat-raised-button::-moz-focus-inner{border:0}.mat-raised-button[disabled]{cursor:default}.mat-raised-button.cdk-keyboard-focused .mat-button-focus-overlay,.mat-raised-button.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-raised-button::-moz-focus-inner{border:0}._mat-animation-noopable.mat-raised-button{transition:none;animation:none}.mat-stroked-button{border:1px solid currentColor;padding:0 15px;line-height:34px}.mat-stroked-button .mat-button-ripple.mat-ripple,.mat-stroked-button .mat-button-focus-overlay{top:-1px;left:-1px;right:-1px;bottom:-1px}.mat-fab{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);min-width:0;border-radius:50%;width:56px;height:56px;padding:0;flex-shrink:0}.mat-fab::-moz-focus-inner{border:0}.mat-fab[disabled]{cursor:default}.mat-fab.cdk-keyboard-focused .mat-button-focus-overlay,.mat-fab.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-fab::-moz-focus-inner{border:0}._mat-animation-noopable.mat-fab{transition:none;animation:none}.mat-fab .mat-button-wrapper{padding:16px 0;display:inline-block;line-height:24px}.mat-mini-fab{box-sizing:border-box;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;outline:none;border:none;-webkit-tap-highlight-color:transparent;display:inline-block;white-space:nowrap;text-decoration:none;vertical-align:baseline;text-align:center;margin:0;min-width:64px;line-height:36px;padding:0 16px;border-radius:4px;overflow:visible;transform:translate3d(0, 0, 0);transition:background 400ms cubic-bezier(0.25, 0.8, 0.25, 1),box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1);min-width:0;border-radius:50%;width:40px;height:40px;padding:0;flex-shrink:0}.mat-mini-fab::-moz-focus-inner{border:0}.mat-mini-fab[disabled]{cursor:default}.mat-mini-fab.cdk-keyboard-focused .mat-button-focus-overlay,.mat-mini-fab.cdk-program-focused .mat-button-focus-overlay{opacity:.12}.mat-mini-fab::-moz-focus-inner{border:0}._mat-animation-noopable.mat-mini-fab{transition:none;animation:none}.mat-mini-fab .mat-button-wrapper{padding:8px 0;display:inline-block;line-height:24px}.mat-icon-button{padding:0;min-width:0;width:40px;height:40px;flex-shrink:0;line-height:40px;border-radius:50%}.mat-icon-button i,.mat-icon-button .mat-icon{line-height:24px}.mat-button-ripple.mat-ripple,.mat-button-focus-overlay{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none;border-radius:inherit}.mat-button-ripple.mat-ripple:not(:empty){transform:translateZ(0)}.mat-button-focus-overlay{opacity:0;transition:opacity 200ms cubic-bezier(0.35, 0, 0.25, 1),background-color 200ms cubic-bezier(0.35, 0, 0.25, 1)}._mat-animation-noopable .mat-button-focus-overlay{transition:none}.cdk-high-contrast-active .mat-button-focus-overlay{background-color:#fff}.cdk-high-contrast-black-on-white .mat-button-focus-overlay{background-color:#000}.mat-button-ripple-round{border-radius:50%;z-index:1}.mat-button .mat-button-wrapper>*,.mat-flat-button .mat-button-wrapper>*,.mat-stroked-button .mat-button-wrapper>*,.mat-raised-button .mat-button-wrapper>*,.mat-icon-button .mat-button-wrapper>*,.mat-fab .mat-button-wrapper>*,.mat-mini-fab .mat-button-wrapper>*{vertical-align:middle}.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-prefix .mat-icon-button,.mat-form-field:not(.mat-form-field-appearance-legacy) .mat-form-field-suffix .mat-icon-button{display:block;font-size:inherit;width:2.5em;height:2.5em}.cdk-high-contrast-active .mat-button,.cdk-high-contrast-active .mat-flat-button,.cdk-high-contrast-active .mat-raised-button,.cdk-high-contrast-active .mat-icon-button,.cdk-high-contrast-active .mat-fab,.cdk-high-contrast-active .mat-mini-fab{outline:solid 1px}\n"]
        }]
      }], function () {
        return [{
          type: _angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_2__["FocusMonitor"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
        }, {
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [_angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_3__["ANIMATION_MODULE_TYPE"]]
          }]
        }];
      }, {
        tabIndex: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/button/button-module.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var MatButtonModule = function MatButtonModule() {
      _classCallCheck(this, MatButtonModule);
    };

    MatButtonModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: MatButtonModule
    });
    MatButtonModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function MatButtonModule_Factory(t) {
        return new (t || MatButtonModule)();
      },
      imports: [[_angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatRippleModule"], _angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatCommonModule"]], _angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatCommonModule"]]
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](MatButtonModule, {
        declarations: function declarations() {
          return [MatButton, MatAnchor];
        },
        imports: function imports() {
          return [_angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatRippleModule"], _angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatCommonModule"]];
        },
        exports: function exports() {
          return [MatButton, MatAnchor, _angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatCommonModule"]];
        }
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatButtonModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{
          imports: [_angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatRippleModule"], _angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatCommonModule"]],
          exports: [MatButton, MatAnchor, _angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatCommonModule"]],
          declarations: [MatButton, MatAnchor]
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/button/public-api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=button.js.map

    /***/

  },

  /***/
  "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/core.js":
  /*!**********************************************************************!*\
    !*** ./node_modules/@angular/material/__ivy_ngcc__/fesm2015/core.js ***!
    \**********************************************************************/

  /*! exports provided: APR, AUG, AnimationCurves, AnimationDurations, DEC, DateAdapter, ErrorStateMatcher, FEB, GestureConfig, JAN, JUL, JUN, MAR, MATERIAL_SANITY_CHECKS, MAT_DATE_FORMATS, MAT_DATE_LOCALE, MAT_DATE_LOCALE_FACTORY, MAT_DATE_LOCALE_PROVIDER, MAT_HAMMER_OPTIONS, MAT_LABEL_GLOBAL_OPTIONS, MAT_NATIVE_DATE_FORMATS, MAT_OPTION_PARENT_COMPONENT, MAT_RIPPLE_GLOBAL_OPTIONS, MAY, MatCommonModule, MatLine, MatLineModule, MatLineSetter, MatNativeDateModule, MatOptgroup, MatOption, MatOptionModule, MatOptionSelectionChange, MatPseudoCheckbox, MatPseudoCheckboxModule, MatRipple, MatRippleModule, NOV, NativeDateAdapter, NativeDateModule, OCT, RippleRef, RippleRenderer, SEP, ShowOnDirtyErrorStateMatcher, VERSION, _countGroupLabelsBeforeOption, _getOptionScrollPosition, defaultRippleAnimationConfig, mixinColor, mixinDisableRipple, mixinDisabled, mixinErrorState, mixinInitialized, mixinTabIndex, setLines, ɵangular_material_src_material_core_core_a */

  /***/
  function node_modulesAngularMaterial__ivy_ngcc__Fesm2015CoreJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "APR", function () {
      return APR;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AUG", function () {
      return AUG;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AnimationCurves", function () {
      return AnimationCurves;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AnimationDurations", function () {
      return AnimationDurations;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DEC", function () {
      return DEC;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DateAdapter", function () {
      return DateAdapter;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ErrorStateMatcher", function () {
      return ErrorStateMatcher;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FEB", function () {
      return FEB;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "GestureConfig", function () {
      return GestureConfig;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "JAN", function () {
      return JAN;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "JUL", function () {
      return JUL;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "JUN", function () {
      return JUN;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MAR", function () {
      return MAR;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MATERIAL_SANITY_CHECKS", function () {
      return MATERIAL_SANITY_CHECKS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MAT_DATE_FORMATS", function () {
      return MAT_DATE_FORMATS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MAT_DATE_LOCALE", function () {
      return MAT_DATE_LOCALE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MAT_DATE_LOCALE_FACTORY", function () {
      return MAT_DATE_LOCALE_FACTORY;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MAT_DATE_LOCALE_PROVIDER", function () {
      return MAT_DATE_LOCALE_PROVIDER;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MAT_HAMMER_OPTIONS", function () {
      return MAT_HAMMER_OPTIONS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MAT_LABEL_GLOBAL_OPTIONS", function () {
      return MAT_LABEL_GLOBAL_OPTIONS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MAT_NATIVE_DATE_FORMATS", function () {
      return MAT_NATIVE_DATE_FORMATS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MAT_OPTION_PARENT_COMPONENT", function () {
      return MAT_OPTION_PARENT_COMPONENT;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MAT_RIPPLE_GLOBAL_OPTIONS", function () {
      return MAT_RIPPLE_GLOBAL_OPTIONS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MAY", function () {
      return MAY;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatCommonModule", function () {
      return MatCommonModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatLine", function () {
      return MatLine;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatLineModule", function () {
      return MatLineModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatLineSetter", function () {
      return MatLineSetter;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatNativeDateModule", function () {
      return MatNativeDateModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatOptgroup", function () {
      return MatOptgroup;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatOption", function () {
      return MatOption;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatOptionModule", function () {
      return MatOptionModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatOptionSelectionChange", function () {
      return MatOptionSelectionChange;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatPseudoCheckbox", function () {
      return MatPseudoCheckbox;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatPseudoCheckboxModule", function () {
      return MatPseudoCheckboxModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatRipple", function () {
      return MatRipple;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatRippleModule", function () {
      return MatRippleModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NOV", function () {
      return NOV;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NativeDateAdapter", function () {
      return NativeDateAdapter;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NativeDateModule", function () {
      return NativeDateModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "OCT", function () {
      return OCT;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RippleRef", function () {
      return RippleRef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RippleRenderer", function () {
      return RippleRenderer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SEP", function () {
      return SEP;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ShowOnDirtyErrorStateMatcher", function () {
      return ShowOnDirtyErrorStateMatcher;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "VERSION", function () {
      return VERSION;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "_countGroupLabelsBeforeOption", function () {
      return _countGroupLabelsBeforeOption;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "_getOptionScrollPosition", function () {
      return _getOptionScrollPosition;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "defaultRippleAnimationConfig", function () {
      return defaultRippleAnimationConfig;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "mixinColor", function () {
      return mixinColor;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "mixinDisableRipple", function () {
      return mixinDisableRipple;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "mixinDisabled", function () {
      return mixinDisabled;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "mixinErrorState", function () {
      return mixinErrorState;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "mixinInitialized", function () {
      return mixinInitialized;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "mixinTabIndex", function () {
      return mixinTabIndex;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "setLines", function () {
      return setLines;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_material_src_material_core_core_a", function () {
      return MATERIAL_SANITY_CHECKS_FACTORY;
    });
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var _angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! @angular/cdk/a11y */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/a11y.js");
    /* harmony import */


    var _angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! @angular/cdk/bidi */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/bidi.js");
    /* harmony import */


    var _angular_cdk__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! @angular/cdk */
    "./node_modules/@angular/cdk/fesm2015/cdk.js");
    /* harmony import */


    var _angular_common__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! @angular/common */
    "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/common.js");
    /* harmony import */


    var _angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(
    /*! @angular/cdk/coercion */
    "./node_modules/@angular/cdk/fesm2015/coercion.js");
    /* harmony import */


    var rxjs__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(
    /*! rxjs */
    "./node_modules/rxjs/_esm2015/index.js");
    /* harmony import */


    var _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(
    /*! @angular/cdk/platform */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/platform.js");
    /* harmony import */


    var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(
    /*! @angular/platform-browser */
    "./node_modules/@angular/platform-browser/__ivy_ngcc__/fesm2015/platform-browser.js");
    /* harmony import */


    var rxjs_operators__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(
    /*! rxjs/operators */
    "./node_modules/rxjs/_esm2015/operators/index.js");
    /* harmony import */


    var _angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(
    /*! @angular/platform-browser/animations */
    "./node_modules/@angular/platform-browser/__ivy_ngcc__/fesm2015/animations.js");
    /* harmony import */


    var _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(
    /*! @angular/cdk/keycodes */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/keycodes.js");
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/version.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Current version of Angular Material.
     * @type {?}
     */


    var _c0 = ["*", [["mat-option"], ["ng-container"]]];
    var _c1 = ["*", "mat-option, ng-container"];

    function MatOption_mat_pseudo_checkbox_0_Template(rf, ctx) {
      if (rf & 1) {
        _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelement"](0, "mat-pseudo-checkbox", 3);
      }

      if (rf & 2) {
        var ctx_r0 = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵnextContext"]();

        _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("state", ctx_r0.selected ? "checked" : "unchecked")("disabled", ctx_r0.disabled);
      }
    }

    var _c2 = ["*"];
    var VERSION = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["Version"]('9.2.2');
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/animation/animation.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * \@docs-private
     */

    var AnimationCurves = function AnimationCurves() {
      _classCallCheck(this, AnimationCurves);
    };

    AnimationCurves.STANDARD_CURVE = 'cubic-bezier(0.4,0.0,0.2,1)';
    AnimationCurves.DECELERATION_CURVE = 'cubic-bezier(0.0,0.0,0.2,1)';
    AnimationCurves.ACCELERATION_CURVE = 'cubic-bezier(0.4,0.0,1,1)';
    AnimationCurves.SHARP_CURVE = 'cubic-bezier(0.4,0.0,0.6,1)';

    if (false) {}
    /**
     * \@docs-private
     */


    var AnimationDurations = function AnimationDurations() {
      _classCallCheck(this, AnimationDurations);
    };

    AnimationDurations.COMPLEX = '375ms';
    AnimationDurations.ENTERING = '225ms';
    AnimationDurations.EXITING = '195ms';

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/common-behaviors/common-module.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */
    // Private version constant to circumvent test/build issues,
    // i.e. avoid core to depend on the @angular/material primary entry-point
    // Can be removed once the Material primary entry-point no longer
    // re-exports all secondary entry-points

    /** @type {?} */


    var VERSION$1 = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["Version"]('9.2.2');
    /**
     * \@docs-private
     * @return {?}
     */

    function MATERIAL_SANITY_CHECKS_FACTORY() {
      return true;
    }
    /**
     * Injection token that configures whether the Material sanity checks are enabled.
     * @type {?}
     */


    var MATERIAL_SANITY_CHECKS = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('mat-sanity-checks', {
      providedIn: 'root',
      factory: MATERIAL_SANITY_CHECKS_FACTORY
    });
    /**
     * Object that can be used to configure the sanity checks granularly.
     * @record
     */

    function GranularSanityChecks() {}

    if (false) {}
    /**
     * Module that captures anything that should be loaded and/or run for *all* Angular Material
     * components. This includes Bidi, etc.
     *
     * This module should be imported to each top-level component module (e.g., MatTabsModule).
     */


    var MatCommonModule = /*#__PURE__*/function () {
      /**
       * @param {?} highContrastModeDetector
       * @param {?} sanityChecks
       * @param {?=} document
       */
      function MatCommonModule(highContrastModeDetector, sanityChecks,
      /** @breaking-change 11.0.0 make document required */
      document) {
        _classCallCheck(this, MatCommonModule);

        /**
         * Whether we've done the global sanity checks (e.g. a theme is loaded, there is a doctype).
         */
        this._hasDoneGlobalChecks = false;
        this._document = document; // While A11yModule also does this, we repeat it here to avoid importing A11yModule
        // in MatCommonModule.

        highContrastModeDetector._applyBodyHighContrastModeCssClasses(); // Note that `_sanityChecks` is typed to `any`, because AoT
        // throws an error if we use the `SanityChecks` type directly.


        this._sanityChecks = sanityChecks;

        if (!this._hasDoneGlobalChecks) {
          this._checkDoctypeIsDefined();

          this._checkThemeIsPresent();

          this._checkCdkVersionMatch();

          this._hasDoneGlobalChecks = true;
        }
      }
      /**
       * Access injected document if available or fallback to global document reference
       * @private
       * @return {?}
       */


      _createClass2(MatCommonModule, [{
        key: "_getDocument",
        value: function _getDocument() {
          /** @type {?} */
          var doc = this._document || document;
          return typeof doc === 'object' && doc ? doc : null;
        }
        /**
         * Use defaultView of injected document if available or fallback to global window reference
         * @private
         * @return {?}
         */

      }, {
        key: "_getWindow",
        value: function _getWindow() {
          /** @type {?} */
          var doc = this._getDocument();
          /** @type {?} */


          var win = (doc === null || doc === void 0 ? void 0 : doc.defaultView) || window;
          return typeof win === 'object' && win ? win : null;
        }
        /**
         * Whether any sanity checks are enabled.
         * @private
         * @return {?}
         */

      }, {
        key: "_checksAreEnabled",
        value: function _checksAreEnabled() {
          return Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["isDevMode"])() && !this._isTestEnv();
        }
        /**
         * Whether the code is running in tests.
         * @private
         * @return {?}
         */

      }, {
        key: "_isTestEnv",
        value: function _isTestEnv() {
          /** @type {?} */
          var window =
          /** @type {?} */
          this._getWindow();

          return window && (window.__karma__ || window.jasmine);
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_checkDoctypeIsDefined",
        value: function _checkDoctypeIsDefined() {
          /** @type {?} */
          var isEnabled = this._checksAreEnabled() && (this._sanityChecks === true ||
          /** @type {?} */
          this._sanityChecks.doctype);
          /** @type {?} */


          var document = this._getDocument();

          if (isEnabled && document && !document.doctype) {
            console.warn('Current document does not have a doctype. This may cause ' + 'some Angular Material components not to behave as expected.');
          }
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_checkThemeIsPresent",
        value: function _checkThemeIsPresent() {
          // We need to assert that the `body` is defined, because these checks run very early
          // and the `body` won't be defined if the consumer put their scripts in the `head`.

          /** @type {?} */
          var isDisabled = !this._checksAreEnabled() || this._sanityChecks === false || !
          /** @type {?} */
          this._sanityChecks.theme;
          /** @type {?} */

          var document = this._getDocument();

          if (isDisabled || !document || !document.body || typeof getComputedStyle !== 'function') {
            return;
          }
          /** @type {?} */


          var testElement = document.createElement('div');
          testElement.classList.add('mat-theme-loaded-marker');
          document.body.appendChild(testElement);
          /** @type {?} */

          var computedStyle = getComputedStyle(testElement); // In some situations the computed style of the test element can be null. For example in
          // Firefox, the computed style is null if an application is running inside of a hidden iframe.
          // See: https://bugzilla.mozilla.org/show_bug.cgi?id=548397

          if (computedStyle && computedStyle.display !== 'none') {
            console.warn('Could not find Angular Material core theme. Most Material ' + 'components may not work as expected. For more info refer ' + 'to the theming guide: https://material.angular.io/guide/theming');
          }

          document.body.removeChild(testElement);
        }
        /**
         * Checks whether the material version matches the cdk version
         * @private
         * @return {?}
         */

      }, {
        key: "_checkCdkVersionMatch",
        value: function _checkCdkVersionMatch() {
          /** @type {?} */
          var isEnabled = this._checksAreEnabled() && (this._sanityChecks === true ||
          /** @type {?} */
          this._sanityChecks.version);

          if (isEnabled && VERSION$1.full !== _angular_cdk__WEBPACK_IMPORTED_MODULE_3__["VERSION"].full) {
            console.warn('The Angular Material version (' + VERSION$1.full + ') does not match ' + 'the Angular CDK version (' + _angular_cdk__WEBPACK_IMPORTED_MODULE_3__["VERSION"].full + ').\n' + 'Please ensure the versions of these two packages exactly match.');
          }
        }
      }]);

      return MatCommonModule;
    }();

    MatCommonModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: MatCommonModule
    });
    MatCommonModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function MatCommonModule_Factory(t) {
        return new (t || MatCommonModule)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_1__["HighContrastModeDetector"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](MATERIAL_SANITY_CHECKS, 8), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"], 8));
      },
      imports: [[_angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_2__["BidiModule"]], _angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_2__["BidiModule"]]
    });
    /** @nocollapse */

    MatCommonModule.ctorParameters = function () {
      return [{
        type: _angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_1__["HighContrastModeDetector"]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [MATERIAL_SANITY_CHECKS]
        }]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]]
        }]
      }];
    };

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](MatCommonModule, {
        imports: function imports() {
          return [_angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_2__["BidiModule"]];
        },
        exports: function exports() {
          return [_angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_2__["BidiModule"]];
        }
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatCommonModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{
          imports: [_angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_2__["BidiModule"]],
          exports: [_angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_2__["BidiModule"]]
        }]
      }], function () {
        return [{
          type: _angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_1__["HighContrastModeDetector"]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [MATERIAL_SANITY_CHECKS]
          }]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/common-behaviors/disabled.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@docs-private
     * @record
     */


    function CanDisable() {}

    if (false) {}
    /**
     * Mixin to augment a directive with a `disabled` property.
     * @template T
     * @param {?} base
     * @return {?}
     */


    function mixinDisabled(base) {
      return /*#__PURE__*/function (_base2) {
        _inherits(_class, _base2);

        var _super70 = _createSuper(_class);

        /**
         * @param {...?} args
         */
        function _class() {
          var _this226;

          _classCallCheck(this, _class);

          for (var _len20 = arguments.length, args = new Array(_len20), _key21 = 0; _key21 < _len20; _key21++) {
            args[_key21] = arguments[_key21];
          }

          _this226 = _super70.call.apply(_super70, [this].concat(args));
          _this226._disabled = false;
          return _this226;
        }
        /**
         * @return {?}
         */


        _createClass2(_class, [{
          key: "disabled",
          get: function get() {
            return this._disabled;
          }
          /**
           * @param {?} value
           * @return {?}
           */
          ,
          set: function set(value) {
            this._disabled = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceBooleanProperty"])(value);
          }
        }]);

        return _class;
      }(base);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/common-behaviors/color.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * \@docs-private
     * @record
     */


    function CanColor() {}

    if (false) {}
    /**
     * \@docs-private
     * @record
     */


    function HasElementRef() {}

    if (false) {}
    /**
     * Mixin to augment a directive with a `color` property.
     * @template T
     * @param {?} base
     * @param {?=} defaultColor
     * @return {?}
     */


    function mixinColor(base, defaultColor) {
      return /*#__PURE__*/function (_base3) {
        _inherits(_class2, _base3);

        var _super71 = _createSuper(_class2);

        /**
         * @param {...?} args
         */
        function _class2() {
          var _this227;

          _classCallCheck(this, _class2);

          for (var _len21 = arguments.length, args = new Array(_len21), _key22 = 0; _key22 < _len21; _key22++) {
            args[_key22] = arguments[_key22];
          }

          _this227 = _super71.call.apply(_super71, [this].concat(args)); // Set the default color that can be specified from the mixin.

          _this227.color = defaultColor;
          return _this227;
        }
        /**
         * @return {?}
         */


        _createClass2(_class2, [{
          key: "color",
          get: function get() {
            return this._color;
          }
          /**
           * @param {?} value
           * @return {?}
           */
          ,
          set: function set(value) {
            /** @type {?} */
            var colorPalette = value || defaultColor;

            if (colorPalette !== this._color) {
              if (this._color) {
                this._elementRef.nativeElement.classList.remove("mat-".concat(this._color));
              }

              if (colorPalette) {
                this._elementRef.nativeElement.classList.add("mat-".concat(colorPalette));
              }

              this._color = colorPalette;
            }
          }
        }]);

        return _class2;
      }(base);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/common-behaviors/disable-ripple.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@docs-private
     * @record
     */


    function CanDisableRipple() {}

    if (false) {}
    /**
     * Mixin to augment a directive with a `disableRipple` property.
     * @template T
     * @param {?} base
     * @return {?}
     */


    function mixinDisableRipple(base) {
      return /*#__PURE__*/function (_base4) {
        _inherits(_class3, _base4);

        var _super72 = _createSuper(_class3);

        /**
         * @param {...?} args
         */
        function _class3() {
          var _this228;

          _classCallCheck(this, _class3);

          for (var _len22 = arguments.length, args = new Array(_len22), _key23 = 0; _key23 < _len22; _key23++) {
            args[_key23] = arguments[_key23];
          }

          _this228 = _super72.call.apply(_super72, [this].concat(args));
          _this228._disableRipple = false;
          return _this228;
        }
        /**
         * Whether the ripple effect is disabled or not.
         * @return {?}
         */


        _createClass2(_class3, [{
          key: "disableRipple",
          get: function get() {
            return this._disableRipple;
          }
          /**
           * @param {?} value
           * @return {?}
           */
          ,
          set: function set(value) {
            this._disableRipple = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceBooleanProperty"])(value);
          }
        }]);

        return _class3;
      }(base);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/common-behaviors/tabindex.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * \@docs-private
     * @record
     */


    function HasTabIndex() {}

    if (false) {}
    /**
     * Mixin to augment a directive with a `tabIndex` property.
     * @template T
     * @param {?} base
     * @param {?=} defaultTabIndex
     * @return {?}
     */


    function mixinTabIndex(base) {
      var defaultTabIndex = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
      return /*#__PURE__*/function (_base5) {
        _inherits(_class4, _base5);

        var _super73 = _createSuper(_class4);

        /**
         * @param {...?} args
         */
        function _class4() {
          var _this229;

          _classCallCheck(this, _class4);

          for (var _len23 = arguments.length, args = new Array(_len23), _key24 = 0; _key24 < _len23; _key24++) {
            args[_key24] = arguments[_key24];
          }

          _this229 = _super73.call.apply(_super73, [this].concat(args));
          _this229._tabIndex = defaultTabIndex;
          return _this229;
        }
        /**
         * @return {?}
         */


        _createClass2(_class4, [{
          key: "tabIndex",
          get: function get() {
            return this.disabled ? -1 : this._tabIndex;
          }
          /**
           * @param {?} value
           * @return {?}
           */
          ,
          set: function set(value) {
            // If the specified tabIndex value is null or undefined, fall back to the default value.
            this._tabIndex = value != null ? value : defaultTabIndex;
          }
        }]);

        return _class4;
      }(base);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/common-behaviors/error-state.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@docs-private
     * @record
     */


    function CanUpdateErrorState() {}

    if (false) {}
    /**
     * \@docs-private
     * @record
     */


    function HasErrorState() {}

    if (false) {}
    /**
     * Mixin to augment a directive with updateErrorState method.
     * For component with `errorState` and need to update `errorState`.
     * @template T
     * @param {?} base
     * @return {?}
     */


    function mixinErrorState(base) {
      return /*#__PURE__*/function (_base6) {
        _inherits(_class5, _base6);

        var _super74 = _createSuper(_class5);

        /**
         * @param {...?} args
         */
        function _class5() {
          var _this230;

          _classCallCheck(this, _class5);

          for (var _len24 = arguments.length, args = new Array(_len24), _key25 = 0; _key25 < _len24; _key25++) {
            args[_key25] = arguments[_key25];
          }

          _this230 = _super74.call.apply(_super74, [this].concat(args));
          /**
           * Whether the component is in an error state.
           */

          _this230.errorState = false;
          /**
           * Stream that emits whenever the state of the input changes such that the wrapping
           * `MatFormField` needs to run change detection.
           */

          _this230.stateChanges = new rxjs__WEBPACK_IMPORTED_MODULE_6__["Subject"]();
          return _this230;
        }
        /**
         * @return {?}
         */


        _createClass2(_class5, [{
          key: "updateErrorState",
          value: function updateErrorState() {
            /** @type {?} */
            var oldState = this.errorState;
            /** @type {?} */

            var parent = this._parentFormGroup || this._parentForm;
            /** @type {?} */

            var matcher = this.errorStateMatcher || this._defaultErrorStateMatcher;
            /** @type {?} */

            var control = this.ngControl ?
            /** @type {?} */
            this.ngControl.control : null;
            /** @type {?} */

            var newState = matcher.isErrorState(control, parent);

            if (newState !== oldState) {
              this.errorState = newState;
              this.stateChanges.next();
            }
          }
        }]);

        return _class5;
      }(base);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/common-behaviors/initialized.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Mixin that adds an initialized property to a directive which, when subscribed to, will emit a
     * value once markInitialized has been called, which should be done during the ngOnInit function.
     * If the subscription is made after it has already been marked as initialized, then it will trigger
     * an emit immediately.
     * \@docs-private
     * @record
     */


    function HasInitialized() {}

    if (false) {}
    /**
     * Mixin to augment a directive with an initialized property that will emits when ngOnInit ends.
     * @template T
     * @param {?} base
     * @return {?}
     */


    function mixinInitialized(base) {
      return /*#__PURE__*/function (_base7) {
        _inherits(_class6, _base7);

        var _super75 = _createSuper(_class6);

        /**
         * @param {...?} args
         */
        function _class6() {
          var _this231;

          _classCallCheck(this, _class6);

          for (var _len25 = arguments.length, args = new Array(_len25), _key26 = 0; _key26 < _len25; _key26++) {
            args[_key26] = arguments[_key26];
          }

          _this231 = _super75.call.apply(_super75, [this].concat(args));
          /**
           * Whether this directive has been marked as initialized.
           */

          _this231._isInitialized = false;
          /**
           * List of subscribers that subscribed before the directive was initialized. Should be notified
           * during _markInitialized. Set to null after pending subscribers are notified, and should
           * not expect to be populated after.
           */

          _this231._pendingSubscribers = [];
          /**
           * Observable stream that emits when the directive initializes. If already initialized, the
           * subscriber is stored to be notified once _markInitialized is called.
           */

          _this231.initialized = new rxjs__WEBPACK_IMPORTED_MODULE_6__["Observable"](
          /**
          * @param {?} subscriber
          * @return {?}
          */
          function (subscriber) {
            // If initialized, immediately notify the subscriber. Otherwise store the subscriber to notify
            // when _markInitialized is called.
            if (_this231._isInitialized) {
              _this231._notifySubscriber(subscriber);
            } else {
              /** @type {?} */
              _this231._pendingSubscribers.push(subscriber);
            }
          });
          return _this231;
        }
        /**
         * Marks the state as initialized and notifies pending subscribers. Should be called at the end
         * of ngOnInit.
         * \@docs-private
         * @return {?}
         */


        _createClass2(_class6, [{
          key: "_markInitialized",
          value: function _markInitialized() {
            if (this._isInitialized) {
              throw Error('This directive has already been marked as initialized and ' + 'should not be called twice.');
            }

            this._isInitialized = true;

            /** @type {?} */
            this._pendingSubscribers.forEach(this._notifySubscriber);

            this._pendingSubscribers = null;
          }
          /**
           * Emits and completes the subscriber stream (should only emit once).
           * @param {?} subscriber
           * @return {?}
           */

        }, {
          key: "_notifySubscriber",
          value: function _notifySubscriber(subscriber) {
            subscriber.next();
            subscriber.complete();
          }
        }]);

        return _class6;
      }(base);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/common-behaviors/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/datetime/date-adapter.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * InjectionToken for datepicker that can be used to override default locale code.
     * @type {?}
     */


    var MAT_DATE_LOCALE = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('MAT_DATE_LOCALE', {
      providedIn: 'root',
      factory: MAT_DATE_LOCALE_FACTORY
    });
    /**
     * \@docs-private
     * @return {?}
     */

    function MAT_DATE_LOCALE_FACTORY() {
      return Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["inject"])(_angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"]);
    }
    /**
     * No longer needed since MAT_DATE_LOCALE has been changed to a scoped injectable.
     * If you are importing and providing this in your code you can simply remove it.
     * @deprecated
     * \@breaking-change 8.0.0
     * @type {?}
     */


    var MAT_DATE_LOCALE_PROVIDER = {
      provide: MAT_DATE_LOCALE,
      useExisting: _angular_core__WEBPACK_IMPORTED_MODULE_0__["LOCALE_ID"]
    };
    /**
     * Adapts type `D` to be usable as a date by cdk-based components that work with dates.
     * @abstract
     * @template D
     */

    var DateAdapter = /*#__PURE__*/function () {
      function DateAdapter() {
        _classCallCheck(this, DateAdapter);

        this._localeChanges = new rxjs__WEBPACK_IMPORTED_MODULE_6__["Subject"]();
      }
      /**
       * A stream that emits when the locale changes.
       * @return {?}
       */


      _createClass2(DateAdapter, [{
        key: "deserialize",

        /**
         * Attempts to deserialize a value to a valid date object. This is different from parsing in that
         * deserialize should only accept non-ambiguous, locale-independent formats (e.g. a ISO 8601
         * string). The default implementation does not allow any deserialization, it simply checks that
         * the given value is already a valid date object or null. The `<mat-datepicker>` will call this
         * method on all of its `\@Input()` properties that accept dates. It is therefore possible to
         * support passing values from your backend directly to these properties by overriding this method
         * to also deserialize the format used by your backend.
         * @param {?} value The value to be deserialized into a date object.
         * @return {?} The deserialized date object, either a valid date, null if the value can be
         *     deserialized into a null date (e.g. the empty string), or an invalid date.
         */
        value: function deserialize(value) {
          if (value == null || this.isDateInstance(value) && this.isValid(value)) {
            return value;
          }

          return this.invalid();
        }
        /**
         * Sets the locale used for all dates.
         * @param {?} locale The new locale.
         * @return {?}
         */

      }, {
        key: "setLocale",
        value: function setLocale(locale) {
          this.locale = locale;

          this._localeChanges.next();
        }
        /**
         * Compares two dates.
         * @param {?} first The first date to compare.
         * @param {?} second The second date to compare.
         * @return {?} 0 if the dates are equal, a number less than 0 if the first date is earlier,
         *     a number greater than 0 if the first date is later.
         */

      }, {
        key: "compareDate",
        value: function compareDate(first, second) {
          return this.getYear(first) - this.getYear(second) || this.getMonth(first) - this.getMonth(second) || this.getDate(first) - this.getDate(second);
        }
        /**
         * Checks if two dates are equal.
         * @param {?} first The first date to check.
         * @param {?} second The second date to check.
         * @return {?} Whether the two dates are equal.
         *     Null dates are considered equal to other null dates.
         */

      }, {
        key: "sameDate",
        value: function sameDate(first, second) {
          if (first && second) {
            /** @type {?} */
            var firstValid = this.isValid(first);
            /** @type {?} */

            var secondValid = this.isValid(second);

            if (firstValid && secondValid) {
              return !this.compareDate(first, second);
            }

            return firstValid == secondValid;
          }

          return first == second;
        }
        /**
         * Clamp the given date between min and max dates.
         * @param {?} date The date to clamp.
         * @param {?=} min The minimum value to allow. If null or omitted no min is enforced.
         * @param {?=} max The maximum value to allow. If null or omitted no max is enforced.
         * @return {?} `min` if `date` is less than `min`, `max` if date is greater than `max`,
         *     otherwise `date`.
         */

      }, {
        key: "clampDate",
        value: function clampDate(date, min, max) {
          if (min && this.compareDate(date, min) < 0) {
            return min;
          }

          if (max && this.compareDate(date, max) > 0) {
            return max;
          }

          return date;
        }
      }, {
        key: "localeChanges",
        get: function get() {
          return this._localeChanges;
        }
      }]);

      return DateAdapter;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/datetime/date-formats.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var MAT_DATE_FORMATS = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('mat-date-formats');
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/datetime/native-date-adapter.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */
    // TODO(mmalerba): Remove when we no longer support safari 9.

    /**
     * Whether the browser supports the Intl API.
     * @type {?}
     */

    var SUPPORTS_INTL_API; // We need a try/catch around the reference to `Intl`, because accessing it in some cases can
    // cause IE to throw. These cases are tied to particular versions of Windows and can happen if
    // the consumer is providing a polyfilled `Map`. See:
    // https://github.com/Microsoft/ChakraCore/issues/3189
    // https://github.com/angular/components/issues/15687

    try {
      SUPPORTS_INTL_API = typeof Intl != 'undefined';
    } catch (_a) {
      SUPPORTS_INTL_API = false;
    }
    /**
     * The default month names to use if Intl API is not available.
     * @type {?}
     */


    var DEFAULT_MONTH_NAMES = {
      'long': ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'],
      'short': ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'],
      'narrow': ['J', 'F', 'M', 'A', 'M', 'J', 'J', 'A', 'S', 'O', 'N', 'D']
    };

    var ɵ0 =
    /**
    * @param {?} i
    * @return {?}
    */
    function ɵ0(i) {
      return String(i + 1);
    };
    /**
     * The default date names to use if Intl API is not available.
     * @type {?}
     */


    var DEFAULT_DATE_NAMES = range(31, ɵ0);
    /**
     * The default day of the week names to use if Intl API is not available.
     * @type {?}
     */

    var DEFAULT_DAY_OF_WEEK_NAMES = {
      'long': ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'],
      'short': ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'],
      'narrow': ['S', 'M', 'T', 'W', 'T', 'F', 'S']
    };
    /**
     * Matches strings that have the form of a valid RFC 3339 string
     * (https://tools.ietf.org/html/rfc3339). Note that the string may not actually be a valid date
     * because the regex will match strings an with out of bounds month, date, etc.
     * @type {?}
     */

    var ISO_8601_REGEX = /^\d{4}-\d{2}-\d{2}(?:T\d{2}:\d{2}:\d{2}(?:\.\d+)?(?:Z|(?:(?:\+|-)\d{2}:\d{2}))?)?$/;
    /**
     * Creates an array and fills it with values.
     * @template T
     * @param {?} length
     * @param {?} valueFunction
     * @return {?}
     */

    function range(length, valueFunction) {
      /** @type {?} */
      var valuesArray = Array(length);

      for (var i = 0; i < length; i++) {
        valuesArray[i] = valueFunction(i);
      }

      return valuesArray;
    }
    /**
     * Adapts the native JS Date for use with cdk-based components that work with dates.
     */


    var NativeDateAdapter = /*#__PURE__*/function (_DateAdapter) {
      _inherits(NativeDateAdapter, _DateAdapter);

      var _super76 = _createSuper(NativeDateAdapter);

      /**
       * @param {?} matDateLocale
       * @param {?} platform
       */
      function NativeDateAdapter(matDateLocale, platform) {
        var _thisSuper3, _this232;

        _classCallCheck(this, NativeDateAdapter);

        _this232 = _super76.call(this);
        /**
         * Whether to use `timeZone: 'utc'` with `Intl.DateTimeFormat` when formatting dates.
         * Without this `Intl.DateTimeFormat` sometimes chooses the wrong timeZone, which can throw off
         * the result. (e.g. in the en-US locale `new Date(1800, 7, 14).toLocaleDateString()`
         * will produce `'8/13/1800'`.
         *
         * TODO(mmalerba): drop this variable. It's not being used in the code right now. We're now
         * getting the string representation of a Date object from its utc representation. We're keeping
         * it here for sometime, just for precaution, in case we decide to revert some of these changes
         * though.
         */

        _this232.useUtcForDisplay = true;

        _get((_thisSuper3 = _assertThisInitialized(_this232), _getPrototypeOf(NativeDateAdapter.prototype)), "setLocale", _thisSuper3).call(_thisSuper3, matDateLocale); // IE does its own time zone correction, so we disable this on IE.


        _this232.useUtcForDisplay = !platform.TRIDENT;
        _this232._clampDate = platform.TRIDENT || platform.EDGE;
        return _this232;
      }
      /**
       * @param {?} date
       * @return {?}
       */


      _createClass2(NativeDateAdapter, [{
        key: "getYear",
        value: function getYear(date) {
          return date.getFullYear();
        }
        /**
         * @param {?} date
         * @return {?}
         */

      }, {
        key: "getMonth",
        value: function getMonth(date) {
          return date.getMonth();
        }
        /**
         * @param {?} date
         * @return {?}
         */

      }, {
        key: "getDate",
        value: function getDate(date) {
          return date.getDate();
        }
        /**
         * @param {?} date
         * @return {?}
         */

      }, {
        key: "getDayOfWeek",
        value: function getDayOfWeek(date) {
          return date.getDay();
        }
        /**
         * @param {?} style
         * @return {?}
         */

      }, {
        key: "getMonthNames",
        value: function getMonthNames(style) {
          var _this233 = this;

          if (SUPPORTS_INTL_API) {
            /** @type {?} */
            var dtf = new Intl.DateTimeFormat(this.locale, {
              month: style,
              timeZone: 'utc'
            });
            return range(12,
            /**
            * @param {?} i
            * @return {?}
            */
            function (i) {
              return _this233._stripDirectionalityCharacters(_this233._format(dtf, new Date(2017, i, 1)));
            });
          }

          return DEFAULT_MONTH_NAMES[style];
        }
        /**
         * @return {?}
         */

      }, {
        key: "getDateNames",
        value: function getDateNames() {
          var _this234 = this;

          if (SUPPORTS_INTL_API) {
            /** @type {?} */
            var dtf = new Intl.DateTimeFormat(this.locale, {
              day: 'numeric',
              timeZone: 'utc'
            });
            return range(31,
            /**
            * @param {?} i
            * @return {?}
            */
            function (i) {
              return _this234._stripDirectionalityCharacters(_this234._format(dtf, new Date(2017, 0, i + 1)));
            });
          }

          return DEFAULT_DATE_NAMES;
        }
        /**
         * @param {?} style
         * @return {?}
         */

      }, {
        key: "getDayOfWeekNames",
        value: function getDayOfWeekNames(style) {
          var _this235 = this;

          if (SUPPORTS_INTL_API) {
            /** @type {?} */
            var dtf = new Intl.DateTimeFormat(this.locale, {
              weekday: style,
              timeZone: 'utc'
            });
            return range(7,
            /**
            * @param {?} i
            * @return {?}
            */
            function (i) {
              return _this235._stripDirectionalityCharacters(_this235._format(dtf, new Date(2017, 0, i + 1)));
            });
          }

          return DEFAULT_DAY_OF_WEEK_NAMES[style];
        }
        /**
         * @param {?} date
         * @return {?}
         */

      }, {
        key: "getYearName",
        value: function getYearName(date) {
          if (SUPPORTS_INTL_API) {
            /** @type {?} */
            var dtf = new Intl.DateTimeFormat(this.locale, {
              year: 'numeric',
              timeZone: 'utc'
            });
            return this._stripDirectionalityCharacters(this._format(dtf, date));
          }

          return String(this.getYear(date));
        }
        /**
         * @return {?}
         */

      }, {
        key: "getFirstDayOfWeek",
        value: function getFirstDayOfWeek() {
          // We can't tell using native JS Date what the first day of the week is, we default to Sunday.
          return 0;
        }
        /**
         * @param {?} date
         * @return {?}
         */

      }, {
        key: "getNumDaysInMonth",
        value: function getNumDaysInMonth(date) {
          return this.getDate(this._createDateWithOverflow(this.getYear(date), this.getMonth(date) + 1, 0));
        }
        /**
         * @param {?} date
         * @return {?}
         */

      }, {
        key: "clone",
        value: function clone(date) {
          return new Date(date.getTime());
        }
        /**
         * @param {?} year
         * @param {?} month
         * @param {?} date
         * @return {?}
         */

      }, {
        key: "createDate",
        value: function createDate(year, month, date) {
          // Check for invalid month and date (except upper bound on date which we have to check after
          // creating the Date).
          if (month < 0 || month > 11) {
            throw Error("Invalid month index \"".concat(month, "\". Month index has to be between 0 and 11."));
          }

          if (date < 1) {
            throw Error("Invalid date \"".concat(date, "\". Date has to be greater than 0."));
          }
          /** @type {?} */


          var result = this._createDateWithOverflow(year, month, date); // Check that the date wasn't above the upper bound for the month, causing the month to overflow


          if (result.getMonth() != month) {
            throw Error("Invalid date \"".concat(date, "\" for month with index \"").concat(month, "\"."));
          }

          return result;
        }
        /**
         * @return {?}
         */

      }, {
        key: "today",
        value: function today() {
          return new Date();
        }
        /**
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "parse",
        value: function parse(value) {
          // We have no way using the native JS Date to set the parse format or locale, so we ignore these
          // parameters.
          if (typeof value == 'number') {
            return new Date(value);
          }

          return value ? new Date(Date.parse(value)) : null;
        }
        /**
         * @param {?} date
         * @param {?} displayFormat
         * @return {?}
         */

      }, {
        key: "format",
        value: function format(date, displayFormat) {
          if (!this.isValid(date)) {
            throw Error('NativeDateAdapter: Cannot format invalid date.');
          }

          if (SUPPORTS_INTL_API) {
            // On IE and Edge the i18n API will throw a hard error that can crash the entire app
            // if we attempt to format a date whose year is less than 1 or greater than 9999.
            if (this._clampDate && (date.getFullYear() < 1 || date.getFullYear() > 9999)) {
              date = this.clone(date);
              date.setFullYear(Math.max(1, Math.min(9999, date.getFullYear())));
            }

            displayFormat = Object.assign(Object.assign({}, displayFormat), {
              timeZone: 'utc'
            });
            /** @type {?} */

            var dtf = new Intl.DateTimeFormat(this.locale, displayFormat);
            return this._stripDirectionalityCharacters(this._format(dtf, date));
          }

          return this._stripDirectionalityCharacters(date.toDateString());
        }
        /**
         * @param {?} date
         * @param {?} years
         * @return {?}
         */

      }, {
        key: "addCalendarYears",
        value: function addCalendarYears(date, years) {
          return this.addCalendarMonths(date, years * 12);
        }
        /**
         * @param {?} date
         * @param {?} months
         * @return {?}
         */

      }, {
        key: "addCalendarMonths",
        value: function addCalendarMonths(date, months) {
          /** @type {?} */
          var newDate = this._createDateWithOverflow(this.getYear(date), this.getMonth(date) + months, this.getDate(date)); // It's possible to wind up in the wrong month if the original month has more days than the new
          // month. In this case we want to go to the last day of the desired month.
          // Note: the additional + 12 % 12 ensures we end up with a positive number, since JS % doesn't
          // guarantee this.


          if (this.getMonth(newDate) != ((this.getMonth(date) + months) % 12 + 12) % 12) {
            newDate = this._createDateWithOverflow(this.getYear(newDate), this.getMonth(newDate), 0);
          }

          return newDate;
        }
        /**
         * @param {?} date
         * @param {?} days
         * @return {?}
         */

      }, {
        key: "addCalendarDays",
        value: function addCalendarDays(date, days) {
          return this._createDateWithOverflow(this.getYear(date), this.getMonth(date), this.getDate(date) + days);
        }
        /**
         * @param {?} date
         * @return {?}
         */

      }, {
        key: "toIso8601",
        value: function toIso8601(date) {
          return [date.getUTCFullYear(), this._2digit(date.getUTCMonth() + 1), this._2digit(date.getUTCDate())].join('-');
        }
        /**
         * Returns the given value if given a valid Date or null. Deserializes valid ISO 8601 strings
         * (https://www.ietf.org/rfc/rfc3339.txt) into valid Dates and empty string into null. Returns an
         * invalid date for all other values.
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "deserialize",
        value: function deserialize(value) {
          if (typeof value === 'string') {
            if (!value) {
              return null;
            } // The `Date` constructor accepts formats other than ISO 8601, so we need to make sure the
            // string is the right format first.


            if (ISO_8601_REGEX.test(value)) {
              /** @type {?} */
              var date = new Date(value);

              if (this.isValid(date)) {
                return date;
              }
            }
          }

          return _get(_getPrototypeOf(NativeDateAdapter.prototype), "deserialize", this).call(this, value);
        }
        /**
         * @param {?} obj
         * @return {?}
         */

      }, {
        key: "isDateInstance",
        value: function isDateInstance(obj) {
          return obj instanceof Date;
        }
        /**
         * @param {?} date
         * @return {?}
         */

      }, {
        key: "isValid",
        value: function isValid(date) {
          return !isNaN(date.getTime());
        }
        /**
         * @return {?}
         */

      }, {
        key: "invalid",
        value: function invalid() {
          return new Date(NaN);
        }
        /**
         * Creates a date but allows the month and date to overflow.
         * @private
         * @param {?} year
         * @param {?} month
         * @param {?} date
         * @return {?}
         */

      }, {
        key: "_createDateWithOverflow",
        value: function _createDateWithOverflow(year, month, date) {
          /** @type {?} */
          var result = new Date(year, month, date); // We need to correct for the fact that JS native Date treats years in range [0, 99] as
          // abbreviations for 19xx.

          if (year >= 0 && year < 100) {
            result.setFullYear(this.getYear(result) - 1900);
          }

          return result;
        }
        /**
         * Pads a number to make it two digits.
         * @private
         * @param {?} n The number to pad.
         * @return {?} The padded number.
         */

      }, {
        key: "_2digit",
        value: function _2digit(n) {
          return ('00' + n).slice(-2);
        }
        /**
         * Strip out unicode LTR and RTL characters. Edge and IE insert these into formatted dates while
         * other browsers do not. We remove them to make output consistent and because they interfere with
         * date parsing.
         * @private
         * @param {?} str The string to strip direction characters from.
         * @return {?} The stripped string.
         */

      }, {
        key: "_stripDirectionalityCharacters",
        value: function _stripDirectionalityCharacters(str) {
          return str.replace(/[\u200e\u200f]/g, '');
        }
        /**
         * When converting Date object to string, javascript built-in functions may return wrong
         * results because it applies its internal DST rules. The DST rules around the world change
         * very frequently, and the current valid rule is not always valid in previous years though.
         * We work around this problem building a new Date object which has its internal UTC
         * representation with the local date and time.
         * @private
         * @param {?} dtf Intl.DateTimeFormat object, containg the desired string format. It must have
         *    timeZone set to 'utc' to work fine.
         * @param {?} date Date from which we want to get the string representation according to dtf
         * @return {?} A Date object with its UTC representation based on the passed in date info
         */

      }, {
        key: "_format",
        value: function _format(dtf, date) {
          /** @type {?} */
          var d = new Date(Date.UTC(date.getFullYear(), date.getMonth(), date.getDate(), date.getHours(), date.getMinutes(), date.getSeconds(), date.getMilliseconds()));
          return dtf.format(d);
        }
      }]);

      return NativeDateAdapter;
    }(DateAdapter);

    NativeDateAdapter.ɵfac = function NativeDateAdapter_Factory(t) {
      return new (t || NativeDateAdapter)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](MAT_DATE_LOCALE, 8), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_7__["Platform"]));
    };

    NativeDateAdapter.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({
      token: NativeDateAdapter,
      factory: NativeDateAdapter.ɵfac
    });
    /** @nocollapse */

    NativeDateAdapter.ctorParameters = function () {
      return [{
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [MAT_DATE_LOCALE]
        }]
      }, {
        type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_7__["Platform"]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NativeDateAdapter, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"]
      }], function () {
        return [{
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [MAT_DATE_LOCALE]
          }]
        }, {
          type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_7__["Platform"]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/datetime/native-date-formats.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** @type {?} */


    var MAT_NATIVE_DATE_FORMATS = {
      parse: {
        dateInput: null
      },
      display: {
        dateInput: {
          year: 'numeric',
          month: 'numeric',
          day: 'numeric'
        },
        monthYearLabel: {
          year: 'numeric',
          month: 'short'
        },
        dateA11yLabel: {
          year: 'numeric',
          month: 'long',
          day: 'numeric'
        },
        monthYearA11yLabel: {
          year: 'numeric',
          month: 'long'
        }
      }
    };
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/datetime/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    var NativeDateModule = function NativeDateModule() {
      _classCallCheck(this, NativeDateModule);
    };

    NativeDateModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: NativeDateModule
    });
    NativeDateModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function NativeDateModule_Factory(t) {
        return new (t || NativeDateModule)();
      },
      providers: [{
        provide: DateAdapter,
        useClass: NativeDateAdapter
      }],
      imports: [[_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_7__["PlatformModule"]]]
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](NativeDateModule, {
        imports: function imports() {
          return [_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_7__["PlatformModule"]];
        }
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NativeDateModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{
          imports: [_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_7__["PlatformModule"]],
          providers: [{
            provide: DateAdapter,
            useClass: NativeDateAdapter
          }]
        }]
      }], null, null);
    })();

    var ɵ0$1 = MAT_NATIVE_DATE_FORMATS;

    var MatNativeDateModule = function MatNativeDateModule() {
      _classCallCheck(this, MatNativeDateModule);
    };

    MatNativeDateModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: MatNativeDateModule
    });
    MatNativeDateModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function MatNativeDateModule_Factory(t) {
        return new (t || MatNativeDateModule)();
      },
      providers: [{
        provide: MAT_DATE_FORMATS,
        useValue: ɵ0$1
      }],
      imports: [[NativeDateModule]]
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](MatNativeDateModule, {
        imports: [NativeDateModule]
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatNativeDateModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{
          imports: [NativeDateModule],
          providers: [{
            provide: MAT_DATE_FORMATS,
            useValue: ɵ0$1
          }]
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/error/error-options.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Error state matcher that matches when a control is invalid and dirty.
     */


    var ShowOnDirtyErrorStateMatcher = /*#__PURE__*/function () {
      function ShowOnDirtyErrorStateMatcher() {
        _classCallCheck(this, ShowOnDirtyErrorStateMatcher);
      }

      _createClass2(ShowOnDirtyErrorStateMatcher, [{
        key: "isErrorState",

        /**
         * @param {?} control
         * @param {?} form
         * @return {?}
         */
        value: function isErrorState(control, form) {
          return !!(control && control.invalid && (control.dirty || form && form.submitted));
        }
      }]);

      return ShowOnDirtyErrorStateMatcher;
    }();

    ShowOnDirtyErrorStateMatcher.ɵfac = function ShowOnDirtyErrorStateMatcher_Factory(t) {
      return new (t || ShowOnDirtyErrorStateMatcher)();
    };

    ShowOnDirtyErrorStateMatcher.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({
      token: ShowOnDirtyErrorStateMatcher,
      factory: ShowOnDirtyErrorStateMatcher.ɵfac
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](ShowOnDirtyErrorStateMatcher, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"]
      }], null, null);
    })();
    /**
     * Provider that defines how form controls behave with regards to displaying error messages.
     */


    var ErrorStateMatcher = /*#__PURE__*/function () {
      function ErrorStateMatcher() {
        _classCallCheck(this, ErrorStateMatcher);
      }

      _createClass2(ErrorStateMatcher, [{
        key: "isErrorState",

        /**
         * @param {?} control
         * @param {?} form
         * @return {?}
         */
        value: function isErrorState(control, form) {
          return !!(control && control.invalid && (control.touched || form && form.submitted));
        }
      }]);

      return ErrorStateMatcher;
    }();

    ErrorStateMatcher.ɵfac = function ErrorStateMatcher_Factory(t) {
      return new (t || ErrorStateMatcher)();
    };
    /** @nocollapse */


    ErrorStateMatcher.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"])({
      factory: function ErrorStateMatcher_Factory() {
        return new ErrorStateMatcher();
      },
      token: ErrorStateMatcher,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](ErrorStateMatcher, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"],
        args: [{
          providedIn: 'root'
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/gestures/gesture-annotations.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Stripped-down HammerJS annotations to be used within Material, which are necessary,
     * because HammerJS is an optional dependency. For the full annotations see:
     * https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/types/hammerjs/index.d.ts
     */

    /**
     * @deprecated No longer being used. To be removed.
     * \@breaking-change 10.0.0
     * \@docs-private
     * @record
     */


    function HammerInput() {}

    if (false) {}
    /**
     * @deprecated No longer being used. To be removed.
     * \@breaking-change 10.0.0
     * \@docs-private
     * @record
     */


    function HammerStatic() {}

    if (false) {}
    /**
     * @deprecated No longer being used. To be removed.
     * \@breaking-change 10.0.0
     * \@docs-private
     * @record
     */


    function Recognizer() {}

    if (false) {}
    /**
     * @deprecated No longer being used. To be removed.
     * \@breaking-change 10.0.0
     * \@docs-private
     * @record
     */


    function RecognizerStatic() {}
    /**
     * @deprecated No longer being used. To be removed.
     * \@breaking-change 10.0.0
     * \@docs-private
     * @record
     */


    function HammerInstance() {}

    if (false) {}
    /**
     * @deprecated No longer being used. To be removed.
     * \@breaking-change 10.0.0
     * \@docs-private
     * @record
     */


    function HammerManager() {}

    if (false) {}
    /**
     * @deprecated No longer being used. To be removed.
     * \@breaking-change 10.0.0
     * \@docs-private
     * @record
     */


    function HammerOptions() {}

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/gestures/gesture-config.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Injection token that can be used to provide options to the Hammerjs instance.
     * More info at http://hammerjs.github.io/api/.
     * @deprecated No longer being used. To be removed.
     * \@breaking-change 10.0.0
     * @type {?}
     */


    var MAT_HAMMER_OPTIONS = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('MAT_HAMMER_OPTIONS');
    /** @type {?} */

    var ANGULAR_MATERIAL_SUPPORTED_HAMMER_GESTURES = ['longpress', 'slide', 'slidestart', 'slideend', 'slideright', 'slideleft'];

    var ɵ0$2 =
    /**
    * @return {?}
    */
    function ɵ0$2() {},
        ɵ1 =
    /**
    * @return {?}
    */
    function ɵ1() {};
    /**
     * Fake HammerInstance that is used when a Hammer instance is requested when HammerJS has not
     * been loaded on the page.
     * @type {?}
     */


    var noopHammerInstance = {
      on: ɵ0$2,
      off: ɵ1
    };
    /**
     * Adjusts configuration of our gesture library, Hammer.
     * @deprecated No longer being used. To be removed.
     * \@breaking-change 10.0.0
     */

    var GestureConfig = /*#__PURE__*/function (_angular_platform_bro) {
      _inherits(GestureConfig, _angular_platform_bro);

      var _super77 = _createSuper(GestureConfig);

      /**
       * @param {?=} _hammerOptions
       * @param {?=} _commonModule
       */
      function GestureConfig(_hammerOptions, _commonModule) {
        var _this236;

        _classCallCheck(this, GestureConfig);

        _this236 = _super77.call(this);
        _this236._hammerOptions = _hammerOptions;
        /**
         * List of new event names to add to the gesture support list
         */

        _this236.events = ANGULAR_MATERIAL_SUPPORTED_HAMMER_GESTURES;
        return _this236;
      }
      /**
       * Builds Hammer instance manually to add custom recognizers that match the Material Design spec.
       *
       * Our gesture names come from the Material Design gestures spec:
       * https://material.io/design/#gestures-touch-mechanics
       *
       * More information on default recognizers can be found in Hammer docs:
       * http://hammerjs.github.io/recognizer-pan/
       * http://hammerjs.github.io/recognizer-press/
       *
       * @param {?} element Element to which to assign the new HammerJS gestures.
       * @return {?} Newly-created HammerJS instance.
       */


      _createClass2(GestureConfig, [{
        key: "buildHammer",
        value: function buildHammer(element) {
          /** @type {?} */
          var hammer = typeof window !== 'undefined' ?
          /** @type {?} */
          window.Hammer : null;

          if (!hammer) {
            // If HammerJS is not loaded here, return the noop HammerInstance. This is necessary to
            // ensure that omitting HammerJS completely will not cause any errors while *also* supporting
            // the lazy-loading of HammerJS via the HAMMER_LOADER token introduced in Angular 6.1.
            // Because we can't depend on HAMMER_LOADER's existance until 7.0, we have to always set
            // `this.events` to the set we support, instead of conditionally setting it to `[]` if
            // `HAMMER_LOADER` is present (and then throwing an Error here if `window.Hammer` is
            // undefined).
            // @breaking-change 8.0.0
            return noopHammerInstance;
          }
          /** @type {?} */


          var mc = new hammer(element, this._hammerOptions || undefined); // Default Hammer Recognizers.

          /** @type {?} */

          var pan = new hammer.Pan();
          /** @type {?} */

          var swipe = new hammer.Swipe();
          /** @type {?} */

          var press = new hammer.Press(); // Notice that a HammerJS recognizer can only depend on one other recognizer once.
          // Otherwise the previous `recognizeWith` will be dropped.
          // TODO: Confirm threshold numbers with Material Design UX Team

          /** @type {?} */

          var slide = this._createRecognizer(pan, {
            event: 'slide',
            threshold: 0
          }, swipe);
          /** @type {?} */


          var longpress = this._createRecognizer(press, {
            event: 'longpress',
            time: 500
          }); // Overwrite the default `pan` event to use the swipe event.


          pan.recognizeWith(swipe); // Since the slide event threshold is set to zero, the slide recognizer can fire and
          // accidentally reset the longpress recognizer. In order to make sure that the two
          // recognizers can run simultaneously but don't affect each other, we allow the slide
          // recognizer to recognize while a longpress is being processed.
          // See: https://github.com/hammerjs/hammer.js/blob/master/src/manager.js#L123-L124

          longpress.recognizeWith(slide); // Add customized gestures to Hammer manager

          mc.add([swipe, press, pan, slide, longpress]);
          return (
            /** @type {?} */
            mc
          );
        }
        /**
         * Creates a new recognizer, without affecting the default recognizers of HammerJS
         * @private
         * @param {?} base
         * @param {?} options
         * @param {...?} inheritances
         * @return {?}
         */

      }, {
        key: "_createRecognizer",
        value: function _createRecognizer(base, options) {
          /** @type {?} */
          var recognizer = new
          /** @type {?} */
          base.constructor(options);

          for (var _len26 = arguments.length, inheritances = new Array(_len26 > 2 ? _len26 - 2 : 0), _key27 = 2; _key27 < _len26; _key27++) {
            inheritances[_key27 - 2] = arguments[_key27];
          }

          inheritances.push(base);
          inheritances.forEach(
          /**
          * @param {?} item
          * @return {?}
          */
          function (item) {
            return recognizer.recognizeWith(item);
          });
          return recognizer;
        }
      }]);

      return GestureConfig;
    }(_angular_platform_browser__WEBPACK_IMPORTED_MODULE_8__["HammerGestureConfig"]);

    GestureConfig.ɵfac = function GestureConfig_Factory(t) {
      return new (t || GestureConfig)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](MAT_HAMMER_OPTIONS, 8), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](MatCommonModule, 8));
    };

    GestureConfig.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({
      token: GestureConfig,
      factory: GestureConfig.ɵfac
    });
    /** @nocollapse */

    GestureConfig.ctorParameters = function () {
      return [{
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [MAT_HAMMER_OPTIONS]
        }]
      }, {
        type: MatCommonModule,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](GestureConfig, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"]
      }], function () {
        return [{
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [MAT_HAMMER_OPTIONS]
          }]
        }, {
          type: MatCommonModule,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/line/line.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Shared directive to count lines inside a text area, such as a list item.
     * Line elements can be extracted with a \@ContentChildren(MatLine) query, then
     * counted by checking the query list's length.
     */


    var MatLine = function MatLine() {
      _classCallCheck(this, MatLine);
    };

    MatLine.ɵfac = function MatLine_Factory(t) {
      return new (t || MatLine)();
    };

    MatLine.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: MatLine,
      selectors: [["", "mat-line", ""], ["", "matLine", ""]],
      hostAttrs: [1, "mat-line"]
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatLine, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[mat-line], [matLine]',
          host: {
            'class': 'mat-line'
          }
        }]
      }], null, null);
    })();
    /**
     * Helper that takes a query list of lines and sets the correct class on the host.
     * \@docs-private
     * @param {?} lines
     * @param {?} element
     * @param {?=} prefix
     * @return {?}
     */


    function setLines(lines, element) {
      var prefix = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 'mat';
      // Note: doesn't need to unsubscribe, because `changes`
      // gets completed by Angular when the view is destroyed.
      lines.changes.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_9__["startWith"])(lines)).subscribe(
      /**
      * @param {?} __0
      * @return {?}
      */
      function (_ref13) {
        var length = _ref13.length;
        setClass(element, "".concat(prefix, "-2-line"), false);
        setClass(element, "".concat(prefix, "-3-line"), false);
        setClass(element, "".concat(prefix, "-multi-line"), false);

        if (length === 2 || length === 3) {
          setClass(element, "".concat(prefix, "-").concat(length, "-line"), true);
        } else if (length > 3) {
          setClass(element, "".concat(prefix, "-multi-line"), true);
        }
      });
    }
    /**
     * Adds or removes a class from an element.
     * @param {?} element
     * @param {?} className
     * @param {?} isAdd
     * @return {?}
     */


    function setClass(element, className, isAdd) {
      /** @type {?} */
      var classList = element.nativeElement.classList;
      isAdd ? classList.add(className) : classList.remove(className);
    }
    /**
     * Helper that takes a query list of lines and sets the correct class on the host.
     * \@docs-private
     * @deprecated Use `setLines` instead.
     * \@breaking-change 8.0.0
     */


    var MatLineSetter =
    /**
     * @param {?} lines
     * @param {?} element
     */
    function MatLineSetter(lines, element) {
      _classCallCheck(this, MatLineSetter);

      setLines(lines, element);
    };

    var MatLineModule = function MatLineModule() {
      _classCallCheck(this, MatLineModule);
    };

    MatLineModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: MatLineModule
    });
    MatLineModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function MatLineModule_Factory(t) {
        return new (t || MatLineModule)();
      },
      imports: [[MatCommonModule], MatCommonModule]
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](MatLineModule, {
        declarations: [MatLine],
        imports: [MatCommonModule],
        exports: [MatLine, MatCommonModule]
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatLineModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{
          imports: [MatCommonModule],
          exports: [MatLine, MatCommonModule],
          declarations: [MatLine]
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/ripple/ripple-ref.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** @enum {number} */


    var RippleState = {
      FADING_IN: 0,
      VISIBLE: 1,
      FADING_OUT: 2,
      HIDDEN: 3
    };
    /**
     * Reference to a previously launched ripple element.
     */

    var RippleRef = /*#__PURE__*/function () {
      /**
       * @param {?} _renderer
       * @param {?} element
       * @param {?} config
       */
      function RippleRef(_renderer, element, config) {
        _classCallCheck(this, RippleRef);

        this._renderer = _renderer;
        this.element = element;
        this.config = config;
        /**
         * Current state of the ripple.
         */

        this.state = 3
        /* HIDDEN */
        ;
      }
      /**
       * Fades out the ripple element.
       * @return {?}
       */


      _createClass2(RippleRef, [{
        key: "fadeOut",
        value: function fadeOut() {
          this._renderer.fadeOutRipple(this);
        }
      }]);

      return RippleRef;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/ripple/ripple-renderer.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Interface that describes the configuration for the animation of a ripple.
     * There are two animation phases with different durations for the ripples.
     * @record
     */


    function RippleAnimationConfig() {}

    if (false) {}
    /**
     * Interface that describes the target for launching ripples.
     * It defines the ripple configuration and disabled state for interaction ripples.
     * \@docs-private
     * @record
     */


    function RippleTarget() {}

    if (false) {}
    /**
     * Default ripple animation configuration for ripples without an explicit
     * animation config specified.
     * @type {?}
     */


    var defaultRippleAnimationConfig = {
      enterDuration: 450,
      exitDuration: 400
    };
    /**
     * Timeout for ignoring mouse events. Mouse events will be temporary ignored after touch
     * events to avoid synthetic mouse events.
     * @type {?}
     */

    var ignoreMouseEventsTimeout = 800;
    /**
     * Options that apply to all the event listeners that are bound by the ripple renderer.
     * @type {?}
     */

    var passiveEventOptions = Object(_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_7__["normalizePassiveListenerOptions"])({
      passive: true
    });
    /**
     * Events that signal that the pointer is down.
     * @type {?}
     */

    var pointerDownEvents = ['mousedown', 'touchstart'];
    /**
     * Events that signal that the pointer is up.
     * @type {?}
     */

    var pointerUpEvents = ['mouseup', 'mouseleave', 'touchend', 'touchcancel'];
    /**
     * Helper service that performs DOM manipulations. Not intended to be used outside this module.
     * The constructor takes a reference to the ripple directive's host element and a map of DOM
     * event handlers to be installed on the element that triggers ripple animations.
     * This will eventually become a custom renderer once Angular support exists.
     * \@docs-private
     */

    var RippleRenderer = /*#__PURE__*/function () {
      /**
       * @param {?} _target
       * @param {?} _ngZone
       * @param {?} elementOrElementRef
       * @param {?} platform
       */
      function RippleRenderer(_target, _ngZone, elementOrElementRef, platform) {
        _classCallCheck(this, RippleRenderer);

        this._target = _target;
        this._ngZone = _ngZone;
        /**
         * Whether the pointer is currently down or not.
         */

        this._isPointerDown = false;
        /**
         * Set of currently active ripple references.
         */

        this._activeRipples = new Set();
        /**
         * Whether pointer-up event listeners have been registered.
         */

        this._pointerUpEventsRegistered = false; // Only do anything if we're on the browser.

        if (platform.isBrowser) {
          this._containerElement = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceElement"])(elementOrElementRef);
        }
      }
      /**
       * Fades in a ripple at the given coordinates.
       * @param {?} x Coordinate within the element, along the X axis at which to start the ripple.
       * @param {?} y Coordinate within the element, along the Y axis at which to start the ripple.
       * @param {?=} config Extra ripple options.
       * @return {?}
       */


      _createClass2(RippleRenderer, [{
        key: "fadeInRipple",
        value: function fadeInRipple(x, y) {
          var _this237 = this;

          var config = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};

          /** @type {?} */
          var containerRect = this._containerRect = this._containerRect || this._containerElement.getBoundingClientRect();
          /** @type {?} */


          var animationConfig = Object.assign(Object.assign({}, defaultRippleAnimationConfig), config.animation);

          if (config.centered) {
            x = containerRect.left + containerRect.width / 2;
            y = containerRect.top + containerRect.height / 2;
          }
          /** @type {?} */


          var radius = config.radius || distanceToFurthestCorner(x, y, containerRect);
          /** @type {?} */

          var offsetX = x - containerRect.left;
          /** @type {?} */

          var offsetY = y - containerRect.top;
          /** @type {?} */

          var duration = animationConfig.enterDuration;
          /** @type {?} */

          var ripple = document.createElement('div');
          ripple.classList.add('mat-ripple-element');
          ripple.style.left = "".concat(offsetX - radius, "px");
          ripple.style.top = "".concat(offsetY - radius, "px");
          ripple.style.height = "".concat(radius * 2, "px");
          ripple.style.width = "".concat(radius * 2, "px"); // If a custom color has been specified, set it as inline style. If no color is
          // set, the default color will be applied through the ripple theme styles.

          if (config.color != null) {
            ripple.style.backgroundColor = config.color;
          }

          ripple.style.transitionDuration = "".concat(duration, "ms");

          this._containerElement.appendChild(ripple); // By default the browser does not recalculate the styles of dynamically created
          // ripple elements. This is critical because then the `scale` would not animate properly.


          enforceStyleRecalculation(ripple);
          ripple.style.transform = 'scale(1)'; // Exposed reference to the ripple that will be returned.

          /** @type {?} */

          var rippleRef = new RippleRef(this, ripple, config);
          rippleRef.state = 0
          /* FADING_IN */
          ; // Add the ripple reference to the list of all active ripples.

          this._activeRipples.add(rippleRef);

          if (!config.persistent) {
            this._mostRecentTransientRipple = rippleRef;
          } // Wait for the ripple element to be completely faded in.
          // Once it's faded in, the ripple can be hidden immediately if the mouse is released.


          this._runTimeoutOutsideZone(
          /**
          * @return {?}
          */
          function () {
            /** @type {?} */
            var isMostRecentTransientRipple = rippleRef === _this237._mostRecentTransientRipple;
            rippleRef.state = 1
            /* VISIBLE */
            ; // When the timer runs out while the user has kept their pointer down, we want to
            // keep only the persistent ripples and the latest transient ripple. We do this,
            // because we don't want stacked transient ripples to appear after their enter
            // animation has finished.

            if (!config.persistent && (!isMostRecentTransientRipple || !_this237._isPointerDown)) {
              rippleRef.fadeOut();
            }
          }, duration);

          return rippleRef;
        }
        /**
         * Fades out a ripple reference.
         * @param {?} rippleRef
         * @return {?}
         */

      }, {
        key: "fadeOutRipple",
        value: function fadeOutRipple(rippleRef) {
          /** @type {?} */
          var wasActive = this._activeRipples["delete"](rippleRef);

          if (rippleRef === this._mostRecentTransientRipple) {
            this._mostRecentTransientRipple = null;
          } // Clear out the cached bounding rect if we have no more ripples.


          if (!this._activeRipples.size) {
            this._containerRect = null;
          } // For ripples that are not active anymore, don't re-run the fade-out animation.


          if (!wasActive) {
            return;
          }
          /** @type {?} */


          var rippleEl = rippleRef.element;
          /** @type {?} */

          var animationConfig = Object.assign(Object.assign({}, defaultRippleAnimationConfig), rippleRef.config.animation);
          rippleEl.style.transitionDuration = "".concat(animationConfig.exitDuration, "ms");
          rippleEl.style.opacity = '0';
          rippleRef.state = 2
          /* FADING_OUT */
          ; // Once the ripple faded out, the ripple can be safely removed from the DOM.

          this._runTimeoutOutsideZone(
          /**
          * @return {?}
          */
          function () {
            rippleRef.state = 3
            /* HIDDEN */
            ;

            /** @type {?} */
            rippleEl.parentNode.removeChild(rippleEl);
          }, animationConfig.exitDuration);
        }
        /**
         * Fades out all currently active ripples.
         * @return {?}
         */

      }, {
        key: "fadeOutAll",
        value: function fadeOutAll() {
          this._activeRipples.forEach(
          /**
          * @param {?} ripple
          * @return {?}
          */
          function (ripple) {
            return ripple.fadeOut();
          });
        }
        /**
         * Sets up the trigger event listeners
         * @param {?} elementOrElementRef
         * @return {?}
         */

      }, {
        key: "setupTriggerEvents",
        value: function setupTriggerEvents(elementOrElementRef) {
          /** @type {?} */
          var element = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceElement"])(elementOrElementRef);

          if (!element || element === this._triggerElement) {
            return;
          } // Remove all previously registered event listeners from the trigger element.


          this._removeTriggerEvents();

          this._triggerElement = element;

          this._registerEvents(pointerDownEvents);
        }
        /**
         * Handles all registered events.
         * \@docs-private
         * @param {?} event
         * @return {?}
         */

      }, {
        key: "handleEvent",
        value: function handleEvent(event) {
          if (event.type === 'mousedown') {
            this._onMousedown(
            /** @type {?} */
            event);
          } else if (event.type === 'touchstart') {
            this._onTouchStart(
            /** @type {?} */
            event);
          } else {
            this._onPointerUp();
          } // If pointer-up events haven't been registered yet, do so now.
          // We do this on-demand in order to reduce the total number of event listeners
          // registered by the ripples, which speeds up the rendering time for large UIs.


          if (!this._pointerUpEventsRegistered) {
            this._registerEvents(pointerUpEvents);

            this._pointerUpEventsRegistered = true;
          }
        }
        /**
         * Function being called whenever the trigger is being pressed using mouse.
         * @private
         * @param {?} event
         * @return {?}
         */

      }, {
        key: "_onMousedown",
        value: function _onMousedown(event) {
          // Screen readers will fire fake mouse events for space/enter. Skip launching a
          // ripple in this case for consistency with the non-screen-reader experience.

          /** @type {?} */
          var isFakeMousedown = Object(_angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_1__["isFakeMousedownFromScreenReader"])(event);
          /** @type {?} */

          var isSyntheticEvent = this._lastTouchStartEvent && Date.now() < this._lastTouchStartEvent + ignoreMouseEventsTimeout;

          if (!this._target.rippleDisabled && !isFakeMousedown && !isSyntheticEvent) {
            this._isPointerDown = true;
            this.fadeInRipple(event.clientX, event.clientY, this._target.rippleConfig);
          }
        }
        /**
         * Function being called whenever the trigger is being pressed using touch.
         * @private
         * @param {?} event
         * @return {?}
         */

      }, {
        key: "_onTouchStart",
        value: function _onTouchStart(event) {
          if (!this._target.rippleDisabled) {
            // Some browsers fire mouse events after a `touchstart` event. Those synthetic mouse
            // events will launch a second ripple if we don't ignore mouse events for a specific
            // time after a touchstart event.
            this._lastTouchStartEvent = Date.now();
            this._isPointerDown = true; // Use `changedTouches` so we skip any touches where the user put
            // their finger down, but used another finger to tap the element again.

            /** @type {?} */

            var touches = event.changedTouches;

            for (var i = 0; i < touches.length; i++) {
              this.fadeInRipple(touches[i].clientX, touches[i].clientY, this._target.rippleConfig);
            }
          }
        }
        /**
         * Function being called whenever the trigger is being released.
         * @private
         * @return {?}
         */

      }, {
        key: "_onPointerUp",
        value: function _onPointerUp() {
          if (!this._isPointerDown) {
            return;
          }

          this._isPointerDown = false; // Fade-out all ripples that are visible and not persistent.

          this._activeRipples.forEach(
          /**
          * @param {?} ripple
          * @return {?}
          */
          function (ripple) {
            // By default, only ripples that are completely visible will fade out on pointer release.
            // If the `terminateOnPointerUp` option is set, ripples that still fade in will also fade out.

            /** @type {?} */
            var isVisible = ripple.state === 1
            /* VISIBLE */
            || ripple.config.terminateOnPointerUp && ripple.state === 0
            /* FADING_IN */
            ;

            if (!ripple.config.persistent && isVisible) {
              ripple.fadeOut();
            }
          });
        }
        /**
         * Runs a timeout outside of the Angular zone to avoid triggering the change detection.
         * @private
         * @param {?} fn
         * @param {?=} delay
         * @return {?}
         */

      }, {
        key: "_runTimeoutOutsideZone",
        value: function _runTimeoutOutsideZone(fn) {
          var delay = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;

          this._ngZone.runOutsideAngular(
          /**
          * @return {?}
          */
          function () {
            return setTimeout(fn, delay);
          });
        }
        /**
         * Registers event listeners for a given list of events.
         * @private
         * @param {?} eventTypes
         * @return {?}
         */

      }, {
        key: "_registerEvents",
        value: function _registerEvents(eventTypes) {
          var _this238 = this;

          this._ngZone.runOutsideAngular(
          /**
          * @return {?}
          */
          function () {
            eventTypes.forEach(
            /**
            * @param {?} type
            * @return {?}
            */
            function (type) {
              /** @type {?} */
              _this238._triggerElement.addEventListener(type, _this238, passiveEventOptions);
            });
          });
        }
        /**
         * Removes previously registered event listeners from the trigger element.
         * @return {?}
         */

      }, {
        key: "_removeTriggerEvents",
        value: function _removeTriggerEvents() {
          var _this239 = this;

          if (this._triggerElement) {
            pointerDownEvents.forEach(
            /**
            * @param {?} type
            * @return {?}
            */
            function (type) {
              /** @type {?} */
              _this239._triggerElement.removeEventListener(type, _this239, passiveEventOptions);
            });

            if (this._pointerUpEventsRegistered) {
              pointerUpEvents.forEach(
              /**
              * @param {?} type
              * @return {?}
              */
              function (type) {
                /** @type {?} */
                _this239._triggerElement.removeEventListener(type, _this239, passiveEventOptions);
              });
            }
          }
        }
      }]);

      return RippleRenderer;
    }();

    if (false) {}
    /**
     * Enforces a style recalculation of a DOM element by computing its styles.
     * @param {?} element
     * @return {?}
     */


    function enforceStyleRecalculation(element) {
      // Enforce a style recalculation by calling `getComputedStyle` and accessing any property.
      // Calling `getPropertyValue` is important to let optimizers know that this is not a noop.
      // See: https://gist.github.com/paulirish/5d52fb081b3570c81e3a
      window.getComputedStyle(element).getPropertyValue('opacity');
    }
    /**
     * Returns the distance from the point (x, y) to the furthest corner of a rectangle.
     * @param {?} x
     * @param {?} y
     * @param {?} rect
     * @return {?}
     */


    function distanceToFurthestCorner(x, y, rect) {
      /** @type {?} */
      var distX = Math.max(Math.abs(x - rect.left), Math.abs(x - rect.right));
      /** @type {?} */

      var distY = Math.max(Math.abs(y - rect.top), Math.abs(y - rect.bottom));
      return Math.sqrt(distX * distX + distY * distY);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/ripple/ripple.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Configurable options for `matRipple`.
     * @record
     */


    function RippleGlobalOptions() {}

    if (false) {}
    /**
     * Injection token that can be used to specify the global ripple options.
     * @type {?}
     */


    var MAT_RIPPLE_GLOBAL_OPTIONS = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('mat-ripple-global-options');

    var MatRipple = /*#__PURE__*/function () {
      /**
       * @param {?} _elementRef
       * @param {?} ngZone
       * @param {?} platform
       * @param {?=} globalOptions
       * @param {?=} _animationMode
       */
      function MatRipple(_elementRef, ngZone, platform, globalOptions, _animationMode) {
        _classCallCheck(this, MatRipple);

        this._elementRef = _elementRef;
        this._animationMode = _animationMode;
        /**
         * If set, the radius in pixels of foreground ripples when fully expanded. If unset, the radius
         * will be the distance from the center of the ripple to the furthest corner of the host element's
         * bounding rectangle.
         */

        this.radius = 0;
        this._disabled = false;
        /**
         * Whether ripple directive is initialized and the input bindings are set.
         */

        this._isInitialized = false;
        this._globalOptions = globalOptions || {};
        this._rippleRenderer = new RippleRenderer(this, ngZone, _elementRef, platform);
      }
      /**
       * Whether click events will not trigger the ripple. Ripples can be still launched manually
       * by using the `launch()` method.
       * @return {?}
       */


      _createClass2(MatRipple, [{
        key: "ngOnInit",

        /**
         * @return {?}
         */
        value: function ngOnInit() {
          this._isInitialized = true;

          this._setupTriggerEventsIfEnabled();
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this._rippleRenderer._removeTriggerEvents();
        }
        /**
         * Fades out all currently showing ripple elements.
         * @return {?}
         */

      }, {
        key: "fadeOutAll",
        value: function fadeOutAll() {
          this._rippleRenderer.fadeOutAll();
        }
        /**
         * Ripple configuration from the directive's input values.
         * \@docs-private Implemented as part of RippleTarget
         * @return {?}
         */

      }, {
        key: "_setupTriggerEventsIfEnabled",

        /**
         * Sets up the trigger event listeners if ripples are enabled.
         * @private
         * @return {?}
         */
        value: function _setupTriggerEventsIfEnabled() {
          if (!this.disabled && this._isInitialized) {
            this._rippleRenderer.setupTriggerEvents(this.trigger);
          }
        }
        /**
         * Launches a manual ripple at the specified coordinated or just by the ripple config.
         * @param {?} configOrX
         * @param {?=} y
         * @param {?=} config
         * @return {?}
         */

      }, {
        key: "launch",
        value: function launch(configOrX) {
          var y = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
          var config = arguments.length > 2 ? arguments[2] : undefined;

          if (typeof configOrX === 'number') {
            return this._rippleRenderer.fadeInRipple(configOrX, y, Object.assign(Object.assign({}, this.rippleConfig), config));
          } else {
            return this._rippleRenderer.fadeInRipple(0, 0, Object.assign(Object.assign({}, this.rippleConfig), configOrX));
          }
        }
      }, {
        key: "disabled",
        get: function get() {
          return this._disabled;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._disabled = value;

          this._setupTriggerEventsIfEnabled();
        }
        /**
         * The element that triggers the ripple when click events are received.
         * Defaults to the directive's host element.
         * @return {?}
         */

      }, {
        key: "trigger",
        get: function get() {
          return this._trigger || this._elementRef.nativeElement;
        }
        /**
         * @param {?} trigger
         * @return {?}
         */
        ,
        set: function set(trigger) {
          this._trigger = trigger;

          this._setupTriggerEventsIfEnabled();
        }
      }, {
        key: "rippleConfig",
        get: function get() {
          return {
            centered: this.centered,
            radius: this.radius,
            color: this.color,
            animation: Object.assign(Object.assign(Object.assign({}, this._globalOptions.animation), this._animationMode === 'NoopAnimations' ? {
              enterDuration: 0,
              exitDuration: 0
            } : {}), this.animation),
            terminateOnPointerUp: this._globalOptions.terminateOnPointerUp
          };
        }
        /**
         * Whether ripples on pointer-down are disabled or not.
         * \@docs-private Implemented as part of RippleTarget
         * @return {?}
         */

      }, {
        key: "rippleDisabled",
        get: function get() {
          return this.disabled || !!this._globalOptions.disabled;
        }
      }]);

      return MatRipple;
    }();

    MatRipple.ɵfac = function MatRipple_Factory(t) {
      return new (t || MatRipple)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["NgZone"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_7__["Platform"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](MAT_RIPPLE_GLOBAL_OPTIONS, 8), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_10__["ANIMATION_MODULE_TYPE"], 8));
    };

    MatRipple.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: MatRipple,
      selectors: [["", "mat-ripple", ""], ["", "matRipple", ""]],
      hostAttrs: [1, "mat-ripple"],
      hostVars: 2,
      hostBindings: function MatRipple_HostBindings(rf, ctx) {
        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵclassProp"]("mat-ripple-unbounded", ctx.unbounded);
        }
      },
      inputs: {
        radius: ["matRippleRadius", "radius"],
        disabled: ["matRippleDisabled", "disabled"],
        trigger: ["matRippleTrigger", "trigger"],
        color: ["matRippleColor", "color"],
        unbounded: ["matRippleUnbounded", "unbounded"],
        centered: ["matRippleCentered", "centered"],
        animation: ["matRippleAnimation", "animation"]
      },
      exportAs: ["matRipple"]
    });
    /** @nocollapse */

    MatRipple.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgZone"]
      }, {
        type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_7__["Platform"]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [MAT_RIPPLE_GLOBAL_OPTIONS]
        }]
      }, {
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [_angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_10__["ANIMATION_MODULE_TYPE"]]
        }]
      }];
    };

    MatRipple.propDecorators = {
      color: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['matRippleColor']
      }],
      unbounded: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['matRippleUnbounded']
      }],
      centered: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['matRippleCentered']
      }],
      radius: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['matRippleRadius']
      }],
      animation: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['matRippleAnimation']
      }],
      disabled: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['matRippleDisabled']
      }],
      trigger: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
        args: ['matRippleTrigger']
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatRipple, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[mat-ripple], [matRipple]',
          exportAs: 'matRipple',
          host: {
            'class': 'mat-ripple',
            '[class.mat-ripple-unbounded]': 'unbounded'
          }
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgZone"]
        }, {
          type: _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_7__["Platform"]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [MAT_RIPPLE_GLOBAL_OPTIONS]
          }]
        }, {
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [_angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_10__["ANIMATION_MODULE_TYPE"]]
          }]
        }];
      }, {
        radius: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['matRippleRadius']
        }],
        disabled: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['matRippleDisabled']
        }],
        trigger: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['matRippleTrigger']
        }],
        color: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['matRippleColor']
        }],
        unbounded: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['matRippleUnbounded']
        }],
        centered: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['matRippleCentered']
        }],
        animation: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"],
          args: ['matRippleAnimation']
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/ripple/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var MatRippleModule = function MatRippleModule() {
      _classCallCheck(this, MatRippleModule);
    };

    MatRippleModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: MatRippleModule
    });
    MatRippleModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function MatRippleModule_Factory(t) {
        return new (t || MatRippleModule)();
      },
      imports: [[MatCommonModule, _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_7__["PlatformModule"]], MatCommonModule]
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](MatRippleModule, {
        declarations: function declarations() {
          return [MatRipple];
        },
        imports: function imports() {
          return [MatCommonModule, _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_7__["PlatformModule"]];
        },
        exports: function exports() {
          return [MatRipple, MatCommonModule];
        }
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatRippleModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{
          imports: [MatCommonModule, _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_7__["PlatformModule"]],
          exports: [MatRipple, MatCommonModule],
          declarations: [MatRipple]
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/selection/pseudo-checkbox/pseudo-checkbox.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Component that shows a simplified checkbox without including any kind of "real" checkbox.
     * Meant to be used when the checkbox is purely decorative and a large number of them will be
     * included, such as for the options in a multi-select. Uses no SVGs or complex animations.
     * Note that theming is meant to be handled by the parent element, e.g.
     * `mat-primary .mat-pseudo-checkbox`.
     *
     * Note that this component will be completely invisible to screen-reader users. This is *not*
     * interchangeable with `<mat-checkbox>` and should *not* be used if the user would directly
     * interact with the checkbox. The pseudo-checkbox should only be used as an implementation detail
     * of more complex components that appropriately handle selected / checked state.
     * \@docs-private
     */


    var MatPseudoCheckbox =
    /**
     * @param {?=} _animationMode
     */
    function MatPseudoCheckbox(_animationMode) {
      _classCallCheck(this, MatPseudoCheckbox);

      this._animationMode = _animationMode;
      /**
       * Display state of the checkbox.
       */

      this.state = 'unchecked';
      /**
       * Whether the checkbox is disabled.
       */

      this.disabled = false;
    };

    MatPseudoCheckbox.ɵfac = function MatPseudoCheckbox_Factory(t) {
      return new (t || MatPseudoCheckbox)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_10__["ANIMATION_MODULE_TYPE"], 8));
    };

    MatPseudoCheckbox.ɵcmp = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineComponent"]({
      type: MatPseudoCheckbox,
      selectors: [["mat-pseudo-checkbox"]],
      hostAttrs: [1, "mat-pseudo-checkbox"],
      hostVars: 8,
      hostBindings: function MatPseudoCheckbox_HostBindings(rf, ctx) {
        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵclassProp"]("mat-pseudo-checkbox-indeterminate", ctx.state === "indeterminate")("mat-pseudo-checkbox-checked", ctx.state === "checked")("mat-pseudo-checkbox-disabled", ctx.disabled)("_mat-animation-noopable", ctx._animationMode === "NoopAnimations");
        }
      },
      inputs: {
        state: "state",
        disabled: "disabled"
      },
      decls: 0,
      vars: 0,
      template: function MatPseudoCheckbox_Template(rf, ctx) {},
      styles: [".mat-pseudo-checkbox{width:16px;height:16px;border:2px solid;border-radius:2px;cursor:pointer;display:inline-block;vertical-align:middle;box-sizing:border-box;position:relative;flex-shrink:0;transition:border-color 90ms cubic-bezier(0, 0, 0.2, 0.1),background-color 90ms cubic-bezier(0, 0, 0.2, 0.1)}.mat-pseudo-checkbox::after{position:absolute;opacity:0;content:\"\";border-bottom:2px solid currentColor;transition:opacity 90ms cubic-bezier(0, 0, 0.2, 0.1)}.mat-pseudo-checkbox.mat-pseudo-checkbox-checked,.mat-pseudo-checkbox.mat-pseudo-checkbox-indeterminate{border-color:transparent}._mat-animation-noopable.mat-pseudo-checkbox{transition:none;animation:none}._mat-animation-noopable.mat-pseudo-checkbox::after{transition:none}.mat-pseudo-checkbox-disabled{cursor:default}.mat-pseudo-checkbox-indeterminate::after{top:5px;left:1px;width:10px;opacity:1;border-radius:2px}.mat-pseudo-checkbox-checked::after{top:2.4px;left:1px;width:8px;height:3px;border-left:2px solid currentColor;transform:rotate(-45deg);opacity:1;box-sizing:content-box}\n"],
      encapsulation: 2,
      changeDetection: 0
    });
    /** @nocollapse */

    MatPseudoCheckbox.ctorParameters = function () {
      return [{
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [_angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_10__["ANIMATION_MODULE_TYPE"]]
        }]
      }];
    };

    MatPseudoCheckbox.propDecorators = {
      state: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }],
      disabled: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatPseudoCheckbox, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Component"],
        args: [{
          encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewEncapsulation"].None,
          changeDetection: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ChangeDetectionStrategy"].OnPush,
          selector: 'mat-pseudo-checkbox',
          template: '',
          host: {
            'class': 'mat-pseudo-checkbox',
            '[class.mat-pseudo-checkbox-indeterminate]': 'state === "indeterminate"',
            '[class.mat-pseudo-checkbox-checked]': 'state === "checked"',
            '[class.mat-pseudo-checkbox-disabled]': 'disabled',
            '[class._mat-animation-noopable]': '_animationMode === "NoopAnimations"'
          },
          styles: [".mat-pseudo-checkbox{width:16px;height:16px;border:2px solid;border-radius:2px;cursor:pointer;display:inline-block;vertical-align:middle;box-sizing:border-box;position:relative;flex-shrink:0;transition:border-color 90ms cubic-bezier(0, 0, 0.2, 0.1),background-color 90ms cubic-bezier(0, 0, 0.2, 0.1)}.mat-pseudo-checkbox::after{position:absolute;opacity:0;content:\"\";border-bottom:2px solid currentColor;transition:opacity 90ms cubic-bezier(0, 0, 0.2, 0.1)}.mat-pseudo-checkbox.mat-pseudo-checkbox-checked,.mat-pseudo-checkbox.mat-pseudo-checkbox-indeterminate{border-color:transparent}._mat-animation-noopable.mat-pseudo-checkbox{transition:none;animation:none}._mat-animation-noopable.mat-pseudo-checkbox::after{transition:none}.mat-pseudo-checkbox-disabled{cursor:default}.mat-pseudo-checkbox-indeterminate::after{top:5px;left:1px;width:10px;opacity:1;border-radius:2px}.mat-pseudo-checkbox-checked::after{top:2.4px;left:1px;width:8px;height:3px;border-left:2px solid currentColor;transform:rotate(-45deg);opacity:1;box-sizing:content-box}\n"]
        }]
      }], function () {
        return [{
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [_angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_10__["ANIMATION_MODULE_TYPE"]]
          }]
        }];
      }, {
        state: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }],
        disabled: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/selection/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var MatPseudoCheckboxModule = function MatPseudoCheckboxModule() {
      _classCallCheck(this, MatPseudoCheckboxModule);
    };

    MatPseudoCheckboxModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: MatPseudoCheckboxModule
    });
    MatPseudoCheckboxModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function MatPseudoCheckboxModule_Factory(t) {
        return new (t || MatPseudoCheckboxModule)();
      }
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](MatPseudoCheckboxModule, {
        declarations: [MatPseudoCheckbox],
        exports: [MatPseudoCheckbox]
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatPseudoCheckboxModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{
          exports: [MatPseudoCheckbox],
          declarations: [MatPseudoCheckbox]
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/option/optgroup.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */
    // Boilerplate for applying mixins to MatOptgroup.

    /**
     * \@docs-private
     */


    var MatOptgroupBase = function MatOptgroupBase() {
      _classCallCheck(this, MatOptgroupBase);
    };
    /** @type {?} */


    var _MatOptgroupMixinBase = mixinDisabled(MatOptgroupBase); // Counter for unique group ids.

    /** @type {?} */


    var _uniqueOptgroupIdCounter = 0;
    /**
     * Component that is used to group instances of `mat-option`.
     */

    var MatOptgroup = /*#__PURE__*/function (_MatOptgroupMixinBase2) {
      _inherits(MatOptgroup, _MatOptgroupMixinBase2);

      var _super78 = _createSuper(MatOptgroup);

      function MatOptgroup() {
        var _this240;

        _classCallCheck(this, MatOptgroup);

        _this240 = _super78.apply(this, arguments);
        /**
         * Unique id for the underlying label.
         */

        _this240._labelId = "mat-optgroup-label-".concat(_uniqueOptgroupIdCounter++);
        return _this240;
      }

      return MatOptgroup;
    }(_MatOptgroupMixinBase);

    MatOptgroup.ɵfac = function MatOptgroup_Factory(t) {
      return ɵMatOptgroup_BaseFactory(t || MatOptgroup);
    };

    MatOptgroup.ɵcmp = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineComponent"]({
      type: MatOptgroup,
      selectors: [["mat-optgroup"]],
      hostAttrs: ["role", "group", 1, "mat-optgroup"],
      hostVars: 4,
      hostBindings: function MatOptgroup_HostBindings(rf, ctx) {
        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵattribute"]("aria-disabled", ctx.disabled.toString())("aria-labelledby", ctx._labelId);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵclassProp"]("mat-optgroup-disabled", ctx.disabled);
        }
      },
      inputs: {
        disabled: "disabled",
        label: "label"
      },
      exportAs: ["matOptgroup"],
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]],
      ngContentSelectors: _c1,
      decls: 4,
      vars: 2,
      consts: [[1, "mat-optgroup-label", 3, "id"]],
      template: function MatOptgroup_Template(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵprojectionDef"](_c0);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](0, "label", 0);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtext"](1);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵprojection"](2);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"]();

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵprojection"](3, 1);
        }

        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("id", ctx._labelId);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](1);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtextInterpolate1"]("", ctx.label, " ");
        }
      },
      styles: [".mat-optgroup-label{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;display:block;line-height:48px;height:48px;padding:0 16px;text-align:left;text-decoration:none;max-width:100%;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:default}.mat-optgroup-label[disabled]{cursor:default}[dir=rtl] .mat-optgroup-label{text-align:right}.mat-optgroup-label .mat-icon{margin-right:16px;vertical-align:middle}.mat-optgroup-label .mat-icon svg{vertical-align:top}[dir=rtl] .mat-optgroup-label .mat-icon{margin-left:16px;margin-right:0}\n"],
      encapsulation: 2,
      changeDetection: 0
    });
    MatOptgroup.propDecorators = {
      label: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };

    var ɵMatOptgroup_BaseFactory = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵgetInheritedFactory"](MatOptgroup);
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatOptgroup, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Component"],
        args: [{
          selector: 'mat-optgroup',
          exportAs: 'matOptgroup',
          template: "<label class=\"mat-optgroup-label\" [id]=\"_labelId\">{{ label }} <ng-content></ng-content></label>\n<ng-content select=\"mat-option, ng-container\"></ng-content>\n",
          encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewEncapsulation"].None,
          changeDetection: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ChangeDetectionStrategy"].OnPush,
          inputs: ['disabled'],
          host: {
            'class': 'mat-optgroup',
            'role': 'group',
            '[class.mat-optgroup-disabled]': 'disabled',
            '[attr.aria-disabled]': 'disabled.toString()',
            '[attr.aria-labelledby]': '_labelId'
          },
          styles: [".mat-optgroup-label{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;display:block;line-height:48px;height:48px;padding:0 16px;text-align:left;text-decoration:none;max-width:100%;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:default}.mat-optgroup-label[disabled]{cursor:default}[dir=rtl] .mat-optgroup-label{text-align:right}.mat-optgroup-label .mat-icon{margin-right:16px;vertical-align:middle}.mat-optgroup-label .mat-icon svg{vertical-align:top}[dir=rtl] .mat-optgroup-label .mat-icon{margin-left:16px;margin-right:0}\n"]
        }]
      }], null, {
        label: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/option/option.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Option IDs need to be unique across components, so this counter exists outside of
     * the component definition.
     * @type {?}
     */


    var _uniqueIdCounter = 0;
    /**
     * Event object emitted by MatOption when selected or deselected.
     */

    var MatOptionSelectionChange =
    /**
     * @param {?} source
     * @param {?=} isUserInput
     */
    function MatOptionSelectionChange(source) {
      var isUserInput = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;

      _classCallCheck(this, MatOptionSelectionChange);

      this.source = source;
      this.isUserInput = isUserInput;
    };

    if (false) {}
    /**
     * Describes a parent component that manages a list of options.
     * Contains properties that the options can inherit.
     * \@docs-private
     * @record
     */


    function MatOptionParentComponent() {}

    if (false) {}
    /**
     * Injection token used to provide the parent component to options.
     * @type {?}
     */


    var MAT_OPTION_PARENT_COMPONENT = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('MAT_OPTION_PARENT_COMPONENT');
    /**
     * Single option inside of a `<mat-select>` element.
     */

    var MatOption = /*#__PURE__*/function () {
      /**
       * @param {?} _element
       * @param {?} _changeDetectorRef
       * @param {?} _parent
       * @param {?} group
       */
      function MatOption(_element, _changeDetectorRef, _parent, group) {
        _classCallCheck(this, MatOption);

        this._element = _element;
        this._changeDetectorRef = _changeDetectorRef;
        this._parent = _parent;
        this.group = group;
        this._selected = false;
        this._active = false;
        this._disabled = false;
        this._mostRecentViewValue = '';
        /**
         * The unique ID of the option.
         */

        this.id = "mat-option-".concat(_uniqueIdCounter++);
        /**
         * Event emitted when the option is selected or deselected.
         */
        // tslint:disable-next-line:no-output-on-prefix

        this.onSelectionChange = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"]();
        /**
         * Emits when the state of the option changes and any parents have to be notified.
         */

        this._stateChanges = new rxjs__WEBPACK_IMPORTED_MODULE_6__["Subject"]();
      }
      /**
       * Whether the wrapping component is in multiple selection mode.
       * @return {?}
       */


      _createClass2(MatOption, [{
        key: "select",

        /**
         * Selects the option.
         * @return {?}
         */
        value: function select() {
          if (!this._selected) {
            this._selected = true;

            this._changeDetectorRef.markForCheck();

            this._emitSelectionChangeEvent();
          }
        }
        /**
         * Deselects the option.
         * @return {?}
         */

      }, {
        key: "deselect",
        value: function deselect() {
          if (this._selected) {
            this._selected = false;

            this._changeDetectorRef.markForCheck();

            this._emitSelectionChangeEvent();
          }
        }
        /**
         * Sets focus onto this option.
         * @param {?=} _origin
         * @param {?=} options
         * @return {?}
         */

      }, {
        key: "focus",
        value: function focus(_origin, options) {
          // Note that we aren't using `_origin`, but we need to keep it because some internal consumers
          // use `MatOption` in a `FocusKeyManager` and we need it to match `FocusableOption`.

          /** @type {?} */
          var element = this._getHostElement();

          if (typeof element.focus === 'function') {
            element.focus(options);
          }
        }
        /**
         * This method sets display styles on the option to make it appear
         * active. This is used by the ActiveDescendantKeyManager so key
         * events will display the proper options as active on arrow key events.
         * @return {?}
         */

      }, {
        key: "setActiveStyles",
        value: function setActiveStyles() {
          if (!this._active) {
            this._active = true;

            this._changeDetectorRef.markForCheck();
          }
        }
        /**
         * This method removes display styles on the option that made it appear
         * active. This is used by the ActiveDescendantKeyManager so key
         * events will display the proper options as active on arrow key events.
         * @return {?}
         */

      }, {
        key: "setInactiveStyles",
        value: function setInactiveStyles() {
          if (this._active) {
            this._active = false;

            this._changeDetectorRef.markForCheck();
          }
        }
        /**
         * Gets the label to be used when determining whether the option should be focused.
         * @return {?}
         */

      }, {
        key: "getLabel",
        value: function getLabel() {
          return this.viewValue;
        }
        /**
         * Ensures the option is selected when activated from the keyboard.
         * @param {?} event
         * @return {?}
         */

      }, {
        key: "_handleKeydown",
        value: function _handleKeydown(event) {
          if ((event.keyCode === _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_11__["ENTER"] || event.keyCode === _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_11__["SPACE"]) && !Object(_angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_11__["hasModifierKey"])(event)) {
            this._selectViaInteraction(); // Prevent the page from scrolling down and form submits.


            event.preventDefault();
          }
        }
        /**
         * `Selects the option while indicating the selection came from the user. Used to
         * determine if the select's view -> model callback should be invoked.`
         * @return {?}
         */

      }, {
        key: "_selectViaInteraction",
        value: function _selectViaInteraction() {
          if (!this.disabled) {
            this._selected = this.multiple ? !this._selected : true;

            this._changeDetectorRef.markForCheck();

            this._emitSelectionChangeEvent(true);
          }
        }
        /**
         * Gets the `aria-selected` value for the option. We explicitly omit the `aria-selected`
         * attribute from single-selection, unselected options. Including the `aria-selected="false"`
         * attributes adds a significant amount of noise to screen-reader users without providing useful
         * information.
         * @return {?}
         */

      }, {
        key: "_getAriaSelected",
        value: function _getAriaSelected() {
          return this.selected || (this.multiple ? false : null);
        }
        /**
         * Returns the correct tabindex for the option depending on disabled state.
         * @return {?}
         */

      }, {
        key: "_getTabIndex",
        value: function _getTabIndex() {
          return this.disabled ? '-1' : '0';
        }
        /**
         * Gets the host DOM element.
         * @return {?}
         */

      }, {
        key: "_getHostElement",
        value: function _getHostElement() {
          return this._element.nativeElement;
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngAfterViewChecked",
        value: function ngAfterViewChecked() {
          // Since parent components could be using the option's label to display the selected values
          // (e.g. `mat-select`) and they don't have a way of knowing if the option's label has changed
          // we have to check for changes in the DOM ourselves and dispatch an event. These checks are
          // relatively cheap, however we still limit them only to selected options in order to avoid
          // hitting the DOM too often.
          if (this._selected) {
            /** @type {?} */
            var viewValue = this.viewValue;

            if (viewValue !== this._mostRecentViewValue) {
              this._mostRecentViewValue = viewValue;

              this._stateChanges.next();
            }
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this._stateChanges.complete();
        }
        /**
         * Emits the selection change event.
         * @private
         * @param {?=} isUserInput
         * @return {?}
         */

      }, {
        key: "_emitSelectionChangeEvent",
        value: function _emitSelectionChangeEvent() {
          var isUserInput = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
          this.onSelectionChange.emit(new MatOptionSelectionChange(this, isUserInput));
        }
      }, {
        key: "multiple",
        get: function get() {
          return this._parent && this._parent.multiple;
        }
        /**
         * Whether or not the option is currently selected.
         * @return {?}
         */

      }, {
        key: "selected",
        get: function get() {
          return this._selected;
        }
        /**
         * Whether the option is disabled.
         * @return {?}
         */

      }, {
        key: "disabled",
        get: function get() {
          return this.group && this.group.disabled || this._disabled;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._disabled = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceBooleanProperty"])(value);
        }
        /**
         * Whether ripples for the option are disabled.
         * @return {?}
         */

      }, {
        key: "disableRipple",
        get: function get() {
          return this._parent && this._parent.disableRipple;
        }
        /**
         * Whether or not the option is currently active and ready to be selected.
         * An active option displays styles as if it is focused, but the
         * focus is actually retained somewhere else. This comes in handy
         * for components like autocomplete where focus must remain on the input.
         * @return {?}
         */

      }, {
        key: "active",
        get: function get() {
          return this._active;
        }
        /**
         * The displayed value of the option. It is necessary to show the selected option in the
         * select's trigger.
         * @return {?}
         */

      }, {
        key: "viewValue",
        get: function get() {
          // TODO(kara): Add input property alternative for node envs.
          return (this._getHostElement().textContent || '').trim();
        }
      }]);

      return MatOption;
    }();

    MatOption.ɵfac = function MatOption_Factory(t) {
      return new (t || MatOption)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ChangeDetectorRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](MAT_OPTION_PARENT_COMPONENT, 8), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](MatOptgroup, 8));
    };

    MatOption.ɵcmp = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineComponent"]({
      type: MatOption,
      selectors: [["mat-option"]],
      hostAttrs: ["role", "option", 1, "mat-option", "mat-focus-indicator"],
      hostVars: 12,
      hostBindings: function MatOption_HostBindings(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵlistener"]("click", function MatOption_click_HostBindingHandler() {
            return ctx._selectViaInteraction();
          })("keydown", function MatOption_keydown_HostBindingHandler($event) {
            return ctx._handleKeydown($event);
          });
        }

        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵhostProperty"]("id", ctx.id);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵattribute"]("tabindex", ctx._getTabIndex())("aria-selected", ctx._getAriaSelected())("aria-disabled", ctx.disabled.toString());

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵclassProp"]("mat-selected", ctx.selected)("mat-option-multiple", ctx.multiple)("mat-active", ctx.active)("mat-option-disabled", ctx.disabled);
        }
      },
      inputs: {
        id: "id",
        disabled: "disabled",
        value: "value"
      },
      outputs: {
        onSelectionChange: "onSelectionChange"
      },
      exportAs: ["matOption"],
      ngContentSelectors: _c2,
      decls: 4,
      vars: 3,
      consts: [["class", "mat-option-pseudo-checkbox", 3, "state", "disabled", 4, "ngIf"], [1, "mat-option-text"], ["mat-ripple", "", 1, "mat-option-ripple", 3, "matRippleTrigger", "matRippleDisabled"], [1, "mat-option-pseudo-checkbox", 3, "state", "disabled"]],
      template: function MatOption_Template(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵprojectionDef"]();

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtemplate"](0, MatOption_mat_pseudo_checkbox_0_Template, 1, 2, "mat-pseudo-checkbox", 0);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](1, "span", 1);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵprojection"](2);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"]();

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelement"](3, "div", 2);
        }

        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("ngIf", ctx.multiple);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](3);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("matRippleTrigger", ctx._getHostElement())("matRippleDisabled", ctx.disabled || ctx.disableRipple);
        }
      },
      directives: [_angular_common__WEBPACK_IMPORTED_MODULE_4__["NgIf"], MatRipple, MatPseudoCheckbox],
      styles: [".mat-option{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;display:block;line-height:48px;height:48px;padding:0 16px;text-align:left;text-decoration:none;max-width:100%;position:relative;cursor:pointer;outline:none;display:flex;flex-direction:row;max-width:100%;box-sizing:border-box;align-items:center;-webkit-tap-highlight-color:transparent}.mat-option[disabled]{cursor:default}[dir=rtl] .mat-option{text-align:right}.mat-option .mat-icon{margin-right:16px;vertical-align:middle}.mat-option .mat-icon svg{vertical-align:top}[dir=rtl] .mat-option .mat-icon{margin-left:16px;margin-right:0}.mat-option[aria-disabled=true]{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:default}.mat-optgroup .mat-option:not(.mat-option-multiple){padding-left:32px}[dir=rtl] .mat-optgroup .mat-option:not(.mat-option-multiple){padding-left:16px;padding-right:32px}.cdk-high-contrast-active .mat-option{margin:0 1px}.cdk-high-contrast-active .mat-option.mat-active{border:solid 1px currentColor;margin:0}.mat-option-text{display:inline-block;flex-grow:1;overflow:hidden;text-overflow:ellipsis}.mat-option .mat-option-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.cdk-high-contrast-active .mat-option .mat-option-ripple{opacity:.5}.mat-option-pseudo-checkbox{margin-right:8px}[dir=rtl] .mat-option-pseudo-checkbox{margin-left:8px;margin-right:0}\n"],
      encapsulation: 2,
      changeDetection: 0
    });
    /** @nocollapse */

    MatOption.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ChangeDetectorRef"]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [MAT_OPTION_PARENT_COMPONENT]
        }]
      }, {
        type: MatOptgroup,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }]
      }];
    };

    MatOption.propDecorators = {
      value: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }],
      id: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }],
      disabled: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }],
      onSelectionChange: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Output"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatOption, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Component"],
        args: [{
          selector: 'mat-option',
          exportAs: 'matOption',
          host: {
            'role': 'option',
            '[attr.tabindex]': '_getTabIndex()',
            '[class.mat-selected]': 'selected',
            '[class.mat-option-multiple]': 'multiple',
            '[class.mat-active]': 'active',
            '[id]': 'id',
            '[attr.aria-selected]': '_getAriaSelected()',
            '[attr.aria-disabled]': 'disabled.toString()',
            '[class.mat-option-disabled]': 'disabled',
            '(click)': '_selectViaInteraction()',
            '(keydown)': '_handleKeydown($event)',
            'class': 'mat-option mat-focus-indicator'
          },
          template: "<mat-pseudo-checkbox *ngIf=\"multiple\" class=\"mat-option-pseudo-checkbox\"\n    [state]=\"selected ? 'checked' : 'unchecked'\" [disabled]=\"disabled\"></mat-pseudo-checkbox>\n\n<span class=\"mat-option-text\"><ng-content></ng-content></span>\n\n<div class=\"mat-option-ripple\" mat-ripple\n     [matRippleTrigger]=\"_getHostElement()\"\n     [matRippleDisabled]=\"disabled || disableRipple\">\n</div>\n",
          encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewEncapsulation"].None,
          changeDetection: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ChangeDetectionStrategy"].OnPush,
          styles: [".mat-option{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;display:block;line-height:48px;height:48px;padding:0 16px;text-align:left;text-decoration:none;max-width:100%;position:relative;cursor:pointer;outline:none;display:flex;flex-direction:row;max-width:100%;box-sizing:border-box;align-items:center;-webkit-tap-highlight-color:transparent}.mat-option[disabled]{cursor:default}[dir=rtl] .mat-option{text-align:right}.mat-option .mat-icon{margin-right:16px;vertical-align:middle}.mat-option .mat-icon svg{vertical-align:top}[dir=rtl] .mat-option .mat-icon{margin-left:16px;margin-right:0}.mat-option[aria-disabled=true]{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:default}.mat-optgroup .mat-option:not(.mat-option-multiple){padding-left:32px}[dir=rtl] .mat-optgroup .mat-option:not(.mat-option-multiple){padding-left:16px;padding-right:32px}.cdk-high-contrast-active .mat-option{margin:0 1px}.cdk-high-contrast-active .mat-option.mat-active{border:solid 1px currentColor;margin:0}.mat-option-text{display:inline-block;flex-grow:1;overflow:hidden;text-overflow:ellipsis}.mat-option .mat-option-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}.cdk-high-contrast-active .mat-option .mat-option-ripple{opacity:.5}.mat-option-pseudo-checkbox{margin-right:8px}[dir=rtl] .mat-option-pseudo-checkbox{margin-left:8px;margin-right:0}\n"]
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ChangeDetectorRef"]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [MAT_OPTION_PARENT_COMPONENT]
          }]
        }, {
          type: MatOptgroup,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }]
        }];
      }, {
        id: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }],
        onSelectionChange: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Output"]
        }],
        disabled: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }],
        value: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * Counts the amount of option group labels that precede the specified option.
     * \@docs-private
     * @param {?} optionIndex Index of the option at which to start counting.
     * @param {?} options Flat list of all of the options.
     * @param {?} optionGroups Flat list of all of the option groups.
     * @return {?}
     */


    function _countGroupLabelsBeforeOption(optionIndex, options, optionGroups) {
      if (optionGroups.length) {
        /** @type {?} */
        var optionsArray = options.toArray();
        /** @type {?} */

        var groups = optionGroups.toArray();
        /** @type {?} */

        var groupCounter = 0;

        for (var i = 0; i < optionIndex + 1; i++) {
          if (optionsArray[i].group && optionsArray[i].group === groups[groupCounter]) {
            groupCounter++;
          }
        }

        return groupCounter;
      }

      return 0;
    }
    /**
     * Determines the position to which to scroll a panel in order for an option to be into view.
     * \@docs-private
     * @param {?} optionIndex Index of the option to be scrolled into the view.
     * @param {?} optionHeight Height of the options.
     * @param {?} currentScrollPosition Current scroll position of the panel.
     * @param {?} panelHeight Height of the panel.
     * @return {?}
     */


    function _getOptionScrollPosition(optionIndex, optionHeight, currentScrollPosition, panelHeight) {
      /** @type {?} */
      var optionOffset = optionIndex * optionHeight;

      if (optionOffset < currentScrollPosition) {
        return optionOffset;
      }

      if (optionOffset + optionHeight > currentScrollPosition + panelHeight) {
        return Math.max(0, optionOffset - panelHeight + optionHeight);
      }

      return currentScrollPosition;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/option/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var MatOptionModule = function MatOptionModule() {
      _classCallCheck(this, MatOptionModule);
    };

    MatOptionModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: MatOptionModule
    });
    MatOptionModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function MatOptionModule_Factory(t) {
        return new (t || MatOptionModule)();
      },
      imports: [[MatRippleModule, _angular_common__WEBPACK_IMPORTED_MODULE_4__["CommonModule"], MatPseudoCheckboxModule]]
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](MatOptionModule, {
        declarations: function declarations() {
          return [MatOption, MatOptgroup];
        },
        imports: function imports() {
          return [MatRippleModule, _angular_common__WEBPACK_IMPORTED_MODULE_4__["CommonModule"], MatPseudoCheckboxModule];
        },
        exports: function exports() {
          return [MatOption, MatOptgroup];
        }
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatOptionModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{
          imports: [MatRippleModule, _angular_common__WEBPACK_IMPORTED_MODULE_4__["CommonModule"], MatPseudoCheckboxModule],
          exports: [MatOption, MatOptgroup],
          declarations: [MatOption, MatOptgroup]
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/label/label-options.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * InjectionToken that can be used to specify the global label options.
     * @deprecated Use `MAT_FORM_FIELD_DEFAULT_OPTIONS` injection token from
     *     `\@angular/material/form-field` instead.
     * \@breaking-change 11.0.0
     * @type {?}
     */


    var MAT_LABEL_GLOBAL_OPTIONS = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('mat-label-global-options');
    /**
     * Configurable options for floating labels.
     * @deprecated Use `MatFormFieldDefaultOptions` from `\@angular/material/form-field` instead.
     * \@breaking-change 11.0.0
     * @record
     */

    function LabelOptions() {}

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/month-constants.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * When constructing a Date, the month is zero-based. This can be confusing, since people are
     * used to seeing them one-based. So we create these aliases to make writing the tests easier.
     * \@docs-private
     * \@breaking-change 8.0.0 Remove this with V8 since it was only targeted for testing.
     * @type {?}
     */


    var JAN = 0;
    /** @type {?} */

    var FEB = 1;
    /** @type {?} */

    var MAR = 2;
    /** @type {?} */

    var APR = 3;
    /** @type {?} */

    var MAY = 4;
    /** @type {?} */

    var JUN = 5;
    /** @type {?} */

    var JUL = 6;
    /** @type {?} */

    var AUG = 7;
    /** @type {?} */

    var SEP = 8;
    /** @type {?} */

    var OCT = 9;
    /** @type {?} */

    var NOV = 10;
    /** @type {?} */

    var DEC = 11;
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/core/public-api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=core.js.map

    /***/
  },

  /***/
  "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/grid-list.js":
  /*!***************************************************************************!*\
    !*** ./node_modules/@angular/material/__ivy_ngcc__/fesm2015/grid-list.js ***!
    \***************************************************************************/

  /*! exports provided: MatGridAvatarCssMatStyler, MatGridList, MatGridListModule, MatGridTile, MatGridTileFooterCssMatStyler, MatGridTileHeaderCssMatStyler, MatGridTileText, ɵTileCoordinator, ɵangular_material_src_material_grid_list_grid_list_a */

  /***/
  function node_modulesAngularMaterial__ivy_ngcc__Fesm2015GridListJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatGridAvatarCssMatStyler", function () {
      return MatGridAvatarCssMatStyler;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatGridList", function () {
      return MatGridList;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatGridListModule", function () {
      return MatGridListModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatGridTile", function () {
      return MatGridTile;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatGridTileFooterCssMatStyler", function () {
      return MatGridTileFooterCssMatStyler;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatGridTileHeaderCssMatStyler", function () {
      return MatGridTileHeaderCssMatStyler;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatGridTileText", function () {
      return MatGridTileText;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵTileCoordinator", function () {
      return TileCoordinator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_material_src_material_grid_list_grid_list_a", function () {
      return MAT_GRID_LIST;
    });
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var _angular_material_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! @angular/material/core */
    "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var _angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! @angular/cdk/coercion */
    "./node_modules/@angular/cdk/fesm2015/coercion.js");
    /* harmony import */


    var _angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! @angular/cdk/bidi */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/bidi.js");
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/grid-list/grid-list-base.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Injection token used to provide a grid list to a tile and to avoid circular imports.
     * \@docs-private
     * @type {?}
     */


    var _c0 = ["*"];
    var _c1 = [[["", "mat-grid-avatar", ""], ["", "matGridAvatar", ""]], [["", "mat-line", ""], ["", "matLine", ""]], "*"];
    var _c2 = ["[mat-grid-avatar], [matGridAvatar]", "[mat-line], [matLine]", "*"];
    var MAT_GRID_LIST = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('MAT_GRID_LIST');
    /**
     * Base interface for a `MatGridList`.
     * \@docs-private
     * @record
     */

    function MatGridListBase() {}

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/grid-list/grid-tile.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var MatGridTile = /*#__PURE__*/function () {
      /**
       * @param {?} _element
       * @param {?=} _gridList
       */
      function MatGridTile(_element, _gridList) {
        _classCallCheck(this, MatGridTile);

        this._element = _element;
        this._gridList = _gridList;
        this._rowspan = 1;
        this._colspan = 1;
      }
      /**
       * Amount of rows that the grid tile takes up.
       * @return {?}
       */


      _createClass2(MatGridTile, [{
        key: "_setStyle",

        /**
         * Sets the style of the grid-tile element.  Needs to be set manually to avoid
         * "Changed after checked" errors that would occur with HostBinding.
         * @param {?} property
         * @param {?} value
         * @return {?}
         */
        value: function _setStyle(property, value) {
          /** @type {?} */
          this._element.nativeElement.style[property] = value;
        }
      }, {
        key: "rowspan",
        get: function get() {
          return this._rowspan;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._rowspan = Math.round(Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_2__["coerceNumberProperty"])(value));
        }
        /**
         * Amount of columns that the grid tile takes up.
         * @return {?}
         */

      }, {
        key: "colspan",
        get: function get() {
          return this._colspan;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._colspan = Math.round(Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_2__["coerceNumberProperty"])(value));
        }
      }]);

      return MatGridTile;
    }();

    MatGridTile.ɵfac = function MatGridTile_Factory(t) {
      return new (t || MatGridTile)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](MAT_GRID_LIST, 8));
    };

    MatGridTile.ɵcmp = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineComponent"]({
      type: MatGridTile,
      selectors: [["mat-grid-tile"]],
      hostAttrs: [1, "mat-grid-tile"],
      hostVars: 2,
      hostBindings: function MatGridTile_HostBindings(rf, ctx) {
        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵattribute"]("rowspan", ctx.rowspan)("colspan", ctx.colspan);
        }
      },
      inputs: {
        rowspan: "rowspan",
        colspan: "colspan"
      },
      exportAs: ["matGridTile"],
      ngContentSelectors: _c0,
      decls: 2,
      vars: 0,
      consts: [[1, "mat-figure"]],
      template: function MatGridTile_Template(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵprojectionDef"]();

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](0, "figure", 0);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵprojection"](1);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"]();
        }
      },
      styles: [".mat-grid-list{display:block;position:relative}.mat-grid-tile{display:block;position:absolute;overflow:hidden}.mat-grid-tile .mat-figure{top:0;left:0;right:0;bottom:0;position:absolute;display:flex;align-items:center;justify-content:center;height:100%;padding:0;margin:0}.mat-grid-tile .mat-grid-tile-header,.mat-grid-tile .mat-grid-tile-footer{display:flex;align-items:center;height:48px;color:#fff;background:rgba(0,0,0,.38);overflow:hidden;padding:0 16px;position:absolute;left:0;right:0}.mat-grid-tile .mat-grid-tile-header>*,.mat-grid-tile .mat-grid-tile-footer>*{margin:0;padding:0;font-weight:normal;font-size:inherit}.mat-grid-tile .mat-grid-tile-header.mat-2-line,.mat-grid-tile .mat-grid-tile-footer.mat-2-line{height:68px}.mat-grid-tile .mat-grid-list-text{display:flex;flex-direction:column;width:100%;box-sizing:border-box;overflow:hidden}.mat-grid-tile .mat-grid-list-text>*{margin:0;padding:0;font-weight:normal;font-size:inherit}.mat-grid-tile .mat-grid-list-text:empty{display:none}.mat-grid-tile .mat-grid-tile-header{top:0}.mat-grid-tile .mat-grid-tile-footer{bottom:0}.mat-grid-tile .mat-grid-avatar{padding-right:16px}[dir=rtl] .mat-grid-tile .mat-grid-avatar{padding-right:0;padding-left:16px}.mat-grid-tile .mat-grid-avatar:empty{display:none}\n"],
      encapsulation: 2,
      changeDetection: 0
    });
    /** @nocollapse */

    MatGridTile.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [MAT_GRID_LIST]
        }]
      }];
    };

    MatGridTile.propDecorators = {
      rowspan: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }],
      colspan: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatGridTile, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Component"],
        args: [{
          selector: 'mat-grid-tile',
          exportAs: 'matGridTile',
          host: {
            'class': 'mat-grid-tile',
            // Ensures that the "rowspan" and "colspan" input value is reflected in
            // the DOM. This is needed for the grid-tile harness.
            '[attr.rowspan]': 'rowspan',
            '[attr.colspan]': 'colspan'
          },
          template: "<!-- TODO(kara): Revisit why this is a figure.-->\n<figure class=\"mat-figure\">\n  <ng-content></ng-content>\n</figure>",
          encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewEncapsulation"].None,
          changeDetection: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ChangeDetectionStrategy"].OnPush,
          styles: [".mat-grid-list{display:block;position:relative}.mat-grid-tile{display:block;position:absolute;overflow:hidden}.mat-grid-tile .mat-figure{top:0;left:0;right:0;bottom:0;position:absolute;display:flex;align-items:center;justify-content:center;height:100%;padding:0;margin:0}.mat-grid-tile .mat-grid-tile-header,.mat-grid-tile .mat-grid-tile-footer{display:flex;align-items:center;height:48px;color:#fff;background:rgba(0,0,0,.38);overflow:hidden;padding:0 16px;position:absolute;left:0;right:0}.mat-grid-tile .mat-grid-tile-header>*,.mat-grid-tile .mat-grid-tile-footer>*{margin:0;padding:0;font-weight:normal;font-size:inherit}.mat-grid-tile .mat-grid-tile-header.mat-2-line,.mat-grid-tile .mat-grid-tile-footer.mat-2-line{height:68px}.mat-grid-tile .mat-grid-list-text{display:flex;flex-direction:column;width:100%;box-sizing:border-box;overflow:hidden}.mat-grid-tile .mat-grid-list-text>*{margin:0;padding:0;font-weight:normal;font-size:inherit}.mat-grid-tile .mat-grid-list-text:empty{display:none}.mat-grid-tile .mat-grid-tile-header{top:0}.mat-grid-tile .mat-grid-tile-footer{bottom:0}.mat-grid-tile .mat-grid-avatar{padding-right:16px}[dir=rtl] .mat-grid-tile .mat-grid-avatar{padding-right:0;padding-left:16px}.mat-grid-tile .mat-grid-avatar:empty{display:none}\n"]
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [MAT_GRID_LIST]
          }]
        }];
      }, {
        rowspan: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }],
        colspan: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }]
      });
    })();

    if (false) {}

    var MatGridTileText = /*#__PURE__*/function () {
      /**
       * @param {?} _element
       */
      function MatGridTileText(_element) {
        _classCallCheck(this, MatGridTileText);

        this._element = _element;
      }
      /**
       * @return {?}
       */


      _createClass2(MatGridTileText, [{
        key: "ngAfterContentInit",
        value: function ngAfterContentInit() {
          Object(_angular_material_core__WEBPACK_IMPORTED_MODULE_1__["setLines"])(this._lines, this._element);
        }
      }]);

      return MatGridTileText;
    }();

    MatGridTileText.ɵfac = function MatGridTileText_Factory(t) {
      return new (t || MatGridTileText)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]));
    };

    MatGridTileText.ɵcmp = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineComponent"]({
      type: MatGridTileText,
      selectors: [["mat-grid-tile-header"], ["mat-grid-tile-footer"]],
      contentQueries: function MatGridTileText_ContentQueries(rf, ctx, dirIndex) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵcontentQuery"](dirIndex, _angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatLine"], true);
        }

        if (rf & 2) {
          var _t;

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵqueryRefresh"](_t = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵloadQuery"]()) && (ctx._lines = _t);
        }
      },
      ngContentSelectors: _c2,
      decls: 4,
      vars: 0,
      consts: [[1, "mat-grid-list-text"]],
      template: function MatGridTileText_Template(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵprojectionDef"](_c1);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵprojection"](0);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](1, "div", 0);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵprojection"](2, 1);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"]();

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵprojection"](3, 2);
        }
      },
      encapsulation: 2,
      changeDetection: 0
    });
    /** @nocollapse */

    MatGridTileText.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
      }];
    };

    MatGridTileText.propDecorators = {
      _lines: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ContentChildren"],
        args: [_angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatLine"], {
          descendants: true
        }]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatGridTileText, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Component"],
        args: [{
          selector: 'mat-grid-tile-header, mat-grid-tile-footer',
          template: "<ng-content select=\"[mat-grid-avatar], [matGridAvatar]\"></ng-content>\n<div class=\"mat-grid-list-text\"><ng-content select=\"[mat-line], [matLine]\"></ng-content></div>\n<ng-content></ng-content>\n",
          changeDetection: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ChangeDetectionStrategy"].OnPush,
          encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewEncapsulation"].None
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
        }];
      }, {
        _lines: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ContentChildren"],
          args: [_angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatLine"], {
            descendants: true
          }]
        }]
      });
    })();

    if (false) {}
    /**
     * Directive whose purpose is to add the mat- CSS styling to this selector.
     * \@docs-private
     */


    var MatGridAvatarCssMatStyler = function MatGridAvatarCssMatStyler() {
      _classCallCheck(this, MatGridAvatarCssMatStyler);
    };

    MatGridAvatarCssMatStyler.ɵfac = function MatGridAvatarCssMatStyler_Factory(t) {
      return new (t || MatGridAvatarCssMatStyler)();
    };

    MatGridAvatarCssMatStyler.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: MatGridAvatarCssMatStyler,
      selectors: [["", "mat-grid-avatar", ""], ["", "matGridAvatar", ""]],
      hostAttrs: [1, "mat-grid-avatar"]
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatGridAvatarCssMatStyler, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: '[mat-grid-avatar], [matGridAvatar]',
          host: {
            'class': 'mat-grid-avatar'
          }
        }]
      }], null, null);
    })();
    /**
     * Directive whose purpose is to add the mat- CSS styling to this selector.
     * \@docs-private
     */


    var MatGridTileHeaderCssMatStyler = function MatGridTileHeaderCssMatStyler() {
      _classCallCheck(this, MatGridTileHeaderCssMatStyler);
    };

    MatGridTileHeaderCssMatStyler.ɵfac = function MatGridTileHeaderCssMatStyler_Factory(t) {
      return new (t || MatGridTileHeaderCssMatStyler)();
    };

    MatGridTileHeaderCssMatStyler.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: MatGridTileHeaderCssMatStyler,
      selectors: [["mat-grid-tile-header"]],
      hostAttrs: [1, "mat-grid-tile-header"]
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatGridTileHeaderCssMatStyler, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: 'mat-grid-tile-header',
          host: {
            'class': 'mat-grid-tile-header'
          }
        }]
      }], null, null);
    })();
    /**
     * Directive whose purpose is to add the mat- CSS styling to this selector.
     * \@docs-private
     */


    var MatGridTileFooterCssMatStyler = function MatGridTileFooterCssMatStyler() {
      _classCallCheck(this, MatGridTileFooterCssMatStyler);
    };

    MatGridTileFooterCssMatStyler.ɵfac = function MatGridTileFooterCssMatStyler_Factory(t) {
      return new (t || MatGridTileFooterCssMatStyler)();
    };

    MatGridTileFooterCssMatStyler.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({
      type: MatGridTileFooterCssMatStyler,
      selectors: [["mat-grid-tile-footer"]],
      hostAttrs: [1, "mat-grid-tile-footer"]
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatGridTileFooterCssMatStyler, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Directive"],
        args: [{
          selector: 'mat-grid-tile-footer',
          host: {
            'class': 'mat-grid-tile-footer'
          }
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/grid-list/tile-coordinator.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Interface describing a tile.
     * \@docs-private
     * @record
     */


    function Tile() {}

    if (false) {}
    /**
     * Class for determining, from a list of tiles, the (row, col) position of each of those tiles
     * in the grid. This is necessary (rather than just rendering the tiles in normal document flow)
     * because the tiles can have a rowspan.
     *
     * The positioning algorithm greedily places each tile as soon as it encounters a gap in the grid
     * large enough to accommodate it so that the tiles still render in the same order in which they
     * are given.
     *
     * The basis of the algorithm is the use of an array to track the already placed tiles. Each
     * element of the array corresponds to a column, and the value indicates how many cells in that
     * column are already occupied; zero indicates an empty cell. Moving "down" to the next row
     * decrements each value in the tracking array (indicating that the column is one cell closer to
     * being free).
     *
     * \@docs-private
     */


    var TileCoordinator = /*#__PURE__*/function () {
      function TileCoordinator() {
        _classCallCheck(this, TileCoordinator);

        /**
         * Index at which the search for the next gap will start.
         */
        this.columnIndex = 0;
        /**
         * The current row index.
         */

        this.rowIndex = 0;
      }
      /**
       * Gets the total number of rows occupied by tiles
       * @return {?}
       */


      _createClass2(TileCoordinator, [{
        key: "update",

        /**
         * Updates the tile positions.
         * @param {?} numColumns Amount of columns in the grid.
         * @param {?} tiles Tiles to be positioned.
         * @return {?}
         */
        value: function update(numColumns, tiles) {
          var _this241 = this;

          this.columnIndex = 0;
          this.rowIndex = 0;
          this.tracker = new Array(numColumns);
          this.tracker.fill(0, 0, this.tracker.length);
          this.positions = tiles.map(
          /**
          * @param {?} tile
          * @return {?}
          */
          function (tile) {
            return _this241._trackTile(tile);
          });
        }
        /**
         * Calculates the row and col position of a tile.
         * @private
         * @param {?} tile
         * @return {?}
         */

      }, {
        key: "_trackTile",
        value: function _trackTile(tile) {
          // Find a gap large enough for this tile.

          /** @type {?} */
          var gapStartIndex = this._findMatchingGap(tile.colspan); // Place tile in the resulting gap.


          this._markTilePosition(gapStartIndex, tile); // The next time we look for a gap, the search will start at columnIndex, which should be
          // immediately after the tile that has just been placed.


          this.columnIndex = gapStartIndex + tile.colspan;
          return new TilePosition(this.rowIndex, gapStartIndex);
        }
        /**
         * Finds the next available space large enough to fit the tile.
         * @private
         * @param {?} tileCols
         * @return {?}
         */

      }, {
        key: "_findMatchingGap",
        value: function _findMatchingGap(tileCols) {
          if (tileCols > this.tracker.length) {
            throw Error("mat-grid-list: tile with colspan ".concat(tileCols, " is wider than ") + "grid with cols=\"".concat(this.tracker.length, "\"."));
          } // Start index is inclusive, end index is exclusive.

          /** @type {?} */


          var gapStartIndex = -1;
          /** @type {?} */

          var gapEndIndex = -1; // Look for a gap large enough to fit the given tile. Empty spaces are marked with a zero.

          do {
            // If we've reached the end of the row, go to the next row.
            if (this.columnIndex + tileCols > this.tracker.length) {
              this._nextRow();

              gapStartIndex = this.tracker.indexOf(0, this.columnIndex);
              gapEndIndex = this._findGapEndIndex(gapStartIndex);
              continue;
            }

            gapStartIndex = this.tracker.indexOf(0, this.columnIndex); // If there are no more empty spaces in this row at all, move on to the next row.

            if (gapStartIndex == -1) {
              this._nextRow();

              gapStartIndex = this.tracker.indexOf(0, this.columnIndex);
              gapEndIndex = this._findGapEndIndex(gapStartIndex);
              continue;
            }

            gapEndIndex = this._findGapEndIndex(gapStartIndex); // If a gap large enough isn't found, we want to start looking immediately after the current
            // gap on the next iteration.

            this.columnIndex = gapStartIndex + 1; // Continue iterating until we find a gap wide enough for this tile. Since gapEndIndex is
            // exclusive, gapEndIndex is 0 means we didn't find a gap and should continue.
          } while (gapEndIndex - gapStartIndex < tileCols || gapEndIndex == 0); // If we still didn't manage to find a gap, ensure that the index is
          // at least zero so the tile doesn't get pulled out of the grid.


          return Math.max(gapStartIndex, 0);
        }
        /**
         * Move "down" to the next row.
         * @private
         * @return {?}
         */

      }, {
        key: "_nextRow",
        value: function _nextRow() {
          this.columnIndex = 0;
          this.rowIndex++; // Decrement all spaces by one to reflect moving down one row.

          for (var i = 0; i < this.tracker.length; i++) {
            this.tracker[i] = Math.max(0, this.tracker[i] - 1);
          }
        }
        /**
         * Finds the end index (exclusive) of a gap given the index from which to start looking.
         * The gap ends when a non-zero value is found.
         * @private
         * @param {?} gapStartIndex
         * @return {?}
         */

      }, {
        key: "_findGapEndIndex",
        value: function _findGapEndIndex(gapStartIndex) {
          for (var i = gapStartIndex + 1; i < this.tracker.length; i++) {
            if (this.tracker[i] != 0) {
              return i;
            }
          } // The gap ends with the end of the row.


          return this.tracker.length;
        }
        /**
         * Update the tile tracker to account for the given tile in the given space.
         * @private
         * @param {?} start
         * @param {?} tile
         * @return {?}
         */

      }, {
        key: "_markTilePosition",
        value: function _markTilePosition(start, tile) {
          for (var i = 0; i < tile.colspan; i++) {
            this.tracker[start + i] = tile.rowspan;
          }
        }
      }, {
        key: "rowCount",
        get: function get() {
          return this.rowIndex + 1;
        }
        /**
         * Gets the total span of rows occupied by tiles.
         * Ex: A list with 1 row that contains a tile with rowspan 2 will have a total rowspan of 2.
         * @return {?}
         */

      }, {
        key: "rowspan",
        get: function get() {
          /** @type {?} */
          var lastRowMax = Math.max.apply(Math, _toConsumableArray(this.tracker)); // if any of the tiles has a rowspan that pushes it beyond the total row count,
          // add the difference to the rowcount

          return lastRowMax > 1 ? this.rowCount + lastRowMax - 1 : this.rowCount;
        }
      }]);

      return TileCoordinator;
    }();

    if (false) {}
    /**
     * Simple data structure for tile position (row, col).
     * \@docs-private
     */


    var TilePosition =
    /**
     * @param {?} row
     * @param {?} col
     */
    function TilePosition(row, col) {
      _classCallCheck(this, TilePosition);

      this.row = row;
      this.col = col;
    };

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/grid-list/tile-styler.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google LLC All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * RegExp that can be used to check whether a value will
     * be allowed inside a CSS `calc()` expression.
     * @type {?}
     */


    var cssCalcAllowedValue = /^-?\d+((\.\d+)?[A-Za-z%$]?)+$/;
    /**
     * Sets the style properties for an individual tile, given the position calculated by the
     * Tile Coordinator.
     * \@docs-private
     * @abstract
     */

    var TileStyler = /*#__PURE__*/function () {
      function TileStyler() {
        _classCallCheck(this, TileStyler);

        this._rows = 0;
        this._rowspan = 0;
      }
      /**
       * Adds grid-list layout info once it is available. Cannot be processed in the constructor
       * because these properties haven't been calculated by that point.
       *
       * @param {?} gutterSize Size of the grid's gutter.
       * @param {?} tracker Instance of the TileCoordinator.
       * @param {?} cols Amount of columns in the grid.
       * @param {?} direction Layout direction of the grid.
       * @return {?}
       */


      _createClass2(TileStyler, [{
        key: "init",
        value: function init(gutterSize, tracker, cols, direction) {
          this._gutterSize = normalizeUnits(gutterSize);
          this._rows = tracker.rowCount;
          this._rowspan = tracker.rowspan;
          this._cols = cols;
          this._direction = direction;
        }
        /**
         * Computes the amount of space a single 1x1 tile would take up (width or height).
         * Used as a basis for other calculations.
         * @param {?} sizePercent Percent of the total grid-list space that one 1x1 tile would take up.
         * @param {?} gutterFraction Fraction of the gutter size taken up by one 1x1 tile.
         * @return {?} The size of a 1x1 tile as an expression that can be evaluated via CSS calc().
         */

      }, {
        key: "getBaseTileSize",
        value: function getBaseTileSize(sizePercent, gutterFraction) {
          // Take the base size percent (as would be if evenly dividing the size between cells),
          // and then subtracting the size of one gutter. However, since there are no gutters on the
          // edges, each tile only uses a fraction (gutterShare = numGutters / numCells) of the gutter
          // size. (Imagine having one gutter per tile, and then breaking up the extra gutter on the
          // edge evenly among the cells).
          return "(".concat(sizePercent, "% - (").concat(this._gutterSize, " * ").concat(gutterFraction, "))");
        }
        /**
         * Gets The horizontal or vertical position of a tile, e.g., the 'top' or 'left' property value.
         * @param {?} baseSize Base size of a 1x1 tile (as computed in getBaseTileSize).
         * @param {?} offset Number of tiles that have already been rendered in the row/column.
         * @return {?} Position of the tile as a CSS calc() expression.
         */

      }, {
        key: "getTilePosition",
        value: function getTilePosition(baseSize, offset) {
          // The position comes the size of a 1x1 tile plus gutter for each previous tile in the
          // row/column (offset).
          return offset === 0 ? '0' : calc("(".concat(baseSize, " + ").concat(this._gutterSize, ") * ").concat(offset));
        }
        /**
         * Gets the actual size of a tile, e.g., width or height, taking rowspan or colspan into account.
         * @param {?} baseSize Base size of a 1x1 tile (as computed in getBaseTileSize).
         * @param {?} span The tile's rowspan or colspan.
         * @return {?} Size of the tile as a CSS calc() expression.
         */

      }, {
        key: "getTileSize",
        value: function getTileSize(baseSize, span) {
          return "(".concat(baseSize, " * ").concat(span, ") + (").concat(span - 1, " * ").concat(this._gutterSize, ")");
        }
        /**
         * Sets the style properties to be applied to a tile for the given row and column index.
         * @param {?} tile Tile to which to apply the styling.
         * @param {?} rowIndex Index of the tile's row.
         * @param {?} colIndex Index of the tile's column.
         * @return {?}
         */

      }, {
        key: "setStyle",
        value: function setStyle(tile, rowIndex, colIndex) {
          // Percent of the available horizontal space that one column takes up.

          /** @type {?} */
          var percentWidthPerTile = 100 / this._cols; // Fraction of the vertical gutter size that each column takes up.
          // For example, if there are 5 columns, each column uses 4/5 = 0.8 times the gutter width.

          /** @type {?} */

          var gutterWidthFractionPerTile = (this._cols - 1) / this._cols;
          this.setColStyles(tile, colIndex, percentWidthPerTile, gutterWidthFractionPerTile);
          this.setRowStyles(tile, rowIndex, percentWidthPerTile, gutterWidthFractionPerTile);
        }
        /**
         * Sets the horizontal placement of the tile in the list.
         * @param {?} tile
         * @param {?} colIndex
         * @param {?} percentWidth
         * @param {?} gutterWidth
         * @return {?}
         */

      }, {
        key: "setColStyles",
        value: function setColStyles(tile, colIndex, percentWidth, gutterWidth) {
          // Base horizontal size of a column.

          /** @type {?} */
          var baseTileWidth = this.getBaseTileSize(percentWidth, gutterWidth); // The width and horizontal position of each tile is always calculated the same way, but the
          // height and vertical position depends on the rowMode.

          /** @type {?} */

          var side = this._direction === 'rtl' ? 'right' : 'left';

          tile._setStyle(side, this.getTilePosition(baseTileWidth, colIndex));

          tile._setStyle('width', calc(this.getTileSize(baseTileWidth, tile.colspan)));
        }
        /**
         * Calculates the total size taken up by gutters across one axis of a list.
         * @return {?}
         */

      }, {
        key: "getGutterSpan",
        value: function getGutterSpan() {
          return "".concat(this._gutterSize, " * (").concat(this._rowspan, " - 1)");
        }
        /**
         * Calculates the total size taken up by tiles across one axis of a list.
         * @param {?} tileHeight Height of the tile.
         * @return {?}
         */

      }, {
        key: "getTileSpan",
        value: function getTileSpan(tileHeight) {
          return "".concat(this._rowspan, " * ").concat(this.getTileSize(tileHeight, 1));
        }
        /**
         * Calculates the computed height and returns the correct style property to set.
         * This method can be implemented by each type of TileStyler.
         * \@docs-private
         * @return {?}
         */

      }, {
        key: "getComputedHeight",
        value: function getComputedHeight() {
          return null;
        }
      }]);

      return TileStyler;
    }();

    if (false) {}
    /**
     * This type of styler is instantiated when the user passes in a fixed row height.
     * Example `<mat-grid-list cols="3" rowHeight="100px">`
     * \@docs-private
     */


    var FixedTileStyler = /*#__PURE__*/function (_TileStyler) {
      _inherits(FixedTileStyler, _TileStyler);

      var _super79 = _createSuper(FixedTileStyler);

      /**
       * @param {?} fixedRowHeight
       */
      function FixedTileStyler(fixedRowHeight) {
        var _this242;

        _classCallCheck(this, FixedTileStyler);

        _this242 = _super79.call(this);
        _this242.fixedRowHeight = fixedRowHeight;
        return _this242;
      }
      /**
       * @param {?} gutterSize
       * @param {?} tracker
       * @param {?} cols
       * @param {?} direction
       * @return {?}
       */


      _createClass2(FixedTileStyler, [{
        key: "init",
        value: function init(gutterSize, tracker, cols, direction) {
          _get(_getPrototypeOf(FixedTileStyler.prototype), "init", this).call(this, gutterSize, tracker, cols, direction);

          this.fixedRowHeight = normalizeUnits(this.fixedRowHeight);

          if (!cssCalcAllowedValue.test(this.fixedRowHeight)) {
            throw Error("Invalid value \"".concat(this.fixedRowHeight, "\" set as rowHeight."));
          }
        }
        /**
         * @param {?} tile
         * @param {?} rowIndex
         * @return {?}
         */

      }, {
        key: "setRowStyles",
        value: function setRowStyles(tile, rowIndex) {
          tile._setStyle('top', this.getTilePosition(this.fixedRowHeight, rowIndex));

          tile._setStyle('height', calc(this.getTileSize(this.fixedRowHeight, tile.rowspan)));
        }
        /**
         * @return {?}
         */

      }, {
        key: "getComputedHeight",
        value: function getComputedHeight() {
          return ['height', calc("".concat(this.getTileSpan(this.fixedRowHeight), " + ").concat(this.getGutterSpan()))];
        }
        /**
         * @param {?} list
         * @return {?}
         */

      }, {
        key: "reset",
        value: function reset(list) {
          list._setListStyle(['height', null]);

          if (list._tiles) {
            list._tiles.forEach(
            /**
            * @param {?} tile
            * @return {?}
            */
            function (tile) {
              tile._setStyle('top', null);

              tile._setStyle('height', null);
            });
          }
        }
      }]);

      return FixedTileStyler;
    }(TileStyler);

    if (false) {}
    /**
     * This type of styler is instantiated when the user passes in a width:height ratio
     * for the row height.  Example `<mat-grid-list cols="3" rowHeight="3:1">`
     * \@docs-private
     */


    var RatioTileStyler = /*#__PURE__*/function (_TileStyler2) {
      _inherits(RatioTileStyler, _TileStyler2);

      var _super80 = _createSuper(RatioTileStyler);

      /**
       * @param {?} value
       */
      function RatioTileStyler(value) {
        var _this243;

        _classCallCheck(this, RatioTileStyler);

        _this243 = _super80.call(this);

        _this243._parseRatio(value);

        return _this243;
      }
      /**
       * @param {?} tile
       * @param {?} rowIndex
       * @param {?} percentWidth
       * @param {?} gutterWidth
       * @return {?}
       */


      _createClass2(RatioTileStyler, [{
        key: "setRowStyles",
        value: function setRowStyles(tile, rowIndex, percentWidth, gutterWidth) {
          /** @type {?} */
          var percentHeightPerTile = percentWidth / this.rowHeightRatio;
          this.baseTileHeight = this.getBaseTileSize(percentHeightPerTile, gutterWidth); // Use padding-top and margin-top to maintain the given aspect ratio, as
          // a percentage-based value for these properties is applied versus the *width* of the
          // containing block. See http://www.w3.org/TR/CSS2/box.html#margin-properties

          tile._setStyle('marginTop', this.getTilePosition(this.baseTileHeight, rowIndex));

          tile._setStyle('paddingTop', calc(this.getTileSize(this.baseTileHeight, tile.rowspan)));
        }
        /**
         * @return {?}
         */

      }, {
        key: "getComputedHeight",
        value: function getComputedHeight() {
          return ['paddingBottom', calc("".concat(this.getTileSpan(this.baseTileHeight), " + ").concat(this.getGutterSpan()))];
        }
        /**
         * @param {?} list
         * @return {?}
         */

      }, {
        key: "reset",
        value: function reset(list) {
          list._setListStyle(['paddingBottom', null]);

          list._tiles.forEach(
          /**
          * @param {?} tile
          * @return {?}
          */
          function (tile) {
            tile._setStyle('marginTop', null);

            tile._setStyle('paddingTop', null);
          });
        }
        /**
         * @private
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "_parseRatio",
        value: function _parseRatio(value) {
          /** @type {?} */
          var ratioParts = value.split(':');

          if (ratioParts.length !== 2) {
            throw Error("mat-grid-list: invalid ratio given for row-height: \"".concat(value, "\""));
          }

          this.rowHeightRatio = parseFloat(ratioParts[0]) / parseFloat(ratioParts[1]);
        }
      }]);

      return RatioTileStyler;
    }(TileStyler);

    if (false) {}
    /**
     * This type of styler is instantiated when the user selects a "fit" row height mode.
     * In other words, the row height will reflect the total height of the container divided
     * by the number of rows.  Example `<mat-grid-list cols="3" rowHeight="fit">`
     *
     * \@docs-private
     */


    var FitTileStyler = /*#__PURE__*/function (_TileStyler3) {
      _inherits(FitTileStyler, _TileStyler3);

      var _super81 = _createSuper(FitTileStyler);

      function FitTileStyler() {
        _classCallCheck(this, FitTileStyler);

        return _super81.apply(this, arguments);
      }

      _createClass2(FitTileStyler, [{
        key: "setRowStyles",

        /**
         * @param {?} tile
         * @param {?} rowIndex
         * @return {?}
         */
        value: function setRowStyles(tile, rowIndex) {
          // Percent of the available vertical space that one row takes up.

          /** @type {?} */
          var percentHeightPerTile = 100 / this._rowspan; // Fraction of the horizontal gutter size that each column takes up.

          /** @type {?} */

          var gutterHeightPerTile = (this._rows - 1) / this._rows; // Base vertical size of a column.

          /** @type {?} */

          var baseTileHeight = this.getBaseTileSize(percentHeightPerTile, gutterHeightPerTile);

          tile._setStyle('top', this.getTilePosition(baseTileHeight, rowIndex));

          tile._setStyle('height', calc(this.getTileSize(baseTileHeight, tile.rowspan)));
        }
        /**
         * @param {?} list
         * @return {?}
         */

      }, {
        key: "reset",
        value: function reset(list) {
          if (list._tiles) {
            list._tiles.forEach(
            /**
            * @param {?} tile
            * @return {?}
            */
            function (tile) {
              tile._setStyle('top', null);

              tile._setStyle('height', null);
            });
          }
        }
      }]);

      return FitTileStyler;
    }(TileStyler);
    /**
     * Wraps a CSS string in a calc function
     * @param {?} exp
     * @return {?}
     */


    function calc(exp) {
      return "calc(".concat(exp, ")");
    }
    /**
     * Appends pixels to a CSS string if no units are given.
     * @param {?} value
     * @return {?}
     */


    function normalizeUnits(value) {
      return value.match(/([A-Za-z%]+)$/) ? value : "".concat(value, "px");
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/grid-list/grid-list.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */
    // TODO(kara): Conditional (responsive) column count / row size.
    // TODO(kara): Re-layout on window resize / media change (debounced).
    // TODO(kara): gridTileHeader and gridTileFooter.

    /** @type {?} */


    var MAT_FIT_MODE = 'fit';

    var MatGridList = /*#__PURE__*/function () {
      /**
       * @param {?} _element
       * @param {?} _dir
       */
      function MatGridList(_element, _dir) {
        _classCallCheck(this, MatGridList);

        this._element = _element;
        this._dir = _dir;
        /**
         * The amount of space between tiles. This will be something like '5px' or '2em'.
         */

        this._gutter = '1px';
      }
      /**
       * Amount of columns in the grid list.
       * @return {?}
       */


      _createClass2(MatGridList, [{
        key: "ngOnInit",

        /**
         * @return {?}
         */
        value: function ngOnInit() {
          this._checkCols();

          this._checkRowHeight();
        }
        /**
         * The layout calculation is fairly cheap if nothing changes, so there's little cost
         * to run it frequently.
         * @return {?}
         */

      }, {
        key: "ngAfterContentChecked",
        value: function ngAfterContentChecked() {
          this._layoutTiles();
        }
        /**
         * Throw a friendly error if cols property is missing
         * @private
         * @return {?}
         */

      }, {
        key: "_checkCols",
        value: function _checkCols() {
          if (!this.cols) {
            throw Error("mat-grid-list: must pass in number of columns. " + "Example: <mat-grid-list cols=\"3\">");
          }
        }
        /**
         * Default to equal width:height if rowHeight property is missing
         * @private
         * @return {?}
         */

      }, {
        key: "_checkRowHeight",
        value: function _checkRowHeight() {
          if (!this._rowHeight) {
            this._setTileStyler('1:1');
          }
        }
        /**
         * Creates correct Tile Styler subtype based on rowHeight passed in by user
         * @private
         * @param {?} rowHeight
         * @return {?}
         */

      }, {
        key: "_setTileStyler",
        value: function _setTileStyler(rowHeight) {
          if (this._tileStyler) {
            this._tileStyler.reset(this);
          }

          if (rowHeight === MAT_FIT_MODE) {
            this._tileStyler = new FitTileStyler();
          } else if (rowHeight && rowHeight.indexOf(':') > -1) {
            this._tileStyler = new RatioTileStyler(rowHeight);
          } else {
            this._tileStyler = new FixedTileStyler(rowHeight);
          }
        }
        /**
         * Computes and applies the size and position for all children grid tiles.
         * @private
         * @return {?}
         */

      }, {
        key: "_layoutTiles",
        value: function _layoutTiles() {
          var _this244 = this;

          if (!this._tileCoordinator) {
            this._tileCoordinator = new TileCoordinator();
          }
          /** @type {?} */


          var tracker = this._tileCoordinator;
          /** @type {?} */

          var tiles = this._tiles.filter(
          /**
          * @param {?} tile
          * @return {?}
          */
          function (tile) {
            return !tile._gridList || tile._gridList === _this244;
          });
          /** @type {?} */


          var direction = this._dir ? this._dir.value : 'ltr';

          this._tileCoordinator.update(this.cols, tiles);

          this._tileStyler.init(this.gutterSize, tracker, this.cols, direction);

          tiles.forEach(
          /**
          * @param {?} tile
          * @param {?} index
          * @return {?}
          */
          function (tile, index) {
            /** @type {?} */
            var pos = tracker.positions[index];

            _this244._tileStyler.setStyle(tile, pos.row, pos.col);
          });

          this._setListStyle(this._tileStyler.getComputedHeight());
        }
        /**
         * Sets style on the main grid-list element, given the style name and value.
         * @param {?} style
         * @return {?}
         */

      }, {
        key: "_setListStyle",
        value: function _setListStyle(style) {
          if (style) {
            /** @type {?} */
            this._element.nativeElement.style[style[0]] = style[1];
          }
        }
      }, {
        key: "cols",
        get: function get() {
          return this._cols;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._cols = Math.max(1, Math.round(Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_2__["coerceNumberProperty"])(value)));
        }
        /**
         * Size of the grid list's gutter in pixels.
         * @return {?}
         */

      }, {
        key: "gutterSize",
        get: function get() {
          return this._gutter;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._gutter = "".concat(value == null ? '' : value);
        }
        /**
         * Set internal representation of row height from the user-provided value.
         * @return {?}
         */

      }, {
        key: "rowHeight",
        get: function get() {
          return this._rowHeight;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          /** @type {?} */
          var newValue = "".concat(value == null ? '' : value);

          if (newValue !== this._rowHeight) {
            this._rowHeight = newValue;

            this._setTileStyler(this._rowHeight);
          }
        }
      }]);

      return MatGridList;
    }();

    MatGridList.ɵfac = function MatGridList_Factory(t) {
      return new (t || MatGridList)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_3__["Directionality"], 8));
    };

    MatGridList.ɵcmp = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineComponent"]({
      type: MatGridList,
      selectors: [["mat-grid-list"]],
      contentQueries: function MatGridList_ContentQueries(rf, ctx, dirIndex) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵcontentQuery"](dirIndex, MatGridTile, true);
        }

        if (rf & 2) {
          var _t;

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵqueryRefresh"](_t = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵloadQuery"]()) && (ctx._tiles = _t);
        }
      },
      hostAttrs: [1, "mat-grid-list"],
      hostVars: 1,
      hostBindings: function MatGridList_HostBindings(rf, ctx) {
        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵattribute"]("cols", ctx.cols);
        }
      },
      inputs: {
        cols: "cols",
        gutterSize: "gutterSize",
        rowHeight: "rowHeight"
      },
      exportAs: ["matGridList"],
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([{
        provide: MAT_GRID_LIST,
        useExisting: MatGridList
      }])],
      ngContentSelectors: _c0,
      decls: 2,
      vars: 0,
      template: function MatGridList_Template(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵprojectionDef"]();

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](0, "div");

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵprojection"](1);

          _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"]();
        }
      },
      styles: [".mat-grid-list{display:block;position:relative}.mat-grid-tile{display:block;position:absolute;overflow:hidden}.mat-grid-tile .mat-figure{top:0;left:0;right:0;bottom:0;position:absolute;display:flex;align-items:center;justify-content:center;height:100%;padding:0;margin:0}.mat-grid-tile .mat-grid-tile-header,.mat-grid-tile .mat-grid-tile-footer{display:flex;align-items:center;height:48px;color:#fff;background:rgba(0,0,0,.38);overflow:hidden;padding:0 16px;position:absolute;left:0;right:0}.mat-grid-tile .mat-grid-tile-header>*,.mat-grid-tile .mat-grid-tile-footer>*{margin:0;padding:0;font-weight:normal;font-size:inherit}.mat-grid-tile .mat-grid-tile-header.mat-2-line,.mat-grid-tile .mat-grid-tile-footer.mat-2-line{height:68px}.mat-grid-tile .mat-grid-list-text{display:flex;flex-direction:column;width:100%;box-sizing:border-box;overflow:hidden}.mat-grid-tile .mat-grid-list-text>*{margin:0;padding:0;font-weight:normal;font-size:inherit}.mat-grid-tile .mat-grid-list-text:empty{display:none}.mat-grid-tile .mat-grid-tile-header{top:0}.mat-grid-tile .mat-grid-tile-footer{bottom:0}.mat-grid-tile .mat-grid-avatar{padding-right:16px}[dir=rtl] .mat-grid-tile .mat-grid-avatar{padding-right:0;padding-left:16px}.mat-grid-tile .mat-grid-avatar:empty{display:none}\n"],
      encapsulation: 2,
      changeDetection: 0
    });
    /** @nocollapse */

    MatGridList.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
      }, {
        type: _angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_3__["Directionality"],
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
        }]
      }];
    };

    MatGridList.propDecorators = {
      _tiles: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ContentChildren"],
        args: [MatGridTile, {
          descendants: true
        }]
      }],
      cols: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }],
      gutterSize: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }],
      rowHeight: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatGridList, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Component"],
        args: [{
          selector: 'mat-grid-list',
          exportAs: 'matGridList',
          template: "<div>\n  <ng-content></ng-content>\n</div>",
          host: {
            'class': 'mat-grid-list',
            // Ensures that the "cols" input value is reflected in the DOM. This is
            // needed for the grid-list harness.
            '[attr.cols]': 'cols'
          },
          providers: [{
            provide: MAT_GRID_LIST,
            useExisting: MatGridList
          }],
          changeDetection: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ChangeDetectionStrategy"].OnPush,
          encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewEncapsulation"].None,
          styles: [".mat-grid-list{display:block;position:relative}.mat-grid-tile{display:block;position:absolute;overflow:hidden}.mat-grid-tile .mat-figure{top:0;left:0;right:0;bottom:0;position:absolute;display:flex;align-items:center;justify-content:center;height:100%;padding:0;margin:0}.mat-grid-tile .mat-grid-tile-header,.mat-grid-tile .mat-grid-tile-footer{display:flex;align-items:center;height:48px;color:#fff;background:rgba(0,0,0,.38);overflow:hidden;padding:0 16px;position:absolute;left:0;right:0}.mat-grid-tile .mat-grid-tile-header>*,.mat-grid-tile .mat-grid-tile-footer>*{margin:0;padding:0;font-weight:normal;font-size:inherit}.mat-grid-tile .mat-grid-tile-header.mat-2-line,.mat-grid-tile .mat-grid-tile-footer.mat-2-line{height:68px}.mat-grid-tile .mat-grid-list-text{display:flex;flex-direction:column;width:100%;box-sizing:border-box;overflow:hidden}.mat-grid-tile .mat-grid-list-text>*{margin:0;padding:0;font-weight:normal;font-size:inherit}.mat-grid-tile .mat-grid-list-text:empty{display:none}.mat-grid-tile .mat-grid-tile-header{top:0}.mat-grid-tile .mat-grid-tile-footer{bottom:0}.mat-grid-tile .mat-grid-avatar{padding-right:16px}[dir=rtl] .mat-grid-tile .mat-grid-avatar{padding-right:0;padding-left:16px}.mat-grid-tile .mat-grid-avatar:empty{display:none}\n"]
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]
        }, {
          type: _angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_3__["Directionality"],
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Optional"]
          }]
        }];
      }, {
        cols: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }],
        gutterSize: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }],
        rowHeight: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Input"]
        }],
        _tiles: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ContentChildren"],
          args: [MatGridTile, {
            descendants: true
          }]
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/grid-list/grid-list-module.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var MatGridListModule = function MatGridListModule() {
      _classCallCheck(this, MatGridListModule);
    };

    MatGridListModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: MatGridListModule
    });
    MatGridListModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function MatGridListModule_Factory(t) {
        return new (t || MatGridListModule)();
      },
      imports: [[_angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatLineModule"], _angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatCommonModule"]], _angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatLineModule"], _angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatCommonModule"]]
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](MatGridListModule, {
        declarations: function declarations() {
          return [MatGridList, MatGridTile, MatGridTileText, MatGridTileHeaderCssMatStyler, MatGridTileFooterCssMatStyler, MatGridAvatarCssMatStyler];
        },
        imports: function imports() {
          return [_angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatLineModule"], _angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatCommonModule"]];
        },
        exports: function exports() {
          return [MatGridList, MatGridTile, MatGridTileText, _angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatLineModule"], _angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatCommonModule"], MatGridTileHeaderCssMatStyler, MatGridTileFooterCssMatStyler, MatGridAvatarCssMatStyler];
        }
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](MatGridListModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{
          imports: [_angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatLineModule"], _angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatCommonModule"]],
          exports: [MatGridList, MatGridTile, MatGridTileText, _angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatLineModule"], _angular_material_core__WEBPACK_IMPORTED_MODULE_1__["MatCommonModule"], MatGridTileHeaderCssMatStyler, MatGridTileFooterCssMatStyler, MatGridAvatarCssMatStyler],
          declarations: [MatGridList, MatGridTile, MatGridTileText, MatGridTileHeaderCssMatStyler, MatGridTileFooterCssMatStyler, MatGridAvatarCssMatStyler]
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/grid-list/public-api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=grid-list.js.map

    /***/

  },

  /***/
  "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/slider.js":
  /*!************************************************************************!*\
    !*** ./node_modules/@angular/material/__ivy_ngcc__/fesm2015/slider.js ***!
    \************************************************************************/

  /*! exports provided: MAT_SLIDER_VALUE_ACCESSOR, MatSlider, MatSliderChange, MatSliderModule */

  /***/
  function node_modulesAngularMaterial__ivy_ngcc__Fesm2015SliderJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MAT_SLIDER_VALUE_ACCESSOR", function () {
      return MAT_SLIDER_VALUE_ACCESSOR;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatSlider", function () {
      return MatSlider;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatSliderChange", function () {
      return MatSliderChange;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatSliderModule", function () {
      return MatSliderModule;
    });
    /* harmony import */


    var _angular_common__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/common */
    "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/common.js");
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var _angular_material_core__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! @angular/material/core */
    "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var _angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! @angular/cdk/a11y */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/a11y.js");
    /* harmony import */


    var _angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! @angular/cdk/bidi */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/bidi.js");
    /* harmony import */


    var _angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(
    /*! @angular/cdk/coercion */
    "./node_modules/@angular/cdk/fesm2015/coercion.js");
    /* harmony import */


    var _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(
    /*! @angular/cdk/keycodes */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/keycodes.js");
    /* harmony import */


    var _angular_forms__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(
    /*! @angular/forms */
    "./node_modules/@angular/forms/__ivy_ngcc__/fesm2015/forms.js");
    /* harmony import */


    var _angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(
    /*! @angular/platform-browser/animations */
    "./node_modules/@angular/platform-browser/__ivy_ngcc__/fesm2015/animations.js");
    /* harmony import */


    var _angular_cdk_platform__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(
    /*! @angular/cdk/platform */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/platform.js");
    /* harmony import */


    var rxjs__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(
    /*! rxjs */
    "./node_modules/rxjs/_esm2015/index.js");
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/slider/slider.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var _c0 = ["sliderWrapper"];
    var activeEventOptions = Object(_angular_cdk_platform__WEBPACK_IMPORTED_MODULE_9__["normalizePassiveListenerOptions"])({
      passive: false
    });
    /**
     * Visually, a 30px separation between tick marks looks best. This is very subjective but it is
     * the default separation we chose.
     * @type {?}
     */

    var MIN_AUTO_TICK_SEPARATION = 30;
    /**
     * The thumb gap size for a disabled slider.
     * @type {?}
     */

    var DISABLED_THUMB_GAP = 7;
    /**
     * The thumb gap size for a non-active slider at its minimum value.
     * @type {?}
     */

    var MIN_VALUE_NONACTIVE_THUMB_GAP = 7;
    /**
     * The thumb gap size for an active slider at its minimum value.
     * @type {?}
     */

    var MIN_VALUE_ACTIVE_THUMB_GAP = 10;
    /**
     * Provider Expression that allows mat-slider to register as a ControlValueAccessor.
     * This allows it to support [(ngModel)] and [formControl].
     * \@docs-private
     * @type {?}
     */

    var MAT_SLIDER_VALUE_ACCESSOR = {
      provide: _angular_forms__WEBPACK_IMPORTED_MODULE_7__["NG_VALUE_ACCESSOR"],
      useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["forwardRef"])(
      /**
      * @return {?}
      */
      function () {
        return MatSlider;
      }),
      multi: true
    };
    /**
     * A simple change event emitted by the MatSlider component.
     */

    var MatSliderChange = function MatSliderChange() {
      _classCallCheck(this, MatSliderChange);
    };

    if (false) {} // Boilerplate for applying mixins to MatSlider.

    /**
     * \@docs-private
     */


    var MatSliderBase =
    /**
     * @param {?} _elementRef
     */
    function MatSliderBase(_elementRef) {
      _classCallCheck(this, MatSliderBase);

      this._elementRef = _elementRef;
    };

    if (false) {}
    /** @type {?} */


    var _MatSliderMixinBase = Object(_angular_material_core__WEBPACK_IMPORTED_MODULE_2__["mixinTabIndex"])(Object(_angular_material_core__WEBPACK_IMPORTED_MODULE_2__["mixinColor"])(Object(_angular_material_core__WEBPACK_IMPORTED_MODULE_2__["mixinDisabled"])(MatSliderBase), 'accent'));
    /**
     * Allows users to select from a range of values by moving the slider thumb. It is similar in
     * behavior to the native `<input type="range">` element.
     */


    var MatSlider = /*#__PURE__*/function (_MatSliderMixinBase2) {
      _inherits(MatSlider, _MatSliderMixinBase2);

      var _super82 = _createSuper(MatSlider);

      /**
       * @param {?} elementRef
       * @param {?} _focusMonitor
       * @param {?} _changeDetectorRef
       * @param {?} _dir
       * @param {?} tabIndex
       * @param {?=} _animationMode
       * @param {?=} _ngZone
       * @param {?=} document
       */
      function MatSlider(elementRef, _focusMonitor, _changeDetectorRef, _dir, tabIndex, _animationMode, _ngZone,
      /** @breaking-change 11.0.0 make document required */
      document) {
        var _this245;

        _classCallCheck(this, MatSlider);

        _this245 = _super82.call(this, elementRef);
        _this245._focusMonitor = _focusMonitor;
        _this245._changeDetectorRef = _changeDetectorRef;
        _this245._dir = _dir;
        _this245._animationMode = _animationMode;
        _this245._ngZone = _ngZone;
        _this245._invert = false;
        _this245._max = 100;
        _this245._min = 0;
        _this245._step = 1;
        _this245._thumbLabel = false;
        _this245._tickInterval = 0;
        _this245._value = null;
        _this245._vertical = false;
        /**
         * Event emitted when the slider value has changed.
         */

        _this245.change = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"]();
        /**
         * Event emitted when the slider thumb moves.
         */

        _this245.input = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"]();
        /**
         * Emits when the raw value of the slider changes. This is here primarily
         * to facilitate the two-way binding for the `value` input.
         * \@docs-private
         */

        _this245.valueChange = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"]();
        /**
         * onTouch function registered via registerOnTouch (ControlValueAccessor).
         */

        _this245.onTouched =
        /**
        * @return {?}
        */
        function () {};

        _this245._percent = 0;
        /**
         * Whether or not the thumb is sliding.
         * Used to determine if there should be a transition for the thumb and fill track.
         */

        _this245._isSliding = false;
        /**
         * Whether or not the slider is active (clicked or sliding).
         * Used to shrink and grow the thumb as according to the Material Design spec.
         */

        _this245._isActive = false;
        /**
         * The size of a tick interval as a percentage of the size of the track.
         */

        _this245._tickIntervalPercent = 0;
        /**
         * The dimensions of the slider.
         */

        _this245._sliderDimensions = null;

        _this245._controlValueAccessorChangeFn =
        /**
        * @return {?}
        */
        function () {};
        /**
         * Subscription to the Directionality change EventEmitter.
         */


        _this245._dirChangeSubscription = rxjs__WEBPACK_IMPORTED_MODULE_10__["Subscription"].EMPTY;
        /**
         * Called when the user has put their pointer down on the slider.
         */

        _this245._pointerDown =
        /**
        * @param {?} event
        * @return {?}
        */
        function (event) {
          // Don't do anything if the slider is disabled or the
          // user is using anything other than the main mouse button.
          if (_this245.disabled || _this245._isSliding || !isTouchEvent(event) && event.button !== 0) {
            return;
          }

          _this245._runInsideZone(
          /**
          * @return {?}
          */
          function () {
            /** @type {?} */
            var oldValue = _this245.value;
            /** @type {?} */

            var pointerPosition = getPointerPositionOnPage(event);
            _this245._isSliding = true;
            _this245._lastPointerEvent = event;
            event.preventDefault();

            _this245._focusHostElement();

            _this245._onMouseenter(); // Simulate mouseenter in case this is a mobile device.


            _this245._bindGlobalEvents(event);

            _this245._focusHostElement();

            _this245._updateValueFromPosition(pointerPosition);

            _this245._valueOnSlideStart = _this245.value;
            _this245._pointerPositionOnStart = pointerPosition; // Emit a change and input event if the value changed.

            if (oldValue != _this245.value) {
              _this245._emitInputEvent();

              _this245._emitChangeEvent();
            }
          });
        };
        /**
         * Called when the user has moved their pointer after
         * starting to drag. Bound on the document level.
         */


        _this245._pointerMove =
        /**
        * @param {?} event
        * @return {?}
        */
        function (event) {
          if (_this245._isSliding) {
            // Prevent the slide from selecting anything else.
            event.preventDefault();
            /** @type {?} */

            var oldValue = _this245.value;
            _this245._lastPointerEvent = event;

            _this245._updateValueFromPosition(getPointerPositionOnPage(event)); // Native range elements always emit `input` events when the value changed while sliding.


            if (oldValue != _this245.value) {
              _this245._emitInputEvent();
            }
          }
        };
        /**
         * Called when the user has lifted their pointer. Bound on the document level.
         */


        _this245._pointerUp =
        /**
        * @param {?} event
        * @return {?}
        */
        function (event) {
          if (_this245._isSliding) {
            /** @type {?} */
            var pointerPositionOnStart = _this245._pointerPositionOnStart;
            /** @type {?} */

            var currentPointerPosition = getPointerPositionOnPage(event);
            event.preventDefault();

            _this245._removeGlobalEvents();

            _this245._valueOnSlideStart = _this245._pointerPositionOnStart = _this245._lastPointerEvent = null;
            _this245._isSliding = false;

            if (_this245._valueOnSlideStart != _this245.value && !_this245.disabled && pointerPositionOnStart && (pointerPositionOnStart.x !== currentPointerPosition.x || pointerPositionOnStart.y !== currentPointerPosition.y)) {
              _this245._emitChangeEvent();
            }
          }
        };
        /**
         * Called when the window has lost focus.
         */


        _this245._windowBlur =
        /**
        * @return {?}
        */
        function () {
          // If the window is blurred while dragging we need to stop dragging because the
          // browser won't dispatch the `mouseup` and `touchend` events anymore.
          if (_this245._lastPointerEvent) {
            _this245._pointerUp(_this245._lastPointerEvent);
          }
        };

        _this245._document = document;
        _this245.tabIndex = parseInt(tabIndex) || 0;

        _this245._runOutsizeZone(
        /**
        * @return {?}
        */
        function () {
          /** @type {?} */
          var element = elementRef.nativeElement;
          element.addEventListener('mousedown', _this245._pointerDown, activeEventOptions);
          element.addEventListener('touchstart', _this245._pointerDown, activeEventOptions);
        });

        return _this245;
      }
      /**
       * Whether the slider is inverted.
       * @return {?}
       */


      _createClass2(MatSlider, [{
        key: "focus",

        /**
         * set focus to the host element
         * @param {?=} options
         * @return {?}
         */
        value: function focus(options) {
          this._focusHostElement(options);
        }
        /**
         * blur the host element
         * @return {?}
         */

      }, {
        key: "blur",
        value: function blur() {
          this._blurHostElement();
        }
        /**
         * The percentage of the slider that coincides with the value.
         * @return {?}
         */

      }, {
        key: "_shouldInvertMouseCoords",

        /**
         * Whether mouse events should be converted to a slider position by calculating their distance
         * from the right or bottom edge of the slider as opposed to the top or left.
         * @return {?}
         */
        value: function _shouldInvertMouseCoords() {
          return this._getDirection() == 'rtl' && !this.vertical ? !this._invertAxis : this._invertAxis;
        }
        /**
         * The language direction for this slider element.
         * @private
         * @return {?}
         */

      }, {
        key: "_getDirection",
        value: function _getDirection() {
          return this._dir && this._dir.value == 'rtl' ? 'rtl' : 'ltr';
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnInit",
        value: function ngOnInit() {
          var _this246 = this;

          this._focusMonitor.monitor(this._elementRef, true).subscribe(
          /**
          * @param {?} origin
          * @return {?}
          */
          function (origin) {
            _this246._isActive = !!origin && origin !== 'keyboard';

            _this246._changeDetectorRef.detectChanges();
          });

          if (this._dir) {
            this._dirChangeSubscription = this._dir.change.subscribe(
            /**
            * @return {?}
            */
            function () {
              _this246._changeDetectorRef.markForCheck();
            });
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          /** @type {?} */
          var element = this._elementRef.nativeElement;
          element.removeEventListener('mousedown', this._pointerDown, activeEventOptions);
          element.removeEventListener('touchstart', this._pointerDown, activeEventOptions);
          this._lastPointerEvent = null;

          this._removeGlobalEvents();

          this._focusMonitor.stopMonitoring(this._elementRef);

          this._dirChangeSubscription.unsubscribe();
        }
        /**
         * @return {?}
         */

      }, {
        key: "_onMouseenter",
        value: function _onMouseenter() {
          if (this.disabled) {
            return;
          } // We save the dimensions of the slider here so we can use them to update the spacing of the
          // ticks and determine where on the slider click and slide events happen.


          this._sliderDimensions = this._getSliderDimensions();

          this._updateTickIntervalPercent();
        }
        /**
         * @return {?}
         */

      }, {
        key: "_onFocus",
        value: function _onFocus() {
          // We save the dimensions of the slider here so we can use them to update the spacing of the
          // ticks and determine where on the slider click and slide events happen.
          this._sliderDimensions = this._getSliderDimensions();

          this._updateTickIntervalPercent();
        }
        /**
         * @return {?}
         */

      }, {
        key: "_onBlur",
        value: function _onBlur() {
          this.onTouched();
        }
        /**
         * @param {?} event
         * @return {?}
         */

      }, {
        key: "_onKeydown",
        value: function _onKeydown(event) {
          if (this.disabled || Object(_angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_6__["hasModifierKey"])(event)) {
            return;
          }
          /** @type {?} */


          var oldValue = this.value;

          switch (event.keyCode) {
            case _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_6__["PAGE_UP"]:
              this._increment(10);

              break;

            case _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_6__["PAGE_DOWN"]:
              this._increment(-10);

              break;

            case _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_6__["END"]:
              this.value = this.max;
              break;

            case _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_6__["HOME"]:
              this.value = this.min;
              break;

            case _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_6__["LEFT_ARROW"]:
              // NOTE: For a sighted user it would make more sense that when they press an arrow key on an
              // inverted slider the thumb moves in that direction. However for a blind user, nothing
              // about the slider indicates that it is inverted. They will expect left to be decrement,
              // regardless of how it appears on the screen. For speakers ofRTL languages, they probably
              // expect left to mean increment. Therefore we flip the meaning of the side arrow keys for
              // RTL. For inverted sliders we prefer a good a11y experience to having it "look right" for
              // sighted users, therefore we do not swap the meaning.
              this._increment(this._getDirection() == 'rtl' ? 1 : -1);

              break;

            case _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_6__["UP_ARROW"]:
              this._increment(1);

              break;

            case _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_6__["RIGHT_ARROW"]:
              // See comment on LEFT_ARROW about the conditions under which we flip the meaning.
              this._increment(this._getDirection() == 'rtl' ? -1 : 1);

              break;

            case _angular_cdk_keycodes__WEBPACK_IMPORTED_MODULE_6__["DOWN_ARROW"]:
              this._increment(-1);

              break;

            default:
              // Return if the key is not one that we explicitly handle to avoid calling preventDefault on
              // it.
              return;
          }

          if (oldValue != this.value) {
            this._emitInputEvent();

            this._emitChangeEvent();
          }

          this._isSliding = true;
          event.preventDefault();
        }
        /**
         * @return {?}
         */

      }, {
        key: "_onKeyup",
        value: function _onKeyup() {
          this._isSliding = false;
        }
        /**
         * Use defaultView of injected document if available or fallback to global window reference
         * @private
         * @return {?}
         */

      }, {
        key: "_getWindow",
        value: function _getWindow() {
          var _a;

          return ((_a = this._document) === null || _a === void 0 ? void 0 : _a.defaultView) || window;
        }
        /**
         * Binds our global move and end events. They're bound at the document level and only while
         * dragging so that the user doesn't have to keep their pointer exactly over the slider
         * as they're swiping across the screen.
         * @private
         * @param {?} triggerEvent
         * @return {?}
         */

      }, {
        key: "_bindGlobalEvents",
        value: function _bindGlobalEvents(triggerEvent) {
          // Note that we bind the events to the `document`, because it allows us to capture
          // drag cancel events where the user's pointer is outside the browser window.

          /** @type {?} */
          var document = this._document;

          if (typeof document !== 'undefined' && document) {
            /** @type {?} */
            var isTouch = isTouchEvent(triggerEvent);
            /** @type {?} */

            var moveEventName = isTouch ? 'touchmove' : 'mousemove';
            /** @type {?} */

            var endEventName = isTouch ? 'touchend' : 'mouseup';
            document.addEventListener(moveEventName, this._pointerMove, activeEventOptions);
            document.addEventListener(endEventName, this._pointerUp, activeEventOptions);

            if (isTouch) {
              document.addEventListener('touchcancel', this._pointerUp, activeEventOptions);
            }
          }
          /** @type {?} */


          var window = this._getWindow();

          if (typeof window !== 'undefined' && window) {
            window.addEventListener('blur', this._windowBlur);
          }
        }
        /**
         * Removes any global event listeners that we may have added.
         * @private
         * @return {?}
         */

      }, {
        key: "_removeGlobalEvents",
        value: function _removeGlobalEvents() {
          /** @type {?} */
          var document = this._document;

          if (typeof document !== 'undefined' && document) {
            document.removeEventListener('mousemove', this._pointerMove, activeEventOptions);
            document.removeEventListener('mouseup', this._pointerUp, activeEventOptions);
            document.removeEventListener('touchmove', this._pointerMove, activeEventOptions);
            document.removeEventListener('touchend', this._pointerUp, activeEventOptions);
            document.removeEventListener('touchcancel', this._pointerUp, activeEventOptions);
          }
          /** @type {?} */


          var window = this._getWindow();

          if (typeof window !== 'undefined' && window) {
            window.removeEventListener('blur', this._windowBlur);
          }
        }
        /**
         * Increments the slider by the given number of steps (negative number decrements).
         * @private
         * @param {?} numSteps
         * @return {?}
         */

      }, {
        key: "_increment",
        value: function _increment(numSteps) {
          this.value = this._clamp((this.value || 0) + this.step * numSteps, this.min, this.max);
        }
        /**
         * Calculate the new value from the new physical location. The value will always be snapped.
         * @private
         * @param {?} pos
         * @return {?}
         */

      }, {
        key: "_updateValueFromPosition",
        value: function _updateValueFromPosition(pos) {
          if (!this._sliderDimensions) {
            return;
          }
          /** @type {?} */


          var offset = this.vertical ? this._sliderDimensions.top : this._sliderDimensions.left;
          /** @type {?} */

          var size = this.vertical ? this._sliderDimensions.height : this._sliderDimensions.width;
          /** @type {?} */

          var posComponent = this.vertical ? pos.y : pos.x; // The exact value is calculated from the event and used to find the closest snap value.

          /** @type {?} */

          var percent = this._clamp((posComponent - offset) / size);

          if (this._shouldInvertMouseCoords()) {
            percent = 1 - percent;
          } // Since the steps may not divide cleanly into the max value, if the user
          // slid to 0 or 100 percent, we jump to the min/max value. This approach
          // is slightly more intuitive than using `Math.ceil` below, because it
          // follows the user's pointer closer.


          if (percent === 0) {
            this.value = this.min;
          } else if (percent === 1) {
            this.value = this.max;
          } else {
            /** @type {?} */
            var exactValue = this._calculateValue(percent); // This calculation finds the closest step by finding the closest
            // whole number divisible by the step relative to the min.

            /** @type {?} */


            var closestValue = Math.round((exactValue - this.min) / this.step) * this.step + this.min; // The value needs to snap to the min and max.

            this.value = this._clamp(closestValue, this.min, this.max);
          }
        }
        /**
         * Emits a change event if the current value is different from the last emitted value.
         * @private
         * @return {?}
         */

      }, {
        key: "_emitChangeEvent",
        value: function _emitChangeEvent() {
          this._controlValueAccessorChangeFn(this.value);

          this.valueChange.emit(this.value);
          this.change.emit(this._createChangeEvent());
        }
        /**
         * Emits an input event when the current value is different from the last emitted value.
         * @private
         * @return {?}
         */

      }, {
        key: "_emitInputEvent",
        value: function _emitInputEvent() {
          this.input.emit(this._createChangeEvent());
        }
        /**
         * Updates the amount of space between ticks as a percentage of the width of the slider.
         * @private
         * @return {?}
         */

      }, {
        key: "_updateTickIntervalPercent",
        value: function _updateTickIntervalPercent() {
          if (!this.tickInterval || !this._sliderDimensions) {
            return;
          }

          if (this.tickInterval == 'auto') {
            /** @type {?} */
            var trackSize = this.vertical ? this._sliderDimensions.height : this._sliderDimensions.width;
            /** @type {?} */

            var pixelsPerStep = trackSize * this.step / (this.max - this.min);
            /** @type {?} */

            var stepsPerTick = Math.ceil(MIN_AUTO_TICK_SEPARATION / pixelsPerStep);
            /** @type {?} */

            var pixelsPerTick = stepsPerTick * this.step;
            this._tickIntervalPercent = pixelsPerTick / trackSize;
          } else {
            this._tickIntervalPercent = this.tickInterval * this.step / (this.max - this.min);
          }
        }
        /**
         * Creates a slider change object from the specified value.
         * @private
         * @param {?=} value
         * @return {?}
         */

      }, {
        key: "_createChangeEvent",
        value: function _createChangeEvent() {
          var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : this.value;

          /** @type {?} */
          var event = new MatSliderChange();
          event.source = this;
          event.value = value;
          return event;
        }
        /**
         * Calculates the percentage of the slider that a value is.
         * @private
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "_calculatePercentage",
        value: function _calculatePercentage(value) {
          return ((value || 0) - this.min) / (this.max - this.min);
        }
        /**
         * Calculates the value a percentage of the slider corresponds to.
         * @private
         * @param {?} percentage
         * @return {?}
         */

      }, {
        key: "_calculateValue",
        value: function _calculateValue(percentage) {
          return this.min + percentage * (this.max - this.min);
        }
        /**
         * Return a number between two numbers.
         * @private
         * @param {?} value
         * @param {?=} min
         * @param {?=} max
         * @return {?}
         */

      }, {
        key: "_clamp",
        value: function _clamp(value) {
          var min = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
          var max = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 1;
          return Math.max(min, Math.min(value, max));
        }
        /**
         * Get the bounding client rect of the slider track element.
         * The track is used rather than the native element to ignore the extra space that the thumb can
         * take up.
         * @private
         * @return {?}
         */

      }, {
        key: "_getSliderDimensions",
        value: function _getSliderDimensions() {
          return this._sliderWrapper ? this._sliderWrapper.nativeElement.getBoundingClientRect() : null;
        }
        /**
         * Focuses the native element.
         * Currently only used to allow a blur event to fire but will be used with keyboard input later.
         * @private
         * @param {?=} options
         * @return {?}
         */

      }, {
        key: "_focusHostElement",
        value: function _focusHostElement(options) {
          this._elementRef.nativeElement.focus(options);
        }
        /**
         * Blurs the native element.
         * @private
         * @return {?}
         */

      }, {
        key: "_blurHostElement",
        value: function _blurHostElement() {
          this._elementRef.nativeElement.blur();
        }
        /**
         * Runs a callback inside of the NgZone, if possible.
         * @private
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "_runInsideZone",
        value: function _runInsideZone(fn) {
          // @breaking-change 9.0.0 Remove this function once `_ngZone` is a required parameter.
          this._ngZone ? this._ngZone.run(fn) : fn();
        }
        /**
         * Runs a callback outside of the NgZone, if possible.
         * @private
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "_runOutsizeZone",
        value: function _runOutsizeZone(fn) {
          // @breaking-change 9.0.0 Remove this function once `_ngZone` is a required parameter.
          this._ngZone ? this._ngZone.runOutsideAngular(fn) : fn();
        }
        /**
         * Sets the model value. Implemented as part of ControlValueAccessor.
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "writeValue",
        value: function writeValue(value) {
          this.value = value;
        }
        /**
         * Registers a callback to be triggered when the value has changed.
         * Implemented as part of ControlValueAccessor.
         * @param {?} fn Callback to be registered.
         * @return {?}
         */

      }, {
        key: "registerOnChange",
        value: function registerOnChange(fn) {
          this._controlValueAccessorChangeFn = fn;
        }
        /**
         * Registers a callback to be triggered when the component is touched.
         * Implemented as part of ControlValueAccessor.
         * @param {?} fn Callback to be registered.
         * @return {?}
         */

      }, {
        key: "registerOnTouched",
        value: function registerOnTouched(fn) {
          this.onTouched = fn;
        }
        /**
         * Sets whether the component should be disabled.
         * Implemented as part of ControlValueAccessor.
         * @param {?} isDisabled
         * @return {?}
         */

      }, {
        key: "setDisabledState",
        value: function setDisabledState(isDisabled) {
          this.disabled = isDisabled;
        }
      }, {
        key: "invert",
        get: function get() {
          return this._invert;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._invert = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceBooleanProperty"])(value);
        }
        /**
         * The maximum value that the slider can have.
         * @return {?}
         */

      }, {
        key: "max",
        get: function get() {
          return this._max;
        }
        /**
         * @param {?} v
         * @return {?}
         */
        ,
        set: function set(v) {
          this._max = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceNumberProperty"])(v, this._max);
          this._percent = this._calculatePercentage(this._value); // Since this also modifies the percentage, we need to let the change detection know.

          this._changeDetectorRef.markForCheck();
        }
        /**
         * The minimum value that the slider can have.
         * @return {?}
         */

      }, {
        key: "min",
        get: function get() {
          return this._min;
        }
        /**
         * @param {?} v
         * @return {?}
         */
        ,
        set: function set(v) {
          this._min = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceNumberProperty"])(v, this._min); // If the value wasn't explicitly set by the user, set it to the min.

          if (this._value === null) {
            this.value = this._min;
          }

          this._percent = this._calculatePercentage(this._value); // Since this also modifies the percentage, we need to let the change detection know.

          this._changeDetectorRef.markForCheck();
        }
        /**
         * The values at which the thumb will snap.
         * @return {?}
         */

      }, {
        key: "step",
        get: function get() {
          return this._step;
        }
        /**
         * @param {?} v
         * @return {?}
         */
        ,
        set: function set(v) {
          this._step = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceNumberProperty"])(v, this._step);

          if (this._step % 1 !== 0) {
            this._roundToDecimal =
            /** @type {?} */
            this._step.toString().split('.').pop().length;
          } // Since this could modify the label, we need to notify the change detection.


          this._changeDetectorRef.markForCheck();
        }
        /**
         * Whether or not to show the thumb label.
         * @return {?}
         */

      }, {
        key: "thumbLabel",
        get: function get() {
          return this._thumbLabel;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._thumbLabel = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceBooleanProperty"])(value);
        }
        /**
         * How often to show ticks. Relative to the step so that a tick always appears on a step.
         * Ex: Tick interval of 4 with a step of 3 will draw a tick every 4 steps (every 12 values).
         * @return {?}
         */

      }, {
        key: "tickInterval",
        get: function get() {
          return this._tickInterval;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          if (value === 'auto') {
            this._tickInterval = 'auto';
          } else if (typeof value === 'number' || typeof value === 'string') {
            this._tickInterval = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceNumberProperty"])(value,
            /** @type {?} */
            this._tickInterval);
          } else {
            this._tickInterval = 0;
          }
        }
        /**
         * Value of the slider.
         * @return {?}
         */

      }, {
        key: "value",
        get: function get() {
          // If the value needs to be read and it is still uninitialized, initialize it to the min.
          if (this._value === null) {
            this.value = this._min;
          }

          return this._value;
        }
        /**
         * @param {?} v
         * @return {?}
         */
        ,
        set: function set(v) {
          if (v !== this._value) {
            /** @type {?} */
            var value = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceNumberProperty"])(v); // While incrementing by a decimal we can end up with values like 33.300000000000004.
            // Truncate it to ensure that it matches the label and to make it easier to work with.

            if (this._roundToDecimal) {
              value = parseFloat(value.toFixed(this._roundToDecimal));
            }

            this._value = value;
            this._percent = this._calculatePercentage(this._value); // Since this also modifies the percentage, we need to let the change detection know.

            this._changeDetectorRef.markForCheck();
          }
        }
        /**
         * Whether the slider is vertical.
         * @return {?}
         */

      }, {
        key: "vertical",
        get: function get() {
          return this._vertical;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          this._vertical = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__["coerceBooleanProperty"])(value);
        }
        /**
         * The value to be used for display purposes.
         * @return {?}
         */

      }, {
        key: "displayValue",
        get: function get() {
          if (this.displayWith) {
            // Value is never null but since setters and getters cannot have
            // different types, the value getter is also typed to return null.
            return this.displayWith(
            /** @type {?} */
            this.value);
          } // Note that this could be improved further by rounding something like 0.999 to 1 or
          // 0.899 to 0.9, however it is very performance sensitive, because it gets called on
          // every change detection cycle.


          if (this._roundToDecimal && this.value && this.value % 1 !== 0) {
            return this.value.toFixed(this._roundToDecimal);
          }

          return this.value || 0;
        }
      }, {
        key: "percent",
        get: function get() {
          return this._clamp(this._percent);
        }
        /**
         * Whether the axis of the slider is inverted.
         * (i.e. whether moving the thumb in the positive x or y direction decreases the slider's value).
         * @return {?}
         */

      }, {
        key: "_invertAxis",
        get: function get() {
          // Standard non-inverted mode for a vertical slider should be dragging the thumb from bottom to
          // top. However from a y-axis standpoint this is inverted.
          return this.vertical ? !this.invert : this.invert;
        }
        /**
         * Whether the slider is at its minimum value.
         * @return {?}
         */

      }, {
        key: "_isMinValue",
        get: function get() {
          return this.percent === 0;
        }
        /**
         * The amount of space to leave between the slider thumb and the track fill & track background
         * elements.
         * @return {?}
         */

      }, {
        key: "_thumbGap",
        get: function get() {
          if (this.disabled) {
            return DISABLED_THUMB_GAP;
          }

          if (this._isMinValue && !this.thumbLabel) {
            return this._isActive ? MIN_VALUE_ACTIVE_THUMB_GAP : MIN_VALUE_NONACTIVE_THUMB_GAP;
          }

          return 0;
        }
        /**
         * CSS styles for the track background element.
         * @return {?}
         */

      }, {
        key: "_trackBackgroundStyles",
        get: function get() {
          /** @type {?} */
          var axis = this.vertical ? 'Y' : 'X';
          /** @type {?} */

          var scale = this.vertical ? "1, ".concat(1 - this.percent, ", 1") : "".concat(1 - this.percent, ", 1, 1");
          /** @type {?} */

          var sign = this._shouldInvertMouseCoords() ? '-' : '';
          return {
            // scale3d avoids some rendering issues in Chrome. See #12071.
            transform: "translate".concat(axis, "(").concat(sign).concat(this._thumbGap, "px) scale3d(").concat(scale, ")")
          };
        }
        /**
         * CSS styles for the track fill element.
         * @return {?}
         */

      }, {
        key: "_trackFillStyles",
        get: function get() {
          /** @type {?} */
          var percent = this.percent;
          /** @type {?} */

          var axis = this.vertical ? 'Y' : 'X';
          /** @type {?} */

          var scale = this.vertical ? "1, ".concat(percent, ", 1") : "".concat(percent, ", 1, 1");
          /** @type {?} */

          var sign = this._shouldInvertMouseCoords() ? '' : '-';
          return {
            // scale3d avoids some rendering issues in Chrome. See #12071.
            transform: "translate".concat(axis, "(").concat(sign).concat(this._thumbGap, "px) scale3d(").concat(scale, ")"),
            // iOS Safari has a bug where it won't re-render elements which start of as `scale(0)` until
            // something forces a style recalculation on it. Since we'll end up with `scale(0)` when
            // the value of the slider is 0, we can easily get into this situation. We force a
            // recalculation by changing the element's `display` when it goes from 0 to any other value.
            display: percent === 0 ? 'none' : ''
          };
        }
        /**
         * CSS styles for the ticks container element.
         * @return {?}
         */

      }, {
        key: "_ticksContainerStyles",
        get: function get() {
          /** @type {?} */
          var axis = this.vertical ? 'Y' : 'X'; // For a horizontal slider in RTL languages we push the ticks container off the left edge
          // instead of the right edge to avoid causing a horizontal scrollbar to appear.

          /** @type {?} */

          var sign = !this.vertical && this._getDirection() == 'rtl' ? '' : '-';
          /** @type {?} */

          var offset = this._tickIntervalPercent / 2 * 100;
          return {
            'transform': "translate".concat(axis, "(").concat(sign).concat(offset, "%)")
          };
        }
        /**
         * CSS styles for the ticks element.
         * @return {?}
         */

      }, {
        key: "_ticksStyles",
        get: function get() {
          /** @type {?} */
          var tickSize = this._tickIntervalPercent * 100;
          /** @type {?} */

          var backgroundSize = this.vertical ? "2px ".concat(tickSize, "%") : "".concat(tickSize, "% 2px");
          /** @type {?} */

          var axis = this.vertical ? 'Y' : 'X'; // Depending on the direction we pushed the ticks container, push the ticks the opposite
          // direction to re-center them but clip off the end edge. In RTL languages we need to flip the
          // ticks 180 degrees so we're really cutting off the end edge abd not the start.

          /** @type {?} */

          var sign = !this.vertical && this._getDirection() == 'rtl' ? '-' : '';
          /** @type {?} */

          var rotate = !this.vertical && this._getDirection() == 'rtl' ? ' rotate(180deg)' : '';
          /** @type {?} */

          var styles = {
            'backgroundSize': backgroundSize,
            // Without translateZ ticks sometimes jitter as the slider moves on Chrome & Firefox.
            'transform': "translateZ(0) translate".concat(axis, "(").concat(sign).concat(tickSize / 2, "%)").concat(rotate)
          };

          if (this._isMinValue && this._thumbGap) {
            /** @type {?} */
            var side;

            if (this.vertical) {
              side = this._invertAxis ? 'Bottom' : 'Top';
            } else {
              side = this._invertAxis ? 'Right' : 'Left';
            }

            styles["padding".concat(side)] = "".concat(this._thumbGap, "px");
          }

          return styles;
        }
        /**
         * @return {?}
         */

      }, {
        key: "_thumbContainerStyles",
        get: function get() {
          /** @type {?} */
          var axis = this.vertical ? 'Y' : 'X'; // For a horizontal slider in RTL languages we push the thumb container off the left edge
          // instead of the right edge to avoid causing a horizontal scrollbar to appear.

          /** @type {?} */

          var invertOffset = this._getDirection() == 'rtl' && !this.vertical ? !this._invertAxis : this._invertAxis;
          /** @type {?} */

          var offset = (invertOffset ? this.percent : 1 - this.percent) * 100;
          return {
            'transform': "translate".concat(axis, "(-").concat(offset, "%)")
          };
        }
      }]);

      return MatSlider;
    }(_MatSliderMixinBase);

    MatSlider.ɵfac = function MatSlider_Factory(t) {
      return new (t || MatSlider)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_3__["FocusMonitor"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["ChangeDetectorRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_4__["Directionality"], 8), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinjectAttribute"]('tabindex'), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_8__["ANIMATION_MODULE_TYPE"], 8), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"], 8));
    };

    MatSlider.ɵcmp = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineComponent"]({
      type: MatSlider,
      selectors: [["mat-slider"]],
      viewQuery: function MatSlider_Query(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵviewQuery"](_c0, true);
        }

        if (rf & 2) {
          var _t;

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵqueryRefresh"](_t = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵloadQuery"]()) && (ctx._sliderWrapper = _t.first);
        }
      },
      hostAttrs: ["role", "slider", 1, "mat-slider", "mat-focus-indicator"],
      hostVars: 28,
      hostBindings: function MatSlider_HostBindings(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵlistener"]("focus", function MatSlider_focus_HostBindingHandler() {
            return ctx._onFocus();
          })("blur", function MatSlider_blur_HostBindingHandler() {
            return ctx._onBlur();
          })("keydown", function MatSlider_keydown_HostBindingHandler($event) {
            return ctx._onKeydown($event);
          })("keyup", function MatSlider_keyup_HostBindingHandler() {
            return ctx._onKeyup();
          })("mouseenter", function MatSlider_mouseenter_HostBindingHandler() {
            return ctx._onMouseenter();
          })("selectstart", function MatSlider_selectstart_HostBindingHandler($event) {
            return $event.preventDefault();
          });
        }

        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵhostProperty"]("tabIndex", ctx.tabIndex);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵattribute"]("aria-disabled", ctx.disabled)("aria-valuemax", ctx.max)("aria-valuemin", ctx.min)("aria-valuenow", ctx.value)("aria-orientation", ctx.vertical ? "vertical" : "horizontal");

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵclassProp"]("mat-slider-disabled", ctx.disabled)("mat-slider-has-ticks", ctx.tickInterval)("mat-slider-horizontal", !ctx.vertical)("mat-slider-axis-inverted", ctx._invertAxis)("mat-slider-invert-mouse-coords", ctx._shouldInvertMouseCoords())("mat-slider-sliding", ctx._isSliding)("mat-slider-thumb-label-showing", ctx.thumbLabel)("mat-slider-vertical", ctx.vertical)("mat-slider-min-value", ctx._isMinValue)("mat-slider-hide-last-tick", ctx.disabled || ctx._isMinValue && ctx._thumbGap && ctx._invertAxis)("_mat-animation-noopable", ctx._animationMode === "NoopAnimations");
        }
      },
      inputs: {
        disabled: "disabled",
        color: "color",
        tabIndex: "tabIndex",
        invert: "invert",
        max: "max",
        min: "min",
        value: "value",
        step: "step",
        thumbLabel: "thumbLabel",
        tickInterval: "tickInterval",
        vertical: "vertical",
        displayWith: "displayWith"
      },
      outputs: {
        change: "change",
        input: "input",
        valueChange: "valueChange"
      },
      exportAs: ["matSlider"],
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵProvidersFeature"]([MAT_SLIDER_VALUE_ACCESSOR]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵInheritDefinitionFeature"]],
      decls: 13,
      vars: 6,
      consts: [[1, "mat-slider-wrapper"], ["sliderWrapper", ""], [1, "mat-slider-track-wrapper"], [1, "mat-slider-track-background", 3, "ngStyle"], [1, "mat-slider-track-fill", 3, "ngStyle"], [1, "mat-slider-ticks-container", 3, "ngStyle"], [1, "mat-slider-ticks", 3, "ngStyle"], [1, "mat-slider-thumb-container", 3, "ngStyle"], [1, "mat-slider-focus-ring"], [1, "mat-slider-thumb"], [1, "mat-slider-thumb-label"], [1, "mat-slider-thumb-label-text"]],
      template: function MatSlider_Template(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelementStart"](0, "div", 0, 1);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelementStart"](2, "div", 2);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelement"](3, "div", 3);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelement"](4, "div", 4);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelementEnd"]();

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelementStart"](5, "div", 5);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelement"](6, "div", 6);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelementEnd"]();

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelementStart"](7, "div", 7);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelement"](8, "div", 8);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelement"](9, "div", 9);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelementStart"](10, "div", 10);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelementStart"](11, "span", 11);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵtext"](12);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelementEnd"]();

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelementEnd"]();

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelementEnd"]();

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelementEnd"]();
        }

        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵadvance"](3);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵproperty"]("ngStyle", ctx._trackBackgroundStyles);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵadvance"](1);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵproperty"]("ngStyle", ctx._trackFillStyles);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵadvance"](1);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵproperty"]("ngStyle", ctx._ticksContainerStyles);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵadvance"](1);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵproperty"]("ngStyle", ctx._ticksStyles);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵadvance"](1);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵproperty"]("ngStyle", ctx._thumbContainerStyles);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵadvance"](5);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵtextInterpolate"](ctx.displayValue);
        }
      },
      directives: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["NgStyle"]],
      styles: [".mat-slider{display:inline-block;position:relative;box-sizing:border-box;padding:8px;outline:none;vertical-align:middle}.mat-slider:not(.mat-slider-disabled):active,.mat-slider.mat-slider-sliding:not(.mat-slider-disabled){cursor:-webkit-grabbing;cursor:grabbing}.mat-slider-wrapper{position:absolute}.mat-slider-track-wrapper{position:absolute;top:0;left:0;overflow:hidden}.mat-slider-track-fill{position:absolute;transform-origin:0 0;transition:transform 400ms cubic-bezier(0.25, 0.8, 0.25, 1),background-color 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-slider-track-background{position:absolute;transform-origin:100% 100%;transition:transform 400ms cubic-bezier(0.25, 0.8, 0.25, 1),background-color 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-slider-ticks-container{position:absolute;left:0;top:0;overflow:hidden}.mat-slider-ticks{background-repeat:repeat;background-clip:content-box;box-sizing:border-box;opacity:0;transition:opacity 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-slider-thumb-container{position:absolute;z-index:1;transition:transform 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-slider-focus-ring{position:absolute;width:30px;height:30px;border-radius:50%;transform:scale(0);opacity:0;transition:transform 400ms cubic-bezier(0.25, 0.8, 0.25, 1),background-color 400ms cubic-bezier(0.25, 0.8, 0.25, 1),opacity 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-slider.cdk-keyboard-focused .mat-slider-focus-ring,.mat-slider.cdk-program-focused .mat-slider-focus-ring{transform:scale(1);opacity:1}.mat-slider:not(.mat-slider-disabled):not(.mat-slider-sliding) .mat-slider-thumb-label,.mat-slider:not(.mat-slider-disabled):not(.mat-slider-sliding) .mat-slider-thumb{cursor:-webkit-grab;cursor:grab}.mat-slider-thumb{position:absolute;right:-10px;bottom:-10px;box-sizing:border-box;width:20px;height:20px;border:3px solid transparent;border-radius:50%;transform:scale(0.7);transition:transform 400ms cubic-bezier(0.25, 0.8, 0.25, 1),background-color 400ms cubic-bezier(0.25, 0.8, 0.25, 1),border-color 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-slider-thumb-label{display:none;align-items:center;justify-content:center;position:absolute;width:28px;height:28px;border-radius:50%;transition:transform 400ms cubic-bezier(0.25, 0.8, 0.25, 1),border-radius 400ms cubic-bezier(0.25, 0.8, 0.25, 1),background-color 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}.cdk-high-contrast-active .mat-slider-thumb-label{outline:solid 1px}.mat-slider-thumb-label-text{z-index:1;opacity:0;transition:opacity 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-slider-sliding .mat-slider-track-fill,.mat-slider-sliding .mat-slider-track-background,.mat-slider-sliding .mat-slider-thumb-container{transition-duration:0ms}.mat-slider-has-ticks .mat-slider-wrapper::after{content:\"\";position:absolute;border-width:0;border-style:solid;opacity:0;transition:opacity 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-slider-has-ticks.cdk-focused:not(.mat-slider-hide-last-tick) .mat-slider-wrapper::after,.mat-slider-has-ticks:hover:not(.mat-slider-hide-last-tick) .mat-slider-wrapper::after{opacity:1}.mat-slider-has-ticks.cdk-focused:not(.mat-slider-disabled) .mat-slider-ticks,.mat-slider-has-ticks:hover:not(.mat-slider-disabled) .mat-slider-ticks{opacity:1}.mat-slider-thumb-label-showing .mat-slider-focus-ring{display:none}.mat-slider-thumb-label-showing .mat-slider-thumb-label{display:flex}.mat-slider-axis-inverted .mat-slider-track-fill{transform-origin:100% 100%}.mat-slider-axis-inverted .mat-slider-track-background{transform-origin:0 0}.mat-slider:not(.mat-slider-disabled).cdk-focused.mat-slider-thumb-label-showing .mat-slider-thumb{transform:scale(0)}.mat-slider:not(.mat-slider-disabled).cdk-focused .mat-slider-thumb-label{border-radius:50% 50% 0}.mat-slider:not(.mat-slider-disabled).cdk-focused .mat-slider-thumb-label-text{opacity:1}.mat-slider:not(.mat-slider-disabled).cdk-mouse-focused .mat-slider-thumb,.mat-slider:not(.mat-slider-disabled).cdk-touch-focused .mat-slider-thumb,.mat-slider:not(.mat-slider-disabled).cdk-program-focused .mat-slider-thumb{border-width:2px;transform:scale(1)}.mat-slider-disabled .mat-slider-focus-ring{transform:scale(0);opacity:0}.mat-slider-disabled .mat-slider-thumb{border-width:4px;transform:scale(0.5)}.mat-slider-disabled .mat-slider-thumb-label{display:none}.mat-slider-horizontal{height:48px;min-width:128px}.mat-slider-horizontal .mat-slider-wrapper{height:2px;top:23px;left:8px;right:8px}.mat-slider-horizontal .mat-slider-wrapper::after{height:2px;border-left-width:2px;right:0;top:0}.mat-slider-horizontal .mat-slider-track-wrapper{height:2px;width:100%}.mat-slider-horizontal .mat-slider-track-fill{height:2px;width:100%;transform:scaleX(0)}.mat-slider-horizontal .mat-slider-track-background{height:2px;width:100%;transform:scaleX(1)}.mat-slider-horizontal .mat-slider-ticks-container{height:2px;width:100%}.cdk-high-contrast-active .mat-slider-horizontal .mat-slider-ticks-container{height:0;outline:solid 2px;top:1px}.mat-slider-horizontal .mat-slider-ticks{height:2px;width:100%}.mat-slider-horizontal .mat-slider-thumb-container{width:100%;height:0;top:50%}.mat-slider-horizontal .mat-slider-focus-ring{top:-15px;right:-15px}.mat-slider-horizontal .mat-slider-thumb-label{right:-14px;top:-40px;transform:translateY(26px) scale(0.01) rotate(45deg)}.mat-slider-horizontal .mat-slider-thumb-label-text{transform:rotate(-45deg)}.mat-slider-horizontal.cdk-focused .mat-slider-thumb-label{transform:rotate(45deg)}.cdk-high-contrast-active .mat-slider-horizontal.cdk-focused .mat-slider-thumb-label,.cdk-high-contrast-active .mat-slider-horizontal.cdk-focused .mat-slider-thumb-label-text{transform:none}.mat-slider-vertical{width:48px;min-height:128px}.mat-slider-vertical .mat-slider-wrapper{width:2px;top:8px;bottom:8px;left:23px}.mat-slider-vertical .mat-slider-wrapper::after{width:2px;border-top-width:2px;bottom:0;left:0}.mat-slider-vertical .mat-slider-track-wrapper{height:100%;width:2px}.mat-slider-vertical .mat-slider-track-fill{height:100%;width:2px;transform:scaleY(0)}.mat-slider-vertical .mat-slider-track-background{height:100%;width:2px;transform:scaleY(1)}.mat-slider-vertical .mat-slider-ticks-container{width:2px;height:100%}.cdk-high-contrast-active .mat-slider-vertical .mat-slider-ticks-container{width:0;outline:solid 2px;left:1px}.mat-slider-vertical .mat-slider-focus-ring{bottom:-15px;left:-15px}.mat-slider-vertical .mat-slider-ticks{width:2px;height:100%}.mat-slider-vertical .mat-slider-thumb-container{height:100%;width:0;left:50%}.mat-slider-vertical .mat-slider-thumb{-webkit-backface-visibility:hidden;backface-visibility:hidden}.mat-slider-vertical .mat-slider-thumb-label{bottom:-14px;left:-40px;transform:translateX(26px) scale(0.01) rotate(-45deg)}.mat-slider-vertical .mat-slider-thumb-label-text{transform:rotate(45deg)}.mat-slider-vertical.cdk-focused .mat-slider-thumb-label{transform:rotate(-45deg)}[dir=rtl] .mat-slider-wrapper::after{left:0;right:auto}[dir=rtl] .mat-slider-horizontal .mat-slider-track-fill{transform-origin:100% 100%}[dir=rtl] .mat-slider-horizontal .mat-slider-track-background{transform-origin:0 0}[dir=rtl] .mat-slider-horizontal.mat-slider-axis-inverted .mat-slider-track-fill{transform-origin:0 0}[dir=rtl] .mat-slider-horizontal.mat-slider-axis-inverted .mat-slider-track-background{transform-origin:100% 100%}.mat-slider._mat-animation-noopable .mat-slider-track-fill,.mat-slider._mat-animation-noopable .mat-slider-track-background,.mat-slider._mat-animation-noopable .mat-slider-ticks,.mat-slider._mat-animation-noopable .mat-slider-thumb-container,.mat-slider._mat-animation-noopable .mat-slider-focus-ring,.mat-slider._mat-animation-noopable .mat-slider-thumb,.mat-slider._mat-animation-noopable .mat-slider-thumb-label,.mat-slider._mat-animation-noopable .mat-slider-thumb-label-text,.mat-slider._mat-animation-noopable .mat-slider-has-ticks .mat-slider-wrapper::after{transition:none}\n"],
      encapsulation: 2,
      changeDetection: 0
    });
    /** @nocollapse */

    MatSlider.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]
      }, {
        type: _angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_3__["FocusMonitor"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ChangeDetectorRef"]
      }, {
        type: _angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_4__["Directionality"],
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }]
      }, {
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Attribute"],
          args: ['tabindex']
        }]
      }, {
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_8__["ANIMATION_MODULE_TYPE"]]
        }]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
        }]
      }];
    };

    MatSlider.propDecorators = {
      invert: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      max: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      min: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      step: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      thumbLabel: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      tickInterval: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      value: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      displayWith: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      vertical: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      change: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"]
      }],
      input: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"]
      }],
      valueChange: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"]
      }],
      _sliderWrapper: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"],
        args: ['sliderWrapper']
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](MatSlider, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"],
        args: [{
          selector: 'mat-slider',
          exportAs: 'matSlider',
          providers: [MAT_SLIDER_VALUE_ACCESSOR],
          host: {
            '(focus)': '_onFocus()',
            '(blur)': '_onBlur()',
            '(keydown)': '_onKeydown($event)',
            '(keyup)': '_onKeyup()',
            '(mouseenter)': '_onMouseenter()',
            // On Safari starting to slide temporarily triggers text selection mode which
            // show the wrong cursor. We prevent it by stopping the `selectstart` event.
            '(selectstart)': '$event.preventDefault()',
            'class': 'mat-slider mat-focus-indicator',
            'role': 'slider',
            '[tabIndex]': 'tabIndex',
            '[attr.aria-disabled]': 'disabled',
            '[attr.aria-valuemax]': 'max',
            '[attr.aria-valuemin]': 'min',
            '[attr.aria-valuenow]': 'value',
            '[attr.aria-orientation]': 'vertical ? "vertical" : "horizontal"',
            '[class.mat-slider-disabled]': 'disabled',
            '[class.mat-slider-has-ticks]': 'tickInterval',
            '[class.mat-slider-horizontal]': '!vertical',
            '[class.mat-slider-axis-inverted]': '_invertAxis',
            // Class binding which is only used by the test harness as there is no other
            // way for the harness to detect if mouse coordinates need to be inverted.
            '[class.mat-slider-invert-mouse-coords]': '_shouldInvertMouseCoords()',
            '[class.mat-slider-sliding]': '_isSliding',
            '[class.mat-slider-thumb-label-showing]': 'thumbLabel',
            '[class.mat-slider-vertical]': 'vertical',
            '[class.mat-slider-min-value]': '_isMinValue',
            '[class.mat-slider-hide-last-tick]': 'disabled || _isMinValue && _thumbGap && _invertAxis',
            '[class._mat-animation-noopable]': '_animationMode === "NoopAnimations"'
          },
          template: "<div class=\"mat-slider-wrapper\" #sliderWrapper>\n  <div class=\"mat-slider-track-wrapper\">\n    <div class=\"mat-slider-track-background\" [ngStyle]=\"_trackBackgroundStyles\"></div>\n    <div class=\"mat-slider-track-fill\" [ngStyle]=\"_trackFillStyles\"></div>\n  </div>\n  <div class=\"mat-slider-ticks-container\" [ngStyle]=\"_ticksContainerStyles\">\n    <div class=\"mat-slider-ticks\" [ngStyle]=\"_ticksStyles\"></div>\n  </div>\n  <div class=\"mat-slider-thumb-container\" [ngStyle]=\"_thumbContainerStyles\">\n    <div class=\"mat-slider-focus-ring\"></div>\n    <div class=\"mat-slider-thumb\"></div>\n    <div class=\"mat-slider-thumb-label\">\n      <span class=\"mat-slider-thumb-label-text\">{{displayValue}}</span>\n    </div>\n  </div>\n</div>\n",
          inputs: ['disabled', 'color', 'tabIndex'],
          encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].None,
          changeDetection: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ChangeDetectionStrategy"].OnPush,
          styles: [".mat-slider{display:inline-block;position:relative;box-sizing:border-box;padding:8px;outline:none;vertical-align:middle}.mat-slider:not(.mat-slider-disabled):active,.mat-slider.mat-slider-sliding:not(.mat-slider-disabled){cursor:-webkit-grabbing;cursor:grabbing}.mat-slider-wrapper{position:absolute}.mat-slider-track-wrapper{position:absolute;top:0;left:0;overflow:hidden}.mat-slider-track-fill{position:absolute;transform-origin:0 0;transition:transform 400ms cubic-bezier(0.25, 0.8, 0.25, 1),background-color 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-slider-track-background{position:absolute;transform-origin:100% 100%;transition:transform 400ms cubic-bezier(0.25, 0.8, 0.25, 1),background-color 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-slider-ticks-container{position:absolute;left:0;top:0;overflow:hidden}.mat-slider-ticks{background-repeat:repeat;background-clip:content-box;box-sizing:border-box;opacity:0;transition:opacity 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-slider-thumb-container{position:absolute;z-index:1;transition:transform 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-slider-focus-ring{position:absolute;width:30px;height:30px;border-radius:50%;transform:scale(0);opacity:0;transition:transform 400ms cubic-bezier(0.25, 0.8, 0.25, 1),background-color 400ms cubic-bezier(0.25, 0.8, 0.25, 1),opacity 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-slider.cdk-keyboard-focused .mat-slider-focus-ring,.mat-slider.cdk-program-focused .mat-slider-focus-ring{transform:scale(1);opacity:1}.mat-slider:not(.mat-slider-disabled):not(.mat-slider-sliding) .mat-slider-thumb-label,.mat-slider:not(.mat-slider-disabled):not(.mat-slider-sliding) .mat-slider-thumb{cursor:-webkit-grab;cursor:grab}.mat-slider-thumb{position:absolute;right:-10px;bottom:-10px;box-sizing:border-box;width:20px;height:20px;border:3px solid transparent;border-radius:50%;transform:scale(0.7);transition:transform 400ms cubic-bezier(0.25, 0.8, 0.25, 1),background-color 400ms cubic-bezier(0.25, 0.8, 0.25, 1),border-color 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-slider-thumb-label{display:none;align-items:center;justify-content:center;position:absolute;width:28px;height:28px;border-radius:50%;transition:transform 400ms cubic-bezier(0.25, 0.8, 0.25, 1),border-radius 400ms cubic-bezier(0.25, 0.8, 0.25, 1),background-color 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}.cdk-high-contrast-active .mat-slider-thumb-label{outline:solid 1px}.mat-slider-thumb-label-text{z-index:1;opacity:0;transition:opacity 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-slider-sliding .mat-slider-track-fill,.mat-slider-sliding .mat-slider-track-background,.mat-slider-sliding .mat-slider-thumb-container{transition-duration:0ms}.mat-slider-has-ticks .mat-slider-wrapper::after{content:\"\";position:absolute;border-width:0;border-style:solid;opacity:0;transition:opacity 400ms cubic-bezier(0.25, 0.8, 0.25, 1)}.mat-slider-has-ticks.cdk-focused:not(.mat-slider-hide-last-tick) .mat-slider-wrapper::after,.mat-slider-has-ticks:hover:not(.mat-slider-hide-last-tick) .mat-slider-wrapper::after{opacity:1}.mat-slider-has-ticks.cdk-focused:not(.mat-slider-disabled) .mat-slider-ticks,.mat-slider-has-ticks:hover:not(.mat-slider-disabled) .mat-slider-ticks{opacity:1}.mat-slider-thumb-label-showing .mat-slider-focus-ring{display:none}.mat-slider-thumb-label-showing .mat-slider-thumb-label{display:flex}.mat-slider-axis-inverted .mat-slider-track-fill{transform-origin:100% 100%}.mat-slider-axis-inverted .mat-slider-track-background{transform-origin:0 0}.mat-slider:not(.mat-slider-disabled).cdk-focused.mat-slider-thumb-label-showing .mat-slider-thumb{transform:scale(0)}.mat-slider:not(.mat-slider-disabled).cdk-focused .mat-slider-thumb-label{border-radius:50% 50% 0}.mat-slider:not(.mat-slider-disabled).cdk-focused .mat-slider-thumb-label-text{opacity:1}.mat-slider:not(.mat-slider-disabled).cdk-mouse-focused .mat-slider-thumb,.mat-slider:not(.mat-slider-disabled).cdk-touch-focused .mat-slider-thumb,.mat-slider:not(.mat-slider-disabled).cdk-program-focused .mat-slider-thumb{border-width:2px;transform:scale(1)}.mat-slider-disabled .mat-slider-focus-ring{transform:scale(0);opacity:0}.mat-slider-disabled .mat-slider-thumb{border-width:4px;transform:scale(0.5)}.mat-slider-disabled .mat-slider-thumb-label{display:none}.mat-slider-horizontal{height:48px;min-width:128px}.mat-slider-horizontal .mat-slider-wrapper{height:2px;top:23px;left:8px;right:8px}.mat-slider-horizontal .mat-slider-wrapper::after{height:2px;border-left-width:2px;right:0;top:0}.mat-slider-horizontal .mat-slider-track-wrapper{height:2px;width:100%}.mat-slider-horizontal .mat-slider-track-fill{height:2px;width:100%;transform:scaleX(0)}.mat-slider-horizontal .mat-slider-track-background{height:2px;width:100%;transform:scaleX(1)}.mat-slider-horizontal .mat-slider-ticks-container{height:2px;width:100%}.cdk-high-contrast-active .mat-slider-horizontal .mat-slider-ticks-container{height:0;outline:solid 2px;top:1px}.mat-slider-horizontal .mat-slider-ticks{height:2px;width:100%}.mat-slider-horizontal .mat-slider-thumb-container{width:100%;height:0;top:50%}.mat-slider-horizontal .mat-slider-focus-ring{top:-15px;right:-15px}.mat-slider-horizontal .mat-slider-thumb-label{right:-14px;top:-40px;transform:translateY(26px) scale(0.01) rotate(45deg)}.mat-slider-horizontal .mat-slider-thumb-label-text{transform:rotate(-45deg)}.mat-slider-horizontal.cdk-focused .mat-slider-thumb-label{transform:rotate(45deg)}.cdk-high-contrast-active .mat-slider-horizontal.cdk-focused .mat-slider-thumb-label,.cdk-high-contrast-active .mat-slider-horizontal.cdk-focused .mat-slider-thumb-label-text{transform:none}.mat-slider-vertical{width:48px;min-height:128px}.mat-slider-vertical .mat-slider-wrapper{width:2px;top:8px;bottom:8px;left:23px}.mat-slider-vertical .mat-slider-wrapper::after{width:2px;border-top-width:2px;bottom:0;left:0}.mat-slider-vertical .mat-slider-track-wrapper{height:100%;width:2px}.mat-slider-vertical .mat-slider-track-fill{height:100%;width:2px;transform:scaleY(0)}.mat-slider-vertical .mat-slider-track-background{height:100%;width:2px;transform:scaleY(1)}.mat-slider-vertical .mat-slider-ticks-container{width:2px;height:100%}.cdk-high-contrast-active .mat-slider-vertical .mat-slider-ticks-container{width:0;outline:solid 2px;left:1px}.mat-slider-vertical .mat-slider-focus-ring{bottom:-15px;left:-15px}.mat-slider-vertical .mat-slider-ticks{width:2px;height:100%}.mat-slider-vertical .mat-slider-thumb-container{height:100%;width:0;left:50%}.mat-slider-vertical .mat-slider-thumb{-webkit-backface-visibility:hidden;backface-visibility:hidden}.mat-slider-vertical .mat-slider-thumb-label{bottom:-14px;left:-40px;transform:translateX(26px) scale(0.01) rotate(-45deg)}.mat-slider-vertical .mat-slider-thumb-label-text{transform:rotate(45deg)}.mat-slider-vertical.cdk-focused .mat-slider-thumb-label{transform:rotate(-45deg)}[dir=rtl] .mat-slider-wrapper::after{left:0;right:auto}[dir=rtl] .mat-slider-horizontal .mat-slider-track-fill{transform-origin:100% 100%}[dir=rtl] .mat-slider-horizontal .mat-slider-track-background{transform-origin:0 0}[dir=rtl] .mat-slider-horizontal.mat-slider-axis-inverted .mat-slider-track-fill{transform-origin:0 0}[dir=rtl] .mat-slider-horizontal.mat-slider-axis-inverted .mat-slider-track-background{transform-origin:100% 100%}.mat-slider._mat-animation-noopable .mat-slider-track-fill,.mat-slider._mat-animation-noopable .mat-slider-track-background,.mat-slider._mat-animation-noopable .mat-slider-ticks,.mat-slider._mat-animation-noopable .mat-slider-thumb-container,.mat-slider._mat-animation-noopable .mat-slider-focus-ring,.mat-slider._mat-animation-noopable .mat-slider-thumb,.mat-slider._mat-animation-noopable .mat-slider-thumb-label,.mat-slider._mat-animation-noopable .mat-slider-thumb-label-text,.mat-slider._mat-animation-noopable .mat-slider-has-ticks .mat-slider-wrapper::after{transition:none}\n"]
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]
        }, {
          type: _angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_3__["FocusMonitor"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ChangeDetectorRef"]
        }, {
          type: _angular_cdk_bidi__WEBPACK_IMPORTED_MODULE_4__["Directionality"],
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }]
        }, {
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Attribute"],
            args: ['tabindex']
          }]
        }, {
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_8__["ANIMATION_MODULE_TYPE"]]
          }]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
          }]
        }];
      }, {
        change: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"]
        }],
        input: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"]
        }],
        valueChange: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"]
        }],
        invert: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        max: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        min: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        value: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        step: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        thumbLabel: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        tickInterval: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        vertical: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        displayWith: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        _sliderWrapper: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewChild"],
          args: ['sliderWrapper']
        }]
      });
    })();

    if (false) {}
    /**
     * Returns whether an event is a touch event.
     * @param {?} event
     * @return {?}
     */


    function isTouchEvent(event) {
      // This function is called for every pixel that the user has dragged so we need it to be
      // as fast as possible. Since we only bind mouse events and touch events, we can assume
      // that if the event's name starts with `t`, it's a touch event.
      return event.type[0] === 't';
    }
    /**
     * Gets the coordinates of a touch or mouse event relative to the viewport.
     * @param {?} event
     * @return {?}
     */


    function getPointerPositionOnPage(event) {
      // `touches` will be empty for start/end events so we have to fall back to `changedTouches`.

      /** @type {?} */
      var point = isTouchEvent(event) ? event.touches[0] || event.changedTouches[0] : event;
      return {
        x: point.clientX,
        y: point.clientY
      };
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/slider/slider-module.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var MatSliderModule = function MatSliderModule() {
      _classCallCheck(this, MatSliderModule);
    };

    MatSliderModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineNgModule"]({
      type: MatSliderModule
    });
    MatSliderModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjector"]({
      factory: function MatSliderModule_Factory(t) {
        return new (t || MatSliderModule)();
      },
      imports: [[_angular_common__WEBPACK_IMPORTED_MODULE_0__["CommonModule"], _angular_material_core__WEBPACK_IMPORTED_MODULE_2__["MatCommonModule"]], _angular_material_core__WEBPACK_IMPORTED_MODULE_2__["MatCommonModule"]]
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵsetNgModuleScope"](MatSliderModule, {
        declarations: function declarations() {
          return [MatSlider];
        },
        imports: function imports() {
          return [_angular_common__WEBPACK_IMPORTED_MODULE_0__["CommonModule"], _angular_material_core__WEBPACK_IMPORTED_MODULE_2__["MatCommonModule"]];
        },
        exports: function exports() {
          return [MatSlider, _angular_material_core__WEBPACK_IMPORTED_MODULE_2__["MatCommonModule"]];
        }
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](MatSliderModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModule"],
        args: [{
          imports: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["CommonModule"], _angular_material_core__WEBPACK_IMPORTED_MODULE_2__["MatCommonModule"]],
          exports: [MatSlider, _angular_material_core__WEBPACK_IMPORTED_MODULE_2__["MatCommonModule"]],
          declarations: [MatSlider]
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/slider/public-api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=slider.js.map

    /***/

  },

  /***/
  "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/snack-bar.js":
  /*!***************************************************************************!*\
    !*** ./node_modules/@angular/material/__ivy_ngcc__/fesm2015/snack-bar.js ***!
    \***************************************************************************/

  /*! exports provided: MAT_SNACK_BAR_DATA, MAT_SNACK_BAR_DEFAULT_OPTIONS, MAT_SNACK_BAR_DEFAULT_OPTIONS_FACTORY, MatSnackBar, MatSnackBarConfig, MatSnackBarContainer, MatSnackBarModule, MatSnackBarRef, SimpleSnackBar, matSnackBarAnimations */

  /***/
  function node_modulesAngularMaterial__ivy_ngcc__Fesm2015SnackBarJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MAT_SNACK_BAR_DATA", function () {
      return MAT_SNACK_BAR_DATA;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MAT_SNACK_BAR_DEFAULT_OPTIONS", function () {
      return MAT_SNACK_BAR_DEFAULT_OPTIONS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MAT_SNACK_BAR_DEFAULT_OPTIONS_FACTORY", function () {
      return MAT_SNACK_BAR_DEFAULT_OPTIONS_FACTORY;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatSnackBar", function () {
      return MatSnackBar;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatSnackBarConfig", function () {
      return MatSnackBarConfig;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatSnackBarContainer", function () {
      return MatSnackBarContainer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatSnackBarModule", function () {
      return MatSnackBarModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MatSnackBarRef", function () {
      return MatSnackBarRef;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SimpleSnackBar", function () {
      return SimpleSnackBar;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "matSnackBarAnimations", function () {
      return matSnackBarAnimations;
    });
    /* harmony import */


    var _angular_cdk_overlay__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/cdk/overlay */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/overlay.js");
    /* harmony import */


    var _angular_cdk_portal__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! @angular/cdk/portal */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/portal.js");
    /* harmony import */


    var _angular_common__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! @angular/common */
    "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/common.js");
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var _angular_material_core__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! @angular/material/core */
    "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var _angular_material_button__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(
    /*! @angular/material/button */
    "./node_modules/@angular/material/__ivy_ngcc__/fesm2015/button.js");
    /* harmony import */


    var rxjs__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(
    /*! rxjs */
    "./node_modules/rxjs/_esm2015/index.js");
    /* harmony import */


    var rxjs_operators__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(
    /*! rxjs/operators */
    "./node_modules/rxjs/_esm2015/operators/index.js");
    /* harmony import */


    var _angular_animations__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(
    /*! @angular/animations */
    "./node_modules/@angular/animations/__ivy_ngcc__/fesm2015/animations.js");
    /* harmony import */


    var _angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(
    /*! @angular/cdk/a11y */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/a11y.js");
    /* harmony import */


    var _angular_cdk_layout__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(
    /*! @angular/cdk/layout */
    "./node_modules/@angular/cdk/__ivy_ngcc__/fesm2015/layout.js");
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/snack-bar/snack-bar-ref.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Event that is emitted when a snack bar is dismissed.
     * @record
     */


    function SimpleSnackBar_div_2_Template(rf, ctx) {
      if (rf & 1) {
        var _r2 = _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵgetCurrentView"]();

        _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵelementStart"](0, "div", 1);

        _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵelementStart"](1, "button", 2);

        _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵlistener"]("click", function SimpleSnackBar_div_2_Template_button_click_1_listener() {
          _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵrestoreView"](_r2);

          var ctx_r1 = _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵnextContext"]();

          return ctx_r1.action();
        });

        _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵtext"](2);

        _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵelementEnd"]();

        _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵelementEnd"]();
      }

      if (rf & 2) {
        var ctx_r0 = _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵnextContext"]();

        _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵadvance"](2);

        _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵtextInterpolate"](ctx_r0.data.action);
      }
    }

    function MatSnackBarContainer_ng_template_0_Template(rf, ctx) {}

    function MatSnackBarDismiss() {}

    if (false) {}
    /**
     * Maximum amount of milliseconds that can be passed into setTimeout.
     * @type {?}
     */


    var MAX_TIMEOUT = Math.pow(2, 31) - 1;
    /**
     * Reference to a snack bar dispatched from the snack bar service.
     * @template T
     */

    var MatSnackBarRef = /*#__PURE__*/function () {
      /**
       * @param {?} containerInstance
       * @param {?} _overlayRef
       */
      function MatSnackBarRef(containerInstance, _overlayRef) {
        var _this247 = this;

        _classCallCheck(this, MatSnackBarRef);

        this._overlayRef = _overlayRef;
        /**
         * Subject for notifying the user that the snack bar has been dismissed.
         */

        this._afterDismissed = new rxjs__WEBPACK_IMPORTED_MODULE_6__["Subject"]();
        /**
         * Subject for notifying the user that the snack bar has opened and appeared.
         */

        this._afterOpened = new rxjs__WEBPACK_IMPORTED_MODULE_6__["Subject"]();
        /**
         * Subject for notifying the user that the snack bar action was called.
         */

        this._onAction = new rxjs__WEBPACK_IMPORTED_MODULE_6__["Subject"]();
        /**
         * Whether the snack bar was dismissed using the action button.
         */

        this._dismissedByAction = false;
        this.containerInstance = containerInstance; // Dismiss snackbar on action.

        this.onAction().subscribe(
        /**
        * @return {?}
        */
        function () {
          return _this247.dismiss();
        });

        containerInstance._onExit.subscribe(
        /**
        * @return {?}
        */
        function () {
          return _this247._finishDismiss();
        });
      }
      /**
       * Dismisses the snack bar.
       * @return {?}
       */


      _createClass2(MatSnackBarRef, [{
        key: "dismiss",
        value: function dismiss() {
          if (!this._afterDismissed.closed) {
            this.containerInstance.exit();
          }

          clearTimeout(this._durationTimeoutId);
        }
        /**
         * Marks the snackbar action clicked.
         * @return {?}
         */

      }, {
        key: "dismissWithAction",
        value: function dismissWithAction() {
          if (!this._onAction.closed) {
            this._dismissedByAction = true;

            this._onAction.next();

            this._onAction.complete();
          }
        }
        /**
         * Marks the snackbar action clicked.
         * @deprecated Use `dismissWithAction` instead.
         * \@breaking-change 8.0.0
         * @return {?}
         */

      }, {
        key: "closeWithAction",
        value: function closeWithAction() {
          this.dismissWithAction();
        }
        /**
         * Dismisses the snack bar after some duration
         * @param {?} duration
         * @return {?}
         */

      }, {
        key: "_dismissAfter",
        value: function _dismissAfter(duration) {
          var _this248 = this;

          // Note that we need to cap the duration to the maximum value for setTimeout, because
          // it'll revert to 1 if somebody passes in something greater (e.g. `Infinity`). See #17234.
          this._durationTimeoutId = setTimeout(
          /**
          * @return {?}
          */
          function () {
            return _this248.dismiss();
          }, Math.min(duration, MAX_TIMEOUT));
        }
        /**
         * Marks the snackbar as opened
         * @return {?}
         */

      }, {
        key: "_open",
        value: function _open() {
          if (!this._afterOpened.closed) {
            this._afterOpened.next();

            this._afterOpened.complete();
          }
        }
        /**
         * Cleans up the DOM after closing.
         * @private
         * @return {?}
         */

      }, {
        key: "_finishDismiss",
        value: function _finishDismiss() {
          this._overlayRef.dispose();

          if (!this._onAction.closed) {
            this._onAction.complete();
          }

          this._afterDismissed.next({
            dismissedByAction: this._dismissedByAction
          });

          this._afterDismissed.complete();

          this._dismissedByAction = false;
        }
        /**
         * Gets an observable that is notified when the snack bar is finished closing.
         * @return {?}
         */

      }, {
        key: "afterDismissed",
        value: function afterDismissed() {
          return this._afterDismissed.asObservable();
        }
        /**
         * Gets an observable that is notified when the snack bar has opened and appeared.
         * @return {?}
         */

      }, {
        key: "afterOpened",
        value: function afterOpened() {
          return this.containerInstance._onEnter;
        }
        /**
         * Gets an observable that is notified when the snack bar action is called.
         * @return {?}
         */

      }, {
        key: "onAction",
        value: function onAction() {
          return this._onAction.asObservable();
        }
      }]);

      return MatSnackBarRef;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/snack-bar/snack-bar-config.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Injection token that can be used to access the data that was passed in to a snack bar.
     * @type {?}
     */


    var MAT_SNACK_BAR_DATA = new _angular_core__WEBPACK_IMPORTED_MODULE_3__["InjectionToken"]('MatSnackBarData');
    /**
     * Configuration used when opening a snack-bar.
     * @template D
     */

    var MatSnackBarConfig = function MatSnackBarConfig() {
      _classCallCheck(this, MatSnackBarConfig);

      /**
       * The politeness level for the MatAriaLiveAnnouncer announcement.
       */
      this.politeness = 'assertive';
      /**
       * Message to be announced by the LiveAnnouncer. When opening a snackbar without a custom
       * component or template, the announcement message will default to the specified message.
       */

      this.announcementMessage = '';
      /**
       * The length of time in milliseconds to wait before automatically dismissing the snack bar.
       */

      this.duration = 0;
      /**
       * Data being injected into the child component.
       */

      this.data = null;
      /**
       * The horizontal position to place the snack bar.
       */

      this.horizontalPosition = 'center';
      /**
       * The vertical position to place the snack bar.
       */

      this.verticalPosition = 'bottom';
    };

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/snack-bar/simple-snack-bar.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * A component used to open as the default snack bar, matching material spec.
     * This should only be used internally by the snack bar service.
     */


    var SimpleSnackBar = /*#__PURE__*/function () {
      /**
       * @param {?} snackBarRef
       * @param {?} data
       */
      function SimpleSnackBar(snackBarRef, data) {
        _classCallCheck(this, SimpleSnackBar);

        this.snackBarRef = snackBarRef;
        this.data = data;
      }
      /**
       * Performs the action on the snack bar.
       * @return {?}
       */


      _createClass2(SimpleSnackBar, [{
        key: "action",
        value: function action() {
          this.snackBarRef.dismissWithAction();
        }
        /**
         * If the action button should be shown.
         * @return {?}
         */

      }, {
        key: "hasAction",
        get: function get() {
          return !!this.data.action;
        }
      }]);

      return SimpleSnackBar;
    }();

    SimpleSnackBar.ɵfac = function SimpleSnackBar_Factory(t) {
      return new (t || SimpleSnackBar)(_angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵdirectiveInject"](MatSnackBarRef), _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵdirectiveInject"](MAT_SNACK_BAR_DATA));
    };

    SimpleSnackBar.ɵcmp = _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵdefineComponent"]({
      type: SimpleSnackBar,
      selectors: [["simple-snack-bar"]],
      hostAttrs: [1, "mat-simple-snackbar"],
      decls: 3,
      vars: 2,
      consts: [["class", "mat-simple-snackbar-action", 4, "ngIf"], [1, "mat-simple-snackbar-action"], ["mat-button", "", 3, "click"]],
      template: function SimpleSnackBar_Template(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵelementStart"](0, "span");

          _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵtext"](1);

          _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵelementEnd"]();

          _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵtemplate"](2, SimpleSnackBar_div_2_Template, 3, 1, "div", 0);
        }

        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵadvance"](1);

          _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵtextInterpolate"](ctx.data.message);

          _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵadvance"](1);

          _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵproperty"]("ngIf", ctx.hasAction);
        }
      },
      directives: [_angular_common__WEBPACK_IMPORTED_MODULE_2__["NgIf"], _angular_material_button__WEBPACK_IMPORTED_MODULE_5__["MatButton"]],
      styles: [".mat-simple-snackbar{display:flex;justify-content:space-between;align-items:center;line-height:20px;opacity:1}.mat-simple-snackbar-action{flex-shrink:0;margin:-8px -8px -8px 8px}.mat-simple-snackbar-action button{max-height:36px;min-width:0}[dir=rtl] .mat-simple-snackbar-action{margin-left:-8px;margin-right:8px}\n"],
      encapsulation: 2,
      changeDetection: 0
    });
    /** @nocollapse */

    SimpleSnackBar.ctorParameters = function () {
      return [{
        type: MatSnackBarRef
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["Inject"],
          args: [MAT_SNACK_BAR_DATA]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵsetClassMetadata"](SimpleSnackBar, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["Component"],
        args: [{
          selector: 'simple-snack-bar',
          template: "<span>{{data.message}}</span>\n<div class=\"mat-simple-snackbar-action\"  *ngIf=\"hasAction\">\n  <button mat-button (click)=\"action()\">{{data.action}}</button>\n</div>\n",
          encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_3__["ViewEncapsulation"].None,
          changeDetection: _angular_core__WEBPACK_IMPORTED_MODULE_3__["ChangeDetectionStrategy"].OnPush,
          host: {
            'class': 'mat-simple-snackbar'
          },
          styles: [".mat-simple-snackbar{display:flex;justify-content:space-between;align-items:center;line-height:20px;opacity:1}.mat-simple-snackbar-action{flex-shrink:0;margin:-8px -8px -8px 8px}.mat-simple-snackbar-action button{max-height:36px;min-width:0}[dir=rtl] .mat-simple-snackbar-action{margin-left:-8px;margin-right:8px}\n"]
        }]
      }], function () {
        return [{
          type: MatSnackBarRef
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["Inject"],
            args: [MAT_SNACK_BAR_DATA]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/snack-bar/snack-bar-animations.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Animations used by the Material snack bar.
     * \@docs-private
     * @type {?}
     */


    var matSnackBarAnimations = {
      /**
       * Animation that shows and hides a snack bar.
       */
      snackBarState: Object(_angular_animations__WEBPACK_IMPORTED_MODULE_8__["trigger"])('state', [Object(_angular_animations__WEBPACK_IMPORTED_MODULE_8__["state"])('void, hidden', Object(_angular_animations__WEBPACK_IMPORTED_MODULE_8__["style"])({
        transform: 'scale(0.8)',
        opacity: 0
      })), Object(_angular_animations__WEBPACK_IMPORTED_MODULE_8__["state"])('visible', Object(_angular_animations__WEBPACK_IMPORTED_MODULE_8__["style"])({
        transform: 'scale(1)',
        opacity: 1
      })), Object(_angular_animations__WEBPACK_IMPORTED_MODULE_8__["transition"])('* => visible', Object(_angular_animations__WEBPACK_IMPORTED_MODULE_8__["animate"])('150ms cubic-bezier(0, 0, 0.2, 1)')), Object(_angular_animations__WEBPACK_IMPORTED_MODULE_8__["transition"])('* => void, * => hidden', Object(_angular_animations__WEBPACK_IMPORTED_MODULE_8__["animate"])('75ms cubic-bezier(0.4, 0.0, 1, 1)', Object(_angular_animations__WEBPACK_IMPORTED_MODULE_8__["style"])({
        opacity: 0
      })))])
    };
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/snack-bar/snack-bar-container.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Internal component that wraps user-provided snack bar content.
     * \@docs-private
     */

    var MatSnackBarContainer = /*#__PURE__*/function (_angular_cdk_portal__) {
      _inherits(MatSnackBarContainer, _angular_cdk_portal__);

      var _super83 = _createSuper(MatSnackBarContainer);

      /**
       * @param {?} _ngZone
       * @param {?} _elementRef
       * @param {?} _changeDetectorRef
       * @param {?} snackBarConfig
       */
      function MatSnackBarContainer(_ngZone, _elementRef, _changeDetectorRef, snackBarConfig) {
        var _this249;

        _classCallCheck(this, MatSnackBarContainer);

        _this249 = _super83.call(this);
        _this249._ngZone = _ngZone;
        _this249._elementRef = _elementRef;
        _this249._changeDetectorRef = _changeDetectorRef;
        _this249.snackBarConfig = snackBarConfig;
        /**
         * Whether the component has been destroyed.
         */

        _this249._destroyed = false;
        /**
         * Subject for notifying that the snack bar has exited from view.
         */

        _this249._onExit = new rxjs__WEBPACK_IMPORTED_MODULE_6__["Subject"]();
        /**
         * Subject for notifying that the snack bar has finished entering the view.
         */

        _this249._onEnter = new rxjs__WEBPACK_IMPORTED_MODULE_6__["Subject"]();
        /**
         * The state of the snack bar animations.
         */

        _this249._animationState = 'void';
        /**
         * Attaches a DOM portal to the snack bar container.
         * @deprecated To be turned into a method.
         * \@breaking-change 10.0.0
         */

        _this249.attachDomPortal =
        /**
        * @param {?} portal
        * @return {?}
        */
        function (portal) {
          _this249._assertNotAttached();

          _this249._applySnackBarClasses();

          return _this249._portalOutlet.attachDomPortal(portal);
        }; // Based on the ARIA spec, `alert` and `status` roles have an
        // implicit `assertive` and `polite` politeness respectively.


        if (snackBarConfig.politeness === 'assertive' && !snackBarConfig.announcementMessage) {
          _this249._role = 'alert';
        } else if (snackBarConfig.politeness === 'off') {
          _this249._role = null;
        } else {
          _this249._role = 'status';
        }

        return _this249;
      }
      /**
       * Attach a component portal as content to this snack bar container.
       * @template T
       * @param {?} portal
       * @return {?}
       */


      _createClass2(MatSnackBarContainer, [{
        key: "attachComponentPortal",
        value: function attachComponentPortal(portal) {
          this._assertNotAttached();

          this._applySnackBarClasses();

          return this._portalOutlet.attachComponentPortal(portal);
        }
        /**
         * Attach a template portal as content to this snack bar container.
         * @template C
         * @param {?} portal
         * @return {?}
         */

      }, {
        key: "attachTemplatePortal",
        value: function attachTemplatePortal(portal) {
          this._assertNotAttached();

          this._applySnackBarClasses();

          return this._portalOutlet.attachTemplatePortal(portal);
        }
        /**
         * Handle end of animations, updating the state of the snackbar.
         * @param {?} event
         * @return {?}
         */

      }, {
        key: "onAnimationEnd",
        value: function onAnimationEnd(event) {
          var fromState = event.fromState,
              toState = event.toState;

          if (toState === 'void' && fromState !== 'void' || toState === 'hidden') {
            this._completeExit();
          }

          if (toState === 'visible') {
            // Note: we shouldn't use `this` inside the zone callback,
            // because it can cause a memory leak.

            /** @type {?} */
            var onEnter = this._onEnter;

            this._ngZone.run(
            /**
            * @return {?}
            */
            function () {
              onEnter.next();
              onEnter.complete();
            });
          }
        }
        /**
         * Begin animation of snack bar entrance into view.
         * @return {?}
         */

      }, {
        key: "enter",
        value: function enter() {
          if (!this._destroyed) {
            this._animationState = 'visible';

            this._changeDetectorRef.detectChanges();
          }
        }
        /**
         * Begin animation of the snack bar exiting from view.
         * @return {?}
         */

      }, {
        key: "exit",
        value: function exit() {
          // Note: this one transitions to `hidden`, rather than `void`, in order to handle the case
          // where multiple snack bars are opened in quick succession (e.g. two consecutive calls to
          // `MatSnackBar.open`).
          this._animationState = 'hidden'; // Mark this element with an 'exit' attribute to indicate that the snackbar has
          // been dismissed and will soon be removed from the DOM. This is used by the snackbar
          // test harness.

          this._elementRef.nativeElement.setAttribute('mat-exit', '');

          return this._onExit;
        }
        /**
         * Makes sure the exit callbacks have been invoked when the element is destroyed.
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this._destroyed = true;

          this._completeExit();
        }
        /**
         * Waits for the zone to settle before removing the element. Helps prevent
         * errors where we end up removing an element which is in the middle of an animation.
         * @private
         * @return {?}
         */

      }, {
        key: "_completeExit",
        value: function _completeExit() {
          var _this250 = this;

          this._ngZone.onMicrotaskEmpty.asObservable().pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_7__["take"])(1)).subscribe(
          /**
          * @return {?}
          */
          function () {
            _this250._onExit.next();

            _this250._onExit.complete();
          });
        }
        /**
         * Applies the various positioning and user-configured CSS classes to the snack bar.
         * @private
         * @return {?}
         */

      }, {
        key: "_applySnackBarClasses",
        value: function _applySnackBarClasses() {
          /** @type {?} */
          var element = this._elementRef.nativeElement;
          /** @type {?} */

          var panelClasses = this.snackBarConfig.panelClass;

          if (panelClasses) {
            if (Array.isArray(panelClasses)) {
              // Note that we can't use a spread here, because IE doesn't support multiple arguments.
              panelClasses.forEach(
              /**
              * @param {?} cssClass
              * @return {?}
              */
              function (cssClass) {
                return element.classList.add(cssClass);
              });
            } else {
              element.classList.add(panelClasses);
            }
          }

          if (this.snackBarConfig.horizontalPosition === 'center') {
            element.classList.add('mat-snack-bar-center');
          }

          if (this.snackBarConfig.verticalPosition === 'top') {
            element.classList.add('mat-snack-bar-top');
          }
        }
        /**
         * Asserts that no content is already attached to the container.
         * @private
         * @return {?}
         */

      }, {
        key: "_assertNotAttached",
        value: function _assertNotAttached() {
          if (this._portalOutlet.hasAttached()) {
            throw Error('Attempting to attach snack bar content after content is already attached');
          }
        }
      }]);

      return MatSnackBarContainer;
    }(_angular_cdk_portal__WEBPACK_IMPORTED_MODULE_1__["BasePortalOutlet"]);

    MatSnackBarContainer.ɵfac = function MatSnackBarContainer_Factory(t) {
      return new (t || MatSnackBarContainer)(_angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_3__["NgZone"]), _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_3__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_3__["ChangeDetectorRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵdirectiveInject"](MatSnackBarConfig));
    };

    MatSnackBarContainer.ɵcmp = _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵdefineComponent"]({
      type: MatSnackBarContainer,
      selectors: [["snack-bar-container"]],
      viewQuery: function MatSnackBarContainer_Query(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵstaticViewQuery"](_angular_cdk_portal__WEBPACK_IMPORTED_MODULE_1__["CdkPortalOutlet"], true);
        }

        if (rf & 2) {
          var _t;

          _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵqueryRefresh"](_t = _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵloadQuery"]()) && (ctx._portalOutlet = _t.first);
        }
      },
      hostAttrs: [1, "mat-snack-bar-container"],
      hostVars: 2,
      hostBindings: function MatSnackBarContainer_HostBindings(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵcomponentHostSyntheticListener"]("@state.done", function MatSnackBarContainer_animation_state_done_HostBindingHandler($event) {
            return ctx.onAnimationEnd($event);
          });
        }

        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵattribute"]("role", ctx._role);

          _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵupdateSyntheticHostBinding"]("@state", ctx._animationState);
        }
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵInheritDefinitionFeature"]],
      decls: 1,
      vars: 0,
      consts: [["cdkPortalOutlet", ""]],
      template: function MatSnackBarContainer_Template(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵtemplate"](0, MatSnackBarContainer_ng_template_0_Template, 0, 0, "ng-template", 0);
        }
      },
      directives: [_angular_cdk_portal__WEBPACK_IMPORTED_MODULE_1__["CdkPortalOutlet"]],
      styles: [".mat-snack-bar-container{border-radius:4px;box-sizing:border-box;display:block;margin:24px;max-width:33vw;min-width:344px;padding:14px 16px;min-height:48px;transform-origin:center}.cdk-high-contrast-active .mat-snack-bar-container{border:solid 1px}.mat-snack-bar-handset{width:100%}.mat-snack-bar-handset .mat-snack-bar-container{margin:8px;max-width:100%;min-width:0;width:100%}\n"],
      encapsulation: 2,
      data: {
        animation: [matSnackBarAnimations.snackBarState]
      }
    });
    /** @nocollapse */

    MatSnackBarContainer.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["NgZone"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["ElementRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["ChangeDetectorRef"]
      }, {
        type: MatSnackBarConfig
      }];
    };

    MatSnackBarContainer.propDecorators = {
      _portalOutlet: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["ViewChild"],
        args: [_angular_cdk_portal__WEBPACK_IMPORTED_MODULE_1__["CdkPortalOutlet"], {
          "static": true
        }]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵsetClassMetadata"](MatSnackBarContainer, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["Component"],
        args: [{
          selector: 'snack-bar-container',
          template: "<ng-template cdkPortalOutlet></ng-template>\n",
          // In Ivy embedded views will be change detected from their declaration place, rather than
          // where they were stamped out. This means that we can't have the snack bar container be OnPush,
          // because it might cause snack bars that were opened from a template not to be out of date.
          // tslint:disable-next-line:validate-decorators
          changeDetection: _angular_core__WEBPACK_IMPORTED_MODULE_3__["ChangeDetectionStrategy"].Default,
          encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_3__["ViewEncapsulation"].None,
          animations: [matSnackBarAnimations.snackBarState],
          host: {
            '[attr.role]': '_role',
            'class': 'mat-snack-bar-container',
            '[@state]': '_animationState',
            '(@state.done)': 'onAnimationEnd($event)'
          },
          styles: [".mat-snack-bar-container{border-radius:4px;box-sizing:border-box;display:block;margin:24px;max-width:33vw;min-width:344px;padding:14px 16px;min-height:48px;transform-origin:center}.cdk-high-contrast-active .mat-snack-bar-container{border:solid 1px}.mat-snack-bar-handset{width:100%}.mat-snack-bar-handset .mat-snack-bar-container{margin:8px;max-width:100%;min-width:0;width:100%}\n"]
        }]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["NgZone"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["ElementRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["ChangeDetectorRef"]
        }, {
          type: MatSnackBarConfig
        }];
      }, {
        _portalOutlet: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["ViewChild"],
          args: [_angular_cdk_portal__WEBPACK_IMPORTED_MODULE_1__["CdkPortalOutlet"], {
            "static": true
          }]
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/snack-bar/snack-bar-module.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var MatSnackBarModule = function MatSnackBarModule() {
      _classCallCheck(this, MatSnackBarModule);
    };

    MatSnackBarModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵdefineNgModule"]({
      type: MatSnackBarModule
    });
    MatSnackBarModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵdefineInjector"]({
      factory: function MatSnackBarModule_Factory(t) {
        return new (t || MatSnackBarModule)();
      },
      imports: [[_angular_cdk_overlay__WEBPACK_IMPORTED_MODULE_0__["OverlayModule"], _angular_cdk_portal__WEBPACK_IMPORTED_MODULE_1__["PortalModule"], _angular_common__WEBPACK_IMPORTED_MODULE_2__["CommonModule"], _angular_material_button__WEBPACK_IMPORTED_MODULE_5__["MatButtonModule"], _angular_material_core__WEBPACK_IMPORTED_MODULE_4__["MatCommonModule"]], _angular_material_core__WEBPACK_IMPORTED_MODULE_4__["MatCommonModule"]]
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵsetNgModuleScope"](MatSnackBarModule, {
        declarations: function declarations() {
          return [MatSnackBarContainer, SimpleSnackBar];
        },
        imports: function imports() {
          return [_angular_cdk_overlay__WEBPACK_IMPORTED_MODULE_0__["OverlayModule"], _angular_cdk_portal__WEBPACK_IMPORTED_MODULE_1__["PortalModule"], _angular_common__WEBPACK_IMPORTED_MODULE_2__["CommonModule"], _angular_material_button__WEBPACK_IMPORTED_MODULE_5__["MatButtonModule"], _angular_material_core__WEBPACK_IMPORTED_MODULE_4__["MatCommonModule"]];
        },
        exports: function exports() {
          return [MatSnackBarContainer, _angular_material_core__WEBPACK_IMPORTED_MODULE_4__["MatCommonModule"]];
        }
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵsetClassMetadata"](MatSnackBarModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["NgModule"],
        args: [{
          imports: [_angular_cdk_overlay__WEBPACK_IMPORTED_MODULE_0__["OverlayModule"], _angular_cdk_portal__WEBPACK_IMPORTED_MODULE_1__["PortalModule"], _angular_common__WEBPACK_IMPORTED_MODULE_2__["CommonModule"], _angular_material_button__WEBPACK_IMPORTED_MODULE_5__["MatButtonModule"], _angular_material_core__WEBPACK_IMPORTED_MODULE_4__["MatCommonModule"]],
          exports: [MatSnackBarContainer, _angular_material_core__WEBPACK_IMPORTED_MODULE_4__["MatCommonModule"]],
          declarations: [MatSnackBarContainer, SimpleSnackBar],
          entryComponents: [MatSnackBarContainer, SimpleSnackBar]
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/snack-bar/snack-bar.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Injection token that can be used to specify default snack bar.
     * @type {?}
     */


    var MAT_SNACK_BAR_DEFAULT_OPTIONS = new _angular_core__WEBPACK_IMPORTED_MODULE_3__["InjectionToken"]('mat-snack-bar-default-options', {
      providedIn: 'root',
      factory: MAT_SNACK_BAR_DEFAULT_OPTIONS_FACTORY
    });
    /**
     * \@docs-private
     * @return {?}
     */

    function MAT_SNACK_BAR_DEFAULT_OPTIONS_FACTORY() {
      return new MatSnackBarConfig();
    }
    /**
     * Service to dispatch Material Design snack bar messages.
     */


    var MatSnackBar = /*#__PURE__*/function () {
      /**
       * @param {?} _overlay
       * @param {?} _live
       * @param {?} _injector
       * @param {?} _breakpointObserver
       * @param {?} _parentSnackBar
       * @param {?} _defaultConfig
       */
      function MatSnackBar(_overlay, _live, _injector, _breakpointObserver, _parentSnackBar, _defaultConfig) {
        _classCallCheck(this, MatSnackBar);

        this._overlay = _overlay;
        this._live = _live;
        this._injector = _injector;
        this._breakpointObserver = _breakpointObserver;
        this._parentSnackBar = _parentSnackBar;
        this._defaultConfig = _defaultConfig;
        /**
         * Reference to the current snack bar in the view *at this level* (in the Angular injector tree).
         * If there is a parent snack-bar service, all operations should delegate to that parent
         * via `_openedSnackBarRef`.
         */

        this._snackBarRefAtThisLevel = null;
      }
      /**
       * Reference to the currently opened snackbar at *any* level.
       * @return {?}
       */


      _createClass2(MatSnackBar, [{
        key: "openFromComponent",

        /**
         * Creates and dispatches a snack bar with a custom component for the content, removing any
         * currently opened snack bars.
         *
         * @template T
         * @param {?} component Component to be instantiated.
         * @param {?=} config Extra configuration for the snack bar.
         * @return {?}
         */
        value: function openFromComponent(component, config) {
          return (
            /** @type {?} */
            this._attach(component, config)
          );
        }
        /**
         * Creates and dispatches a snack bar with a custom template for the content, removing any
         * currently opened snack bars.
         *
         * @param {?} template Template to be instantiated.
         * @param {?=} config Extra configuration for the snack bar.
         * @return {?}
         */

      }, {
        key: "openFromTemplate",
        value: function openFromTemplate(template, config) {
          return this._attach(template, config);
        }
        /**
         * Opens a snackbar with a message and an optional action.
         * @param {?} message The message to show in the snackbar.
         * @param {?=} action The label for the snackbar action.
         * @param {?=} config Additional configuration options for the snackbar.
         * @return {?}
         */

      }, {
        key: "open",
        value: function open(message) {
          var action = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';
          var config = arguments.length > 2 ? arguments[2] : undefined;

          /** @type {?} */
          var _config = Object.assign(Object.assign({}, this._defaultConfig), config); // Since the user doesn't have access to the component, we can
          // override the data to pass in our own message and action.


          _config.data = {
            message: message,
            action: action
          };

          if (!_config.announcementMessage) {
            _config.announcementMessage = message;
          }

          return this.openFromComponent(SimpleSnackBar, _config);
        }
        /**
         * Dismisses the currently-visible snack bar.
         * @return {?}
         */

      }, {
        key: "dismiss",
        value: function dismiss() {
          if (this._openedSnackBarRef) {
            this._openedSnackBarRef.dismiss();
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          // Only dismiss the snack bar at the current level on destroy.
          if (this._snackBarRefAtThisLevel) {
            this._snackBarRefAtThisLevel.dismiss();
          }
        }
        /**
         * Attaches the snack bar container component to the overlay.
         * @private
         * @param {?} overlayRef
         * @param {?} config
         * @return {?}
         */

      }, {
        key: "_attachSnackBarContainer",
        value: function _attachSnackBarContainer(overlayRef, config) {
          /** @type {?} */
          var userInjector = config && config.viewContainerRef && config.viewContainerRef.injector;
          /** @type {?} */

          var injector = new _angular_cdk_portal__WEBPACK_IMPORTED_MODULE_1__["PortalInjector"](userInjector || this._injector, new WeakMap([[MatSnackBarConfig, config]]));
          /** @type {?} */

          var containerPortal = new _angular_cdk_portal__WEBPACK_IMPORTED_MODULE_1__["ComponentPortal"](MatSnackBarContainer, config.viewContainerRef, injector);
          /** @type {?} */

          var containerRef = overlayRef.attach(containerPortal);
          containerRef.instance.snackBarConfig = config;
          return containerRef.instance;
        }
        /**
         * Places a new component or a template as the content of the snack bar container.
         * @private
         * @template T
         * @param {?} content
         * @param {?=} userConfig
         * @return {?}
         */

      }, {
        key: "_attach",
        value: function _attach(content, userConfig) {
          /** @type {?} */
          var config = Object.assign(Object.assign(Object.assign({}, new MatSnackBarConfig()), this._defaultConfig), userConfig);
          /** @type {?} */

          var overlayRef = this._createOverlay(config);
          /** @type {?} */


          var container = this._attachSnackBarContainer(overlayRef, config);
          /** @type {?} */


          var snackBarRef = new MatSnackBarRef(container, overlayRef);

          if (content instanceof _angular_core__WEBPACK_IMPORTED_MODULE_3__["TemplateRef"]) {
            /** @type {?} */
            var portal = new _angular_cdk_portal__WEBPACK_IMPORTED_MODULE_1__["TemplatePortal"](content,
            /** @type {?} */
            null,
            /** @type {?} */
            {
              $implicit: config.data,
              snackBarRef: snackBarRef
            });
            snackBarRef.instance = container.attachTemplatePortal(portal);
          } else {
            /** @type {?} */
            var injector = this._createInjector(config, snackBarRef);
            /** @type {?} */


            var _portal = new _angular_cdk_portal__WEBPACK_IMPORTED_MODULE_1__["ComponentPortal"](content, undefined, injector);
            /** @type {?} */


            var contentRef = container.attachComponentPortal(_portal); // We can't pass this via the injector, because the injector is created earlier.

            snackBarRef.instance = contentRef.instance;
          } // Subscribe to the breakpoint observer and attach the mat-snack-bar-handset class as
          // appropriate. This class is applied to the overlay element because the overlay must expand to
          // fill the width of the screen for full width snackbars.


          this._breakpointObserver.observe(_angular_cdk_layout__WEBPACK_IMPORTED_MODULE_10__["Breakpoints"].HandsetPortrait).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_7__["takeUntil"])(overlayRef.detachments())).subscribe(
          /**
          * @param {?} state
          * @return {?}
          */
          function (state) {
            /** @type {?} */
            var classList = overlayRef.overlayElement.classList;
            /** @type {?} */

            var className = 'mat-snack-bar-handset';
            state.matches ? classList.add(className) : classList.remove(className);
          });

          this._animateSnackBar(snackBarRef, config);

          this._openedSnackBarRef = snackBarRef;
          return this._openedSnackBarRef;
        }
        /**
         * Animates the old snack bar out and the new one in.
         * @private
         * @param {?} snackBarRef
         * @param {?} config
         * @return {?}
         */

      }, {
        key: "_animateSnackBar",
        value: function _animateSnackBar(snackBarRef, config) {
          var _this251 = this;

          // When the snackbar is dismissed, clear the reference to it.
          snackBarRef.afterDismissed().subscribe(
          /**
          * @return {?}
          */
          function () {
            // Clear the snackbar ref if it hasn't already been replaced by a newer snackbar.
            if (_this251._openedSnackBarRef == snackBarRef) {
              _this251._openedSnackBarRef = null;
            }

            if (config.announcementMessage) {
              _this251._live.clear();
            }
          });

          if (this._openedSnackBarRef) {
            // If a snack bar is already in view, dismiss it and enter the
            // new snack bar after exit animation is complete.
            this._openedSnackBarRef.afterDismissed().subscribe(
            /**
            * @return {?}
            */
            function () {
              snackBarRef.containerInstance.enter();
            });

            this._openedSnackBarRef.dismiss();
          } else {
            // If no snack bar is in view, enter the new snack bar.
            snackBarRef.containerInstance.enter();
          } // If a dismiss timeout is provided, set up dismiss based on after the snackbar is opened.


          if (config.duration && config.duration > 0) {
            snackBarRef.afterOpened().subscribe(
            /**
            * @return {?}
            */
            function () {
              return snackBarRef._dismissAfter(
              /** @type {?} */
              config.duration);
            });
          }

          if (config.announcementMessage) {
            this._live.announce(config.announcementMessage, config.politeness);
          }
        }
        /**
         * Creates a new overlay and places it in the correct location.
         * @private
         * @param {?} config The user-specified snack bar config.
         * @return {?}
         */

      }, {
        key: "_createOverlay",
        value: function _createOverlay(config) {
          /** @type {?} */
          var overlayConfig = new _angular_cdk_overlay__WEBPACK_IMPORTED_MODULE_0__["OverlayConfig"]();
          overlayConfig.direction = config.direction;
          /** @type {?} */

          var positionStrategy = this._overlay.position().global(); // Set horizontal position.

          /** @type {?} */


          var isRtl = config.direction === 'rtl';
          /** @type {?} */

          var isLeft = config.horizontalPosition === 'left' || config.horizontalPosition === 'start' && !isRtl || config.horizontalPosition === 'end' && isRtl;
          /** @type {?} */

          var isRight = !isLeft && config.horizontalPosition !== 'center';

          if (isLeft) {
            positionStrategy.left('0');
          } else if (isRight) {
            positionStrategy.right('0');
          } else {
            positionStrategy.centerHorizontally();
          } // Set horizontal position.


          if (config.verticalPosition === 'top') {
            positionStrategy.top('0');
          } else {
            positionStrategy.bottom('0');
          }

          overlayConfig.positionStrategy = positionStrategy;
          return this._overlay.create(overlayConfig);
        }
        /**
         * Creates an injector to be used inside of a snack bar component.
         * @private
         * @template T
         * @param {?} config Config that was used to create the snack bar.
         * @param {?} snackBarRef Reference to the snack bar.
         * @return {?}
         */

      }, {
        key: "_createInjector",
        value: function _createInjector(config, snackBarRef) {
          /** @type {?} */
          var userInjector = config && config.viewContainerRef && config.viewContainerRef.injector;
          return new _angular_cdk_portal__WEBPACK_IMPORTED_MODULE_1__["PortalInjector"](userInjector || this._injector, new WeakMap([[MatSnackBarRef, snackBarRef], [MAT_SNACK_BAR_DATA, config.data]]));
        }
      }, {
        key: "_openedSnackBarRef",
        get: function get() {
          /** @type {?} */
          var parent = this._parentSnackBar;
          return parent ? parent._openedSnackBarRef : this._snackBarRefAtThisLevel;
        }
        /**
         * @param {?} value
         * @return {?}
         */
        ,
        set: function set(value) {
          if (this._parentSnackBar) {
            this._parentSnackBar._openedSnackBarRef = value;
          } else {
            this._snackBarRefAtThisLevel = value;
          }
        }
      }]);

      return MatSnackBar;
    }();

    MatSnackBar.ɵfac = function MatSnackBar_Factory(t) {
      return new (t || MatSnackBar)(_angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵinject"](_angular_cdk_overlay__WEBPACK_IMPORTED_MODULE_0__["Overlay"]), _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵinject"](_angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_9__["LiveAnnouncer"]), _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_3__["Injector"]), _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵinject"](_angular_cdk_layout__WEBPACK_IMPORTED_MODULE_10__["BreakpointObserver"]), _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵinject"](MatSnackBar, 12), _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵinject"](MAT_SNACK_BAR_DEFAULT_OPTIONS));
    };
    /** @nocollapse */


    MatSnackBar.ctorParameters = function () {
      return [{
        type: _angular_cdk_overlay__WEBPACK_IMPORTED_MODULE_0__["Overlay"]
      }, {
        type: _angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_9__["LiveAnnouncer"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["Injector"]
      }, {
        type: _angular_cdk_layout__WEBPACK_IMPORTED_MODULE_10__["BreakpointObserver"]
      }, {
        type: MatSnackBar,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["SkipSelf"]
        }]
      }, {
        type: MatSnackBarConfig,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["Inject"],
          args: [MAT_SNACK_BAR_DEFAULT_OPTIONS]
        }]
      }];
    };
    /** @nocollapse */


    MatSnackBar.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵdefineInjectable"])({
      factory: function MatSnackBar_Factory() {
        return new MatSnackBar(Object(_angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵinject"])(_angular_cdk_overlay__WEBPACK_IMPORTED_MODULE_0__["Overlay"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵinject"])(_angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_9__["LiveAnnouncer"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵinject"])(_angular_core__WEBPACK_IMPORTED_MODULE_3__["INJECTOR"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵinject"])(_angular_cdk_layout__WEBPACK_IMPORTED_MODULE_10__["BreakpointObserver"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵinject"])(MatSnackBar, 12), Object(_angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵɵinject"])(MAT_SNACK_BAR_DEFAULT_OPTIONS));
      },
      token: MatSnackBar,
      providedIn: MatSnackBarModule
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_3__["ɵsetClassMetadata"](MatSnackBar, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["Injectable"],
        args: [{
          providedIn: MatSnackBarModule
        }]
      }], function () {
        return [{
          type: _angular_cdk_overlay__WEBPACK_IMPORTED_MODULE_0__["Overlay"]
        }, {
          type: _angular_cdk_a11y__WEBPACK_IMPORTED_MODULE_9__["LiveAnnouncer"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["Injector"]
        }, {
          type: _angular_cdk_layout__WEBPACK_IMPORTED_MODULE_10__["BreakpointObserver"]
        }, {
          type: MatSnackBar,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["SkipSelf"]
          }]
        }, {
          type: MatSnackBarConfig,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_3__["Inject"],
            args: [MAT_SNACK_BAR_DEFAULT_OPTIONS]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: src/material/snack-bar/public-api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=snack-bar.js.map

    /***/

  },

  /***/
  "./node_modules/@angular/platform-browser/__ivy_ngcc__/fesm2015/animations.js":
  /*!************************************************************************************!*\
    !*** ./node_modules/@angular/platform-browser/__ivy_ngcc__/fesm2015/animations.js ***!
    \************************************************************************************/

  /*! exports provided: ANIMATION_MODULE_TYPE, BrowserAnimationsModule, NoopAnimationsModule, ɵAnimationRenderer, ɵAnimationRendererFactory, ɵBrowserAnimationBuilder, ɵBrowserAnimationFactory, ɵInjectableAnimationEngine, ɵangular_packages_platform_browser_animations_animations_a, ɵangular_packages_platform_browser_animations_animations_b, ɵangular_packages_platform_browser_animations_animations_c, ɵangular_packages_platform_browser_animations_animations_d, ɵangular_packages_platform_browser_animations_animations_e, ɵangular_packages_platform_browser_animations_animations_f */

  /***/
  function node_modulesAngularPlatformBrowser__ivy_ngcc__Fesm2015AnimationsJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ANIMATION_MODULE_TYPE", function () {
      return ANIMATION_MODULE_TYPE;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "BrowserAnimationsModule", function () {
      return BrowserAnimationsModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NoopAnimationsModule", function () {
      return NoopAnimationsModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵAnimationRenderer", function () {
      return AnimationRenderer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵAnimationRendererFactory", function () {
      return AnimationRendererFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵBrowserAnimationBuilder", function () {
      return BrowserAnimationBuilder;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵBrowserAnimationFactory", function () {
      return BrowserAnimationFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵInjectableAnimationEngine", function () {
      return InjectableAnimationEngine;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_animations_animations_a", function () {
      return instantiateSupportedAnimationDriver;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_animations_animations_b", function () {
      return instantiateDefaultStyleNormalizer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_animations_animations_c", function () {
      return instantiateRendererFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_animations_animations_d", function () {
      return BROWSER_ANIMATIONS_PROVIDERS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_animations_animations_e", function () {
      return BROWSER_NOOP_ANIMATIONS_PROVIDERS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_animations_animations_f", function () {
      return BaseAnimationRenderer;
    });
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! @angular/platform-browser */
    "./node_modules/@angular/platform-browser/__ivy_ngcc__/fesm2015/platform-browser.js");
    /* harmony import */


    var _angular_animations__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! @angular/animations */
    "./node_modules/@angular/animations/__ivy_ngcc__/fesm2015/animations.js");
    /* harmony import */


    var _angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! @angular/animations/browser */
    "./node_modules/@angular/animations/__ivy_ngcc__/fesm2015/browser.js");
    /* harmony import */


    var _angular_common__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! @angular/common */
    "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/common.js");
    /**
     * @license Angular v9.1.4
     * (c) 2010-2020 Google LLC. https://angular.io/
     * License: MIT
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/animations/src/animation_builder.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var BrowserAnimationBuilder = /*#__PURE__*/function (_angular_animations__2) {
      _inherits(BrowserAnimationBuilder, _angular_animations__2);

      var _super84 = _createSuper(BrowserAnimationBuilder);

      /**
       * @param {?} rootRenderer
       * @param {?} doc
       */
      function BrowserAnimationBuilder(rootRenderer, doc) {
        var _this252;

        _classCallCheck(this, BrowserAnimationBuilder);

        _this252 = _super84.call(this);
        _this252._nextAnimationId = 0;
        /** @type {?} */

        var typeData =
        /** @type {?} */
        {
          id: '0',
          encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewEncapsulation"].None,
          styles: [],
          data: {
            animation: []
          }
        };
        _this252._renderer =
        /** @type {?} */
        rootRenderer.createRenderer(doc.body, typeData);
        return _this252;
      }
      /**
       * @param {?} animation
       * @return {?}
       */


      _createClass2(BrowserAnimationBuilder, [{
        key: "build",
        value: function build(animation) {
          /** @type {?} */
          var id = this._nextAnimationId.toString();

          this._nextAnimationId++;
          /** @type {?} */

          var entry = Array.isArray(animation) ? Object(_angular_animations__WEBPACK_IMPORTED_MODULE_2__["sequence"])(animation) : animation;
          issueAnimationCommand(this._renderer, null, id, 'register', [entry]);
          return new BrowserAnimationFactory(id, this._renderer);
        }
      }]);

      return BrowserAnimationBuilder;
    }(_angular_animations__WEBPACK_IMPORTED_MODULE_2__["AnimationBuilder"]);

    BrowserAnimationBuilder.ɵfac = function BrowserAnimationBuilder_Factory(t) {
      return new (t || BrowserAnimationBuilder)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["RendererFactory2"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]));
    };

    BrowserAnimationBuilder.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({
      token: BrowserAnimationBuilder,
      factory: BrowserAnimationBuilder.ɵfac
    });
    /** @nocollapse */

    BrowserAnimationBuilder.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["RendererFactory2"]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](BrowserAnimationBuilder, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["RendererFactory2"]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]]
          }]
        }];
      }, null);
    })();

    if (false) {}

    var BrowserAnimationFactory = /*#__PURE__*/function (_angular_animations__3) {
      _inherits(BrowserAnimationFactory, _angular_animations__3);

      var _super85 = _createSuper(BrowserAnimationFactory);

      /**
       * @param {?} _id
       * @param {?} _renderer
       */
      function BrowserAnimationFactory(_id, _renderer) {
        var _this253;

        _classCallCheck(this, BrowserAnimationFactory);

        _this253 = _super85.call(this);
        _this253._id = _id;
        _this253._renderer = _renderer;
        return _this253;
      }
      /**
       * @param {?} element
       * @param {?=} options
       * @return {?}
       */


      _createClass2(BrowserAnimationFactory, [{
        key: "create",
        value: function create(element, options) {
          return new RendererAnimationPlayer(this._id, element, options || {}, this._renderer);
        }
      }]);

      return BrowserAnimationFactory;
    }(_angular_animations__WEBPACK_IMPORTED_MODULE_2__["AnimationFactory"]);

    if (false) {}

    var RendererAnimationPlayer = /*#__PURE__*/function () {
      /**
       * @param {?} id
       * @param {?} element
       * @param {?} options
       * @param {?} _renderer
       */
      function RendererAnimationPlayer(id, element, options, _renderer) {
        _classCallCheck(this, RendererAnimationPlayer);

        this.id = id;
        this.element = element;
        this._renderer = _renderer;
        this.parentPlayer = null;
        this._started = false;
        this.totalTime = 0;

        this._command('create', options);
      }
      /**
       * @private
       * @param {?} eventName
       * @param {?} callback
       * @return {?}
       */


      _createClass2(RendererAnimationPlayer, [{
        key: "_listen",
        value: function _listen(eventName, callback) {
          return this._renderer.listen(this.element, "@@".concat(this.id, ":").concat(eventName), callback);
        }
        /**
         * @private
         * @param {?} command
         * @param {...?} args
         * @return {?}
         */

      }, {
        key: "_command",
        value: function _command(command) {
          for (var _len27 = arguments.length, args = new Array(_len27 > 1 ? _len27 - 1 : 0), _key28 = 1; _key28 < _len27; _key28++) {
            args[_key28 - 1] = arguments[_key28];
          }

          return issueAnimationCommand(this._renderer, this.element, this.id, command, args);
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "onDone",
        value: function onDone(fn) {
          this._listen('done', fn);
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "onStart",
        value: function onStart(fn) {
          this._listen('start', fn);
        }
        /**
         * @param {?} fn
         * @return {?}
         */

      }, {
        key: "onDestroy",
        value: function onDestroy(fn) {
          this._listen('destroy', fn);
        }
        /**
         * @return {?}
         */

      }, {
        key: "init",
        value: function init() {
          this._command('init');
        }
        /**
         * @return {?}
         */

      }, {
        key: "hasStarted",
        value: function hasStarted() {
          return this._started;
        }
        /**
         * @return {?}
         */

      }, {
        key: "play",
        value: function play() {
          this._command('play');

          this._started = true;
        }
        /**
         * @return {?}
         */

      }, {
        key: "pause",
        value: function pause() {
          this._command('pause');
        }
        /**
         * @return {?}
         */

      }, {
        key: "restart",
        value: function restart() {
          this._command('restart');
        }
        /**
         * @return {?}
         */

      }, {
        key: "finish",
        value: function finish() {
          this._command('finish');
        }
        /**
         * @return {?}
         */

      }, {
        key: "destroy",
        value: function destroy() {
          this._command('destroy');
        }
        /**
         * @return {?}
         */

      }, {
        key: "reset",
        value: function reset() {
          this._command('reset');
        }
        /**
         * @param {?} p
         * @return {?}
         */

      }, {
        key: "setPosition",
        value: function setPosition(p) {
          this._command('setPosition', p);
        }
        /**
         * @return {?}
         */

      }, {
        key: "getPosition",
        value: function getPosition() {
          return 0;
        }
      }]);

      return RendererAnimationPlayer;
    }();

    if (false) {}
    /**
     * @param {?} renderer
     * @param {?} element
     * @param {?} id
     * @param {?} command
     * @param {?} args
     * @return {?}
     */


    function issueAnimationCommand(renderer, element, id, command, args) {
      return renderer.setProperty(element, "@@".concat(id, ":").concat(command), args);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/animations/src/animation_renderer.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var ANIMATION_PREFIX = '@';
    /** @type {?} */

    var DISABLE_ANIMATIONS_FLAG = '@.disabled';
    /**
     * @record
     */

    function RecursiveAnimationTriggerMetadata() {}

    var AnimationRendererFactory = /*#__PURE__*/function () {
      /**
       * @param {?} delegate
       * @param {?} engine
       * @param {?} _zone
       */
      function AnimationRendererFactory(delegate, engine, _zone) {
        _classCallCheck(this, AnimationRendererFactory);

        this.delegate = delegate;
        this.engine = engine;
        this._zone = _zone;
        this._currentId = 0;
        this._microtaskId = 1;
        this._animationCallbacksBuffer = [];
        this._rendererCache = new Map();
        this._cdRecurDepth = 0;
        this.promise = Promise.resolve(0);

        engine.onRemovalComplete =
        /**
        * @param {?} element
        * @param {?} delegate
        * @return {?}
        */
        function (element, delegate) {
          // Note: if an component element has a leave animation, and the component
          // a host leave animation, the view engine will call `removeChild` for the parent
          // component renderer as well as for the child component renderer.
          // Therefore, we need to check if we already removed the element.
          if (delegate && delegate.parentNode(element)) {
            delegate.removeChild(element.parentNode, element);
          }
        };
      }
      /**
       * @param {?} hostElement
       * @param {?} type
       * @return {?}
       */


      _createClass2(AnimationRendererFactory, [{
        key: "createRenderer",
        value: function createRenderer(hostElement, type) {
          var _this254 = this;

          /** @type {?} */
          var EMPTY_NAMESPACE_ID = ''; // cache the delegates to find out which cached delegate can
          // be used by which cached renderer

          /** @type {?} */

          var delegate = this.delegate.createRenderer(hostElement, type);

          if (!hostElement || !type || !type.data || !type.data['animation']) {
            /** @type {?} */
            var renderer = this._rendererCache.get(delegate);

            if (!renderer) {
              renderer = new BaseAnimationRenderer(EMPTY_NAMESPACE_ID, delegate, this.engine); // only cache this result when the base renderer is used

              this._rendererCache.set(delegate, renderer);
            }

            return renderer;
          }
          /** @type {?} */


          var componentId = type.id;
          /** @type {?} */

          var namespaceId = type.id + '-' + this._currentId;
          this._currentId++;
          this.engine.register(namespaceId, hostElement);
          /** @type {?} */

          var registerTrigger =
          /**
          * @param {?} trigger
          * @return {?}
          */
          function registerTrigger(trigger) {
            if (Array.isArray(trigger)) {
              trigger.forEach(registerTrigger);
            } else {
              _this254.engine.registerTrigger(componentId, namespaceId, hostElement, trigger.name, trigger);
            }
          };
          /** @type {?} */


          var animationTriggers =
          /** @type {?} */
          type.data['animation'];
          animationTriggers.forEach(registerTrigger);
          return new AnimationRenderer(this, namespaceId, delegate, this.engine);
        }
        /**
         * @return {?}
         */

      }, {
        key: "begin",
        value: function begin() {
          this._cdRecurDepth++;

          if (this.delegate.begin) {
            this.delegate.begin();
          }
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "_scheduleCountTask",
        value: function _scheduleCountTask() {
          var _this255 = this;

          // always use promise to schedule microtask instead of use Zone
          this.promise.then(
          /**
          * @return {?}
          */
          function () {
            _this255._microtaskId++;
          });
        }
        /**
         * \@internal
         * @param {?} count
         * @param {?} fn
         * @param {?} data
         * @return {?}
         */

      }, {
        key: "scheduleListenerCallback",
        value: function scheduleListenerCallback(count, fn, data) {
          var _this256 = this;

          if (count >= 0 && count < this._microtaskId) {
            this._zone.run(
            /**
            * @return {?}
            */
            function () {
              return fn(data);
            });

            return;
          }

          if (this._animationCallbacksBuffer.length == 0) {
            Promise.resolve(null).then(
            /**
            * @return {?}
            */
            function () {
              _this256._zone.run(
              /**
              * @return {?}
              */
              function () {
                _this256._animationCallbacksBuffer.forEach(
                /**
                * @param {?} tuple
                * @return {?}
                */
                function (tuple) {
                  var _tuple2 = _slicedToArray(tuple, 2),
                      fn = _tuple2[0],
                      data = _tuple2[1];

                  fn(data);
                });

                _this256._animationCallbacksBuffer = [];
              });
            });
          }

          this._animationCallbacksBuffer.push([fn, data]);
        }
        /**
         * @return {?}
         */

      }, {
        key: "end",
        value: function end() {
          var _this257 = this;

          this._cdRecurDepth--; // this is to prevent animations from running twice when an inner
          // component does CD when a parent component instead has inserted it

          if (this._cdRecurDepth == 0) {
            this._zone.runOutsideAngular(
            /**
            * @return {?}
            */
            function () {
              _this257._scheduleCountTask();

              _this257.engine.flush(_this257._microtaskId);
            });
          }

          if (this.delegate.end) {
            this.delegate.end();
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "whenRenderingDone",
        value: function whenRenderingDone() {
          return this.engine.whenRenderingDone();
        }
      }]);

      return AnimationRendererFactory;
    }();

    AnimationRendererFactory.ɵfac = function AnimationRendererFactory_Factory(t) {
      return new (t || AnimationRendererFactory)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["RendererFactory2"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["ɵAnimationEngine"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["NgZone"]));
    };

    AnimationRendererFactory.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({
      token: AnimationRendererFactory,
      factory: AnimationRendererFactory.ɵfac
    });
    /** @nocollapse */

    AnimationRendererFactory.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["RendererFactory2"]
      }, {
        type: _angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["ɵAnimationEngine"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgZone"]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](AnimationRendererFactory, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["RendererFactory2"]
        }, {
          type: _angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["ɵAnimationEngine"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgZone"]
        }];
      }, null);
    })();

    if (false) {}

    var BaseAnimationRenderer = /*#__PURE__*/function () {
      /**
       * @param {?} namespaceId
       * @param {?} delegate
       * @param {?} engine
       */
      function BaseAnimationRenderer(namespaceId, delegate, engine) {
        _classCallCheck(this, BaseAnimationRenderer);

        this.namespaceId = namespaceId;
        this.delegate = delegate;
        this.engine = engine;
        this.destroyNode = this.delegate.destroyNode ?
        /**
        * @param {?} n
        * @return {?}
        */
        function (n) {
          return (
            /** @type {?} */
            delegate.destroyNode(n)
          );
        } : null;
      }
      /**
       * @return {?}
       */


      _createClass2(BaseAnimationRenderer, [{
        key: "destroy",

        /**
         * @return {?}
         */
        value: function destroy() {
          this.engine.destroy(this.namespaceId, this.delegate);
          this.delegate.destroy();
        }
        /**
         * @param {?} name
         * @param {?=} namespace
         * @return {?}
         */

      }, {
        key: "createElement",
        value: function createElement(name, namespace) {
          return this.delegate.createElement(name, namespace);
        }
        /**
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "createComment",
        value: function createComment(value) {
          return this.delegate.createComment(value);
        }
        /**
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "createText",
        value: function createText(value) {
          return this.delegate.createText(value);
        }
        /**
         * @param {?} parent
         * @param {?} newChild
         * @return {?}
         */

      }, {
        key: "appendChild",
        value: function appendChild(parent, newChild) {
          this.delegate.appendChild(parent, newChild);
          this.engine.onInsert(this.namespaceId, newChild, parent, false);
        }
        /**
         * @param {?} parent
         * @param {?} newChild
         * @param {?} refChild
         * @return {?}
         */

      }, {
        key: "insertBefore",
        value: function insertBefore(parent, newChild, refChild) {
          this.delegate.insertBefore(parent, newChild, refChild);
          this.engine.onInsert(this.namespaceId, newChild, parent, true);
        }
        /**
         * @param {?} parent
         * @param {?} oldChild
         * @param {?} isHostElement
         * @return {?}
         */

      }, {
        key: "removeChild",
        value: function removeChild(parent, oldChild, isHostElement) {
          this.engine.onRemove(this.namespaceId, oldChild, this.delegate, isHostElement);
        }
        /**
         * @param {?} selectorOrNode
         * @param {?=} preserveContent
         * @return {?}
         */

      }, {
        key: "selectRootElement",
        value: function selectRootElement(selectorOrNode, preserveContent) {
          return this.delegate.selectRootElement(selectorOrNode, preserveContent);
        }
        /**
         * @param {?} node
         * @return {?}
         */

      }, {
        key: "parentNode",
        value: function parentNode(node) {
          return this.delegate.parentNode(node);
        }
        /**
         * @param {?} node
         * @return {?}
         */

      }, {
        key: "nextSibling",
        value: function nextSibling(node) {
          return this.delegate.nextSibling(node);
        }
        /**
         * @param {?} el
         * @param {?} name
         * @param {?} value
         * @param {?=} namespace
         * @return {?}
         */

      }, {
        key: "setAttribute",
        value: function setAttribute(el, name, value, namespace) {
          this.delegate.setAttribute(el, name, value, namespace);
        }
        /**
         * @param {?} el
         * @param {?} name
         * @param {?=} namespace
         * @return {?}
         */

      }, {
        key: "removeAttribute",
        value: function removeAttribute(el, name, namespace) {
          this.delegate.removeAttribute(el, name, namespace);
        }
        /**
         * @param {?} el
         * @param {?} name
         * @return {?}
         */

      }, {
        key: "addClass",
        value: function addClass(el, name) {
          this.delegate.addClass(el, name);
        }
        /**
         * @param {?} el
         * @param {?} name
         * @return {?}
         */

      }, {
        key: "removeClass",
        value: function removeClass(el, name) {
          this.delegate.removeClass(el, name);
        }
        /**
         * @param {?} el
         * @param {?} style
         * @param {?} value
         * @param {?=} flags
         * @return {?}
         */

      }, {
        key: "setStyle",
        value: function setStyle(el, style, value, flags) {
          this.delegate.setStyle(el, style, value, flags);
        }
        /**
         * @param {?} el
         * @param {?} style
         * @param {?=} flags
         * @return {?}
         */

      }, {
        key: "removeStyle",
        value: function removeStyle(el, style, flags) {
          this.delegate.removeStyle(el, style, flags);
        }
        /**
         * @param {?} el
         * @param {?} name
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "setProperty",
        value: function setProperty(el, name, value) {
          if (name.charAt(0) == ANIMATION_PREFIX && name == DISABLE_ANIMATIONS_FLAG) {
            this.disableAnimations(el, !!value);
          } else {
            this.delegate.setProperty(el, name, value);
          }
        }
        /**
         * @param {?} node
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "setValue",
        value: function setValue(node, value) {
          this.delegate.setValue(node, value);
        }
        /**
         * @param {?} target
         * @param {?} eventName
         * @param {?} callback
         * @return {?}
         */

      }, {
        key: "listen",
        value: function listen(target, eventName, callback) {
          return this.delegate.listen(target, eventName, callback);
        }
        /**
         * @protected
         * @param {?} element
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "disableAnimations",
        value: function disableAnimations(element, value) {
          this.engine.disableAnimations(element, value);
        }
      }, {
        key: "data",
        get: function get() {
          return this.delegate.data;
        }
      }]);

      return BaseAnimationRenderer;
    }();

    if (false) {}

    var AnimationRenderer = /*#__PURE__*/function (_BaseAnimationRendere) {
      _inherits(AnimationRenderer, _BaseAnimationRendere);

      var _super86 = _createSuper(AnimationRenderer);

      /**
       * @param {?} factory
       * @param {?} namespaceId
       * @param {?} delegate
       * @param {?} engine
       */
      function AnimationRenderer(factory, namespaceId, delegate, engine) {
        var _this258;

        _classCallCheck(this, AnimationRenderer);

        _this258 = _super86.call(this, namespaceId, delegate, engine);
        _this258.factory = factory;
        _this258.namespaceId = namespaceId;
        return _this258;
      }
      /**
       * @param {?} el
       * @param {?} name
       * @param {?} value
       * @return {?}
       */


      _createClass2(AnimationRenderer, [{
        key: "setProperty",
        value: function setProperty(el, name, value) {
          if (name.charAt(0) == ANIMATION_PREFIX) {
            if (name.charAt(1) == '.' && name == DISABLE_ANIMATIONS_FLAG) {
              value = value === undefined ? true : !!value;
              this.disableAnimations(el,
              /** @type {?} */
              value);
            } else {
              this.engine.process(this.namespaceId, el, name.substr(1), value);
            }
          } else {
            this.delegate.setProperty(el, name, value);
          }
        }
        /**
         * @param {?} target
         * @param {?} eventName
         * @param {?} callback
         * @return {?}
         */

      }, {
        key: "listen",
        value: function listen(target, eventName, callback) {
          var _this259 = this;

          if (eventName.charAt(0) == ANIMATION_PREFIX) {
            /** @type {?} */
            var element = resolveElementFromTarget(target);
            /** @type {?} */

            var name = eventName.substr(1);
            /** @type {?} */

            var phase = ''; // @listener.phase is for trigger animation callbacks
            // @@listener is for animation builder callbacks

            if (name.charAt(0) != ANIMATION_PREFIX) {
              var _parseTriggerCallback = parseTriggerCallbackName(name);

              var _parseTriggerCallback2 = _slicedToArray(_parseTriggerCallback, 2);

              name = _parseTriggerCallback2[0];
              phase = _parseTriggerCallback2[1];
            }

            return this.engine.listen(this.namespaceId, element, name, phase,
            /**
            * @param {?} event
            * @return {?}
            */
            function (event) {
              /** @type {?} */
              var countId =
              /** @type {?} */
              event['_data'] || -1;

              _this259.factory.scheduleListenerCallback(countId, callback, event);
            });
          }

          return this.delegate.listen(target, eventName, callback);
        }
      }]);

      return AnimationRenderer;
    }(BaseAnimationRenderer);

    if (false) {}
    /**
     * @param {?} target
     * @return {?}
     */


    function resolveElementFromTarget(target) {
      switch (target) {
        case 'body':
          return document.body;

        case 'document':
          return document;

        case 'window':
          return window;

        default:
          return target;
      }
    }
    /**
     * @param {?} triggerName
     * @return {?}
     */


    function parseTriggerCallbackName(triggerName) {
      /** @type {?} */
      var dotIndex = triggerName.indexOf('.');
      /** @type {?} */

      var trigger = triggerName.substring(0, dotIndex);
      /** @type {?} */

      var phase = triggerName.substr(dotIndex + 1);
      return [trigger, phase];
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/animations/src/providers.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var InjectableAnimationEngine = /*#__PURE__*/function (_angular_animations_b) {
      _inherits(InjectableAnimationEngine, _angular_animations_b);

      var _super87 = _createSuper(InjectableAnimationEngine);

      /**
       * @param {?} doc
       * @param {?} driver
       * @param {?} normalizer
       */
      function InjectableAnimationEngine(doc, driver, normalizer) {
        _classCallCheck(this, InjectableAnimationEngine);

        return _super87.call(this, doc.body, driver, normalizer);
      }

      return InjectableAnimationEngine;
    }(_angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["ɵAnimationEngine"]);

    InjectableAnimationEngine.ɵfac = function InjectableAnimationEngine_Factory(t) {
      return new (t || InjectableAnimationEngine)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["AnimationDriver"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["ɵAnimationStyleNormalizer"]));
    };

    InjectableAnimationEngine.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({
      token: InjectableAnimationEngine,
      factory: InjectableAnimationEngine.ɵfac
    });
    /** @nocollapse */

    InjectableAnimationEngine.ctorParameters = function () {
      return [{
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]]
        }]
      }, {
        type: _angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["AnimationDriver"]
      }, {
        type: _angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["ɵAnimationStyleNormalizer"]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](InjectableAnimationEngine, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injectable"]
      }], function () {
        return [{
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_4__["DOCUMENT"]]
          }]
        }, {
          type: _angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["AnimationDriver"]
        }, {
          type: _angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["ɵAnimationStyleNormalizer"]
        }];
      }, null);
    })();
    /**
     * @return {?}
     */


    function instantiateSupportedAnimationDriver() {
      return Object(_angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["ɵsupportsWebAnimations"])() ? new _angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["ɵWebAnimationsDriver"]() : new _angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["ɵCssKeyframesDriver"]();
    }
    /**
     * @return {?}
     */


    function instantiateDefaultStyleNormalizer() {
      return new _angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["ɵWebAnimationsStyleNormalizer"]();
    }
    /**
     * @param {?} renderer
     * @param {?} engine
     * @param {?} zone
     * @return {?}
     */


    function instantiateRendererFactory(renderer, engine, zone) {
      return new AnimationRendererFactory(renderer, engine, zone);
    }
    /**
     * \@publicApi
     * @type {?}
     */


    var ANIMATION_MODULE_TYPE = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('AnimationModuleType');
    /** @type {?} */

    var SHARED_ANIMATION_PROVIDERS = [{
      provide: _angular_animations__WEBPACK_IMPORTED_MODULE_2__["AnimationBuilder"],
      useClass: BrowserAnimationBuilder
    }, {
      provide: _angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["ɵAnimationStyleNormalizer"],
      useFactory: instantiateDefaultStyleNormalizer
    }, {
      provide: _angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["ɵAnimationEngine"],
      useClass: InjectableAnimationEngine
    }, {
      provide: _angular_core__WEBPACK_IMPORTED_MODULE_0__["RendererFactory2"],
      useFactory: instantiateRendererFactory,
      deps: [_angular_platform_browser__WEBPACK_IMPORTED_MODULE_1__["ɵDomRendererFactory2"], _angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["ɵAnimationEngine"], _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgZone"]]
    }];
    /**
     * Separate providers from the actual module so that we can do a local modification in Google3 to
     * include them in the BrowserModule.
     * @type {?}
     */

    var BROWSER_ANIMATIONS_PROVIDERS = [{
      provide: _angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["AnimationDriver"],
      useFactory: instantiateSupportedAnimationDriver
    }, {
      provide: ANIMATION_MODULE_TYPE,
      useValue: 'BrowserAnimations'
    }].concat(SHARED_ANIMATION_PROVIDERS);
    /**
     * Separate providers from the actual module so that we can do a local modification in Google3 to
     * include them in the BrowserTestingModule.
     * @type {?}
     */

    var BROWSER_NOOP_ANIMATIONS_PROVIDERS = [{
      provide: _angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["AnimationDriver"],
      useClass: _angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["ɵNoopAnimationDriver"]
    }, {
      provide: ANIMATION_MODULE_TYPE,
      useValue: 'NoopAnimations'
    }].concat(SHARED_ANIMATION_PROVIDERS);
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/animations/src/module.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Exports `BrowserModule` with additional [dependency-injection providers](guide/glossary#provider)
     * for use with animations. See [Animations](guide/animations).
     * \@publicApi
     */

    var BrowserAnimationsModule = function BrowserAnimationsModule() {
      _classCallCheck(this, BrowserAnimationsModule);
    };

    BrowserAnimationsModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: BrowserAnimationsModule
    });
    BrowserAnimationsModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function BrowserAnimationsModule_Factory(t) {
        return new (t || BrowserAnimationsModule)();
      },
      providers: BROWSER_ANIMATIONS_PROVIDERS,
      imports: [_angular_platform_browser__WEBPACK_IMPORTED_MODULE_1__["BrowserModule"]]
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](BrowserAnimationsModule, {
        exports: function exports() {
          return [_angular_platform_browser__WEBPACK_IMPORTED_MODULE_1__["BrowserModule"]];
        }
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](BrowserAnimationsModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{
          exports: [_angular_platform_browser__WEBPACK_IMPORTED_MODULE_1__["BrowserModule"]],
          providers: BROWSER_ANIMATIONS_PROVIDERS
        }]
      }], null, null);
    })();
    /**
     * A null player that must be imported to allow disabling of animations.
     * \@publicApi
     */


    var NoopAnimationsModule = function NoopAnimationsModule() {
      _classCallCheck(this, NoopAnimationsModule);
    };

    NoopAnimationsModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({
      type: NoopAnimationsModule
    });
    NoopAnimationsModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({
      factory: function NoopAnimationsModule_Factory(t) {
        return new (t || NoopAnimationsModule)();
      },
      providers: BROWSER_NOOP_ANIMATIONS_PROVIDERS,
      imports: [_angular_platform_browser__WEBPACK_IMPORTED_MODULE_1__["BrowserModule"]]
    });

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](NoopAnimationsModule, {
        exports: function exports() {
          return [_angular_platform_browser__WEBPACK_IMPORTED_MODULE_1__["BrowserModule"]];
        }
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵsetClassMetadata"](NoopAnimationsModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"],
        args: [{
          exports: [_angular_platform_browser__WEBPACK_IMPORTED_MODULE_1__["BrowserModule"]],
          providers: BROWSER_NOOP_ANIMATIONS_PROVIDERS
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/animations/src/private_export.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/animations/src/animations.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/animations/public_api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/animations/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=animations.js.map

    /***/

  },

  /***/
  "./node_modules/@angular/platform-browser/__ivy_ngcc__/fesm2015/platform-browser.js":
  /*!******************************************************************************************!*\
    !*** ./node_modules/@angular/platform-browser/__ivy_ngcc__/fesm2015/platform-browser.js ***!
    \******************************************************************************************/

  /*! exports provided: ɵgetDOM, BrowserModule, BrowserTransferStateModule, By, DomSanitizer, EVENT_MANAGER_PLUGINS, EventManager, HAMMER_GESTURE_CONFIG, HAMMER_LOADER, HammerGestureConfig, HammerModule, Meta, Title, TransferState, VERSION, disableDebugTools, enableDebugTools, makeStateKey, platformBrowser, ɵBROWSER_SANITIZATION_PROVIDERS, ɵBROWSER_SANITIZATION_PROVIDERS__POST_R3__, ɵBrowserDomAdapter, ɵBrowserGetTestability, ɵDomEventsPlugin, ɵDomRendererFactory2, ɵDomSanitizerImpl, ɵDomSharedStylesHost, ɵELEMENT_PROBE_PROVIDERS, ɵELEMENT_PROBE_PROVIDERS__POST_R3__, ɵHAMMER_PROVIDERS__POST_R3__, ɵHammerGesturesPlugin, ɵINTERNAL_BROWSER_PLATFORM_PROVIDERS, ɵKeyEventsPlugin, ɵNAMESPACE_URIS, ɵSharedStylesHost, ɵTRANSITION_ID, ɵangular_packages_platform_browser_platform_browser_a, ɵangular_packages_platform_browser_platform_browser_b, ɵangular_packages_platform_browser_platform_browser_c, ɵangular_packages_platform_browser_platform_browser_d, ɵangular_packages_platform_browser_platform_browser_e, ɵangular_packages_platform_browser_platform_browser_f, ɵangular_packages_platform_browser_platform_browser_g, ɵangular_packages_platform_browser_platform_browser_h, ɵangular_packages_platform_browser_platform_browser_i, ɵangular_packages_platform_browser_platform_browser_j, ɵangular_packages_platform_browser_platform_browser_k, ɵangular_packages_platform_browser_platform_browser_l, ɵangular_packages_platform_browser_platform_browser_m, ɵangular_packages_platform_browser_platform_browser_n, ɵangular_packages_platform_browser_platform_browser_o, ɵescapeHtml, ɵflattenStyles, ɵinitDomAdapter, ɵshimContentAttribute, ɵshimHostAttribute */

  /***/
  function node_modulesAngularPlatformBrowser__ivy_ngcc__Fesm2015PlatformBrowserJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "BrowserModule", function () {
      return BrowserModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "BrowserTransferStateModule", function () {
      return BrowserTransferStateModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "By", function () {
      return By;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DomSanitizer", function () {
      return DomSanitizer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "EVENT_MANAGER_PLUGINS", function () {
      return EVENT_MANAGER_PLUGINS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "EventManager", function () {
      return EventManager;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HAMMER_GESTURE_CONFIG", function () {
      return HAMMER_GESTURE_CONFIG;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HAMMER_LOADER", function () {
      return HAMMER_LOADER;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HammerGestureConfig", function () {
      return HammerGestureConfig;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "HammerModule", function () {
      return HammerModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Meta", function () {
      return Meta;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Title", function () {
      return Title;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "TransferState", function () {
      return TransferState;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "VERSION", function () {
      return VERSION;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "disableDebugTools", function () {
      return disableDebugTools;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "enableDebugTools", function () {
      return enableDebugTools;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "makeStateKey", function () {
      return makeStateKey;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "platformBrowser", function () {
      return platformBrowser;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵBROWSER_SANITIZATION_PROVIDERS", function () {
      return BROWSER_SANITIZATION_PROVIDERS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵBROWSER_SANITIZATION_PROVIDERS__POST_R3__", function () {
      return BROWSER_SANITIZATION_PROVIDERS__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵBrowserDomAdapter", function () {
      return BrowserDomAdapter;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵBrowserGetTestability", function () {
      return BrowserGetTestability;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵDomEventsPlugin", function () {
      return DomEventsPlugin;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵDomRendererFactory2", function () {
      return DomRendererFactory2;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵDomSanitizerImpl", function () {
      return DomSanitizerImpl;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵDomSharedStylesHost", function () {
      return DomSharedStylesHost;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵELEMENT_PROBE_PROVIDERS", function () {
      return ELEMENT_PROBE_PROVIDERS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵELEMENT_PROBE_PROVIDERS__POST_R3__", function () {
      return ELEMENT_PROBE_PROVIDERS__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵHAMMER_PROVIDERS__POST_R3__", function () {
      return HAMMER_PROVIDERS__POST_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵHammerGesturesPlugin", function () {
      return HammerGesturesPlugin;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵINTERNAL_BROWSER_PLATFORM_PROVIDERS", function () {
      return INTERNAL_BROWSER_PLATFORM_PROVIDERS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵKeyEventsPlugin", function () {
      return KeyEventsPlugin;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵNAMESPACE_URIS", function () {
      return NAMESPACE_URIS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵSharedStylesHost", function () {
      return SharedStylesHost;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵTRANSITION_ID", function () {
      return TRANSITION_ID;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_platform_browser_a", function () {
      return errorHandler;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_platform_browser_b", function () {
      return _document;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_platform_browser_c", function () {
      return BROWSER_MODULE_PROVIDERS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_platform_browser_d", function () {
      return createMeta;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_platform_browser_e", function () {
      return createTitle;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_platform_browser_f", function () {
      return initTransferState;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_platform_browser_g", function () {
      return EventManagerPlugin;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_platform_browser_h", function () {
      return HAMMER_PROVIDERS__PRE_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_platform_browser_i", function () {
      return HAMMER_PROVIDERS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_platform_browser_j", function () {
      return domSanitizerImplFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_platform_browser_k", function () {
      return appInitializerFactory;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_platform_browser_l", function () {
      return SERVER_TRANSITION_PROVIDERS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_platform_browser_m", function () {
      return _createNgProbeR2;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_platform_browser_n", function () {
      return ELEMENT_PROBE_PROVIDERS__PRE_R3__;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_platform_browser_platform_browser_o", function () {
      return GenericBrowserDomAdapter;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵescapeHtml", function () {
      return escapeHtml;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵflattenStyles", function () {
      return flattenStyles;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵinitDomAdapter", function () {
      return initDomAdapter;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵshimContentAttribute", function () {
      return shimContentAttribute;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵshimHostAttribute", function () {
      return shimHostAttribute;
    });
    /* harmony import */


    var _angular_common__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/common */
    "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/common.js");
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "ɵgetDOM", function () {
      return _angular_common__WEBPACK_IMPORTED_MODULE_0__["ɵgetDOM"];
    });
    /**
     * @license Angular v9.1.4
     * (c) 2010-2020 Google LLC. https://angular.io/
     * License: MIT
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/browser/generic_browser_adapter.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Provides DOM operations in any browser environment.
     *
     * \@security Tread carefully! Interacting with the DOM directly is dangerous and
     * can introduce XSS risks.
     * @abstract
     */


    var GenericBrowserDomAdapter = /*#__PURE__*/function (_angular_common__WEBP) {
      _inherits(GenericBrowserDomAdapter, _angular_common__WEBP);

      var _super88 = _createSuper(GenericBrowserDomAdapter);

      function GenericBrowserDomAdapter() {
        _classCallCheck(this, GenericBrowserDomAdapter);

        return _super88.call(this);
      }
      /**
       * @return {?}
       */


      _createClass2(GenericBrowserDomAdapter, [{
        key: "supportsDOMEvents",
        value: function supportsDOMEvents() {
          return true;
        }
      }]);

      return GenericBrowserDomAdapter;
    }(_angular_common__WEBPACK_IMPORTED_MODULE_0__["ɵDomAdapter"]);
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/browser/browser_adapter.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var ɵ0 =
    /**
    * @return {?}
    */
    function ɵ0() {
      if (_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵglobal"]['Node']) {
        return _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵglobal"]['Node'].prototype.contains ||
        /**
        * @this {?}
        * @param {?} node
        * @return {?}
        */
        function (node) {
          return !!(this.compareDocumentPosition(node) & 16);
        };
      }

      return (
        /** @type {?} */
        undefined
      );
    };
    /** @type {?} */


    var nodeContains = ɵ0();
    /**
     * A `DomAdapter` powered by full browser DOM APIs.
     *
     * \@security Tread carefully! Interacting with the DOM directly is dangerous and
     * can introduce XSS risks.
     */

    /* tslint:disable:requireParameterType no-console */

    var BrowserDomAdapter = /*#__PURE__*/function (_GenericBrowserDomAda) {
      _inherits(BrowserDomAdapter, _GenericBrowserDomAda);

      var _super89 = _createSuper(BrowserDomAdapter);

      function BrowserDomAdapter() {
        _classCallCheck(this, BrowserDomAdapter);

        return _super89.apply(this, arguments);
      }

      _createClass2(BrowserDomAdapter, [{
        key: "getProperty",

        /**
         * @param {?} el
         * @param {?} name
         * @return {?}
         */
        value: function getProperty(el, name) {
          return (
            /** @type {?} */
            el[name]
          );
        }
        /**
         * @param {?} error
         * @return {?}
         */

      }, {
        key: "log",
        value: function log(error) {
          if (window.console) {
            window.console.log && window.console.log(error);
          }
        }
        /**
         * @param {?} error
         * @return {?}
         */

      }, {
        key: "logGroup",
        value: function logGroup(error) {
          if (window.console) {
            window.console.group && window.console.group(error);
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "logGroupEnd",
        value: function logGroupEnd() {
          if (window.console) {
            window.console.groupEnd && window.console.groupEnd();
          }
        }
        /**
         * @param {?} el
         * @param {?} evt
         * @param {?} listener
         * @return {?}
         */

      }, {
        key: "onAndCancel",
        value: function onAndCancel(el, evt, listener) {
          el.addEventListener(evt, listener, false); // Needed to follow Dart's subscription semantic, until fix of
          // https://code.google.com/p/dart/issues/detail?id=17406

          return (
            /**
            * @return {?}
            */
            function () {
              el.removeEventListener(evt, listener, false);
            }
          );
        }
        /**
         * @param {?} el
         * @param {?} evt
         * @return {?}
         */

      }, {
        key: "dispatchEvent",
        value: function dispatchEvent(el, evt) {
          el.dispatchEvent(evt);
        }
        /**
         * @param {?} node
         * @return {?}
         */

      }, {
        key: "remove",
        value: function remove(node) {
          if (node.parentNode) {
            node.parentNode.removeChild(node);
          }

          return node;
        }
        /**
         * @param {?} el
         * @return {?}
         */

      }, {
        key: "getValue",
        value: function getValue(el) {
          return el.value;
        }
        /**
         * @param {?} tagName
         * @param {?=} doc
         * @return {?}
         */

      }, {
        key: "createElement",
        value: function createElement(tagName, doc) {
          doc = doc || this.getDefaultDocument();
          return doc.createElement(tagName);
        }
        /**
         * @return {?}
         */

      }, {
        key: "createHtmlDocument",
        value: function createHtmlDocument() {
          return document.implementation.createHTMLDocument('fakeTitle');
        }
        /**
         * @return {?}
         */

      }, {
        key: "getDefaultDocument",
        value: function getDefaultDocument() {
          return document;
        }
        /**
         * @param {?} node
         * @return {?}
         */

      }, {
        key: "isElementNode",
        value: function isElementNode(node) {
          return node.nodeType === Node.ELEMENT_NODE;
        }
        /**
         * @param {?} node
         * @return {?}
         */

      }, {
        key: "isShadowRoot",
        value: function isShadowRoot(node) {
          return node instanceof DocumentFragment;
        }
        /**
         * @param {?} doc
         * @param {?} target
         * @return {?}
         */

      }, {
        key: "getGlobalEventTarget",
        value: function getGlobalEventTarget(doc, target) {
          if (target === 'window') {
            return window;
          }

          if (target === 'document') {
            return doc;
          }

          if (target === 'body') {
            return doc.body;
          }

          return null;
        }
        /**
         * @return {?}
         */

      }, {
        key: "getHistory",
        value: function getHistory() {
          return window.history;
        }
        /**
         * @return {?}
         */

      }, {
        key: "getLocation",
        value: function getLocation() {
          return window.location;
        }
        /**
         * @param {?} doc
         * @return {?}
         */

      }, {
        key: "getBaseHref",
        value: function getBaseHref(doc) {
          /** @type {?} */
          var href = getBaseElementHref();
          return href == null ? null : relativePath(href);
        }
        /**
         * @return {?}
         */

      }, {
        key: "resetBaseElement",
        value: function resetBaseElement() {
          baseElement = null;
        }
        /**
         * @return {?}
         */

      }, {
        key: "getUserAgent",
        value: function getUserAgent() {
          return window.navigator.userAgent;
        }
        /**
         * @return {?}
         */

      }, {
        key: "performanceNow",
        value: function performanceNow() {
          // performance.now() is not available in all browsers, see
          // http://caniuse.com/#search=performance.now
          return window.performance && window.performance.now ? window.performance.now() : new Date().getTime();
        }
        /**
         * @return {?}
         */

      }, {
        key: "supportsCookies",
        value: function supportsCookies() {
          return true;
        }
        /**
         * @param {?} name
         * @return {?}
         */

      }, {
        key: "getCookie",
        value: function getCookie(name) {
          return Object(_angular_common__WEBPACK_IMPORTED_MODULE_0__["ɵparseCookieValue"])(document.cookie, name);
        }
      }], [{
        key: "makeCurrent",

        /**
         * @return {?}
         */
        value: function makeCurrent() {
          Object(_angular_common__WEBPACK_IMPORTED_MODULE_0__["ɵsetRootDomAdapter"])(new BrowserDomAdapter());
        }
      }]);

      return BrowserDomAdapter;
    }(GenericBrowserDomAdapter);
    /** @type {?} */


    var baseElement = null;
    /**
     * @return {?}
     */

    function getBaseElementHref() {
      if (!baseElement) {
        baseElement =
        /** @type {?} */
        document.querySelector('base');

        if (!baseElement) {
          return null;
        }
      }

      return baseElement.getAttribute('href');
    } // based on urlUtils.js in AngularJS 1

    /** @type {?} */


    var urlParsingNode;
    /**
     * @param {?} url
     * @return {?}
     */

    function relativePath(url) {
      if (!urlParsingNode) {
        urlParsingNode = document.createElement('a');
      }

      urlParsingNode.setAttribute('href', url);
      return urlParsingNode.pathname.charAt(0) === '/' ? urlParsingNode.pathname : '/' + urlParsingNode.pathname;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/browser/server-transition.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * An id that identifies a particular application being bootstrapped, that should
     * match across the client/server boundary.
     * @type {?}
     */


    var TRANSITION_ID = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["InjectionToken"]('TRANSITION_ID');
    /**
     * @param {?} transitionId
     * @param {?} document
     * @param {?} injector
     * @return {?}
     */

    function appInitializerFactory(transitionId, document, injector) {
      return (
        /**
        * @return {?}
        */
        function () {
          // Wait for all application initializers to be completed before removing the styles set by
          // the server.
          injector.get(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ApplicationInitStatus"]).donePromise.then(
          /**
          * @return {?}
          */
          function () {
            /** @type {?} */
            var dom = Object(_angular_common__WEBPACK_IMPORTED_MODULE_0__["ɵgetDOM"])();
            /** @type {?} */

            var styles = Array.prototype.slice.apply(document.querySelectorAll("style[ng-transition]"));
            styles.filter(
            /**
            * @param {?} el
            * @return {?}
            */
            function (el) {
              return el.getAttribute('ng-transition') === transitionId;
            }).forEach(
            /**
            * @param {?} el
            * @return {?}
            */
            function (el) {
              return dom.remove(el);
            });
          });
        }
      );
    }
    /** @type {?} */


    var SERVER_TRANSITION_PROVIDERS = [{
      provide: _angular_core__WEBPACK_IMPORTED_MODULE_1__["APP_INITIALIZER"],
      useFactory: appInitializerFactory,
      deps: [TRANSITION_ID, _angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"], _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injector"]],
      multi: true
    }];
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/browser/testability.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    var BrowserGetTestability = /*#__PURE__*/function () {
      function BrowserGetTestability() {
        _classCallCheck(this, BrowserGetTestability);
      }

      _createClass2(BrowserGetTestability, [{
        key: "addToWindow",

        /**
         * @param {?} registry
         * @return {?}
         */
        value: function addToWindow(registry) {
          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵglobal"]['getAngularTestability'] =
          /**
          * @param {?} elem
          * @param {?=} findInAncestors
          * @return {?}
          */
          function (elem) {
            var findInAncestors = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;

            /** @type {?} */
            var testability = registry.findTestabilityInTree(elem, findInAncestors);

            if (testability == null) {
              throw new Error('Could not find testability for element.');
            }

            return testability;
          };

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵglobal"]['getAllAngularTestabilities'] =
          /**
          * @return {?}
          */
          function () {
            return registry.getAllTestabilities();
          };

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵglobal"]['getAllAngularRootElements'] =
          /**
          * @return {?}
          */
          function () {
            return registry.getAllRootElements();
          };
          /** @type {?} */


          var whenAllStable =
          /**
          * @param {?} callback
          * @return {?}
          */
          function whenAllStable(callback
          /** TODO #9100 */
          ) {
            /** @type {?} */
            var testabilities = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵglobal"]['getAllAngularTestabilities']();
            /** @type {?} */


            var count = testabilities.length;
            /** @type {?} */

            var didWork = false;
            /** @type {?} */

            var decrement =
            /**
            * @param {?} didWork_
            * @return {?}
            */
            function decrement(didWork_
            /** TODO #9100 */
            ) {
              didWork = didWork || didWork_;
              count--;

              if (count == 0) {
                callback(didWork);
              }
            };

            testabilities.forEach(
            /**
            * @param {?} testability
            * @return {?}
            */
            function (testability
            /** TODO #9100 */
            ) {
              testability.whenStable(decrement);
            });
          };

          if (!_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵglobal"]['frameworkStabilizers']) {
            _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵglobal"]['frameworkStabilizers'] = [];
          }

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵglobal"]['frameworkStabilizers'].push(whenAllStable);
        }
        /**
         * @param {?} registry
         * @param {?} elem
         * @param {?} findInAncestors
         * @return {?}
         */

      }, {
        key: "findTestabilityInTree",
        value: function findTestabilityInTree(registry, elem, findInAncestors) {
          if (elem == null) {
            return null;
          }
          /** @type {?} */


          var t = registry.getTestability(elem);

          if (t != null) {
            return t;
          } else if (!findInAncestors) {
            return null;
          }

          if (Object(_angular_common__WEBPACK_IMPORTED_MODULE_0__["ɵgetDOM"])().isShadowRoot(elem)) {
            return this.findTestabilityInTree(registry,
            /** @type {?} */
            elem.host, true);
          }

          return this.findTestabilityInTree(registry, elem.parentElement, true);
        }
      }], [{
        key: "init",

        /**
         * @return {?}
         */
        value: function init() {
          Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["setTestabilityGetter"])(new BrowserGetTestability());
        }
      }]);

      return BrowserGetTestability;
    }();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/dom/util.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var CAMEL_CASE_REGEXP = /([A-Z])/g;
    /** @type {?} */

    var DASH_CASE_REGEXP = /-([a-z])/g;
    /**
     * @param {?} input
     * @return {?}
     */

    function camelCaseToDashCase(input) {
      return input.replace(CAMEL_CASE_REGEXP,
      /**
      * @param {...?} m
      * @return {?}
      */
      function () {
        for (var _len28 = arguments.length, m = new Array(_len28), _key29 = 0; _key29 < _len28; _key29++) {
          m[_key29] = arguments[_key29];
        }

        return '-' + m[1].toLowerCase();
      });
    }
    /**
     * @param {?} input
     * @return {?}
     */


    function dashCaseToCamelCase(input) {
      return input.replace(DASH_CASE_REGEXP,
      /**
      * @param {...?} m
      * @return {?}
      */
      function () {
        for (var _len29 = arguments.length, m = new Array(_len29), _key30 = 0; _key30 < _len29; _key30++) {
          m[_key30] = arguments[_key30];
        }

        return m[1].toUpperCase();
      });
    }
    /**
     * Exports the value under a given `name` in the global property `ng`. For example `ng.probe` if
     * `name` is `'probe'`.
     * @param {?} name Name under which it will be exported. Keep in mind this will be a property of the
     * global `ng` object.
     * @param {?} value The value to export.
     * @return {?}
     */


    function exportNgVar(name, value) {
      if (typeof COMPILED === 'undefined' || !COMPILED) {
        // Note: we can't export `ng` when using closure enhanced optimization as:
        // - closure declares globals itself for minified names, which sometimes clobber our `ng` global
        // - we can't declare a closure extern as the namespace `ng` is already used within Google
        //   for typings for angularJS (via `goog.provide('ng....')`).

        /** @type {?} */
        var ng = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵglobal"]['ng'] =
        /** @type {?} */
        _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵglobal"]['ng'] || {};
        ng[name] = value;
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/dom/debug/ng_probe.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var ɵ0$1 =
    /**
    * @return {?}
    */
    function ɵ0$1() {
      return {
        'ApplicationRef': _angular_core__WEBPACK_IMPORTED_MODULE_1__["ApplicationRef"],
        'NgZone': _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
      };
    };
    /** @type {?} */


    var CORE_TOKENS = ɵ0$1();
    /** @type {?} */

    var INSPECT_GLOBAL_NAME = 'probe';
    /** @type {?} */

    var CORE_TOKENS_GLOBAL_NAME = 'coreTokens';
    /**
     * Returns a {\@link DebugElement} for the given native DOM element, or
     * null if the given native element does not have an Angular view associated
     * with it.
     * @param {?} element
     * @return {?}
     */

    function inspectNativeElementR2(element) {
      return Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵgetDebugNodeR2"])(element);
    }
    /**
     * @param {?} coreTokens
     * @return {?}
     */


    function _createNgProbeR2(coreTokens) {
      exportNgVar(INSPECT_GLOBAL_NAME, inspectNativeElementR2);
      exportNgVar(CORE_TOKENS_GLOBAL_NAME, Object.assign(Object.assign({}, CORE_TOKENS), _ngProbeTokensToMap(coreTokens || [])));
      return (
        /**
        * @return {?}
        */
        function () {
          return inspectNativeElementR2;
        }
      );
    }
    /**
     * @param {?} tokens
     * @return {?}
     */


    function _ngProbeTokensToMap(tokens) {
      return tokens.reduce(
      /**
      * @param {?} prev
      * @param {?} t
      * @return {?}
      */
      function (prev, t) {
        return prev[t.name] = t.token, prev;
      }, {});
    }
    /**
     * In Ivy, we don't support NgProbe because we have our own set of testing utilities
     * with more robust functionality.
     *
     * We shouldn't bring in NgProbe because it prevents DebugNode and friends from
     * tree-shaking properly.
     * @type {?}
     */


    var ELEMENT_PROBE_PROVIDERS__POST_R3__ = [];
    /**
     * Providers which support debugging Angular applications (e.g. via `ng.probe`).
     * @type {?}
     */

    var ELEMENT_PROBE_PROVIDERS__PRE_R3__ = [{
      provide: _angular_core__WEBPACK_IMPORTED_MODULE_1__["APP_INITIALIZER"],
      useFactory: _createNgProbeR2,
      deps: [[_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgProbeToken"], new _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]()]],
      multi: true
    }];
    /** @type {?} */

    var ELEMENT_PROBE_PROVIDERS = ELEMENT_PROBE_PROVIDERS__POST_R3__;
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/dom/events/event_manager.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * The injection token for the event-manager plug-in service.
     *
     * \@publicApi
     * @type {?}
     */

    var EVENT_MANAGER_PLUGINS = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["InjectionToken"]('EventManagerPlugins');
    /**
     * An injectable service that provides event management for Angular
     * through a browser plug-in.
     *
     * \@publicApi
     */

    var EventManager = /*#__PURE__*/function () {
      /**
       * Initializes an instance of the event-manager service.
       * @param {?} plugins
       * @param {?} _zone
       */
      function EventManager(plugins, _zone) {
        var _this260 = this;

        _classCallCheck(this, EventManager);

        this._zone = _zone;
        this._eventNameToPlugin = new Map();
        plugins.forEach(
        /**
        * @template THIS
        * @this {THIS}
        * @param {?} p
        * @return {THIS}
        */
        function (p) {
          return p.manager = _this260;
        });
        this._plugins = plugins.slice().reverse();
      }
      /**
       * Registers a handler for a specific element and event.
       *
       * @param {?} element The HTML element to receive event notifications.
       * @param {?} eventName The name of the event to listen for.
       * @param {?} handler A function to call when the notification occurs. Receives the
       * event object as an argument.
       * @return {?} A callback function that can be used to remove the handler.
       */


      _createClass2(EventManager, [{
        key: "addEventListener",
        value: function addEventListener(element, eventName, handler) {
          /** @type {?} */
          var plugin = this._findPluginFor(eventName);

          return plugin.addEventListener(element, eventName, handler);
        }
        /**
         * Registers a global handler for an event in a target view.
         *
         * @param {?} target A target for global event notifications. One of "window", "document", or "body".
         * @param {?} eventName The name of the event to listen for.
         * @param {?} handler A function to call when the notification occurs. Receives the
         * event object as an argument.
         * @return {?} A callback function that can be used to remove the handler.
         */

      }, {
        key: "addGlobalEventListener",
        value: function addGlobalEventListener(target, eventName, handler) {
          /** @type {?} */
          var plugin = this._findPluginFor(eventName);

          return plugin.addGlobalEventListener(target, eventName, handler);
        }
        /**
         * Retrieves the compilation zone in which event listeners are registered.
         * @return {?}
         */

      }, {
        key: "getZone",
        value: function getZone() {
          return this._zone;
        }
        /**
         * \@internal
         * @param {?} eventName
         * @return {?}
         */

      }, {
        key: "_findPluginFor",
        value: function _findPluginFor(eventName) {
          /** @type {?} */
          var plugin = this._eventNameToPlugin.get(eventName);

          if (plugin) {
            return plugin;
          }
          /** @type {?} */


          var plugins = this._plugins;

          for (var i = 0; i < plugins.length; i++) {
            /** @type {?} */
            var _plugin = plugins[i];

            if (_plugin.supports(eventName)) {
              this._eventNameToPlugin.set(eventName, _plugin);

              return _plugin;
            }
          }

          throw new Error("No event manager plugin found for event ".concat(eventName));
        }
      }]);

      return EventManager;
    }();

    EventManager.ɵfac = function EventManager_Factory(t) {
      return new (t || EventManager)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](EVENT_MANAGER_PLUGINS), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]));
    };

    EventManager.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"]({
      token: EventManager,
      factory: EventManager.ɵfac
    });
    /** @nocollapse */

    EventManager.ctorParameters = function () {
      return [{
        type: Array,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [EVENT_MANAGER_PLUGINS]
        }]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](EventManager, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"]
      }], function () {
        return [{
          type: Array,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [EVENT_MANAGER_PLUGINS]
          }]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @abstract
     */


    var EventManagerPlugin = /*#__PURE__*/function () {
      /**
       * @param {?} _doc
       */
      function EventManagerPlugin(_doc) {
        _classCallCheck(this, EventManagerPlugin);

        this._doc = _doc;
      }
      /**
       * @param {?} element
       * @param {?} eventName
       * @param {?} handler
       * @return {?}
       */


      _createClass2(EventManagerPlugin, [{
        key: "addGlobalEventListener",
        value: function addGlobalEventListener(element, eventName, handler) {
          /** @type {?} */
          var target = Object(_angular_common__WEBPACK_IMPORTED_MODULE_0__["ɵgetDOM"])().getGlobalEventTarget(this._doc, element);

          if (!target) {
            throw new Error("Unsupported event target ".concat(target, " for event ").concat(eventName));
          }

          return this.addEventListener(target, eventName, handler);
        }
      }]);

      return EventManagerPlugin;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/dom/shared_styles_host.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var SharedStylesHost = /*#__PURE__*/function () {
      function SharedStylesHost() {
        _classCallCheck(this, SharedStylesHost);

        /**
         * \@internal
         */
        this._stylesSet = new Set();
      }
      /**
       * @param {?} styles
       * @return {?}
       */


      _createClass2(SharedStylesHost, [{
        key: "addStyles",
        value: function addStyles(styles) {
          var _this261 = this;

          /** @type {?} */
          var additions = new Set();
          styles.forEach(
          /**
          * @param {?} style
          * @return {?}
          */
          function (style) {
            if (!_this261._stylesSet.has(style)) {
              _this261._stylesSet.add(style);

              additions.add(style);
            }
          });
          this.onStylesAdded(additions);
        }
        /**
         * @param {?} additions
         * @return {?}
         */

      }, {
        key: "onStylesAdded",
        value: function onStylesAdded(additions) {}
        /**
         * @return {?}
         */

      }, {
        key: "getAllStyles",
        value: function getAllStyles() {
          return Array.from(this._stylesSet);
        }
      }]);

      return SharedStylesHost;
    }();

    SharedStylesHost.ɵfac = function SharedStylesHost_Factory(t) {
      return new (t || SharedStylesHost)();
    };

    SharedStylesHost.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"]({
      token: SharedStylesHost,
      factory: SharedStylesHost.ɵfac
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](SharedStylesHost, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"]
      }], function () {
        return [];
      }, null);
    })();

    if (false) {}

    var DomSharedStylesHost = /*#__PURE__*/function (_SharedStylesHost) {
      _inherits(DomSharedStylesHost, _SharedStylesHost);

      var _super90 = _createSuper(DomSharedStylesHost);

      /**
       * @param {?} _doc
       */
      function DomSharedStylesHost(_doc) {
        var _this262;

        _classCallCheck(this, DomSharedStylesHost);

        _this262 = _super90.call(this);
        _this262._doc = _doc;
        _this262._hostNodes = new Set();
        _this262._styleNodes = new Set();

        _this262._hostNodes.add(_doc.head);

        return _this262;
      }
      /**
       * @private
       * @param {?} styles
       * @param {?} host
       * @return {?}
       */


      _createClass2(DomSharedStylesHost, [{
        key: "_addStylesToHost",
        value: function _addStylesToHost(styles, host) {
          var _this263 = this;

          styles.forEach(
          /**
          * @param {?} style
          * @return {?}
          */
          function (style) {
            /** @type {?} */
            var styleEl = _this263._doc.createElement('style');

            styleEl.textContent = style;

            _this263._styleNodes.add(host.appendChild(styleEl));
          });
        }
        /**
         * @param {?} hostNode
         * @return {?}
         */

      }, {
        key: "addHost",
        value: function addHost(hostNode) {
          this._addStylesToHost(this._stylesSet, hostNode);

          this._hostNodes.add(hostNode);
        }
        /**
         * @param {?} hostNode
         * @return {?}
         */

      }, {
        key: "removeHost",
        value: function removeHost(hostNode) {
          this._hostNodes["delete"](hostNode);
        }
        /**
         * @param {?} additions
         * @return {?}
         */

      }, {
        key: "onStylesAdded",
        value: function onStylesAdded(additions) {
          var _this264 = this;

          this._hostNodes.forEach(
          /**
          * @param {?} hostNode
          * @return {?}
          */
          function (hostNode) {
            return _this264._addStylesToHost(additions, hostNode);
          });
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this._styleNodes.forEach(
          /**
          * @param {?} styleNode
          * @return {?}
          */
          function (styleNode) {
            return Object(_angular_common__WEBPACK_IMPORTED_MODULE_0__["ɵgetDOM"])().remove(styleNode);
          });
        }
      }]);

      return DomSharedStylesHost;
    }(SharedStylesHost);

    DomSharedStylesHost.ɵfac = function DomSharedStylesHost_Factory(t) {
      return new (t || DomSharedStylesHost)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]));
    };

    DomSharedStylesHost.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"]({
      token: DomSharedStylesHost,
      factory: DomSharedStylesHost.ɵfac
    });
    /** @nocollapse */

    DomSharedStylesHost.ctorParameters = function () {
      return [{
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](DomSharedStylesHost, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"]
      }], function () {
        return [{
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/dom/dom_renderer.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var NAMESPACE_URIS = {
      'svg': 'http://www.w3.org/2000/svg',
      'xhtml': 'http://www.w3.org/1999/xhtml',
      'xlink': 'http://www.w3.org/1999/xlink',
      'xml': 'http://www.w3.org/XML/1998/namespace',
      'xmlns': 'http://www.w3.org/2000/xmlns/'
    };
    /** @type {?} */

    var COMPONENT_REGEX = /%COMP%/g;
    /** @type {?} */

    var NG_DEV_MODE = typeof ngDevMode === 'undefined' || !!ngDevMode;
    /** @type {?} */

    var COMPONENT_VARIABLE = '%COMP%';
    /** @type {?} */

    var HOST_ATTR = "_nghost-".concat(COMPONENT_VARIABLE);
    /** @type {?} */

    var CONTENT_ATTR = "_ngcontent-".concat(COMPONENT_VARIABLE);
    /**
     * @param {?} componentShortId
     * @return {?}
     */

    function shimContentAttribute(componentShortId) {
      return CONTENT_ATTR.replace(COMPONENT_REGEX, componentShortId);
    }
    /**
     * @param {?} componentShortId
     * @return {?}
     */


    function shimHostAttribute(componentShortId) {
      return HOST_ATTR.replace(COMPONENT_REGEX, componentShortId);
    }
    /**
     * @param {?} compId
     * @param {?} styles
     * @param {?} target
     * @return {?}
     */


    function flattenStyles(compId, styles, target) {
      for (var i = 0; i < styles.length; i++) {
        /** @type {?} */
        var style = styles[i];

        if (Array.isArray(style)) {
          flattenStyles(compId, style, target);
        } else {
          style = style.replace(COMPONENT_REGEX, compId);
          target.push(style);
        }
      }

      return target;
    }
    /**
     * @param {?} eventHandler
     * @return {?}
     */


    function decoratePreventDefault(eventHandler) {
      // `DebugNode.triggerEventHandler` needs to know if the listener was created with
      // decoratePreventDefault or is a listener added outside the Angular context so it can handle the
      // two differently. In the first case, the special '__ngUnwrap__' token is passed to the unwrap
      // the listener (see below).
      return (
        /**
        * @param {?} event
        * @return {?}
        */
        function (event) {
          // Ivy uses '__ngUnwrap__' as a special token that allows us to unwrap the function
          // so that it can be invoked programmatically by `DebugNode.triggerEventHandler`. The debug_node
          // can inspect the listener toString contents for the existence of this special token. Because
          // the token is a string literal, it is ensured to not be modified by compiled code.
          if (event === '__ngUnwrap__') {
            return eventHandler;
          }
          /** @type {?} */


          var allowDefaultBehavior = eventHandler(event);

          if (allowDefaultBehavior === false) {
            // TODO(tbosch): move preventDefault into event plugins...
            event.preventDefault();
            event.returnValue = false;
          }

          return undefined;
        }
      );
    }

    var DomRendererFactory2 = /*#__PURE__*/function () {
      /**
       * @param {?} eventManager
       * @param {?} sharedStylesHost
       * @param {?} appId
       */
      function DomRendererFactory2(eventManager, sharedStylesHost, appId) {
        _classCallCheck(this, DomRendererFactory2);

        this.eventManager = eventManager;
        this.sharedStylesHost = sharedStylesHost;
        this.appId = appId;
        this.rendererByCompId = new Map();
        this.defaultRenderer = new DefaultDomRenderer2(eventManager);
      }
      /**
       * @param {?} element
       * @param {?} type
       * @return {?}
       */


      _createClass2(DomRendererFactory2, [{
        key: "createRenderer",
        value: function createRenderer(element, type) {
          if (!element || !type) {
            return this.defaultRenderer;
          }

          switch (type.encapsulation) {
            case _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].Emulated:
              {
                /** @type {?} */
                var renderer = this.rendererByCompId.get(type.id);

                if (!renderer) {
                  renderer = new EmulatedEncapsulationDomRenderer2(this.eventManager, this.sharedStylesHost, type, this.appId);
                  this.rendererByCompId.set(type.id, renderer);
                }

                /** @type {?} */
                renderer.applyToHost(element);
                return renderer;
              }

            case _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].Native:
            case _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].ShadowDom:
              return new ShadowDomRenderer(this.eventManager, this.sharedStylesHost, element, type);

            default:
              {
                if (!this.rendererByCompId.has(type.id)) {
                  /** @type {?} */
                  var styles = flattenStyles(type.id, type.styles, []);
                  this.sharedStylesHost.addStyles(styles);
                  this.rendererByCompId.set(type.id, this.defaultRenderer);
                }

                return this.defaultRenderer;
              }
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "begin",
        value: function begin() {}
        /**
         * @return {?}
         */

      }, {
        key: "end",
        value: function end() {}
      }]);

      return DomRendererFactory2;
    }();

    DomRendererFactory2.ɵfac = function DomRendererFactory2_Factory(t) {
      return new (t || DomRendererFactory2)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](EventManager), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](DomSharedStylesHost), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["APP_ID"]));
    };

    DomRendererFactory2.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"]({
      token: DomRendererFactory2,
      factory: DomRendererFactory2.ɵfac
    });
    /** @nocollapse */

    DomRendererFactory2.ctorParameters = function () {
      return [{
        type: EventManager
      }, {
        type: DomSharedStylesHost
      }, {
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_core__WEBPACK_IMPORTED_MODULE_1__["APP_ID"]]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](DomRendererFactory2, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"]
      }], function () {
        return [{
          type: EventManager
        }, {
          type: DomSharedStylesHost
        }, {
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_core__WEBPACK_IMPORTED_MODULE_1__["APP_ID"]]
          }]
        }];
      }, null);
    })();

    if (false) {}

    var DefaultDomRenderer2 = /*#__PURE__*/function () {
      /**
       * @param {?} eventManager
       */
      function DefaultDomRenderer2(eventManager) {
        _classCallCheck(this, DefaultDomRenderer2);

        this.eventManager = eventManager;
        this.data = Object.create(null);
      }
      /**
       * @return {?}
       */


      _createClass2(DefaultDomRenderer2, [{
        key: "destroy",
        value: function destroy() {}
        /**
         * @param {?} name
         * @param {?=} namespace
         * @return {?}
         */

      }, {
        key: "createElement",
        value: function createElement(name, namespace) {
          if (namespace) {
            // In cases where Ivy (not ViewEngine) is giving us the actual namespace, the look up by key
            // will result in undefined, so we just return the namespace here.
            return document.createElementNS(NAMESPACE_URIS[namespace] || namespace, name);
          }

          return document.createElement(name);
        }
        /**
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "createComment",
        value: function createComment(value) {
          return document.createComment(value);
        }
        /**
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "createText",
        value: function createText(value) {
          return document.createTextNode(value);
        }
        /**
         * @param {?} parent
         * @param {?} newChild
         * @return {?}
         */

      }, {
        key: "appendChild",
        value: function appendChild(parent, newChild) {
          parent.appendChild(newChild);
        }
        /**
         * @param {?} parent
         * @param {?} newChild
         * @param {?} refChild
         * @return {?}
         */

      }, {
        key: "insertBefore",
        value: function insertBefore(parent, newChild, refChild) {
          if (parent) {
            parent.insertBefore(newChild, refChild);
          }
        }
        /**
         * @param {?} parent
         * @param {?} oldChild
         * @return {?}
         */

      }, {
        key: "removeChild",
        value: function removeChild(parent, oldChild) {
          if (parent) {
            parent.removeChild(oldChild);
          }
        }
        /**
         * @param {?} selectorOrNode
         * @param {?=} preserveContent
         * @return {?}
         */

      }, {
        key: "selectRootElement",
        value: function selectRootElement(selectorOrNode, preserveContent) {
          /** @type {?} */
          var el = typeof selectorOrNode === 'string' ? document.querySelector(selectorOrNode) : selectorOrNode;

          if (!el) {
            throw new Error("The selector \"".concat(selectorOrNode, "\" did not match any elements"));
          }

          if (!preserveContent) {
            el.textContent = '';
          }

          return el;
        }
        /**
         * @param {?} node
         * @return {?}
         */

      }, {
        key: "parentNode",
        value: function parentNode(node) {
          return node.parentNode;
        }
        /**
         * @param {?} node
         * @return {?}
         */

      }, {
        key: "nextSibling",
        value: function nextSibling(node) {
          return node.nextSibling;
        }
        /**
         * @param {?} el
         * @param {?} name
         * @param {?} value
         * @param {?=} namespace
         * @return {?}
         */

      }, {
        key: "setAttribute",
        value: function setAttribute(el, name, value, namespace) {
          if (namespace) {
            name = namespace + ':' + name; // TODO(FW-811): Ivy may cause issues here because it's passing around
            // full URIs for namespaces, therefore this lookup will fail.

            /** @type {?} */

            var namespaceUri = NAMESPACE_URIS[namespace];

            if (namespaceUri) {
              el.setAttributeNS(namespaceUri, name, value);
            } else {
              el.setAttribute(name, value);
            }
          } else {
            el.setAttribute(name, value);
          }
        }
        /**
         * @param {?} el
         * @param {?} name
         * @param {?=} namespace
         * @return {?}
         */

      }, {
        key: "removeAttribute",
        value: function removeAttribute(el, name, namespace) {
          if (namespace) {
            // TODO(FW-811): Ivy may cause issues here because it's passing around
            // full URIs for namespaces, therefore this lookup will fail.

            /** @type {?} */
            var namespaceUri = NAMESPACE_URIS[namespace];

            if (namespaceUri) {
              el.removeAttributeNS(namespaceUri, name);
            } else {
              // TODO(FW-811): Since ivy is passing around full URIs for namespaces
              // this could result in properties like `http://www.w3.org/2000/svg:cx="123"`,
              // which is wrong.
              el.removeAttribute("".concat(namespace, ":").concat(name));
            }
          } else {
            el.removeAttribute(name);
          }
        }
        /**
         * @param {?} el
         * @param {?} name
         * @return {?}
         */

      }, {
        key: "addClass",
        value: function addClass(el, name) {
          el.classList.add(name);
        }
        /**
         * @param {?} el
         * @param {?} name
         * @return {?}
         */

      }, {
        key: "removeClass",
        value: function removeClass(el, name) {
          el.classList.remove(name);
        }
        /**
         * @param {?} el
         * @param {?} style
         * @param {?} value
         * @param {?} flags
         * @return {?}
         */

      }, {
        key: "setStyle",
        value: function setStyle(el, style, value, flags) {
          if (flags & _angular_core__WEBPACK_IMPORTED_MODULE_1__["RendererStyleFlags2"].DashCase) {
            el.style.setProperty(style, value, !!(flags & _angular_core__WEBPACK_IMPORTED_MODULE_1__["RendererStyleFlags2"].Important) ? 'important' : '');
          } else {
            el.style[style] = value;
          }
        }
        /**
         * @param {?} el
         * @param {?} style
         * @param {?} flags
         * @return {?}
         */

      }, {
        key: "removeStyle",
        value: function removeStyle(el, style, flags) {
          if (flags & _angular_core__WEBPACK_IMPORTED_MODULE_1__["RendererStyleFlags2"].DashCase) {
            el.style.removeProperty(style);
          } else {
            // IE requires '' instead of null
            // see https://github.com/angular/angular/issues/7916
            el.style[style] = '';
          }
        }
        /**
         * @param {?} el
         * @param {?} name
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "setProperty",
        value: function setProperty(el, name, value) {
          NG_DEV_MODE && checkNoSyntheticProp(name, 'property');
          el[name] = value;
        }
        /**
         * @param {?} node
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "setValue",
        value: function setValue(node, value) {
          node.nodeValue = value;
        }
        /**
         * @param {?} target
         * @param {?} event
         * @param {?} callback
         * @return {?}
         */

      }, {
        key: "listen",
        value: function listen(target, event, callback) {
          NG_DEV_MODE && checkNoSyntheticProp(event, 'listener');

          if (typeof target === 'string') {
            return (
              /** @type {?} */
              this.eventManager.addGlobalEventListener(target, event, decoratePreventDefault(callback))
            );
          }

          return (
            /** @type {?} */

            /** @type {?} */
            this.eventManager.addEventListener(target, event, decoratePreventDefault(callback))
          );
        }
      }]);

      return DefaultDomRenderer2;
    }();

    if (false) {}

    var ɵ0$2 =
    /**
    * @return {?}
    */
    function ɵ0$2() {
      return '@'.charCodeAt(0);
    };
    /** @type {?} */


    var AT_CHARCODE = ɵ0$2();
    /**
     * @param {?} name
     * @param {?} nameKind
     * @return {?}
     */

    function checkNoSyntheticProp(name, nameKind) {
      if (name.charCodeAt(0) === AT_CHARCODE) {
        throw new Error("Found the synthetic ".concat(nameKind, " ").concat(name, ". Please include either \"BrowserAnimationsModule\" or \"NoopAnimationsModule\" in your application."));
      }
    }

    var EmulatedEncapsulationDomRenderer2 = /*#__PURE__*/function (_DefaultDomRenderer) {
      _inherits(EmulatedEncapsulationDomRenderer2, _DefaultDomRenderer);

      var _super91 = _createSuper(EmulatedEncapsulationDomRenderer2);

      /**
       * @param {?} eventManager
       * @param {?} sharedStylesHost
       * @param {?} component
       * @param {?} appId
       */
      function EmulatedEncapsulationDomRenderer2(eventManager, sharedStylesHost, component, appId) {
        var _this265;

        _classCallCheck(this, EmulatedEncapsulationDomRenderer2);

        _this265 = _super91.call(this, eventManager);
        _this265.component = component;
        /** @type {?} */

        var styles = flattenStyles(appId + '-' + component.id, component.styles, []);
        sharedStylesHost.addStyles(styles);
        _this265.contentAttr = shimContentAttribute(appId + '-' + component.id);
        _this265.hostAttr = shimHostAttribute(appId + '-' + component.id);
        return _this265;
      }
      /**
       * @param {?} element
       * @return {?}
       */


      _createClass2(EmulatedEncapsulationDomRenderer2, [{
        key: "applyToHost",
        value: function applyToHost(element) {
          _get(_getPrototypeOf(EmulatedEncapsulationDomRenderer2.prototype), "setAttribute", this).call(this, element, this.hostAttr, '');
        }
        /**
         * @param {?} parent
         * @param {?} name
         * @return {?}
         */

      }, {
        key: "createElement",
        value: function createElement(parent, name) {
          /** @type {?} */
          var el = _get(_getPrototypeOf(EmulatedEncapsulationDomRenderer2.prototype), "createElement", this).call(this, parent, name);

          _get(_getPrototypeOf(EmulatedEncapsulationDomRenderer2.prototype), "setAttribute", this).call(this, el, this.contentAttr, '');

          return el;
        }
      }]);

      return EmulatedEncapsulationDomRenderer2;
    }(DefaultDomRenderer2);

    if (false) {}

    var ShadowDomRenderer = /*#__PURE__*/function (_DefaultDomRenderer2) {
      _inherits(ShadowDomRenderer, _DefaultDomRenderer2);

      var _super92 = _createSuper(ShadowDomRenderer);

      /**
       * @param {?} eventManager
       * @param {?} sharedStylesHost
       * @param {?} hostEl
       * @param {?} component
       */
      function ShadowDomRenderer(eventManager, sharedStylesHost, hostEl, component) {
        var _this266;

        _classCallCheck(this, ShadowDomRenderer);

        _this266 = _super92.call(this, eventManager);
        _this266.sharedStylesHost = sharedStylesHost;
        _this266.hostEl = hostEl;
        _this266.component = component;

        if (component.encapsulation === _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewEncapsulation"].ShadowDom) {
          _this266.shadowRoot =
          /** @type {?} */
          hostEl.attachShadow({
            mode: 'open'
          });
        } else {
          _this266.shadowRoot =
          /** @type {?} */
          hostEl.createShadowRoot();
        }

        _this266.sharedStylesHost.addHost(_this266.shadowRoot);
        /** @type {?} */


        var styles = flattenStyles(component.id, component.styles, []);

        for (var i = 0; i < styles.length; i++) {
          /** @type {?} */
          var styleEl = document.createElement('style');
          styleEl.textContent = styles[i];

          _this266.shadowRoot.appendChild(styleEl);
        }

        return _this266;
      }
      /**
       * @private
       * @param {?} node
       * @return {?}
       */


      _createClass2(ShadowDomRenderer, [{
        key: "nodeOrShadowRoot",
        value: function nodeOrShadowRoot(node) {
          return node === this.hostEl ? this.shadowRoot : node;
        }
        /**
         * @return {?}
         */

      }, {
        key: "destroy",
        value: function destroy() {
          this.sharedStylesHost.removeHost(this.shadowRoot);
        }
        /**
         * @param {?} parent
         * @param {?} newChild
         * @return {?}
         */

      }, {
        key: "appendChild",
        value: function appendChild(parent, newChild) {
          return _get(_getPrototypeOf(ShadowDomRenderer.prototype), "appendChild", this).call(this, this.nodeOrShadowRoot(parent), newChild);
        }
        /**
         * @param {?} parent
         * @param {?} newChild
         * @param {?} refChild
         * @return {?}
         */

      }, {
        key: "insertBefore",
        value: function insertBefore(parent, newChild, refChild) {
          return _get(_getPrototypeOf(ShadowDomRenderer.prototype), "insertBefore", this).call(this, this.nodeOrShadowRoot(parent), newChild, refChild);
        }
        /**
         * @param {?} parent
         * @param {?} oldChild
         * @return {?}
         */

      }, {
        key: "removeChild",
        value: function removeChild(parent, oldChild) {
          return _get(_getPrototypeOf(ShadowDomRenderer.prototype), "removeChild", this).call(this, this.nodeOrShadowRoot(parent), oldChild);
        }
        /**
         * @param {?} node
         * @return {?}
         */

      }, {
        key: "parentNode",
        value: function parentNode(node) {
          return this.nodeOrShadowRoot(_get(_getPrototypeOf(ShadowDomRenderer.prototype), "parentNode", this).call(this, this.nodeOrShadowRoot(node)));
        }
      }]);

      return ShadowDomRenderer;
    }(DefaultDomRenderer2);

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/dom/events/dom_events.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var DomEventsPlugin = /*#__PURE__*/function (_EventManagerPlugin) {
      _inherits(DomEventsPlugin, _EventManagerPlugin);

      var _super93 = _createSuper(DomEventsPlugin);

      /**
       * @param {?} doc
       */
      function DomEventsPlugin(doc) {
        _classCallCheck(this, DomEventsPlugin);

        return _super93.call(this, doc);
      } // This plugin should come last in the list of plugins, because it accepts all
      // events.

      /**
       * @param {?} eventName
       * @return {?}
       */


      _createClass2(DomEventsPlugin, [{
        key: "supports",
        value: function supports(eventName) {
          return true;
        }
        /**
         * @param {?} element
         * @param {?} eventName
         * @param {?} handler
         * @return {?}
         */

      }, {
        key: "addEventListener",
        value: function addEventListener(element, eventName, handler) {
          var _this267 = this;

          element.addEventListener(eventName,
          /** @type {?} */
          handler, false);
          return (
            /**
            * @return {?}
            */
            function () {
              return _this267.removeEventListener(element, eventName,
              /** @type {?} */
              handler);
            }
          );
        }
        /**
         * @param {?} target
         * @param {?} eventName
         * @param {?} callback
         * @return {?}
         */

      }, {
        key: "removeEventListener",
        value: function removeEventListener(target, eventName, callback) {
          return target.removeEventListener(eventName,
          /** @type {?} */
          callback);
        }
      }]);

      return DomEventsPlugin;
    }(EventManagerPlugin);

    DomEventsPlugin.ɵfac = function DomEventsPlugin_Factory(t) {
      return new (t || DomEventsPlugin)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]));
    };

    DomEventsPlugin.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"]({
      token: DomEventsPlugin,
      factory: DomEventsPlugin.ɵfac
    });
    /** @nocollapse */

    DomEventsPlugin.ctorParameters = function () {
      return [{
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](DomEventsPlugin, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"]
      }], function () {
        return [{
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
          }]
        }];
      }, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/dom/events/hammer_gestures.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Supported HammerJS recognizer event names.
     * @type {?}
     */


    var EVENT_NAMES = {
      // pan
      'pan': true,
      'panstart': true,
      'panmove': true,
      'panend': true,
      'pancancel': true,
      'panleft': true,
      'panright': true,
      'panup': true,
      'pandown': true,
      // pinch
      'pinch': true,
      'pinchstart': true,
      'pinchmove': true,
      'pinchend': true,
      'pinchcancel': true,
      'pinchin': true,
      'pinchout': true,
      // press
      'press': true,
      'pressup': true,
      // rotate
      'rotate': true,
      'rotatestart': true,
      'rotatemove': true,
      'rotateend': true,
      'rotatecancel': true,
      // swipe
      'swipe': true,
      'swipeleft': true,
      'swiperight': true,
      'swipeup': true,
      'swipedown': true,
      // tap
      'tap': true
    };
    /**
     * DI token for providing [HammerJS](http://hammerjs.github.io/) support to Angular.
     * @see `HammerGestureConfig`
     *
     * \@ngModule HammerModule
     * \@publicApi
     * @type {?}
     */

    var HAMMER_GESTURE_CONFIG = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["InjectionToken"]('HammerGestureConfig');
    /**
     * Injection token used to provide a {\@link HammerLoader} to Angular.
     *
     * \@publicApi
     * @type {?}
     */

    var HAMMER_LOADER = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["InjectionToken"]('HammerLoader');
    /**
     * @record
     */

    function HammerInstance() {}

    if (false) {}
    /**
     * An injectable [HammerJS Manager](http://hammerjs.github.io/api/#hammer.manager)
     * for gesture recognition. Configures specific event recognition.
     * \@publicApi
     */


    var HammerGestureConfig = /*#__PURE__*/function () {
      function HammerGestureConfig() {
        _classCallCheck(this, HammerGestureConfig);

        /**
         * A set of supported event names for gestures to be used in Angular.
         * Angular supports all built-in recognizers, as listed in
         * [HammerJS documentation](http://hammerjs.github.io/).
         */
        this.events = [];
        /**
         * Maps gesture event names to a set of configuration options
         * that specify overrides to the default values for specific properties.
         *
         * The key is a supported event name to be configured,
         * and the options object contains a set of properties, with override values
         * to be applied to the named recognizer event.
         * For example, to disable recognition of the rotate event, specify
         *  `{"rotate": {"enable": false}}`.
         *
         * Properties that are not present take the HammerJS default values.
         * For information about which properties are supported for which events,
         * and their allowed and default values, see
         * [HammerJS documentation](http://hammerjs.github.io/).
         *
         */

        this.overrides = {};
      }
      /**
       * Creates a [HammerJS Manager](http://hammerjs.github.io/api/#hammer.manager)
       * and attaches it to a given HTML element.
       * @param {?} element The element that will recognize gestures.
       * @return {?} A HammerJS event-manager object.
       */


      _createClass2(HammerGestureConfig, [{
        key: "buildHammer",
        value: function buildHammer(element) {
          /** @type {?} */
          var mc = new
          /** @type {?} */
          Hammer(element, this.options);
          mc.get('pinch').set({
            enable: true
          });
          mc.get('rotate').set({
            enable: true
          });

          for (var eventName in this.overrides) {
            mc.get(eventName).set(this.overrides[eventName]);
          }

          return mc;
        }
      }]);

      return HammerGestureConfig;
    }();

    HammerGestureConfig.ɵfac = function HammerGestureConfig_Factory(t) {
      return new (t || HammerGestureConfig)();
    };

    HammerGestureConfig.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"]({
      token: HammerGestureConfig,
      factory: HammerGestureConfig.ɵfac
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](HammerGestureConfig, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"]
      }], function () {
        return [];
      }, null);
    })();

    if (false) {}
    /**
     * Event plugin that adds Hammer support to an application.
     *
     * \@ngModule HammerModule
     */


    var HammerGesturesPlugin = /*#__PURE__*/function (_EventManagerPlugin2) {
      _inherits(HammerGesturesPlugin, _EventManagerPlugin2);

      var _super94 = _createSuper(HammerGesturesPlugin);

      /**
       * @param {?} doc
       * @param {?} _config
       * @param {?} console
       * @param {?=} loader
       */
      function HammerGesturesPlugin(doc, _config, console, loader) {
        var _this268;

        _classCallCheck(this, HammerGesturesPlugin);

        _this268 = _super94.call(this, doc);
        _this268._config = _config;
        _this268.console = console;
        _this268.loader = loader;
        return _this268;
      }
      /**
       * @param {?} eventName
       * @return {?}
       */


      _createClass2(HammerGesturesPlugin, [{
        key: "supports",
        value: function supports(eventName) {
          if (!EVENT_NAMES.hasOwnProperty(eventName.toLowerCase()) && !this.isCustomEvent(eventName)) {
            return false;
          }

          if (!
          /** @type {?} */
          window.Hammer && !this.loader) {
            this.console.warn("The \"".concat(eventName, "\" event cannot be bound because Hammer.JS is not ") + "loaded and no custom loader has been specified.");
            return false;
          }

          return true;
        }
        /**
         * @param {?} element
         * @param {?} eventName
         * @param {?} handler
         * @return {?}
         */

      }, {
        key: "addEventListener",
        value: function addEventListener(element, eventName, handler) {
          var _this269 = this;

          /** @type {?} */
          var zone = this.manager.getZone();
          eventName = eventName.toLowerCase(); // If Hammer is not present but a loader is specified, we defer adding the event listener
          // until Hammer is loaded.

          if (!
          /** @type {?} */
          window.Hammer && this.loader) {
            // This `addEventListener` method returns a function to remove the added listener.
            // Until Hammer is loaded, the returned function needs to *cancel* the registration rather
            // than remove anything.

            /** @type {?} */
            var cancelRegistration = false;
            /** @type {?} */

            var deregister =
            /**
            * @return {?}
            */
            function deregister() {
              cancelRegistration = true;
            };

            this.loader().then(
            /**
            * @return {?}
            */
            function () {
              // If Hammer isn't actually loaded when the custom loader resolves, give up.
              if (!
              /** @type {?} */
              window.Hammer) {
                _this269.console.warn("The custom HAMMER_LOADER completed, but Hammer.JS is not present.");

                deregister =
                /**
                * @return {?}
                */
                function deregister() {};

                return;
              }

              if (!cancelRegistration) {
                // Now that Hammer is loaded and the listener is being loaded for real,
                // the deregistration function changes from canceling registration to removal.
                deregister = _this269.addEventListener(element, eventName, handler);
              }
            })["catch"](
            /**
            * @return {?}
            */
            function () {
              _this269.console.warn("The \"".concat(eventName, "\" event cannot be bound because the custom ") + "Hammer.JS loader failed.");

              deregister =
              /**
              * @return {?}
              */
              function deregister() {};
            }); // Return a function that *executes* `deregister` (and not `deregister` itself) so that we
            // can change the behavior of `deregister` once the listener is added. Using a closure in
            // this way allows us to avoid any additional data structures to track listener removal.

            return (
              /**
              * @return {?}
              */
              function () {
                deregister();
              }
            );
          }

          return zone.runOutsideAngular(
          /**
          * @return {?}
          */
          function () {
            // Creating the manager bind events, must be done outside of angular

            /** @type {?} */
            var mc = _this269._config.buildHammer(element);
            /** @type {?} */


            var callback =
            /**
            * @param {?} eventObj
            * @return {?}
            */
            function callback(eventObj) {
              zone.runGuarded(
              /**
              * @return {?}
              */
              function () {
                handler(eventObj);
              });
            };

            mc.on(eventName, callback);
            return (
              /**
              * @return {?}
              */
              function () {
                mc.off(eventName, callback); // destroy mc to prevent memory leak

                if (typeof mc.destroy === 'function') {
                  mc.destroy();
                }
              }
            );
          });
        }
        /**
         * @param {?} eventName
         * @return {?}
         */

      }, {
        key: "isCustomEvent",
        value: function isCustomEvent(eventName) {
          return this._config.events.indexOf(eventName) > -1;
        }
      }]);

      return HammerGesturesPlugin;
    }(EventManagerPlugin);

    HammerGesturesPlugin.ɵfac = function HammerGesturesPlugin_Factory(t) {
      return new (t || HammerGesturesPlugin)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](HAMMER_GESTURE_CONFIG), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵConsole"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](HAMMER_LOADER, 8));
    };

    HammerGesturesPlugin.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"]({
      token: HammerGesturesPlugin,
      factory: HammerGesturesPlugin.ɵfac
    });
    /** @nocollapse */

    HammerGesturesPlugin.ctorParameters = function () {
      return [{
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
        }]
      }, {
        type: HammerGestureConfig,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [HAMMER_GESTURE_CONFIG]
        }]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵConsole"]
      }, {
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [HAMMER_LOADER]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](HammerGesturesPlugin, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"]
      }], function () {
        return [{
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
          }]
        }, {
          type: HammerGestureConfig,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [HAMMER_GESTURE_CONFIG]
          }]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵConsole"]
        }, {
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [HAMMER_LOADER]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * In Ivy, support for Hammer gestures is optional, so applications must
     * import the `HammerModule` at root to turn on support. This means that
     * Hammer-specific code can be tree-shaken away if not needed.
     * @type {?}
     */


    var HAMMER_PROVIDERS__POST_R3__ = [];
    /**
     * In View Engine, support for Hammer gestures is built-in by default.
     * @type {?}
     */

    var HAMMER_PROVIDERS__PRE_R3__ = [{
      provide: EVENT_MANAGER_PLUGINS,
      useClass: HammerGesturesPlugin,
      multi: true,
      deps: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"], HAMMER_GESTURE_CONFIG, _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵConsole"], [new _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"](), HAMMER_LOADER]]
    }, {
      provide: HAMMER_GESTURE_CONFIG,
      useClass: HammerGestureConfig,
      deps: []
    }];
    /** @type {?} */

    var HAMMER_PROVIDERS = HAMMER_PROVIDERS__POST_R3__;
    /**
     * Adds support for HammerJS.
     *
     * Import this module at the root of your application so that Angular can work with
     * HammerJS to detect gesture events.
     *
     * Note that applications still need to include the HammerJS script itself. This module
     * simply sets up the coordination layer between HammerJS and Angular's EventManager.
     *
     * \@publicApi
     */

    var HammerModule = function HammerModule() {
      _classCallCheck(this, HammerModule);
    };

    HammerModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineNgModule"]({
      type: HammerModule
    });
    HammerModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjector"]({
      factory: function HammerModule_Factory(t) {
        return new (t || HammerModule)();
      },
      providers: HAMMER_PROVIDERS__PRE_R3__
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](HammerModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModule"],
        args: [{
          providers: HAMMER_PROVIDERS__PRE_R3__
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/dom/events/key_events.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Defines supported modifiers for key events.
     * @type {?}
     */


    var MODIFIER_KEYS = ['alt', 'control', 'meta', 'shift'];
    /** @type {?} */

    var DOM_KEY_LOCATION_NUMPAD = 3; // Map to convert some key or keyIdentifier values to what will be returned by getEventKey

    /** @type {?} */

    var _keyMap = {
      // The following values are here for cross-browser compatibility and to match the W3C standard
      // cf http://www.w3.org/TR/DOM-Level-3-Events-key/
      '\b': 'Backspace',
      '\t': 'Tab',
      '\x7F': 'Delete',
      '\x1B': 'Escape',
      'Del': 'Delete',
      'Esc': 'Escape',
      'Left': 'ArrowLeft',
      'Right': 'ArrowRight',
      'Up': 'ArrowUp',
      'Down': 'ArrowDown',
      'Menu': 'ContextMenu',
      'Scroll': 'ScrollLock',
      'Win': 'OS'
    }; // There is a bug in Chrome for numeric keypad keys:
    // https://code.google.com/p/chromium/issues/detail?id=155654
    // 1, 2, 3 ... are reported as A, B, C ...

    /** @type {?} */

    var _chromeNumKeyPadMap = {
      'A': '1',
      'B': '2',
      'C': '3',
      'D': '4',
      'E': '5',
      'F': '6',
      'G': '7',
      'H': '8',
      'I': '9',
      'J': '*',
      'K': '+',
      'M': '-',
      'N': '.',
      'O': '/',
      '\x60': '0',
      '\x90': 'NumLock'
    };

    var ɵ0$3 =
    /**
    * @param {?} event
    * @return {?}
    */
    function ɵ0$3(event) {
      return event.altKey;
    },
        ɵ1 =
    /**
    * @param {?} event
    * @return {?}
    */
    function ɵ1(event) {
      return event.ctrlKey;
    },
        ɵ2 =
    /**
    * @param {?} event
    * @return {?}
    */
    function ɵ2(event) {
      return event.metaKey;
    },
        ɵ3 =
    /**
    * @param {?} event
    * @return {?}
    */
    function ɵ3(event) {
      return event.shiftKey;
    };
    /**
     * Retrieves modifiers from key-event objects.
     * @type {?}
     */


    var MODIFIER_KEY_GETTERS = {
      'alt': ɵ0$3,
      'control': ɵ1,
      'meta': ɵ2,
      'shift': ɵ3
    };
    /**
     * \@publicApi
     * A browser plug-in that provides support for handling of key events in Angular.
     */

    var KeyEventsPlugin = /*#__PURE__*/function (_EventManagerPlugin3) {
      _inherits(KeyEventsPlugin, _EventManagerPlugin3);

      var _super95 = _createSuper(KeyEventsPlugin);

      /**
       * Initializes an instance of the browser plug-in.
       * @param {?} doc The document in which key events will be detected.
       */
      function KeyEventsPlugin(doc) {
        _classCallCheck(this, KeyEventsPlugin);

        return _super95.call(this, doc);
      }
      /**
       * Reports whether a named key event is supported.
       * @param {?} eventName The event name to query.
       * @return {?} True if the named key event is supported.
       */


      _createClass2(KeyEventsPlugin, [{
        key: "supports",
        value: function supports(eventName) {
          return KeyEventsPlugin.parseEventName(eventName) != null;
        }
        /**
         * Registers a handler for a specific element and key event.
         * @param {?} element The HTML element to receive event notifications.
         * @param {?} eventName The name of the key event to listen for.
         * @param {?} handler A function to call when the notification occurs. Receives the
         * event object as an argument.
         * @return {?} The key event that was registered.
         */

      }, {
        key: "addEventListener",
        value: function addEventListener(element, eventName, handler) {
          /** @type {?} */
          var parsedEvent =
          /** @type {?} */
          KeyEventsPlugin.parseEventName(eventName);
          /** @type {?} */

          var outsideHandler = KeyEventsPlugin.eventCallback(parsedEvent['fullKey'], handler, this.manager.getZone());
          return this.manager.getZone().runOutsideAngular(
          /**
          * @return {?}
          */
          function () {
            return Object(_angular_common__WEBPACK_IMPORTED_MODULE_0__["ɵgetDOM"])().onAndCancel(element, parsedEvent['domEventName'], outsideHandler);
          });
        }
        /**
         * @param {?} eventName
         * @return {?}
         */

      }], [{
        key: "parseEventName",
        value: function parseEventName(eventName) {
          /** @type {?} */
          var parts = eventName.toLowerCase().split('.');
          /** @type {?} */

          var domEventName = parts.shift();

          if (parts.length === 0 || !(domEventName === 'keydown' || domEventName === 'keyup')) {
            return null;
          }
          /** @type {?} */


          var key = KeyEventsPlugin._normalizeKey(
          /** @type {?} */
          parts.pop());
          /** @type {?} */


          var fullKey = '';
          MODIFIER_KEYS.forEach(
          /**
          * @param {?} modifierName
          * @return {?}
          */
          function (modifierName) {
            /** @type {?} */
            var index = parts.indexOf(modifierName);

            if (index > -1) {
              parts.splice(index, 1);
              fullKey += modifierName + '.';
            }
          });
          fullKey += key;

          if (parts.length != 0 || key.length === 0) {
            // returning null instead of throwing to let another plugin process the event
            return null;
          }
          /** @type {?} */


          var result = {};
          result['domEventName'] = domEventName;
          result['fullKey'] = fullKey;
          return result;
        }
        /**
         * @param {?} event
         * @return {?}
         */

      }, {
        key: "getEventFullKey",
        value: function getEventFullKey(event) {
          /** @type {?} */
          var fullKey = '';
          /** @type {?} */

          var key = getEventKey(event);
          key = key.toLowerCase();

          if (key === ' ') {
            key = 'space'; // for readability
          } else if (key === '.') {
            key = 'dot'; // because '.' is used as a separator in event names
          }

          MODIFIER_KEYS.forEach(
          /**
          * @param {?} modifierName
          * @return {?}
          */
          function (modifierName) {
            if (modifierName != key) {
              /** @type {?} */
              var modifierGetter = MODIFIER_KEY_GETTERS[modifierName];

              if (modifierGetter(event)) {
                fullKey += modifierName + '.';
              }
            }
          });
          fullKey += key;
          return fullKey;
        }
        /**
         * Configures a handler callback for a key event.
         * @param {?} fullKey The event name that combines all simultaneous keystrokes.
         * @param {?} handler The function that responds to the key event.
         * @param {?} zone The zone in which the event occurred.
         * @return {?} A callback function.
         */

      }, {
        key: "eventCallback",
        value: function eventCallback(fullKey, handler, zone) {
          return (
            /**
            * @param {?} event
            * @return {?}
            */
            function (event
            /** TODO #9100 */
            ) {
              if (KeyEventsPlugin.getEventFullKey(event) === fullKey) {
                zone.runGuarded(
                /**
                * @return {?}
                */
                function () {
                  return handler(event);
                });
              }
            }
          );
        }
        /**
         * \@internal
         * @param {?} keyName
         * @return {?}
         */

      }, {
        key: "_normalizeKey",
        value: function _normalizeKey(keyName) {
          // TODO: switch to a Map if the mapping grows too much
          switch (keyName) {
            case 'esc':
              return 'escape';

            default:
              return keyName;
          }
        }
      }]);

      return KeyEventsPlugin;
    }(EventManagerPlugin);

    KeyEventsPlugin.ɵfac = function KeyEventsPlugin_Factory(t) {
      return new (t || KeyEventsPlugin)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]));
    };

    KeyEventsPlugin.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"]({
      token: KeyEventsPlugin,
      factory: KeyEventsPlugin.ɵfac
    });
    /** @nocollapse */

    KeyEventsPlugin.ctorParameters = function () {
      return [{
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
        }]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](KeyEventsPlugin, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"]
      }], function () {
        return [{
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
          }]
        }];
      }, null);
    })();
    /**
     * @param {?} event
     * @return {?}
     */


    function getEventKey(event) {
      /** @type {?} */
      var key = event.key;

      if (key == null) {
        key = event.keyIdentifier; // keyIdentifier is defined in the old draft of DOM Level 3 Events implemented by Chrome and
        // Safari cf
        // http://www.w3.org/TR/2007/WD-DOM-Level-3-Events-20071221/events.html#Events-KeyboardEvents-Interfaces

        if (key == null) {
          return 'Unidentified';
        }

        if (key.startsWith('U+')) {
          key = String.fromCharCode(parseInt(key.substring(2), 16));

          if (event.location === DOM_KEY_LOCATION_NUMPAD && _chromeNumKeyPadMap.hasOwnProperty(key)) {
            // There is a bug in Chrome for numeric keypad keys:
            // https://code.google.com/p/chromium/issues/detail?id=155654
            // 1, 2, 3 ... are reported as A, B, C ...
            key =
            /** @type {?} */
            _chromeNumKeyPadMap[key];
          }
        }
      }

      return _keyMap[key] || key;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/security/dom_sanitization_service.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Marker interface for a value that's safe to use in a particular context.
     *
     * \@publicApi
     * @record
     */


    function SafeValue() {}
    /**
     * Marker interface for a value that's safe to use as HTML.
     *
     * \@publicApi
     * @record
     */


    function SafeHtml() {}
    /**
     * Marker interface for a value that's safe to use as style (CSS).
     *
     * \@publicApi
     * @record
     */


    function SafeStyle() {}
    /**
     * Marker interface for a value that's safe to use as JavaScript.
     *
     * \@publicApi
     * @record
     */


    function SafeScript() {}
    /**
     * Marker interface for a value that's safe to use as a URL linking to a document.
     *
     * \@publicApi
     * @record
     */


    function SafeUrl() {}
    /**
     * Marker interface for a value that's safe to use as a URL to load executable code from.
     *
     * \@publicApi
     * @record
     */


    function SafeResourceUrl() {}
    /**
     * DomSanitizer helps preventing Cross Site Scripting Security bugs (XSS) by sanitizing
     * values to be safe to use in the different DOM contexts.
     *
     * For example, when binding a URL in an `<a [href]="someValue">` hyperlink, `someValue` will be
     * sanitized so that an attacker cannot inject e.g. a `javascript:` URL that would execute code on
     * the website.
     *
     * In specific situations, it might be necessary to disable sanitization, for example if the
     * application genuinely needs to produce a `javascript:` style link with a dynamic value in it.
     * Users can bypass security by constructing a value with one of the `bypassSecurityTrust...`
     * methods, and then binding to that value from the template.
     *
     * These situations should be very rare, and extraordinary care must be taken to avoid creating a
     * Cross Site Scripting (XSS) security bug!
     *
     * When using `bypassSecurityTrust...`, make sure to call the method as early as possible and as
     * close as possible to the source of the value, to make it easy to verify no security bug is
     * created by its use.
     *
     * It is not required (and not recommended) to bypass security if the value is safe, e.g. a URL that
     * does not start with a suspicious protocol, or an HTML snippet that does not contain dangerous
     * code. The sanitizer leaves safe values intact.
     *
     * \@security Calling any of the `bypassSecurityTrust...` APIs disables Angular's built-in
     * sanitization for the value passed in. Carefully check and audit all values and code paths going
     * into this call. Make sure any user data is appropriately escaped for this security context.
     * For more detail, see the [Security Guide](http://g.co/ng/security).
     *
     * \@publicApi
     * @abstract
     */


    var DomSanitizer = function DomSanitizer() {
      _classCallCheck(this, DomSanitizer);
    };

    DomSanitizer.ɵfac = function DomSanitizer_Factory(t) {
      return new (t || DomSanitizer)();
    };
    /** @nocollapse */


    DomSanitizer.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: function DomSanitizer_Factory() {
        return Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(DomSanitizerImpl);
      },
      token: DomSanitizer,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](DomSanitizer, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root',
          useExisting: Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["forwardRef"])(
          /**
          * @return {?}
          */
          function () {
            return DomSanitizerImpl;
          })
        }]
      }], null, null);
    })();

    if (false) {}
    /**
     * @param {?} injector
     * @return {?}
     */


    function domSanitizerImplFactory(injector) {
      return new DomSanitizerImpl(injector.get(_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]));
    }

    var DomSanitizerImpl = /*#__PURE__*/function (_DomSanitizer) {
      _inherits(DomSanitizerImpl, _DomSanitizer);

      var _super96 = _createSuper(DomSanitizerImpl);

      /**
       * @param {?} _doc
       */
      function DomSanitizerImpl(_doc) {
        var _this270;

        _classCallCheck(this, DomSanitizerImpl);

        _this270 = _super96.call(this);
        _this270._doc = _doc;
        return _this270;
      }
      /**
       * @param {?} ctx
       * @param {?} value
       * @return {?}
       */


      _createClass2(DomSanitizerImpl, [{
        key: "sanitize",
        value: function sanitize(ctx, value) {
          if (value == null) return null;

          switch (ctx) {
            case _angular_core__WEBPACK_IMPORTED_MODULE_1__["SecurityContext"].NONE:
              return (
                /** @type {?} */
                value
              );

            case _angular_core__WEBPACK_IMPORTED_MODULE_1__["SecurityContext"].HTML:
              if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵallowSanitizationBypassAndThrow"])(value, "HTML"
              /* Html */
              )) {
                return Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵunwrapSafeValue"])(value);
              }

              return Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵ_sanitizeHtml"])(this._doc, String(value));

            case _angular_core__WEBPACK_IMPORTED_MODULE_1__["SecurityContext"].STYLE:
              if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵallowSanitizationBypassAndThrow"])(value, "Style"
              /* Style */
              )) {
                return Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵunwrapSafeValue"])(value);
              }

              return Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵ_sanitizeStyle"])(
              /** @type {?} */
              value);

            case _angular_core__WEBPACK_IMPORTED_MODULE_1__["SecurityContext"].SCRIPT:
              if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵallowSanitizationBypassAndThrow"])(value, "Script"
              /* Script */
              )) {
                return Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵunwrapSafeValue"])(value);
              }

              throw new Error('unsafe value used in a script context');

            case _angular_core__WEBPACK_IMPORTED_MODULE_1__["SecurityContext"].URL:
              /** @type {?} */
              var type = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵgetSanitizationBypassType"])(value);

              if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵallowSanitizationBypassAndThrow"])(value, "URL"
              /* Url */
              )) {
                return Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵunwrapSafeValue"])(value);
              }

              return Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵ_sanitizeUrl"])(String(value));

            case _angular_core__WEBPACK_IMPORTED_MODULE_1__["SecurityContext"].RESOURCE_URL:
              if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵallowSanitizationBypassAndThrow"])(value, "ResourceURL"
              /* ResourceUrl */
              )) {
                return Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵunwrapSafeValue"])(value);
              }

              throw new Error('unsafe value used in a resource URL context (see http://g.co/ng/security#xss)');

            default:
              throw new Error("Unexpected SecurityContext ".concat(ctx, " (see http://g.co/ng/security#xss)"));
          }
        }
        /**
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "bypassSecurityTrustHtml",
        value: function bypassSecurityTrustHtml(value) {
          return Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵbypassSanitizationTrustHtml"])(value);
        }
        /**
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "bypassSecurityTrustStyle",
        value: function bypassSecurityTrustStyle(value) {
          return Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵbypassSanitizationTrustStyle"])(value);
        }
        /**
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "bypassSecurityTrustScript",
        value: function bypassSecurityTrustScript(value) {
          return Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵbypassSanitizationTrustScript"])(value);
        }
        /**
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "bypassSecurityTrustUrl",
        value: function bypassSecurityTrustUrl(value) {
          return Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵbypassSanitizationTrustUrl"])(value);
        }
        /**
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "bypassSecurityTrustResourceUrl",
        value: function bypassSecurityTrustResourceUrl(value) {
          return Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵbypassSanitizationTrustResourceUrl"])(value);
        }
      }]);

      return DomSanitizerImpl;
    }(DomSanitizer);

    DomSanitizerImpl.ɵfac = function DomSanitizerImpl_Factory(t) {
      return new (t || DomSanitizerImpl)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]));
    };
    /** @nocollapse */


    DomSanitizerImpl.ctorParameters = function () {
      return [{
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
        }]
      }];
    };
    /** @nocollapse */


    DomSanitizerImpl.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: function DomSanitizerImpl_Factory() {
        return domSanitizerImplFactory(Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_core__WEBPACK_IMPORTED_MODULE_1__["INJECTOR"]));
      },
      token: DomSanitizerImpl,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](DomSanitizerImpl, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root',
          useFactory: domSanitizerImplFactory,
          deps: [_angular_core__WEBPACK_IMPORTED_MODULE_1__["Injector"]]
        }]
      }], function () {
        return [{
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/browser.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @return {?}
     */


    function initDomAdapter() {
      BrowserDomAdapter.makeCurrent();
      BrowserGetTestability.init();
    }
    /**
     * @return {?}
     */


    function errorHandler() {
      return new _angular_core__WEBPACK_IMPORTED_MODULE_1__["ErrorHandler"]();
    }
    /**
     * @return {?}
     */


    function _document() {
      // Tell ivy about the global document
      Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetDocument"])(document);
      return document;
    }

    var ɵ0$4 = _angular_common__WEBPACK_IMPORTED_MODULE_0__["ɵPLATFORM_BROWSER_ID"];
    /** @type {?} */

    var INTERNAL_BROWSER_PLATFORM_PROVIDERS = [{
      provide: _angular_core__WEBPACK_IMPORTED_MODULE_1__["PLATFORM_ID"],
      useValue: ɵ0$4
    }, {
      provide: _angular_core__WEBPACK_IMPORTED_MODULE_1__["PLATFORM_INITIALIZER"],
      useValue: initDomAdapter,
      multi: true
    }, {
      provide: _angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"],
      useFactory: _document,
      deps: []
    }];
    /** @type {?} */

    var BROWSER_SANITIZATION_PROVIDERS__PRE_R3__ = [{
      provide: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Sanitizer"],
      useExisting: DomSanitizer
    }, {
      provide: DomSanitizer,
      useClass: DomSanitizerImpl,
      deps: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
    }];
    /** @type {?} */

    var BROWSER_SANITIZATION_PROVIDERS__POST_R3__ = [];
    /**
     * \@security Replacing built-in sanitization providers exposes the application to XSS risks.
     * Attacker-controlled data introduced by an unsanitized provider could expose your
     * application to XSS risks. For more detail, see the [Security Guide](http://g.co/ng/security).
     * \@publicApi
     * @type {?}
     */

    var BROWSER_SANITIZATION_PROVIDERS = BROWSER_SANITIZATION_PROVIDERS__POST_R3__;
    /**
     * \@publicApi
     * @type {?}
     */

    var platformBrowser = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["createPlatformFactory"])(_angular_core__WEBPACK_IMPORTED_MODULE_1__["platformCore"], 'browser', INTERNAL_BROWSER_PLATFORM_PROVIDERS);
    /** @type {?} */

    var BROWSER_MODULE_PROVIDERS = [BROWSER_SANITIZATION_PROVIDERS, {
      provide: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵINJECTOR_SCOPE"],
      useValue: 'root'
    }, {
      provide: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ErrorHandler"],
      useFactory: errorHandler,
      deps: []
    }, {
      provide: EVENT_MANAGER_PLUGINS,
      useClass: DomEventsPlugin,
      multi: true,
      deps: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"], _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"], _angular_core__WEBPACK_IMPORTED_MODULE_1__["PLATFORM_ID"]]
    }, {
      provide: EVENT_MANAGER_PLUGINS,
      useClass: KeyEventsPlugin,
      multi: true,
      deps: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
    }, HAMMER_PROVIDERS, {
      provide: DomRendererFactory2,
      useClass: DomRendererFactory2,
      deps: [EventManager, DomSharedStylesHost, _angular_core__WEBPACK_IMPORTED_MODULE_1__["APP_ID"]]
    }, {
      provide: _angular_core__WEBPACK_IMPORTED_MODULE_1__["RendererFactory2"],
      useExisting: DomRendererFactory2
    }, {
      provide: SharedStylesHost,
      useExisting: DomSharedStylesHost
    }, {
      provide: DomSharedStylesHost,
      useClass: DomSharedStylesHost,
      deps: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
    }, {
      provide: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Testability"],
      useClass: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Testability"],
      deps: [_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]]
    }, {
      provide: EventManager,
      useClass: EventManager,
      deps: [EVENT_MANAGER_PLUGINS, _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]]
    }, ELEMENT_PROBE_PROVIDERS];
    /**
     * Exports required infrastructure for all Angular apps.
     * Included by default in all Angular apps created with the CLI
     * `new` command.
     * Re-exports `CommonModule` and `ApplicationModule`, making their
     * exports and providers available to all apps.
     *
     * \@publicApi
     */

    var BrowserModule = /*#__PURE__*/function () {
      /**
       * @param {?} parentModule
       */
      function BrowserModule(parentModule) {
        _classCallCheck(this, BrowserModule);

        if (parentModule) {
          throw new Error("BrowserModule has already been loaded. If you need access to common directives such as NgIf and NgFor from a lazy loaded module, import CommonModule instead.");
        }
      }
      /**
       * Configures a browser-based app to transition from a server-rendered app, if
       * one is present on the page.
       *
       * @param {?} params An object containing an identifier for the app to transition.
       * The ID must match between the client and server versions of the app.
       * @return {?} The reconfigured `BrowserModule` to import into the app's root `AppModule`.
       */


      _createClass2(BrowserModule, null, [{
        key: "withServerTransition",
        value: function withServerTransition(params) {
          return {
            ngModule: BrowserModule,
            providers: [{
              provide: _angular_core__WEBPACK_IMPORTED_MODULE_1__["APP_ID"],
              useValue: params.appId
            }, {
              provide: TRANSITION_ID,
              useExisting: _angular_core__WEBPACK_IMPORTED_MODULE_1__["APP_ID"]
            }, SERVER_TRANSITION_PROVIDERS]
          };
        }
      }]);

      return BrowserModule;
    }();

    BrowserModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineNgModule"]({
      type: BrowserModule
    });
    BrowserModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjector"]({
      factory: function BrowserModule_Factory(t) {
        return new (t || BrowserModule)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](BrowserModule, 12));
      },
      providers: BROWSER_MODULE_PROVIDERS,
      imports: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["CommonModule"], _angular_core__WEBPACK_IMPORTED_MODULE_1__["ApplicationModule"]]
    });
    /** @nocollapse */

    BrowserModule.ctorParameters = function () {
      return [{
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["SkipSelf"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [BrowserModule]
        }]
      }];
    };

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵsetNgModuleScope"](BrowserModule, {
        exports: function exports() {
          return [_angular_common__WEBPACK_IMPORTED_MODULE_0__["CommonModule"], _angular_core__WEBPACK_IMPORTED_MODULE_1__["ApplicationModule"]];
        }
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](BrowserModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModule"],
        args: [{
          providers: BROWSER_MODULE_PROVIDERS,
          exports: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["CommonModule"], _angular_core__WEBPACK_IMPORTED_MODULE_1__["ApplicationModule"]]
        }]
      }], function () {
        return [{
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["SkipSelf"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [BrowserModule]
          }]
        }];
      }, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/browser/meta.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Factory to create Meta service.
     * @return {?}
     */


    function createMeta() {
      return new Meta(Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]));
    }
    /**
     * A service that can be used to get and add meta tags.
     *
     * \@publicApi
     */


    var Meta = /*#__PURE__*/function () {
      /**
       * @param {?} _doc
       */
      function Meta(_doc) {
        _classCallCheck(this, Meta);

        this._doc = _doc;
        this._dom = Object(_angular_common__WEBPACK_IMPORTED_MODULE_0__["ɵgetDOM"])();
      }
      /**
       * @param {?} tag
       * @param {?=} forceCreation
       * @return {?}
       */


      _createClass2(Meta, [{
        key: "addTag",
        value: function addTag(tag) {
          var forceCreation = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
          if (!tag) return null;
          return this._getOrCreateElement(tag, forceCreation);
        }
        /**
         * @param {?} tags
         * @param {?=} forceCreation
         * @return {?}
         */

      }, {
        key: "addTags",
        value: function addTags(tags) {
          var _this271 = this;

          var forceCreation = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
          if (!tags) return [];
          return tags.reduce(
          /**
          * @param {?} result
          * @param {?} tag
          * @return {?}
          */
          function (result, tag) {
            if (tag) {
              result.push(_this271._getOrCreateElement(tag, forceCreation));
            }

            return result;
          }, []);
        }
        /**
         * @param {?} attrSelector
         * @return {?}
         */

      }, {
        key: "getTag",
        value: function getTag(attrSelector) {
          if (!attrSelector) return null;
          return this._doc.querySelector("meta[".concat(attrSelector, "]")) || null;
        }
        /**
         * @param {?} attrSelector
         * @return {?}
         */

      }, {
        key: "getTags",
        value: function getTags(attrSelector) {
          if (!attrSelector) return [];
          /** @type {?} */

          var list
          /*NodeList*/
          = this._doc.querySelectorAll("meta[".concat(attrSelector, "]"));

          return list ? [].slice.call(list) : [];
        }
        /**
         * @param {?} tag
         * @param {?=} selector
         * @return {?}
         */

      }, {
        key: "updateTag",
        value: function updateTag(tag, selector) {
          if (!tag) return null;
          selector = selector || this._parseSelector(tag);
          /** @type {?} */

          var meta =
          /** @type {?} */
          this.getTag(selector);

          if (meta) {
            return this._setMetaElementAttributes(tag, meta);
          }

          return this._getOrCreateElement(tag, true);
        }
        /**
         * @param {?} attrSelector
         * @return {?}
         */

      }, {
        key: "removeTag",
        value: function removeTag(attrSelector) {
          this.removeTagElement(
          /** @type {?} */
          this.getTag(attrSelector));
        }
        /**
         * @param {?} meta
         * @return {?}
         */

      }, {
        key: "removeTagElement",
        value: function removeTagElement(meta) {
          if (meta) {
            this._dom.remove(meta);
          }
        }
        /**
         * @private
         * @param {?} meta
         * @param {?=} forceCreation
         * @return {?}
         */

      }, {
        key: "_getOrCreateElement",
        value: function _getOrCreateElement(meta) {
          var forceCreation = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;

          if (!forceCreation) {
            /** @type {?} */
            var selector = this._parseSelector(meta);
            /** @type {?} */


            var elem =
            /** @type {?} */
            this.getTag(selector); // It's allowed to have multiple elements with the same name so it's not enough to
            // just check that element with the same name already present on the page. We also need to
            // check if element has tag attributes

            if (elem && this._containsAttributes(meta, elem)) return elem;
          }
          /** @type {?} */


          var element =
          /** @type {?} */
          this._dom.createElement('meta');

          this._setMetaElementAttributes(meta, element);
          /** @type {?} */


          var head = this._doc.getElementsByTagName('head')[0];

          head.appendChild(element);
          return element;
        }
        /**
         * @private
         * @param {?} tag
         * @param {?} el
         * @return {?}
         */

      }, {
        key: "_setMetaElementAttributes",
        value: function _setMetaElementAttributes(tag, el) {
          Object.keys(tag).forEach(
          /**
          * @param {?} prop
          * @return {?}
          */
          function (prop) {
            return el.setAttribute(prop, tag[prop]);
          });
          return el;
        }
        /**
         * @private
         * @param {?} tag
         * @return {?}
         */

      }, {
        key: "_parseSelector",
        value: function _parseSelector(tag) {
          /** @type {?} */
          var attr = tag.name ? 'name' : 'property';
          return "".concat(attr, "=\"").concat(tag[attr], "\"");
        }
        /**
         * @private
         * @param {?} tag
         * @param {?} elem
         * @return {?}
         */

      }, {
        key: "_containsAttributes",
        value: function _containsAttributes(tag, elem) {
          return Object.keys(tag).every(
          /**
          * @param {?} key
          * @return {?}
          */
          function (key) {
            return elem.getAttribute(key) === tag[key];
          });
        }
      }]);

      return Meta;
    }();

    Meta.ɵfac = function Meta_Factory(t) {
      return new (t || Meta)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]));
    };
    /** @nocollapse */


    Meta.ctorParameters = function () {
      return [{
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
        }]
      }];
    };
    /** @nocollapse */


    Meta.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: createMeta,
      token: Meta,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](Meta, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root',
          useFactory: createMeta,
          deps: []
        }]
      }], function () {
        return [{
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/browser/title.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Factory to create Title service.
     * @return {?}
     */


    function createTitle() {
      return new Title(Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]));
    }
    /**
     * A service that can be used to get and set the title of a current HTML document.
     *
     * Since an Angular application can't be bootstrapped on the entire HTML document (`<html>` tag)
     * it is not possible to bind to the `text` property of the `HTMLTitleElement` elements
     * (representing the `<title>` tag). Instead, this service can be used to set and get the current
     * title value.
     *
     * \@publicApi
     */


    var Title = /*#__PURE__*/function () {
      /**
       * @param {?} _doc
       */
      function Title(_doc) {
        _classCallCheck(this, Title);

        this._doc = _doc;
      }
      /**
       * Get the title of the current HTML document.
       * @return {?}
       */


      _createClass2(Title, [{
        key: "getTitle",
        value: function getTitle() {
          return this._doc.title;
        }
        /**
         * Set the title of the current HTML document.
         * @param {?} newTitle
         * @return {?}
         */

      }, {
        key: "setTitle",
        value: function setTitle(newTitle) {
          this._doc.title = newTitle || '';
        }
      }]);

      return Title;
    }();

    Title.ɵfac = function Title_Factory(t) {
      return new (t || Title)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]));
    };
    /** @nocollapse */


    Title.ctorParameters = function () {
      return [{
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
        }]
      }];
    };
    /** @nocollapse */


    Title.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({
      factory: createTitle,
      token: Title,
      providedIn: "root"
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](Title, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"],
        args: [{
          providedIn: 'root',
          useFactory: createTitle,
          deps: []
        }]
      }], function () {
        return [{
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"]]
          }]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/browser/tools/browser.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /** @type {?} */


    var win = typeof window !== 'undefined' && window ||
    /** @type {?} */
    {};
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/browser/tools/common_tools.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    var ChangeDetectionPerfRecord =
    /**
     * @param {?} msPerTick
     * @param {?} numTicks
     */
    function ChangeDetectionPerfRecord(msPerTick, numTicks) {
      _classCallCheck(this, ChangeDetectionPerfRecord);

      this.msPerTick = msPerTick;
      this.numTicks = numTicks;
    };

    if (false) {}
    /**
     * Entry point for all Angular profiling-related debug tools. This object
     * corresponds to the `ng.profiler` in the dev console.
     */


    var AngularProfiler = /*#__PURE__*/function () {
      /**
       * @param {?} ref
       */
      function AngularProfiler(ref) {
        _classCallCheck(this, AngularProfiler);

        this.appRef = ref.injector.get(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ApplicationRef"]);
      } // tslint:disable:no-console

      /**
       * Exercises change detection in a loop and then prints the average amount of
       * time in milliseconds how long a single round of change detection takes for
       * the current state of the UI. It runs a minimum of 5 rounds for a minimum
       * of 500 milliseconds.
       *
       * Optionally, a user may pass a `config` parameter containing a map of
       * options. Supported options are:
       *
       * `record` (boolean) - causes the profiler to record a CPU profile while
       * it exercises the change detector. Example:
       *
       * ```
       * ng.profiler.timeChangeDetection({record: true})
       * ```
       * @param {?} config
       * @return {?}
       */


      _createClass2(AngularProfiler, [{
        key: "timeChangeDetection",
        value: function timeChangeDetection(config) {
          /** @type {?} */
          var record = config && config['record'];
          /** @type {?} */

          var profileName = 'Change Detection'; // Profiler is not available in Android browsers, nor in IE 9 without dev tools opened

          /** @type {?} */

          var isProfilerAvailable = win.console.profile != null;

          if (record && isProfilerAvailable) {
            win.console.profile(profileName);
          }
          /** @type {?} */


          var start = Object(_angular_common__WEBPACK_IMPORTED_MODULE_0__["ɵgetDOM"])().performanceNow();
          /** @type {?} */

          var numTicks = 0;

          while (numTicks < 5 || Object(_angular_common__WEBPACK_IMPORTED_MODULE_0__["ɵgetDOM"])().performanceNow() - start < 500) {
            this.appRef.tick();
            numTicks++;
          }
          /** @type {?} */


          var end = Object(_angular_common__WEBPACK_IMPORTED_MODULE_0__["ɵgetDOM"])().performanceNow();

          if (record && isProfilerAvailable) {
            win.console.profileEnd(profileName);
          }
          /** @type {?} */


          var msPerTick = (end - start) / numTicks;
          win.console.log("ran ".concat(numTicks, " change detection cycles"));
          win.console.log("".concat(msPerTick.toFixed(2), " ms per check"));
          return new ChangeDetectionPerfRecord(msPerTick, numTicks);
        }
      }]);

      return AngularProfiler;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/browser/tools/tools.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var PROFILER_GLOBAL_NAME = 'profiler';
    /**
     * Enabled Angular debug tools that are accessible via your browser's
     * developer console.
     *
     * Usage:
     *
     * 1. Open developer console (e.g. in Chrome Ctrl + Shift + j)
     * 1. Type `ng.` (usually the console will show auto-complete suggestion)
     * 1. Try the change detection profiler `ng.profiler.timeChangeDetection()`
     *    then hit Enter.
     *
     * \@publicApi
     * @template T
     * @param {?} ref
     * @return {?}
     */

    function enableDebugTools(ref) {
      exportNgVar(PROFILER_GLOBAL_NAME, new AngularProfiler(ref));
      return ref;
    }
    /**
     * Disables Angular tools.
     *
     * \@publicApi
     * @return {?}
     */


    function disableDebugTools() {
      exportNgVar(PROFILER_GLOBAL_NAME, null);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/browser/transfer_state.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} text
     * @return {?}
     */


    function escapeHtml(text) {
      /** @type {?} */
      var escapedText = {
        '&': '&a;',
        '"': '&q;',
        '\'': '&s;',
        '<': '&l;',
        '>': '&g;'
      };
      return text.replace(/[&"'<>]/g,
      /**
      * @param {?} s
      * @return {?}
      */
      function (s) {
        return escapedText[s];
      });
    }
    /**
     * @param {?} text
     * @return {?}
     */


    function unescapeHtml(text) {
      /** @type {?} */
      var unescapedText = {
        '&a;': '&',
        '&q;': '"',
        '&s;': '\'',
        '&l;': '<',
        '&g;': '>'
      };
      return text.replace(/&[^;]+;/g,
      /**
      * @param {?} s
      * @return {?}
      */
      function (s) {
        return unescapedText[s];
      });
    }
    /**
     * Create a `StateKey<T>` that can be used to store value of type T with `TransferState`.
     *
     * Example:
     *
     * ```
     * const COUNTER_KEY = makeStateKey<number>('counter');
     * let value = 10;
     *
     * transferState.set(COUNTER_KEY, value);
     * ```
     *
     * \@publicApi
     * @template T
     * @param {?} key
     * @return {?}
     */


    function makeStateKey(key) {
      return (
        /** @type {?} */
        key
      );
    }
    /**
     * A key value store that is transferred from the application on the server side to the application
     * on the client side.
     *
     * `TransferState` will be available as an injectable token. To use it import
     * `ServerTransferStateModule` on the server and `BrowserTransferStateModule` on the client.
     *
     * The values in the store are serialized/deserialized using JSON.stringify/JSON.parse. So only
     * boolean, number, string, null and non-class objects will be serialized and deserialzied in a
     * non-lossy manner.
     *
     * \@publicApi
     */


    var TransferState = /*#__PURE__*/function () {
      function TransferState() {
        _classCallCheck(this, TransferState);

        this.store = {};
        this.onSerializeCallbacks = {};
      }
      /**
       * \@internal
       * @param {?} initState
       * @return {?}
       */


      _createClass2(TransferState, [{
        key: "get",

        /**
         * Get the value corresponding to a key. Return `defaultValue` if key is not found.
         * @template T
         * @param {?} key
         * @param {?} defaultValue
         * @return {?}
         */
        value: function get(key, defaultValue) {
          return this.store[key] !== undefined ?
          /** @type {?} */
          this.store[key] : defaultValue;
        }
        /**
         * Set the value corresponding to a key.
         * @template T
         * @param {?} key
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "set",
        value: function set(key, value) {
          this.store[key] = value;
        }
        /**
         * Remove a key from the store.
         * @template T
         * @param {?} key
         * @return {?}
         */

      }, {
        key: "remove",
        value: function remove(key) {
          delete this.store[key];
        }
        /**
         * Test whether a key exists in the store.
         * @template T
         * @param {?} key
         * @return {?}
         */

      }, {
        key: "hasKey",
        value: function hasKey(key) {
          return this.store.hasOwnProperty(key);
        }
        /**
         * Register a callback to provide the value for a key when `toJson` is called.
         * @template T
         * @param {?} key
         * @param {?} callback
         * @return {?}
         */

      }, {
        key: "onSerialize",
        value: function onSerialize(key, callback) {
          this.onSerializeCallbacks[key] = callback;
        }
        /**
         * Serialize the current state of the store to JSON.
         * @return {?}
         */

      }, {
        key: "toJson",
        value: function toJson() {
          // Call the onSerialize callbacks and put those values into the store.
          for (var key in this.onSerializeCallbacks) {
            if (this.onSerializeCallbacks.hasOwnProperty(key)) {
              try {
                this.store[key] = this.onSerializeCallbacks[key]();
              } catch (e) {
                console.warn('Exception in onSerialize callback: ', e);
              }
            }
          }

          return JSON.stringify(this.store);
        }
      }], [{
        key: "init",
        value: function init(initState) {
          /** @type {?} */
          var transferState = new TransferState();
          transferState.store = initState;
          return transferState;
        }
      }]);

      return TransferState;
    }();

    TransferState.ɵfac = function TransferState_Factory(t) {
      return new (t || TransferState)();
    };

    TransferState.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"]({
      token: TransferState,
      factory: TransferState.ɵfac
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](TransferState, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"]
      }], function () {
        return [];
      }, null);
    })();

    if (false) {}
    /**
     * @param {?} doc
     * @param {?} appId
     * @return {?}
     */


    function initTransferState(doc, appId) {
      // Locate the script tag with the JSON data transferred from the server.
      // The id of the script tag is set to the Angular appId + 'state'.

      /** @type {?} */
      var script = doc.getElementById(appId + '-state');
      /** @type {?} */

      var initialState = {};

      if (script && script.textContent) {
        try {
          initialState = JSON.parse(unescapeHtml(script.textContent));
        } catch (e) {
          console.warn('Exception while restoring TransferState for app ' + appId, e);
        }
      }

      return TransferState.init(initialState);
    }
    /**
     * NgModule to install on the client side while using the `TransferState` to transfer state from
     * server to client.
     *
     * \@publicApi
     */


    var BrowserTransferStateModule = function BrowserTransferStateModule() {
      _classCallCheck(this, BrowserTransferStateModule);
    };

    BrowserTransferStateModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineNgModule"]({
      type: BrowserTransferStateModule
    });
    BrowserTransferStateModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjector"]({
      factory: function BrowserTransferStateModule_Factory(t) {
        return new (t || BrowserTransferStateModule)();
      },
      providers: [{
        provide: TransferState,
        useFactory: initTransferState,
        deps: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"], _angular_core__WEBPACK_IMPORTED_MODULE_1__["APP_ID"]]
      }]
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](BrowserTransferStateModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModule"],
        args: [{
          providers: [{
            provide: TransferState,
            useFactory: initTransferState,
            deps: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["DOCUMENT"], _angular_core__WEBPACK_IMPORTED_MODULE_1__["APP_ID"]]
          }]
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/dom/debug/by.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Predicates for use with {\@link DebugElement}'s query functions.
     *
     * \@publicApi
     */


    var By = /*#__PURE__*/function () {
      function By() {
        _classCallCheck(this, By);
      }

      _createClass2(By, null, [{
        key: "all",

        /**
         * Match all nodes.
         *
         * \@usageNotes
         * ### Example
         *
         * {\@example platform-browser/dom/debug/ts/by/by.ts region='by_all'}
         * @return {?}
         */
        value: function all() {
          return (
            /**
            * @return {?}
            */
            function () {
              return true;
            }
          );
        }
        /**
         * Match elements by the given CSS selector.
         *
         * \@usageNotes
         * ### Example
         *
         * {\@example platform-browser/dom/debug/ts/by/by.ts region='by_css'}
         * @param {?} selector
         * @return {?}
         */

      }, {
        key: "css",
        value: function css(selector) {
          return (
            /**
            * @param {?} debugElement
            * @return {?}
            */
            function (debugElement) {
              return debugElement.nativeElement != null ? elementMatches(debugElement.nativeElement, selector) : false;
            }
          );
        }
        /**
         * Match nodes that have the given directive present.
         *
         * \@usageNotes
         * ### Example
         *
         * {\@example platform-browser/dom/debug/ts/by/by.ts region='by_directive'}
         * @param {?} type
         * @return {?}
         */

      }, {
        key: "directive",
        value: function directive(type) {
          return (
            /**
            * @param {?} debugNode
            * @return {?}
            */
            function (debugNode) {
              return (
                /** @type {?} */
                debugNode.providerTokens.indexOf(type) !== -1
              );
            }
          );
        }
      }]);

      return By;
    }();
    /**
     * @param {?} n
     * @param {?} selector
     * @return {?}
     */


    function elementMatches(n, selector) {
      if (Object(_angular_common__WEBPACK_IMPORTED_MODULE_0__["ɵgetDOM"])().isElementNode(n)) {
        return n.matches && n.matches(selector) || n.msMatchesSelector && n.msMatchesSelector(selector) || n.webkitMatchesSelector && n.webkitMatchesSelector(selector);
      }

      return false;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/private_export.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/version.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@publicApi
     * @type {?}
     */


    var VERSION = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["Version"]('9.1.4');
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/src/platform-browser.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/public_api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/platform-browser/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=platform-browser.js.map

    /***/
  },

  /***/
  "./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js":
  /*!**********************************************************************!*\
    !*** ./node_modules/@angular/router/__ivy_ngcc__/fesm2015/router.js ***!
    \**********************************************************************/

  /*! exports provided: ActivatedRoute, ActivatedRouteSnapshot, ActivationEnd, ActivationStart, ChildActivationEnd, ChildActivationStart, ChildrenOutletContexts, DefaultUrlSerializer, GuardsCheckEnd, GuardsCheckStart, NavigationCancel, NavigationEnd, NavigationError, NavigationStart, NoPreloading, OutletContext, PRIMARY_OUTLET, PreloadAllModules, PreloadingStrategy, ROUTER_CONFIGURATION, ROUTER_INITIALIZER, ROUTES, ResolveEnd, ResolveStart, RouteConfigLoadEnd, RouteConfigLoadStart, RouteReuseStrategy, Router, RouterEvent, RouterLink, RouterLinkActive, RouterLinkWithHref, RouterModule, RouterOutlet, RouterPreloader, RouterState, RouterStateSnapshot, RoutesRecognized, Scroll, UrlHandlingStrategy, UrlSegment, UrlSegmentGroup, UrlSerializer, UrlTree, VERSION, convertToParamMap, provideRoutes, ɵEmptyOutletComponent, ɵROUTER_PROVIDERS, ɵangular_packages_router_router_a, ɵangular_packages_router_router_b, ɵangular_packages_router_router_c, ɵangular_packages_router_router_d, ɵangular_packages_router_router_e, ɵangular_packages_router_router_f, ɵangular_packages_router_router_g, ɵangular_packages_router_router_h, ɵangular_packages_router_router_i, ɵangular_packages_router_router_j, ɵangular_packages_router_router_k, ɵangular_packages_router_router_l, ɵangular_packages_router_router_m, ɵangular_packages_router_router_n, ɵangular_packages_router_router_o, ɵflatten */

  /***/
  function node_modulesAngularRouter__ivy_ngcc__Fesm2015RouterJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ActivatedRoute", function () {
      return ActivatedRoute;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ActivatedRouteSnapshot", function () {
      return ActivatedRouteSnapshot;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ActivationEnd", function () {
      return ActivationEnd;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ActivationStart", function () {
      return ActivationStart;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ChildActivationEnd", function () {
      return ChildActivationEnd;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ChildActivationStart", function () {
      return ChildActivationStart;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ChildrenOutletContexts", function () {
      return ChildrenOutletContexts;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DefaultUrlSerializer", function () {
      return DefaultUrlSerializer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "GuardsCheckEnd", function () {
      return GuardsCheckEnd;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "GuardsCheckStart", function () {
      return GuardsCheckStart;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NavigationCancel", function () {
      return NavigationCancel;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NavigationEnd", function () {
      return NavigationEnd;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NavigationError", function () {
      return NavigationError;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NavigationStart", function () {
      return NavigationStart;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NoPreloading", function () {
      return NoPreloading;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "OutletContext", function () {
      return OutletContext;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "PRIMARY_OUTLET", function () {
      return PRIMARY_OUTLET;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "PreloadAllModules", function () {
      return PreloadAllModules;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "PreloadingStrategy", function () {
      return PreloadingStrategy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ROUTER_CONFIGURATION", function () {
      return ROUTER_CONFIGURATION;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ROUTER_INITIALIZER", function () {
      return ROUTER_INITIALIZER;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ROUTES", function () {
      return ROUTES;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ResolveEnd", function () {
      return ResolveEnd;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ResolveStart", function () {
      return ResolveStart;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RouteConfigLoadEnd", function () {
      return RouteConfigLoadEnd;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RouteConfigLoadStart", function () {
      return RouteConfigLoadStart;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RouteReuseStrategy", function () {
      return RouteReuseStrategy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Router", function () {
      return Router;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RouterEvent", function () {
      return RouterEvent;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RouterLink", function () {
      return RouterLink;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RouterLinkActive", function () {
      return RouterLinkActive;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RouterLinkWithHref", function () {
      return RouterLinkWithHref;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RouterModule", function () {
      return RouterModule;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RouterOutlet", function () {
      return RouterOutlet;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RouterPreloader", function () {
      return RouterPreloader;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RouterState", function () {
      return RouterState;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RouterStateSnapshot", function () {
      return RouterStateSnapshot;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RoutesRecognized", function () {
      return RoutesRecognized;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Scroll", function () {
      return Scroll;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "UrlHandlingStrategy", function () {
      return UrlHandlingStrategy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "UrlSegment", function () {
      return UrlSegment;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "UrlSegmentGroup", function () {
      return UrlSegmentGroup;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "UrlSerializer", function () {
      return UrlSerializer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "UrlTree", function () {
      return UrlTree;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "VERSION", function () {
      return VERSION;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "convertToParamMap", function () {
      return convertToParamMap;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "provideRoutes", function () {
      return provideRoutes;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵEmptyOutletComponent", function () {
      return ɵEmptyOutletComponent;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵROUTER_PROVIDERS", function () {
      return ROUTER_PROVIDERS;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_router_router_a", function () {
      return ROUTER_FORROOT_GUARD;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_router_router_b", function () {
      return routerNgProbeToken;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_router_router_c", function () {
      return createRouterScroller;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_router_router_d", function () {
      return provideLocationStrategy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_router_router_e", function () {
      return provideForRootGuard;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_router_router_f", function () {
      return setupRouter;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_router_router_g", function () {
      return rootRoute;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_router_router_h", function () {
      return RouterInitializer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_router_router_i", function () {
      return getAppInitializer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_router_router_j", function () {
      return getBootstrapListener;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_router_router_k", function () {
      return provideRouterInitializer;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_router_router_l", function () {
      return ɵEmptyOutletComponent;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_router_router_m", function () {
      return Tree;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_router_router_n", function () {
      return TreeNode;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵangular_packages_router_router_o", function () {
      return RouterScroller;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ɵflatten", function () {
      return flatten;
    });
    /* harmony import */


    var _angular_common__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! @angular/common */
    "./node_modules/@angular/common/__ivy_ngcc__/fesm2015/common.js");
    /* harmony import */


    var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! @angular/core */
    "./node_modules/@angular/core/__ivy_ngcc__/fesm2015/core.js");
    /* harmony import */


    var rxjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! rxjs */
    "./node_modules/rxjs/_esm2015/index.js");
    /* harmony import */


    var rxjs_operators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! rxjs/operators */
    "./node_modules/rxjs/_esm2015/operators/index.js");
    /**
     * @license Angular v9.1.4
     * (c) 2010-2020 Google LLC. https://angular.io/
     * License: MIT
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/events.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Base for events the router goes through, as opposed to events tied to a specific
     * route. Fired one time for any given navigation.
     *
     * \@usageNotes
     *
     * ```ts
     * class MyService {
     *   constructor(public router: Router, logger: Logger) {
     *     router.events.pipe(
     *       filter(e => e instanceof RouterEvent)
     *     ).subscribe(e => {
     *       logger.log(e.id, e.url);
     *     });
     *   }
     * }
     * ```
     *
     * @see `Event`
     * \@publicApi
     */


    var RouterEvent =
    /**
     * @param {?} id
     * @param {?} url
     */
    function RouterEvent(id, url) {
      _classCallCheck(this, RouterEvent);

      this.id = id;
      this.url = url;
    };

    if (false) {}
    /**
     * An event triggered when a navigation starts.
     *
     * \@publicApi
     */


    var NavigationStart = /*#__PURE__*/function (_RouterEvent) {
      _inherits(NavigationStart, _RouterEvent);

      var _super97 = _createSuper(NavigationStart);

      /**
       * @param {?} id
       * @param {?} url
       * @param {?=} navigationTrigger
       * @param {?=} restoredState
       */
      function NavigationStart(
      /** @docsNotRequired */
      id,
      /** @docsNotRequired */
      url) {
        var _this272;

        var navigationTrigger = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 'imperative';
        var restoredState = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : null;

        _classCallCheck(this, NavigationStart);

        _this272 = _super97.call(this, id, url);
        _this272.navigationTrigger = navigationTrigger;
        _this272.restoredState = restoredState;
        return _this272;
      }
      /**
       * \@docsNotRequired
       * @return {?}
       */


      _createClass2(NavigationStart, [{
        key: "toString",
        value: function toString() {
          return "NavigationStart(id: ".concat(this.id, ", url: '").concat(this.url, "')");
        }
      }]);

      return NavigationStart;
    }(RouterEvent);

    if (false) {}
    /**
     * An event triggered when a navigation ends successfully.
     *
     * \@publicApi
     */


    var NavigationEnd = /*#__PURE__*/function (_RouterEvent2) {
      _inherits(NavigationEnd, _RouterEvent2);

      var _super98 = _createSuper(NavigationEnd);

      /**
       * @param {?} id
       * @param {?} url
       * @param {?} urlAfterRedirects
       */
      function NavigationEnd(
      /** @docsNotRequired */
      id,
      /** @docsNotRequired */
      url, urlAfterRedirects) {
        var _this273;

        _classCallCheck(this, NavigationEnd);

        _this273 = _super98.call(this, id, url);
        _this273.urlAfterRedirects = urlAfterRedirects;
        return _this273;
      }
      /**
       * \@docsNotRequired
       * @return {?}
       */


      _createClass2(NavigationEnd, [{
        key: "toString",
        value: function toString() {
          return "NavigationEnd(id: ".concat(this.id, ", url: '").concat(this.url, "', urlAfterRedirects: '").concat(this.urlAfterRedirects, "')");
        }
      }]);

      return NavigationEnd;
    }(RouterEvent);

    if (false) {}
    /**
     * An event triggered when a navigation is canceled, directly or indirectly.
     *
     * This can happen when a [route guard](guide/router#milestone-5-route-guards)
     * returns `false` or initiates a redirect by returning a `UrlTree`.
     *
     * \@publicApi
     */


    var NavigationCancel = /*#__PURE__*/function (_RouterEvent3) {
      _inherits(NavigationCancel, _RouterEvent3);

      var _super99 = _createSuper(NavigationCancel);

      /**
       * @param {?} id
       * @param {?} url
       * @param {?} reason
       */
      function NavigationCancel(
      /** @docsNotRequired */
      id,
      /** @docsNotRequired */
      url, reason) {
        var _this274;

        _classCallCheck(this, NavigationCancel);

        _this274 = _super99.call(this, id, url);
        _this274.reason = reason;
        return _this274;
      }
      /**
       * \@docsNotRequired
       * @return {?}
       */


      _createClass2(NavigationCancel, [{
        key: "toString",
        value: function toString() {
          return "NavigationCancel(id: ".concat(this.id, ", url: '").concat(this.url, "')");
        }
      }]);

      return NavigationCancel;
    }(RouterEvent);

    if (false) {}
    /**
     * An event triggered when a navigation fails due to an unexpected error.
     *
     * \@publicApi
     */


    var NavigationError = /*#__PURE__*/function (_RouterEvent4) {
      _inherits(NavigationError, _RouterEvent4);

      var _super100 = _createSuper(NavigationError);

      /**
       * @param {?} id
       * @param {?} url
       * @param {?} error
       */
      function NavigationError(
      /** @docsNotRequired */
      id,
      /** @docsNotRequired */
      url, error) {
        var _this275;

        _classCallCheck(this, NavigationError);

        _this275 = _super100.call(this, id, url);
        _this275.error = error;
        return _this275;
      }
      /**
       * \@docsNotRequired
       * @return {?}
       */


      _createClass2(NavigationError, [{
        key: "toString",
        value: function toString() {
          return "NavigationError(id: ".concat(this.id, ", url: '").concat(this.url, "', error: ").concat(this.error, ")");
        }
      }]);

      return NavigationError;
    }(RouterEvent);

    if (false) {}
    /**
     * An event triggered when routes are recognized.
     *
     * \@publicApi
     */


    var RoutesRecognized = /*#__PURE__*/function (_RouterEvent5) {
      _inherits(RoutesRecognized, _RouterEvent5);

      var _super101 = _createSuper(RoutesRecognized);

      /**
       * @param {?} id
       * @param {?} url
       * @param {?} urlAfterRedirects
       * @param {?} state
       */
      function RoutesRecognized(
      /** @docsNotRequired */
      id,
      /** @docsNotRequired */
      url, urlAfterRedirects, state) {
        var _this276;

        _classCallCheck(this, RoutesRecognized);

        _this276 = _super101.call(this, id, url);
        _this276.urlAfterRedirects = urlAfterRedirects;
        _this276.state = state;
        return _this276;
      }
      /**
       * \@docsNotRequired
       * @return {?}
       */


      _createClass2(RoutesRecognized, [{
        key: "toString",
        value: function toString() {
          return "RoutesRecognized(id: ".concat(this.id, ", url: '").concat(this.url, "', urlAfterRedirects: '").concat(this.urlAfterRedirects, "', state: ").concat(this.state, ")");
        }
      }]);

      return RoutesRecognized;
    }(RouterEvent);

    if (false) {}
    /**
     * An event triggered at the start of the Guard phase of routing.
     *
     * \@publicApi
     */


    var GuardsCheckStart = /*#__PURE__*/function (_RouterEvent6) {
      _inherits(GuardsCheckStart, _RouterEvent6);

      var _super102 = _createSuper(GuardsCheckStart);

      /**
       * @param {?} id
       * @param {?} url
       * @param {?} urlAfterRedirects
       * @param {?} state
       */
      function GuardsCheckStart(
      /** @docsNotRequired */
      id,
      /** @docsNotRequired */
      url, urlAfterRedirects, state) {
        var _this277;

        _classCallCheck(this, GuardsCheckStart);

        _this277 = _super102.call(this, id, url);
        _this277.urlAfterRedirects = urlAfterRedirects;
        _this277.state = state;
        return _this277;
      }
      /**
       * @return {?}
       */


      _createClass2(GuardsCheckStart, [{
        key: "toString",
        value: function toString() {
          return "GuardsCheckStart(id: ".concat(this.id, ", url: '").concat(this.url, "', urlAfterRedirects: '").concat(this.urlAfterRedirects, "', state: ").concat(this.state, ")");
        }
      }]);

      return GuardsCheckStart;
    }(RouterEvent);

    if (false) {}
    /**
     * An event triggered at the end of the Guard phase of routing.
     *
     * \@publicApi
     */


    var GuardsCheckEnd = /*#__PURE__*/function (_RouterEvent7) {
      _inherits(GuardsCheckEnd, _RouterEvent7);

      var _super103 = _createSuper(GuardsCheckEnd);

      /**
       * @param {?} id
       * @param {?} url
       * @param {?} urlAfterRedirects
       * @param {?} state
       * @param {?} shouldActivate
       */
      function GuardsCheckEnd(
      /** @docsNotRequired */
      id,
      /** @docsNotRequired */
      url, urlAfterRedirects, state, shouldActivate) {
        var _this278;

        _classCallCheck(this, GuardsCheckEnd);

        _this278 = _super103.call(this, id, url);
        _this278.urlAfterRedirects = urlAfterRedirects;
        _this278.state = state;
        _this278.shouldActivate = shouldActivate;
        return _this278;
      }
      /**
       * @return {?}
       */


      _createClass2(GuardsCheckEnd, [{
        key: "toString",
        value: function toString() {
          return "GuardsCheckEnd(id: ".concat(this.id, ", url: '").concat(this.url, "', urlAfterRedirects: '").concat(this.urlAfterRedirects, "', state: ").concat(this.state, ", shouldActivate: ").concat(this.shouldActivate, ")");
        }
      }]);

      return GuardsCheckEnd;
    }(RouterEvent);

    if (false) {}
    /**
     * An event triggered at the the start of the Resolve phase of routing.
     *
     * Runs in the "resolve" phase whether or not there is anything to resolve.
     * In future, may change to only run when there are things to be resolved.
     *
     * \@publicApi
     */


    var ResolveStart = /*#__PURE__*/function (_RouterEvent8) {
      _inherits(ResolveStart, _RouterEvent8);

      var _super104 = _createSuper(ResolveStart);

      /**
       * @param {?} id
       * @param {?} url
       * @param {?} urlAfterRedirects
       * @param {?} state
       */
      function ResolveStart(
      /** @docsNotRequired */
      id,
      /** @docsNotRequired */
      url, urlAfterRedirects, state) {
        var _this279;

        _classCallCheck(this, ResolveStart);

        _this279 = _super104.call(this, id, url);
        _this279.urlAfterRedirects = urlAfterRedirects;
        _this279.state = state;
        return _this279;
      }
      /**
       * @return {?}
       */


      _createClass2(ResolveStart, [{
        key: "toString",
        value: function toString() {
          return "ResolveStart(id: ".concat(this.id, ", url: '").concat(this.url, "', urlAfterRedirects: '").concat(this.urlAfterRedirects, "', state: ").concat(this.state, ")");
        }
      }]);

      return ResolveStart;
    }(RouterEvent);

    if (false) {}
    /**
     * An event triggered at the end of the Resolve phase of routing.
     * @see `ResolveStart`.
     *
     * \@publicApi
     */


    var ResolveEnd = /*#__PURE__*/function (_RouterEvent9) {
      _inherits(ResolveEnd, _RouterEvent9);

      var _super105 = _createSuper(ResolveEnd);

      /**
       * @param {?} id
       * @param {?} url
       * @param {?} urlAfterRedirects
       * @param {?} state
       */
      function ResolveEnd(
      /** @docsNotRequired */
      id,
      /** @docsNotRequired */
      url, urlAfterRedirects, state) {
        var _this280;

        _classCallCheck(this, ResolveEnd);

        _this280 = _super105.call(this, id, url);
        _this280.urlAfterRedirects = urlAfterRedirects;
        _this280.state = state;
        return _this280;
      }
      /**
       * @return {?}
       */


      _createClass2(ResolveEnd, [{
        key: "toString",
        value: function toString() {
          return "ResolveEnd(id: ".concat(this.id, ", url: '").concat(this.url, "', urlAfterRedirects: '").concat(this.urlAfterRedirects, "', state: ").concat(this.state, ")");
        }
      }]);

      return ResolveEnd;
    }(RouterEvent);

    if (false) {}
    /**
     * An event triggered before lazy loading a route configuration.
     *
     * \@publicApi
     */


    var RouteConfigLoadStart = /*#__PURE__*/function () {
      /**
       * @param {?} route
       */
      function RouteConfigLoadStart(route) {
        _classCallCheck(this, RouteConfigLoadStart);

        this.route = route;
      }
      /**
       * @return {?}
       */


      _createClass2(RouteConfigLoadStart, [{
        key: "toString",
        value: function toString() {
          return "RouteConfigLoadStart(path: ".concat(this.route.path, ")");
        }
      }]);

      return RouteConfigLoadStart;
    }();

    if (false) {}
    /**
     * An event triggered when a route has been lazy loaded.
     *
     * \@publicApi
     */


    var RouteConfigLoadEnd = /*#__PURE__*/function () {
      /**
       * @param {?} route
       */
      function RouteConfigLoadEnd(route) {
        _classCallCheck(this, RouteConfigLoadEnd);

        this.route = route;
      }
      /**
       * @return {?}
       */


      _createClass2(RouteConfigLoadEnd, [{
        key: "toString",
        value: function toString() {
          return "RouteConfigLoadEnd(path: ".concat(this.route.path, ")");
        }
      }]);

      return RouteConfigLoadEnd;
    }();

    if (false) {}
    /**
     * An event triggered at the start of the child-activation
     * part of the Resolve phase of routing.
     * @see `ChildActivationEnd`
     * @see `ResolveStart`
     *
     * \@publicApi
     */


    var ChildActivationStart = /*#__PURE__*/function () {
      /**
       * @param {?} snapshot
       */
      function ChildActivationStart(snapshot) {
        _classCallCheck(this, ChildActivationStart);

        this.snapshot = snapshot;
      }
      /**
       * @return {?}
       */


      _createClass2(ChildActivationStart, [{
        key: "toString",
        value: function toString() {
          /** @type {?} */
          var path = this.snapshot.routeConfig && this.snapshot.routeConfig.path || '';
          return "ChildActivationStart(path: '".concat(path, "')");
        }
      }]);

      return ChildActivationStart;
    }();

    if (false) {}
    /**
     * An event triggered at the end of the child-activation part
     * of the Resolve phase of routing.
     * @see `ChildActivationStart`
     * @see `ResolveStart` *
     * \@publicApi
     */


    var ChildActivationEnd = /*#__PURE__*/function () {
      /**
       * @param {?} snapshot
       */
      function ChildActivationEnd(snapshot) {
        _classCallCheck(this, ChildActivationEnd);

        this.snapshot = snapshot;
      }
      /**
       * @return {?}
       */


      _createClass2(ChildActivationEnd, [{
        key: "toString",
        value: function toString() {
          /** @type {?} */
          var path = this.snapshot.routeConfig && this.snapshot.routeConfig.path || '';
          return "ChildActivationEnd(path: '".concat(path, "')");
        }
      }]);

      return ChildActivationEnd;
    }();

    if (false) {}
    /**
     * An event triggered at the start of the activation part
     * of the Resolve phase of routing.
     * @see ActivationEnd`
     * @see `ResolveStart`
     *
     * \@publicApi
     */


    var ActivationStart = /*#__PURE__*/function () {
      /**
       * @param {?} snapshot
       */
      function ActivationStart(snapshot) {
        _classCallCheck(this, ActivationStart);

        this.snapshot = snapshot;
      }
      /**
       * @return {?}
       */


      _createClass2(ActivationStart, [{
        key: "toString",
        value: function toString() {
          /** @type {?} */
          var path = this.snapshot.routeConfig && this.snapshot.routeConfig.path || '';
          return "ActivationStart(path: '".concat(path, "')");
        }
      }]);

      return ActivationStart;
    }();

    if (false) {}
    /**
     * An event triggered at the end of the activation part
     * of the Resolve phase of routing.
     * @see `ActivationStart`
     * @see `ResolveStart`
     *
     * \@publicApi
     */


    var ActivationEnd = /*#__PURE__*/function () {
      /**
       * @param {?} snapshot
       */
      function ActivationEnd(snapshot) {
        _classCallCheck(this, ActivationEnd);

        this.snapshot = snapshot;
      }
      /**
       * @return {?}
       */


      _createClass2(ActivationEnd, [{
        key: "toString",
        value: function toString() {
          /** @type {?} */
          var path = this.snapshot.routeConfig && this.snapshot.routeConfig.path || '';
          return "ActivationEnd(path: '".concat(path, "')");
        }
      }]);

      return ActivationEnd;
    }();

    if (false) {}
    /**
     * An event triggered by scrolling.
     *
     * \@publicApi
     */


    var Scroll = /*#__PURE__*/function () {
      /**
       * @param {?} routerEvent
       * @param {?} position
       * @param {?} anchor
       */
      function Scroll(routerEvent, position, anchor) {
        _classCallCheck(this, Scroll);

        this.routerEvent = routerEvent;
        this.position = position;
        this.anchor = anchor;
      }
      /**
       * @return {?}
       */


      _createClass2(Scroll, [{
        key: "toString",
        value: function toString() {
          /** @type {?} */
          var pos = this.position ? "".concat(this.position[0], ", ").concat(this.position[1]) : null;
          return "Scroll(anchor: '".concat(this.anchor, "', position: '").concat(pos, "')");
        }
      }]);

      return Scroll;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/components/empty_outlet.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * This component is used internally within the router to be a placeholder when an empty
     * router-outlet is needed. For example, with a config such as:
     *
     * `{path: 'parent', outlet: 'nav', children: [...]}`
     *
     * In order to render, there needs to be a component on this config, which will default
     * to this `EmptyOutletComponent`.
     */


    var ɵEmptyOutletComponent = function ɵEmptyOutletComponent() {
      _classCallCheck(this, ɵEmptyOutletComponent);
    };

    ɵEmptyOutletComponent.ɵfac = function ɵEmptyOutletComponent_Factory(t) {
      return new (t || ɵEmptyOutletComponent)();
    };

    ɵEmptyOutletComponent.ɵcmp = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineComponent"]({
      type: ɵEmptyOutletComponent,
      selectors: [["ng-component"]],
      decls: 1,
      vars: 0,
      template: function ɵEmptyOutletComponent_Template(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵelement"](0, "router-outlet");
        }
      },
      directives: function directives() {
        return [RouterOutlet];
      },
      encapsulation: 2
    });
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](ɵEmptyOutletComponent, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Component"],
        args: [{
          template: "<router-outlet></router-outlet>"
        }]
      }], null, null);
    })();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/shared.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * The primary routing outlet.
     *
     * \@publicApi
     * @type {?}
     */


    var PRIMARY_OUTLET = 'primary';
    /**
     * A map that provides access to the required and optional parameters
     * specific to a route.
     * The map supports retrieving a single value with `get()`
     * or multiple values with `getAll()`.
     *
     * @see [URLSearchParams](https://developer.mozilla.org/en-US/docs/Web/API/URLSearchParams)
     *
     * \@publicApi
     * @record
     */

    function ParamMap() {}

    if (false) {}

    var ParamsAsMap = /*#__PURE__*/function () {
      /**
       * @param {?} params
       */
      function ParamsAsMap(params) {
        _classCallCheck(this, ParamsAsMap);

        this.params = params || {};
      }
      /**
       * @param {?} name
       * @return {?}
       */


      _createClass2(ParamsAsMap, [{
        key: "has",
        value: function has(name) {
          return this.params.hasOwnProperty(name);
        }
        /**
         * @param {?} name
         * @return {?}
         */

      }, {
        key: "get",
        value: function get(name) {
          if (this.has(name)) {
            /** @type {?} */
            var v = this.params[name];
            return Array.isArray(v) ? v[0] : v;
          }

          return null;
        }
        /**
         * @param {?} name
         * @return {?}
         */

      }, {
        key: "getAll",
        value: function getAll(name) {
          if (this.has(name)) {
            /** @type {?} */
            var v = this.params[name];
            return Array.isArray(v) ? v : [v];
          }

          return [];
        }
        /**
         * @return {?}
         */

      }, {
        key: "keys",
        get: function get() {
          return Object.keys(this.params);
        }
      }]);

      return ParamsAsMap;
    }();

    if (false) {}
    /**
     * Converts a `Params` instance to a `ParamMap`.
     * \@publicApi
     * @param {?} params The instance to convert.
     * @return {?} The new map instance.
     *
     */


    function convertToParamMap(params) {
      return new ParamsAsMap(params);
    }
    /** @type {?} */


    var NAVIGATION_CANCELING_ERROR = 'ngNavigationCancelingError';
    /**
     * @param {?} message
     * @return {?}
     */

    function navigationCancelingError(message) {
      /** @type {?} */
      var error = Error('NavigationCancelingError: ' + message);

      /** @type {?} */
      error[NAVIGATION_CANCELING_ERROR] = true;
      return error;
    }
    /**
     * @param {?} error
     * @return {?}
     */


    function isNavigationCancelingError(error) {
      return error &&
      /** @type {?} */
      error[NAVIGATION_CANCELING_ERROR];
    } // Matches the route configuration (`route`) against the actual URL (`segments`).

    /**
     * @param {?} segments
     * @param {?} segmentGroup
     * @param {?} route
     * @return {?}
     */


    function defaultUrlMatcher(segments, segmentGroup, route) {
      /** @type {?} */
      var parts =
      /** @type {?} */
      route.path.split('/');

      if (parts.length > segments.length) {
        // The actual URL is shorter than the config, no match
        return null;
      }

      if (route.pathMatch === 'full' && (segmentGroup.hasChildren() || parts.length < segments.length)) {
        // The config is longer than the actual URL but we are looking for a full match, return null
        return null;
      }
      /** @type {?} */


      var posParams = {}; // Check each config part against the actual URL

      for (var index = 0; index < parts.length; index++) {
        /** @type {?} */
        var part = parts[index];
        /** @type {?} */

        var segment = segments[index];
        /** @type {?} */

        var isParameter = part.startsWith(':');

        if (isParameter) {
          posParams[part.substring(1)] = segment;
        } else if (part !== segment.path) {
          // The actual URL part does not match the config, no match
          return null;
        }
      }

      return {
        consumed: segments.slice(0, parts.length),
        posParams: posParams
      };
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/config.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * A configuration object that defines a single route.
     * A set of routes are collected in a `Routes` array to define a `Router` configuration.
     * The router attempts to match segments of a given URL against each route,
     * using the configuration options defined in this object.
     *
     * Supports static, parameterized, redirect, and wildcard routes, as well as
     * custom route data and resolve methods.
     *
     * For detailed usage information, see the [Routing Guide](guide/router).
     *
     * \@usageNotes
     *
     * ### Simple Configuration
     *
     * The following route specifies that when navigating to, for example,
     * `/team/11/user/bob`, the router creates the 'Team' component
     * with the 'User' child component in it.
     *
     * ```
     * [{
     *   path: 'team/:id',
     *  component: Team,
     *   children: [{
     *     path: 'user/:name',
     *     component: User
     *   }]
     * }]
     * ```
     *
     * ### Multiple Outlets
     *
     * The following route creates sibling components with multiple outlets.
     * When navigating to `/team/11(aux:chat/jim)`, the router creates the 'Team' component next to
     * the 'Chat' component. The 'Chat' component is placed into the 'aux' outlet.
     *
     * ```
     * [{
     *   path: 'team/:id',
     *   component: Team
     * }, {
     *   path: 'chat/:user',
     *   component: Chat
     *   outlet: 'aux'
     * }]
     * ```
     *
     * ### Wild Cards
     *
     * The following route uses wild-card notation to specify a component
     * that is always instantiated regardless of where you navigate to.
     *
     * ```
     * [{
     *   path: '**',
     *   component: WildcardComponent
     * }]
     * ```
     *
     * ### Redirects
     *
     * The following route uses the `redirectTo` property to ignore a segment of
     * a given URL when looking for a child path.
     *
     * When navigating to '/team/11/legacy/user/jim', the router changes the URL segment
     * '/team/11/legacy/user/jim' to '/team/11/user/jim', and then instantiates
     * the Team component with the User child component in it.
     *
     * ```
     * [{
     *   path: 'team/:id',
     *   component: Team,
     *   children: [{
     *     path: 'legacy/user/:name',
     *     redirectTo: 'user/:name'
     *   }, {
     *     path: 'user/:name',
     *     component: User
     *   }]
     * }]
     * ```
     *
     * The redirect path can be relative, as shown in this example, or absolute.
     * If we change the `redirectTo` value in the example to the absolute URL segment '/user/:name',
     * the result URL is also absolute, '/user/jim'.
     * ### Empty Path
     *
     * Empty-path route configurations can be used to instantiate components that do not 'consume'
     * any URL segments.
     *
     * In the following configuration, when navigating to
     * `/team/11`, the router instantiates the 'AllUsers' component.
     *
     * ```
     * [{
     *   path: 'team/:id',
     *   component: Team,
     *   children: [{
     *     path: '',
     *     component: AllUsers
     *   }, {
     *     path: 'user/:name',
     *     component: User
     *   }]
     * }]
     * ```
     *
     * Empty-path routes can have children. In the following example, when navigating
     * to `/team/11/user/jim`, the router instantiates the wrapper component with
     * the user component in it.
     *
     * Note that an empty path route inherits its parent's parameters and data.
     *
     * ```
     * [{
     *   path: 'team/:id',
     *   component: Team,
     *   children: [{
     *     path: '',
     *     component: WrapperCmp,
     *     children: [{
     *       path: 'user/:name',
     *       component: User
     *     }]
     *   }]
     * }]
     * ```
     *
     * ### Matching Strategy
     *
     * The default path-match strategy is 'prefix', which means that the router
     * checks URL elements from the left to see if the URL matches a specified path.
     * For example, '/team/11/user' matches 'team/:id'.
     *
     * ```
     * [{
     *   path: '',
     *   pathMatch: 'prefix', //default
     *   redirectTo: 'main'
     * }, {
     *   path: 'main',
     *   component: Main
     * }]
     * ```
     *
     * You can specify the path-match strategy 'full' to make sure that the path
     * covers the whole unconsumed URL. It is important to do this when redirecting
     * empty-path routes. Otherwise, because an empty path is a prefix of any URL,
     * the router would apply the redirect even when navigating to the redirect destination,
     * creating an endless loop.
     *
     * In the following example, supplying the 'full' `pathMatch` strategy ensures
     * that the router applies the redirect if and only if navigating to '/'.
     *
     * ```
     * [{
     *   path: '',
     *   pathMatch: 'full',
     *   redirectTo: 'main'
     * }, {
     *   path: 'main',
     *   component: Main
     * }]
     * ```
     *
     * ### Componentless Routes
     *
     * You can share parameters between sibling components.
     * For example, suppose that two sibling components should go next to each other,
     * and both of them require an ID parameter. You can accomplish this using a route
     * that does not specify a component at the top level.
     *
     * In the following example, 'MainChild' and 'AuxChild' are siblings.
     * When navigating to 'parent/10/(a//aux:b)', the route instantiates
     * the main child and aux child components next to each other.
     * For this to work, the application component must have the primary and aux outlets defined.
     *
     * ```
     * [{
     *    path: 'parent/:id',
     *    children: [
     *      { path: 'a', component: MainChild },
     *      { path: 'b', component: AuxChild, outlet: 'aux' }
     *    ]
     * }]
     * ```
     *
     * The router merges the parameters, data, and resolve of the componentless
     * parent into the parameters, data, and resolve of the children.
     *
     * This is especially useful when child components are defined
     * with an empty path string, as in the following example.
     * With this configuration, navigating to '/parent/10' creates
     * the main child and aux components.
     *
     * ```
     * [{
     *    path: 'parent/:id',
     *    children: [
     *      { path: '', component: MainChild },
     *      { path: '', component: AuxChild, outlet: 'aux' }
     *    ]
     * }]
     * ```
     *
     * ### Lazy Loading
     *
     * Lazy loading speeds up application load time by splitting the application
     * into multiple bundles and loading them on demand.
     * To use lazy loading, provide the `loadChildren` property  instead of the `children` property.
     *
     * Given the following example route, the router will lazy load
     * the associated module on demand using the browser native import system.
     *
     * ```
     * [{
     *   path: 'lazy',
     *   loadChildren: () => import('./lazy-route/lazy.module').then(mod => mod.LazyModule),
     * }];
     * ```
     *
     * \@publicApi
     * @record
     */


    function Route() {}

    if (false) {}

    var LoadedRouterConfig =
    /**
     * @param {?} routes
     * @param {?} module
     */
    function LoadedRouterConfig(routes, module) {
      _classCallCheck(this, LoadedRouterConfig);

      this.routes = routes;
      this.module = module;
    };

    if (false) {}
    /**
     * @param {?} config
     * @param {?=} parentPath
     * @return {?}
     */


    function validateConfig(config) {
      var parentPath = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';

      // forEach doesn't iterate undefined values
      for (var i = 0; i < config.length; i++) {
        /** @type {?} */
        var route = config[i];
        /** @type {?} */

        var fullPath = getFullPath(parentPath, route);
        validateNode(route, fullPath);
      }
    }
    /**
     * @param {?} route
     * @param {?} fullPath
     * @return {?}
     */


    function validateNode(route, fullPath) {
      if (!route) {
        throw new Error("\n      Invalid configuration of route '".concat(fullPath, "': Encountered undefined route.\n      The reason might be an extra comma.\n\n      Example:\n      const routes: Routes = [\n        { path: '', redirectTo: '/dashboard', pathMatch: 'full' },\n        { path: 'dashboard',  component: DashboardComponent },, << two commas\n        { path: 'detail/:id', component: HeroDetailComponent }\n      ];\n    "));
      }

      if (Array.isArray(route)) {
        throw new Error("Invalid configuration of route '".concat(fullPath, "': Array cannot be specified"));
      }

      if (!route.component && !route.children && !route.loadChildren && route.outlet && route.outlet !== PRIMARY_OUTLET) {
        throw new Error("Invalid configuration of route '".concat(fullPath, "': a componentless route without children or loadChildren cannot have a named outlet set"));
      }

      if (route.redirectTo && route.children) {
        throw new Error("Invalid configuration of route '".concat(fullPath, "': redirectTo and children cannot be used together"));
      }

      if (route.redirectTo && route.loadChildren) {
        throw new Error("Invalid configuration of route '".concat(fullPath, "': redirectTo and loadChildren cannot be used together"));
      }

      if (route.children && route.loadChildren) {
        throw new Error("Invalid configuration of route '".concat(fullPath, "': children and loadChildren cannot be used together"));
      }

      if (route.redirectTo && route.component) {
        throw new Error("Invalid configuration of route '".concat(fullPath, "': redirectTo and component cannot be used together"));
      }

      if (route.path && route.matcher) {
        throw new Error("Invalid configuration of route '".concat(fullPath, "': path and matcher cannot be used together"));
      }

      if (route.redirectTo === void 0 && !route.component && !route.children && !route.loadChildren) {
        throw new Error("Invalid configuration of route '".concat(fullPath, "'. One of the following must be provided: component, redirectTo, children or loadChildren"));
      }

      if (route.path === void 0 && route.matcher === void 0) {
        throw new Error("Invalid configuration of route '".concat(fullPath, "': routes must have either a path or a matcher specified"));
      }

      if (typeof route.path === 'string' && route.path.charAt(0) === '/') {
        throw new Error("Invalid configuration of route '".concat(fullPath, "': path cannot start with a slash"));
      }

      if (route.path === '' && route.redirectTo !== void 0 && route.pathMatch === void 0) {
        /** @type {?} */
        var exp = "The default value of 'pathMatch' is 'prefix', but often the intent is to use 'full'.";
        throw new Error("Invalid configuration of route '{path: \"".concat(fullPath, "\", redirectTo: \"").concat(route.redirectTo, "\"}': please provide 'pathMatch'. ").concat(exp));
      }

      if (route.pathMatch !== void 0 && route.pathMatch !== 'full' && route.pathMatch !== 'prefix') {
        throw new Error("Invalid configuration of route '".concat(fullPath, "': pathMatch can only be set to 'prefix' or 'full'"));
      }

      if (route.children) {
        validateConfig(route.children, fullPath);
      }
    }
    /**
     * @param {?} parentPath
     * @param {?} currentRoute
     * @return {?}
     */


    function getFullPath(parentPath, currentRoute) {
      if (!currentRoute) {
        return parentPath;
      }

      if (!parentPath && !currentRoute.path) {
        return '';
      } else if (parentPath && !currentRoute.path) {
        return "".concat(parentPath, "/");
      } else if (!parentPath && currentRoute.path) {
        return currentRoute.path;
      } else {
        return "".concat(parentPath, "/").concat(currentRoute.path);
      }
    }
    /**
     * Makes a copy of the config and adds any default required properties.
     * @param {?} r
     * @return {?}
     */


    function standardizeConfig(r) {
      /** @type {?} */
      var children = r.children && r.children.map(standardizeConfig);
      /** @type {?} */

      var c = children ? Object.assign(Object.assign({}, r), {
        children: children
      }) : Object.assign({}, r);

      if (!c.component && (children || c.loadChildren) && c.outlet && c.outlet !== PRIMARY_OUTLET) {
        c.component = ɵEmptyOutletComponent;
      }

      return c;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/utils/collection.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} a
     * @param {?} b
     * @return {?}
     */


    function shallowEqualArrays(a, b) {
      if (a.length !== b.length) return false;

      for (var i = 0; i < a.length; ++i) {
        if (!shallowEqual(a[i], b[i])) return false;
      }

      return true;
    }
    /**
     * @param {?} a
     * @param {?} b
     * @return {?}
     */


    function shallowEqual(a, b) {
      // Casting Object.keys return values to include `undefined` as there are some cases
      // in IE 11 where this can happen. Cannot provide a test because the behavior only
      // exists in certain circumstances in IE 11, therefore doing this cast ensures the
      // logic is correct for when this edge case is hit.

      /** @type {?} */
      var k1 =
      /** @type {?} */
      Object.keys(a);
      /** @type {?} */

      var k2 =
      /** @type {?} */
      Object.keys(b);

      if (!k1 || !k2 || k1.length != k2.length) {
        return false;
      }
      /** @type {?} */


      var key;

      for (var i = 0; i < k1.length; i++) {
        key = k1[i];

        if (!equalArraysOrString(a[key], b[key])) {
          return false;
        }
      }

      return true;
    }
    /**
     * Test equality for arrays of strings or a string.
     * @param {?} a
     * @param {?} b
     * @return {?}
     */


    function equalArraysOrString(a, b) {
      if (Array.isArray(a) && Array.isArray(b)) {
        if (a.length != b.length) return false;
        return a.every(
        /**
        * @param {?} aItem
        * @return {?}
        */
        function (aItem) {
          return b.indexOf(aItem) > -1;
        });
      } else {
        return a === b;
      }
    }
    /**
     * Flattens single-level nested arrays.
     * @template T
     * @param {?} arr
     * @return {?}
     */


    function flatten(arr) {
      return Array.prototype.concat.apply([], arr);
    }
    /**
     * Return the last element of an array.
     * @template T
     * @param {?} a
     * @return {?}
     */


    function last(a) {
      return a.length > 0 ? a[a.length - 1] : null;
    }
    /**
     * Verifys all booleans in an array are `true`.
     * @param {?} bools
     * @return {?}
     */


    function and(bools) {
      return !bools.some(
      /**
      * @param {?} v
      * @return {?}
      */
      function (v) {
        return !v;
      });
    }
    /**
     * @template K, V
     * @param {?} map
     * @param {?} callback
     * @return {?}
     */


    function forEach(map, callback) {
      for (var prop in map) {
        if (map.hasOwnProperty(prop)) {
          callback(map[prop], prop);
        }
      }
    }
    /**
     * @template A, B
     * @param {?} obj
     * @param {?} fn
     * @return {?}
     */


    function waitForMap(obj, fn) {
      if (Object.keys(obj).length === 0) {
        return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])({});
      }
      /** @type {?} */


      var waitHead = [];
      /** @type {?} */

      var waitTail = [];
      /** @type {?} */

      var res = {};
      forEach(obj,
      /**
      * @param {?} a
      * @param {?} k
      * @return {?}
      */
      function (a, k) {
        /** @type {?} */
        var mapped = fn(k, a).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
        /**
        * @param {?} r
        * @return {?}
        */
        function (r) {
          return res[k] = r;
        }));

        if (k === PRIMARY_OUTLET) {
          waitHead.push(mapped);
        } else {
          waitTail.push(mapped);
        }
      }); // Closure compiler has problem with using spread operator here. So we use "Array.concat".
      // Note that we also need to cast the new promise because TypeScript cannot infer the type
      // when calling the "of" function through "Function.apply"

      return (
        /** @type {?} */
        rxjs__WEBPACK_IMPORTED_MODULE_2__["of"].apply(null, waitHead.concat(waitTail)).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["concatAll"])(), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["last"])(), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
        /**
        * @return {?}
        */
        function () {
          return res;
        }))
      );
    }
    /**
     * @template T
     * @param {?} value
     * @return {?}
     */


    function wrapIntoObservable(value) {
      if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵisObservable"])(value)) {
        return value;
      }

      if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵisPromise"])(value)) {
        // Use `Promise.resolve()` to wrap promise-like instances.
        // Required ie when a Resolver returns a AngularJS `$q` promise to correctly trigger the
        // change detection.
        return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["from"])(Promise.resolve(value));
      }

      return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(value);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/url_tree.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @return {?}
     */


    function createEmptyUrlTree() {
      return new UrlTree(new UrlSegmentGroup([], {}), {}, null);
    }
    /**
     * @param {?} container
     * @param {?} containee
     * @param {?} exact
     * @return {?}
     */


    function containsTree(container, containee, exact) {
      if (exact) {
        return equalQueryParams(container.queryParams, containee.queryParams) && equalSegmentGroups(container.root, containee.root);
      }

      return containsQueryParams(container.queryParams, containee.queryParams) && containsSegmentGroup(container.root, containee.root);
    }
    /**
     * @param {?} container
     * @param {?} containee
     * @return {?}
     */


    function equalQueryParams(container, containee) {
      // TODO: This does not handle array params correctly.
      return shallowEqual(container, containee);
    }
    /**
     * @param {?} container
     * @param {?} containee
     * @return {?}
     */


    function equalSegmentGroups(container, containee) {
      if (!equalPath(container.segments, containee.segments)) return false;
      if (container.numberOfChildren !== containee.numberOfChildren) return false;

      for (var c in containee.children) {
        if (!container.children[c]) return false;
        if (!equalSegmentGroups(container.children[c], containee.children[c])) return false;
      }

      return true;
    }
    /**
     * @param {?} container
     * @param {?} containee
     * @return {?}
     */


    function containsQueryParams(container, containee) {
      // TODO: This does not handle array params correctly.
      return Object.keys(containee).length <= Object.keys(container).length && Object.keys(containee).every(
      /**
      * @param {?} key
      * @return {?}
      */
      function (key) {
        return equalArraysOrString(container[key], containee[key]);
      });
    }
    /**
     * @param {?} container
     * @param {?} containee
     * @return {?}
     */


    function containsSegmentGroup(container, containee) {
      return containsSegmentGroupHelper(container, containee, containee.segments);
    }
    /**
     * @param {?} container
     * @param {?} containee
     * @param {?} containeePaths
     * @return {?}
     */


    function containsSegmentGroupHelper(container, containee, containeePaths) {
      if (container.segments.length > containeePaths.length) {
        /** @type {?} */
        var current = container.segments.slice(0, containeePaths.length);
        if (!equalPath(current, containeePaths)) return false;
        if (containee.hasChildren()) return false;
        return true;
      } else if (container.segments.length === containeePaths.length) {
        if (!equalPath(container.segments, containeePaths)) return false;

        for (var c in containee.children) {
          if (!container.children[c]) return false;
          if (!containsSegmentGroup(container.children[c], containee.children[c])) return false;
        }

        return true;
      } else {
        /** @type {?} */
        var _current = containeePaths.slice(0, container.segments.length);
        /** @type {?} */


        var next = containeePaths.slice(container.segments.length);
        if (!equalPath(container.segments, _current)) return false;
        if (!container.children[PRIMARY_OUTLET]) return false;
        return containsSegmentGroupHelper(container.children[PRIMARY_OUTLET], containee, next);
      }
    }
    /**
     * \@description
     *
     * Represents the parsed URL.
     *
     * Since a router state is a tree, and the URL is nothing but a serialized state, the URL is a
     * serialized tree.
     * UrlTree is a data structure that provides a lot of affordances in dealing with URLs
     *
     * \@usageNotes
     * ### Example
     *
     * ```
     * \@Component({templateUrl:'template.html'})
     * class MyComponent {
     *   constructor(router: Router) {
     *     const tree: UrlTree =
     *       router.parseUrl('/team/33/(user/victor//support:help)?debug=true#fragment');
     *     const f = tree.fragment; // return 'fragment'
     *     const q = tree.queryParams; // returns {debug: 'true'}
     *     const g: UrlSegmentGroup = tree.root.children[PRIMARY_OUTLET];
     *     const s: UrlSegment[] = g.segments; // returns 2 segments 'team' and '33'
     *     g.children[PRIMARY_OUTLET].segments; // returns 2 segments 'user' and 'victor'
     *     g.children['support'].segments; // return 1 segment 'help'
     *   }
     * }
     * ```
     *
     * \@publicApi
     */


    var UrlTree = /*#__PURE__*/function () {
      /**
       * \@internal
       * @param {?} root
       * @param {?} queryParams
       * @param {?} fragment
       */
      function UrlTree(root, queryParams, fragment) {
        _classCallCheck(this, UrlTree);

        this.root = root;
        this.queryParams = queryParams;
        this.fragment = fragment;
      }
      /**
       * @return {?}
       */


      _createClass2(UrlTree, [{
        key: "toString",

        /**
         * \@docsNotRequired
         * @return {?}
         */
        value: function toString() {
          return DEFAULT_SERIALIZER.serialize(this);
        }
      }, {
        key: "queryParamMap",
        get: function get() {
          if (!this._queryParamMap) {
            this._queryParamMap = convertToParamMap(this.queryParams);
          }

          return this._queryParamMap;
        }
      }]);

      return UrlTree;
    }();

    if (false) {}
    /**
     * \@description
     *
     * Represents the parsed URL segment group.
     *
     * See `UrlTree` for more information.
     *
     * \@publicApi
     */


    var UrlSegmentGroup = /*#__PURE__*/function () {
      /**
       * @param {?} segments
       * @param {?} children
       */
      function UrlSegmentGroup(segments, children) {
        var _this281 = this;

        _classCallCheck(this, UrlSegmentGroup);

        this.segments = segments;
        this.children = children;
        /**
         * The parent node in the url tree
         */

        this.parent = null;
        forEach(children,
        /**
        * @template THIS
        * @this {THIS}
        * @param {?} v
        * @param {?} k
        * @return {THIS}
        */
        function (v, k) {
          return v.parent = _this281;
        });
      }
      /**
       * Whether the segment has child segments
       * @return {?}
       */


      _createClass2(UrlSegmentGroup, [{
        key: "hasChildren",
        value: function hasChildren() {
          return this.numberOfChildren > 0;
        }
        /**
         * Number of child segments
         * @return {?}
         */

      }, {
        key: "toString",

        /**
         * \@docsNotRequired
         * @return {?}
         */
        value: function toString() {
          return serializePaths(this);
        }
      }, {
        key: "numberOfChildren",
        get: function get() {
          return Object.keys(this.children).length;
        }
      }]);

      return UrlSegmentGroup;
    }();

    if (false) {}
    /**
     * \@description
     *
     * Represents a single URL segment.
     *
     * A UrlSegment is a part of a URL between the two slashes. It contains a path and the matrix
     * parameters associated with the segment.
     *
     * \@usageNotes
     *  ### Example
     *
     * ```
     * \@Component({templateUrl:'template.html'})
     * class MyComponent {
     *   constructor(router: Router) {
     *     const tree: UrlTree = router.parseUrl('/team;id=33');
     *     const g: UrlSegmentGroup = tree.root.children[PRIMARY_OUTLET];
     *     const s: UrlSegment[] = g.segments;
     *     s[0].path; // returns 'team'
     *     s[0].parameters; // returns {id: 33}
     *   }
     * }
     * ```
     *
     * \@publicApi
     */


    var UrlSegment = /*#__PURE__*/function () {
      /**
       * @param {?} path
       * @param {?} parameters
       */
      function UrlSegment(path, parameters) {
        _classCallCheck(this, UrlSegment);

        this.path = path;
        this.parameters = parameters;
      }
      /**
       * @return {?}
       */


      _createClass2(UrlSegment, [{
        key: "toString",

        /**
         * \@docsNotRequired
         * @return {?}
         */
        value: function toString() {
          return serializePath(this);
        }
      }, {
        key: "parameterMap",
        get: function get() {
          if (!this._parameterMap) {
            this._parameterMap = convertToParamMap(this.parameters);
          }

          return this._parameterMap;
        }
      }]);

      return UrlSegment;
    }();

    if (false) {}
    /**
     * @param {?} as
     * @param {?} bs
     * @return {?}
     */


    function equalSegments(as, bs) {
      return equalPath(as, bs) && as.every(
      /**
      * @param {?} a
      * @param {?} i
      * @return {?}
      */
      function (a, i) {
        return shallowEqual(a.parameters, bs[i].parameters);
      });
    }
    /**
     * @param {?} as
     * @param {?} bs
     * @return {?}
     */


    function equalPath(as, bs) {
      if (as.length !== bs.length) return false;
      return as.every(
      /**
      * @param {?} a
      * @param {?} i
      * @return {?}
      */
      function (a, i) {
        return a.path === bs[i].path;
      });
    }
    /**
     * @template T
     * @param {?} segment
     * @param {?} fn
     * @return {?}
     */


    function mapChildrenIntoArray(segment, fn) {
      /** @type {?} */
      var res = [];
      forEach(segment.children,
      /**
      * @param {?} child
      * @param {?} childOutlet
      * @return {?}
      */
      function (child, childOutlet) {
        if (childOutlet === PRIMARY_OUTLET) {
          res = res.concat(fn(child, childOutlet));
        }
      });
      forEach(segment.children,
      /**
      * @param {?} child
      * @param {?} childOutlet
      * @return {?}
      */
      function (child, childOutlet) {
        if (childOutlet !== PRIMARY_OUTLET) {
          res = res.concat(fn(child, childOutlet));
        }
      });
      return res;
    }
    /**
     * \@description
     *
     * Serializes and deserializes a URL string into a URL tree.
     *
     * The url serialization strategy is customizable. You can
     * make all URLs case insensitive by providing a custom UrlSerializer.
     *
     * See `DefaultUrlSerializer` for an example of a URL serializer.
     *
     * \@publicApi
     * @abstract
     */


    var UrlSerializer = function UrlSerializer() {
      _classCallCheck(this, UrlSerializer);
    };

    if (false) {}
    /**
     * \@description
     *
     * A default implementation of the `UrlSerializer`.
     *
     * Example URLs:
     *
     * ```
     * /inbox/33(popup:compose)
     * /inbox/33;open=true/messages/44
     * ```
     *
     * DefaultUrlSerializer uses parentheses to serialize secondary segments (e.g., popup:compose), the
     * colon syntax to specify the outlet, and the ';parameter=value' syntax (e.g., open=true) to
     * specify route specific parameters.
     *
     * \@publicApi
     */


    var DefaultUrlSerializer = /*#__PURE__*/function () {
      function DefaultUrlSerializer() {
        _classCallCheck(this, DefaultUrlSerializer);
      }

      _createClass2(DefaultUrlSerializer, [{
        key: "parse",

        /**
         * Parses a url into a `UrlTree`
         * @param {?} url
         * @return {?}
         */
        value: function parse(url) {
          /** @type {?} */
          var p = new UrlParser(url);
          return new UrlTree(p.parseRootSegment(), p.parseQueryParams(), p.parseFragment());
        }
        /**
         * Converts a `UrlTree` into a url
         * @param {?} tree
         * @return {?}
         */

      }, {
        key: "serialize",
        value: function serialize(tree) {
          /** @type {?} */
          var segment = "/".concat(serializeSegment(tree.root, true));
          /** @type {?} */

          var query = serializeQueryParams(tree.queryParams);
          /** @type {?} */

          var fragment = typeof tree.fragment === "string" ? "#".concat(encodeUriFragment(
          /** @type {?} */
          tree.fragment)) : '';
          return "".concat(segment).concat(query).concat(fragment);
        }
      }]);

      return DefaultUrlSerializer;
    }();
    /** @type {?} */


    var DEFAULT_SERIALIZER = new DefaultUrlSerializer();
    /**
     * @param {?} segment
     * @return {?}
     */

    function serializePaths(segment) {
      return segment.segments.map(
      /**
      * @param {?} p
      * @return {?}
      */
      function (p) {
        return serializePath(p);
      }).join('/');
    }
    /**
     * @param {?} segment
     * @param {?} root
     * @return {?}
     */


    function serializeSegment(segment, root) {
      if (!segment.hasChildren()) {
        return serializePaths(segment);
      }

      if (root) {
        /** @type {?} */
        var primary = segment.children[PRIMARY_OUTLET] ? serializeSegment(segment.children[PRIMARY_OUTLET], false) : '';
        /** @type {?} */

        var children = [];
        forEach(segment.children,
        /**
        * @param {?} v
        * @param {?} k
        * @return {?}
        */
        function (v, k) {
          if (k !== PRIMARY_OUTLET) {
            children.push("".concat(k, ":").concat(serializeSegment(v, false)));
          }
        });
        return children.length > 0 ? "".concat(primary, "(").concat(children.join('//'), ")") : primary;
      } else {
        /** @type {?} */
        var _children = mapChildrenIntoArray(segment,
        /**
        * @param {?} v
        * @param {?} k
        * @return {?}
        */
        function (v, k) {
          if (k === PRIMARY_OUTLET) {
            return [serializeSegment(segment.children[PRIMARY_OUTLET], false)];
          }

          return ["".concat(k, ":").concat(serializeSegment(v, false))];
        });

        return "".concat(serializePaths(segment), "/(").concat(_children.join('//'), ")");
      }
    }
    /**
     * Encodes a URI string with the default encoding. This function will only ever be called from
     * `encodeUriQuery` or `encodeUriSegment` as it's the base set of encodings to be used. We need
     * a custom encoding because encodeURIComponent is too aggressive and encodes stuff that doesn't
     * have to be encoded per https://url.spec.whatwg.org.
     * @param {?} s
     * @return {?}
     */


    function encodeUriString(s) {
      return encodeURIComponent(s).replace(/%40/g, '@').replace(/%3A/gi, ':').replace(/%24/g, '$').replace(/%2C/gi, ',');
    }
    /**
     * This function should be used to encode both keys and values in a query string key/value. In
     * the following URL, you need to call encodeUriQuery on "k" and "v":
     *
     * http://www.site.org/html;mk=mv?k=v#f
     * @param {?} s
     * @return {?}
     */


    function encodeUriQuery(s) {
      return encodeUriString(s).replace(/%3B/gi, ';');
    }
    /**
     * This function should be used to encode a URL fragment. In the following URL, you need to call
     * encodeUriFragment on "f":
     *
     * http://www.site.org/html;mk=mv?k=v#f
     * @param {?} s
     * @return {?}
     */


    function encodeUriFragment(s) {
      return encodeURI(s);
    }
    /**
     * This function should be run on any URI segment as well as the key and value in a key/value
     * pair for matrix params. In the following URL, you need to call encodeUriSegment on "html",
     * "mk", and "mv":
     *
     * http://www.site.org/html;mk=mv?k=v#f
     * @param {?} s
     * @return {?}
     */


    function encodeUriSegment(s) {
      return encodeUriString(s).replace(/\(/g, '%28').replace(/\)/g, '%29').replace(/%26/gi, '&');
    }
    /**
     * @param {?} s
     * @return {?}
     */


    function decode(s) {
      return decodeURIComponent(s);
    } // Query keys/values should have the "+" replaced first, as "+" in a query string is " ".
    // decodeURIComponent function will not decode "+" as a space.

    /**
     * @param {?} s
     * @return {?}
     */


    function decodeQuery(s) {
      return decode(s.replace(/\+/g, '%20'));
    }
    /**
     * @param {?} path
     * @return {?}
     */


    function serializePath(path) {
      return "".concat(encodeUriSegment(path.path)).concat(serializeMatrixParams(path.parameters));
    }
    /**
     * @param {?} params
     * @return {?}
     */


    function serializeMatrixParams(params) {
      return Object.keys(params).map(
      /**
      * @param {?} key
      * @return {?}
      */
      function (key) {
        return ";".concat(encodeUriSegment(key), "=").concat(encodeUriSegment(params[key]));
      }).join('');
    }
    /**
     * @param {?} params
     * @return {?}
     */


    function serializeQueryParams(params) {
      /** @type {?} */
      var strParams = Object.keys(params).map(
      /**
      * @param {?} name
      * @return {?}
      */
      function (name) {
        /** @type {?} */
        var value = params[name];
        return Array.isArray(value) ? value.map(
        /**
        * @param {?} v
        * @return {?}
        */
        function (v) {
          return "".concat(encodeUriQuery(name), "=").concat(encodeUriQuery(v));
        }).join('&') : "".concat(encodeUriQuery(name), "=").concat(encodeUriQuery(value));
      });
      return strParams.length ? "?".concat(strParams.join('&')) : '';
    }
    /** @type {?} */


    var SEGMENT_RE = /^[^\/()?;=#]+/;
    /**
     * @param {?} str
     * @return {?}
     */

    function matchSegments(str) {
      /** @type {?} */
      var match = str.match(SEGMENT_RE);
      return match ? match[0] : '';
    }
    /** @type {?} */


    var QUERY_PARAM_RE = /^[^=?&#]+/; // Return the name of the query param at the start of the string or an empty string

    /**
     * @param {?} str
     * @return {?}
     */

    function matchQueryParams(str) {
      /** @type {?} */
      var match = str.match(QUERY_PARAM_RE);
      return match ? match[0] : '';
    }
    /** @type {?} */


    var QUERY_PARAM_VALUE_RE = /^[^?&#]+/; // Return the value of the query param at the start of the string or an empty string

    /**
     * @param {?} str
     * @return {?}
     */

    function matchUrlQueryParamValue(str) {
      /** @type {?} */
      var match = str.match(QUERY_PARAM_VALUE_RE);
      return match ? match[0] : '';
    }

    var UrlParser = /*#__PURE__*/function () {
      /**
       * @param {?} url
       */
      function UrlParser(url) {
        _classCallCheck(this, UrlParser);

        this.url = url;
        this.remaining = url;
      }
      /**
       * @return {?}
       */


      _createClass2(UrlParser, [{
        key: "parseRootSegment",
        value: function parseRootSegment() {
          this.consumeOptional('/');

          if (this.remaining === '' || this.peekStartsWith('?') || this.peekStartsWith('#')) {
            return new UrlSegmentGroup([], {});
          } // The root segment group never has segments


          return new UrlSegmentGroup([], this.parseChildren());
        }
        /**
         * @return {?}
         */

      }, {
        key: "parseQueryParams",
        value: function parseQueryParams() {
          /** @type {?} */
          var params = {};

          if (this.consumeOptional('?')) {
            do {
              this.parseQueryParam(params);
            } while (this.consumeOptional('&'));
          }

          return params;
        }
        /**
         * @return {?}
         */

      }, {
        key: "parseFragment",
        value: function parseFragment() {
          return this.consumeOptional('#') ? decodeURIComponent(this.remaining) : null;
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "parseChildren",
        value: function parseChildren() {
          if (this.remaining === '') {
            return {};
          }

          this.consumeOptional('/');
          /** @type {?} */

          var segments = [];

          if (!this.peekStartsWith('(')) {
            segments.push(this.parseSegment());
          }

          while (this.peekStartsWith('/') && !this.peekStartsWith('//') && !this.peekStartsWith('/(')) {
            this.capture('/');
            segments.push(this.parseSegment());
          }
          /** @type {?} */


          var children = {};

          if (this.peekStartsWith('/(')) {
            this.capture('/');
            children = this.parseParens(true);
          }
          /** @type {?} */


          var res = {};

          if (this.peekStartsWith('(')) {
            res = this.parseParens(false);
          }

          if (segments.length > 0 || Object.keys(children).length > 0) {
            res[PRIMARY_OUTLET] = new UrlSegmentGroup(segments, children);
          }

          return res;
        } // parse a segment with its matrix parameters
        // ie `name;k1=v1;k2`

        /**
         * @private
         * @return {?}
         */

      }, {
        key: "parseSegment",
        value: function parseSegment() {
          /** @type {?} */
          var path = matchSegments(this.remaining);

          if (path === '' && this.peekStartsWith(';')) {
            throw new Error("Empty path url segment cannot have parameters: '".concat(this.remaining, "'."));
          }

          this.capture(path);
          return new UrlSegment(decode(path), this.parseMatrixParams());
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "parseMatrixParams",
        value: function parseMatrixParams() {
          /** @type {?} */
          var params = {};

          while (this.consumeOptional(';')) {
            this.parseParam(params);
          }

          return params;
        }
        /**
         * @private
         * @param {?} params
         * @return {?}
         */

      }, {
        key: "parseParam",
        value: function parseParam(params) {
          /** @type {?} */
          var key = matchSegments(this.remaining);

          if (!key) {
            return;
          }

          this.capture(key);
          /** @type {?} */

          var value = '';

          if (this.consumeOptional('=')) {
            /** @type {?} */
            var valueMatch = matchSegments(this.remaining);

            if (valueMatch) {
              value = valueMatch;
              this.capture(value);
            }
          }

          params[decode(key)] = decode(value);
        } // Parse a single query parameter `name[=value]`

        /**
         * @private
         * @param {?} params
         * @return {?}
         */

      }, {
        key: "parseQueryParam",
        value: function parseQueryParam(params) {
          /** @type {?} */
          var key = matchQueryParams(this.remaining);

          if (!key) {
            return;
          }

          this.capture(key);
          /** @type {?} */

          var value = '';

          if (this.consumeOptional('=')) {
            /** @type {?} */
            var valueMatch = matchUrlQueryParamValue(this.remaining);

            if (valueMatch) {
              value = valueMatch;
              this.capture(value);
            }
          }
          /** @type {?} */


          var decodedKey = decodeQuery(key);
          /** @type {?} */

          var decodedVal = decodeQuery(value);

          if (params.hasOwnProperty(decodedKey)) {
            // Append to existing values

            /** @type {?} */
            var currentVal = params[decodedKey];

            if (!Array.isArray(currentVal)) {
              currentVal = [currentVal];
              params[decodedKey] = currentVal;
            }

            currentVal.push(decodedVal);
          } else {
            // Create a new value
            params[decodedKey] = decodedVal;
          }
        } // parse `(a/b//outlet_name:c/d)`

        /**
         * @private
         * @param {?} allowPrimary
         * @return {?}
         */

      }, {
        key: "parseParens",
        value: function parseParens(allowPrimary) {
          /** @type {?} */
          var segments = {};
          this.capture('(');

          while (!this.consumeOptional(')') && this.remaining.length > 0) {
            /** @type {?} */
            var path = matchSegments(this.remaining);
            /** @type {?} */

            var next = this.remaining[path.length]; // if is is not one of these characters, then the segment was unescaped
            // or the group was not closed

            if (next !== '/' && next !== ')' && next !== ';') {
              throw new Error("Cannot parse url '".concat(this.url, "'"));
            }
            /** @type {?} */


            var outletName =
            /** @type {?} */
            undefined;

            if (path.indexOf(':') > -1) {
              outletName = path.substr(0, path.indexOf(':'));
              this.capture(outletName);
              this.capture(':');
            } else if (allowPrimary) {
              outletName = PRIMARY_OUTLET;
            }
            /** @type {?} */


            var children = this.parseChildren();
            segments[outletName] = Object.keys(children).length === 1 ? children[PRIMARY_OUTLET] : new UrlSegmentGroup([], children);
            this.consumeOptional('//');
          }

          return segments;
        }
        /**
         * @private
         * @param {?} str
         * @return {?}
         */

      }, {
        key: "peekStartsWith",
        value: function peekStartsWith(str) {
          return this.remaining.startsWith(str);
        } // Consumes the prefix when it is present and returns whether it has been consumed

        /**
         * @private
         * @param {?} str
         * @return {?}
         */

      }, {
        key: "consumeOptional",
        value: function consumeOptional(str) {
          if (this.peekStartsWith(str)) {
            this.remaining = this.remaining.substring(str.length);
            return true;
          }

          return false;
        }
        /**
         * @private
         * @param {?} str
         * @return {?}
         */

      }, {
        key: "capture",
        value: function capture(str) {
          if (!this.consumeOptional(str)) {
            throw new Error("Expected \"".concat(str, "\"."));
          }
        }
      }]);

      return UrlParser;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/utils/tree.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * @template T
     */


    var Tree = /*#__PURE__*/function () {
      /**
       * @param {?} root
       */
      function Tree(root) {
        _classCallCheck(this, Tree);

        this._root = root;
      }
      /**
       * @return {?}
       */


      _createClass2(Tree, [{
        key: "parent",

        /**
         * \@internal
         * @param {?} t
         * @return {?}
         */
        value: function parent(t) {
          /** @type {?} */
          var p = this.pathFromRoot(t);
          return p.length > 1 ? p[p.length - 2] : null;
        }
        /**
         * \@internal
         * @param {?} t
         * @return {?}
         */

      }, {
        key: "children",
        value: function children(t) {
          /** @type {?} */
          var n = findNode(t, this._root);
          return n ? n.children.map(
          /**
          * @param {?} t
          * @return {?}
          */
          function (t) {
            return t.value;
          }) : [];
        }
        /**
         * \@internal
         * @param {?} t
         * @return {?}
         */

      }, {
        key: "firstChild",
        value: function firstChild(t) {
          /** @type {?} */
          var n = findNode(t, this._root);
          return n && n.children.length > 0 ? n.children[0].value : null;
        }
        /**
         * \@internal
         * @param {?} t
         * @return {?}
         */

      }, {
        key: "siblings",
        value: function siblings(t) {
          /** @type {?} */
          var p = findPath(t, this._root);
          if (p.length < 2) return [];
          /** @type {?} */

          var c = p[p.length - 2].children.map(
          /**
          * @param {?} c
          * @return {?}
          */
          function (c) {
            return c.value;
          });
          return c.filter(
          /**
          * @param {?} cc
          * @return {?}
          */
          function (cc) {
            return cc !== t;
          });
        }
        /**
         * \@internal
         * @param {?} t
         * @return {?}
         */

      }, {
        key: "pathFromRoot",
        value: function pathFromRoot(t) {
          return findPath(t, this._root).map(
          /**
          * @param {?} s
          * @return {?}
          */
          function (s) {
            return s.value;
          });
        }
      }, {
        key: "root",
        get: function get() {
          return this._root.value;
        }
      }]);

      return Tree;
    }();

    if (false) {} // DFS for the node matching the value

    /**
     * @template T
     * @param {?} value
     * @param {?} node
     * @return {?}
     */


    function findNode(value, node) {
      if (value === node.value) return node;

      var _iterator17 = _createForOfIteratorHelper(node.children),
          _step17;

      try {
        for (_iterator17.s(); !(_step17 = _iterator17.n()).done;) {
          var child = _step17.value;

          /** @type {?} */
          var _node = findNode(value, child);

          if (_node) return _node;
        }
      } catch (err) {
        _iterator17.e(err);
      } finally {
        _iterator17.f();
      }

      return null;
    } // Return the path to the node with the given value using DFS

    /**
     * @template T
     * @param {?} value
     * @param {?} node
     * @return {?}
     */


    function findPath(value, node) {
      if (value === node.value) return [node];

      var _iterator18 = _createForOfIteratorHelper(node.children),
          _step18;

      try {
        for (_iterator18.s(); !(_step18 = _iterator18.n()).done;) {
          var child = _step18.value;

          /** @type {?} */
          var path = findPath(value, child);

          if (path.length) {
            path.unshift(node);
            return path;
          }
        }
      } catch (err) {
        _iterator18.e(err);
      } finally {
        _iterator18.f();
      }

      return [];
    }
    /**
     * @template T
     */


    var TreeNode = /*#__PURE__*/function () {
      /**
       * @param {?} value
       * @param {?} children
       */
      function TreeNode(value, children) {
        _classCallCheck(this, TreeNode);

        this.value = value;
        this.children = children;
      }
      /**
       * @return {?}
       */


      _createClass2(TreeNode, [{
        key: "toString",
        value: function toString() {
          return "TreeNode(".concat(this.value, ")");
        }
      }]);

      return TreeNode;
    }();

    if (false) {} // Return the list of T indexed by outlet name

    /**
     * @template T
     * @param {?} node
     * @return {?}
     */


    function nodeChildrenAsMap(node) {
      /** @type {?} */
      var map = {};

      if (node) {
        node.children.forEach(
        /**
        * @param {?} child
        * @return {?}
        */
        function (child) {
          return map[child.value.outlet] = child;
        });
      }

      return map;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/router_state.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Represents the state of the router as a tree of activated routes.
     *
     * \@usageNotes
     *
     * Every node in the route tree is an `ActivatedRoute` instance
     * that knows about the "consumed" URL segments, the extracted parameters,
     * and the resolved data.
     * Use the `ActivatedRoute` properties to traverse the tree from any node.
     *
     * ### Example
     *
     * ```
     * \@Component({templateUrl:'template.html'})
     * class MyComponent {
     *   constructor(router: Router) {
     *     const state: RouterState = router.routerState;
     *     const root: ActivatedRoute = state.root;
     *     const child = root.firstChild;
     *     const id: Observable<string> = child.params.map(p => p.id);
     *     //...
     *   }
     * }
     * ```
     *
     * @see `ActivatedRoute`
     *
     * \@publicApi
     */


    var RouterState = /*#__PURE__*/function (_Tree) {
      _inherits(RouterState, _Tree);

      var _super106 = _createSuper(RouterState);

      /**
       * \@internal
       * @param {?} root
       * @param {?} snapshot
       */
      function RouterState(root, snapshot) {
        var _this282;

        _classCallCheck(this, RouterState);

        _this282 = _super106.call(this, root);
        _this282.snapshot = snapshot;
        setRouterState(
        /** @type {?} */
        _assertThisInitialized(_this282), root);
        return _this282;
      }
      /**
       * @return {?}
       */


      _createClass2(RouterState, [{
        key: "toString",
        value: function toString() {
          return this.snapshot.toString();
        }
      }]);

      return RouterState;
    }(Tree);

    if (false) {}
    /**
     * @param {?} urlTree
     * @param {?} rootComponent
     * @return {?}
     */


    function createEmptyState(urlTree, rootComponent) {
      /** @type {?} */
      var snapshot = createEmptyStateSnapshot(urlTree, rootComponent);
      /** @type {?} */

      var emptyUrl = new rxjs__WEBPACK_IMPORTED_MODULE_2__["BehaviorSubject"]([new UrlSegment('', {})]);
      /** @type {?} */

      var emptyParams = new rxjs__WEBPACK_IMPORTED_MODULE_2__["BehaviorSubject"]({});
      /** @type {?} */

      var emptyData = new rxjs__WEBPACK_IMPORTED_MODULE_2__["BehaviorSubject"]({});
      /** @type {?} */

      var emptyQueryParams = new rxjs__WEBPACK_IMPORTED_MODULE_2__["BehaviorSubject"]({});
      /** @type {?} */

      var fragment = new rxjs__WEBPACK_IMPORTED_MODULE_2__["BehaviorSubject"]('');
      /** @type {?} */

      var activated = new ActivatedRoute(emptyUrl, emptyParams, emptyQueryParams, fragment, emptyData, PRIMARY_OUTLET, rootComponent, snapshot.root);
      activated.snapshot = snapshot.root;
      return new RouterState(new TreeNode(activated, []), snapshot);
    }
    /**
     * @param {?} urlTree
     * @param {?} rootComponent
     * @return {?}
     */


    function createEmptyStateSnapshot(urlTree, rootComponent) {
      /** @type {?} */
      var emptyParams = {};
      /** @type {?} */

      var emptyData = {};
      /** @type {?} */

      var emptyQueryParams = {};
      /** @type {?} */

      var fragment = '';
      /** @type {?} */

      var activated = new ActivatedRouteSnapshot([], emptyParams, emptyQueryParams, fragment, emptyData, PRIMARY_OUTLET, rootComponent, null, urlTree.root, -1, {});
      return new RouterStateSnapshot('', new TreeNode(activated, []));
    }
    /**
     * Provides access to information about a route associated with a component
     * that is loaded in an outlet.
     * Use to traverse the `RouterState` tree and extract information from nodes.
     *
     * {\@example router/activated-route/module.ts region="activated-route"
     *     header="activated-route.component.ts"}
     *
     * \@publicApi
     */


    var ActivatedRoute = /*#__PURE__*/function () {
      /**
       * \@internal
       * @param {?} url
       * @param {?} params
       * @param {?} queryParams
       * @param {?} fragment
       * @param {?} data
       * @param {?} outlet
       * @param {?} component
       * @param {?} futureSnapshot
       */
      function ActivatedRoute(url, params, queryParams, fragment, data, outlet, component, futureSnapshot) {
        _classCallCheck(this, ActivatedRoute);

        this.url = url;
        this.params = params;
        this.queryParams = queryParams;
        this.fragment = fragment;
        this.data = data;
        this.outlet = outlet;
        this.component = component;
        this._futureSnapshot = futureSnapshot;
      }
      /**
       * The configuration used to match this route.
       * @return {?}
       */


      _createClass2(ActivatedRoute, [{
        key: "toString",

        /**
         * @return {?}
         */
        value: function toString() {
          return this.snapshot ? this.snapshot.toString() : "Future(".concat(this._futureSnapshot, ")");
        }
      }, {
        key: "routeConfig",
        get: function get() {
          return this._futureSnapshot.routeConfig;
        }
        /**
         * The root of the router state.
         * @return {?}
         */

      }, {
        key: "root",
        get: function get() {
          return this._routerState.root;
        }
        /**
         * The parent of this route in the router state tree.
         * @return {?}
         */

      }, {
        key: "parent",
        get: function get() {
          return this._routerState.parent(this);
        }
        /**
         * The first child of this route in the router state tree.
         * @return {?}
         */

      }, {
        key: "firstChild",
        get: function get() {
          return this._routerState.firstChild(this);
        }
        /**
         * The children of this route in the router state tree.
         * @return {?}
         */

      }, {
        key: "children",
        get: function get() {
          return this._routerState.children(this);
        }
        /**
         * The path from the root of the router state tree to this route.
         * @return {?}
         */

      }, {
        key: "pathFromRoot",
        get: function get() {
          return this._routerState.pathFromRoot(this);
        }
        /**
         * An Observable that contains a map of the required and optional parameters
         * specific to the route.
         * The map supports retrieving single and multiple values from the same parameter.
         * @return {?}
         */

      }, {
        key: "paramMap",
        get: function get() {
          if (!this._paramMap) {
            this._paramMap = this.params.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
            /**
            * @param {?} p
            * @return {?}
            */
            function (p) {
              return convertToParamMap(p);
            }));
          }

          return this._paramMap;
        }
        /**
         * An Observable that contains a map of the query parameters available to all routes.
         * The map supports retrieving single and multiple values from the query parameter.
         * @return {?}
         */

      }, {
        key: "queryParamMap",
        get: function get() {
          if (!this._queryParamMap) {
            this._queryParamMap = this.queryParams.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
            /**
            * @param {?} p
            * @return {?}
            */
            function (p) {
              return convertToParamMap(p);
            }));
          }

          return this._queryParamMap;
        }
      }]);

      return ActivatedRoute;
    }();

    if (false) {}
    /**
     * Returns the inherited params, data, and resolve for a given route.
     * By default, this only inherits values up to the nearest path-less or component-less route.
     * \@internal
     * @param {?} route
     * @param {?=} paramsInheritanceStrategy
     * @return {?}
     */


    function inheritedParamsDataResolve(route) {
      var paramsInheritanceStrategy = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'emptyOnly';

      /** @type {?} */
      var pathFromRoot = route.pathFromRoot;
      /** @type {?} */

      var inheritingStartingFrom = 0;

      if (paramsInheritanceStrategy !== 'always') {
        inheritingStartingFrom = pathFromRoot.length - 1;

        while (inheritingStartingFrom >= 1) {
          /** @type {?} */
          var current = pathFromRoot[inheritingStartingFrom];
          /** @type {?} */

          var parent = pathFromRoot[inheritingStartingFrom - 1]; // current route is an empty path => inherits its parent's params and data

          if (current.routeConfig && current.routeConfig.path === '') {
            inheritingStartingFrom--; // parent is componentless => current route should inherit its params and data
          } else if (!parent.component) {
            inheritingStartingFrom--;
          } else {
            break;
          }
        }
      }

      return flattenInherited(pathFromRoot.slice(inheritingStartingFrom));
    }
    /**
     * \@internal
     * @param {?} pathFromRoot
     * @return {?}
     */


    function flattenInherited(pathFromRoot) {
      return pathFromRoot.reduce(
      /**
      * @param {?} res
      * @param {?} curr
      * @return {?}
      */
      function (res, curr) {
        /** @type {?} */
        var params = Object.assign(Object.assign({}, res.params), curr.params);
        /** @type {?} */

        var data = Object.assign(Object.assign({}, res.data), curr.data);
        /** @type {?} */

        var resolve = Object.assign(Object.assign({}, res.resolve), curr._resolvedData);
        return {
          params: params,
          data: data,
          resolve: resolve
        };
      },
      /** @type {?} */
      {
        params: {},
        data: {},
        resolve: {}
      });
    }
    /**
     * \@description
     *
     * Contains the information about a route associated with a component loaded in an
     * outlet at a particular moment in time. ActivatedRouteSnapshot can also be used to
     * traverse the router state tree.
     *
     * ```
     * \@Component({templateUrl:'./my-component.html'})
     * class MyComponent {
     *   constructor(route: ActivatedRoute) {
     *     const id: string = route.snapshot.params.id;
     *     const url: string = route.snapshot.url.join('');
     *     const user = route.snapshot.data.user;
     *   }
     * }
     * ```
     *
     * \@publicApi
     */


    var ActivatedRouteSnapshot = /*#__PURE__*/function () {
      /**
       * \@internal
       * @param {?} url
       * @param {?} params
       * @param {?} queryParams
       * @param {?} fragment
       * @param {?} data
       * @param {?} outlet
       * @param {?} component
       * @param {?} routeConfig
       * @param {?} urlSegment
       * @param {?} lastPathIndex
       * @param {?} resolve
       */
      function ActivatedRouteSnapshot(url, params, queryParams, fragment, data, outlet, component, routeConfig, urlSegment, lastPathIndex, resolve) {
        _classCallCheck(this, ActivatedRouteSnapshot);

        this.url = url;
        this.params = params;
        this.queryParams = queryParams;
        this.fragment = fragment;
        this.data = data;
        this.outlet = outlet;
        this.component = component;
        this.routeConfig = routeConfig;
        this._urlSegment = urlSegment;
        this._lastPathIndex = lastPathIndex;
        this._resolve = resolve;
      }
      /**
       * The root of the router state
       * @return {?}
       */


      _createClass2(ActivatedRouteSnapshot, [{
        key: "toString",

        /**
         * @return {?}
         */
        value: function toString() {
          /** @type {?} */
          var url = this.url.map(
          /**
          * @param {?} segment
          * @return {?}
          */
          function (segment) {
            return segment.toString();
          }).join('/');
          /** @type {?} */

          var matched = this.routeConfig ? this.routeConfig.path : '';
          return "Route(url:'".concat(url, "', path:'").concat(matched, "')");
        }
      }, {
        key: "root",
        get: function get() {
          return this._routerState.root;
        }
        /**
         * The parent of this route in the router state tree
         * @return {?}
         */

      }, {
        key: "parent",
        get: function get() {
          return this._routerState.parent(this);
        }
        /**
         * The first child of this route in the router state tree
         * @return {?}
         */

      }, {
        key: "firstChild",
        get: function get() {
          return this._routerState.firstChild(this);
        }
        /**
         * The children of this route in the router state tree
         * @return {?}
         */

      }, {
        key: "children",
        get: function get() {
          return this._routerState.children(this);
        }
        /**
         * The path from the root of the router state tree to this route
         * @return {?}
         */

      }, {
        key: "pathFromRoot",
        get: function get() {
          return this._routerState.pathFromRoot(this);
        }
        /**
         * @return {?}
         */

      }, {
        key: "paramMap",
        get: function get() {
          if (!this._paramMap) {
            this._paramMap = convertToParamMap(this.params);
          }

          return this._paramMap;
        }
        /**
         * @return {?}
         */

      }, {
        key: "queryParamMap",
        get: function get() {
          if (!this._queryParamMap) {
            this._queryParamMap = convertToParamMap(this.queryParams);
          }

          return this._queryParamMap;
        }
      }]);

      return ActivatedRouteSnapshot;
    }();

    if (false) {}
    /**
     * \@description
     *
     * Represents the state of the router at a moment in time.
     *
     * This is a tree of activated route snapshots. Every node in this tree knows about
     * the "consumed" URL segments, the extracted parameters, and the resolved data.
     *
     * \@usageNotes
     * ### Example
     *
     * ```
     * \@Component({templateUrl:'template.html'})
     * class MyComponent {
     *   constructor(router: Router) {
     *     const state: RouterState = router.routerState;
     *     const snapshot: RouterStateSnapshot = state.snapshot;
     *     const root: ActivatedRouteSnapshot = snapshot.root;
     *     const child = root.firstChild;
     *     const id: Observable<string> = child.params.map(p => p.id);
     *     //...
     *   }
     * }
     * ```
     *
     * \@publicApi
     */


    var RouterStateSnapshot = /*#__PURE__*/function (_Tree2) {
      _inherits(RouterStateSnapshot, _Tree2);

      var _super107 = _createSuper(RouterStateSnapshot);

      /**
       * \@internal
       * @param {?} url
       * @param {?} root
       */
      function RouterStateSnapshot(url, root) {
        var _this283;

        _classCallCheck(this, RouterStateSnapshot);

        _this283 = _super107.call(this, root);
        _this283.url = url;
        setRouterState(
        /** @type {?} */
        _assertThisInitialized(_this283), root);
        return _this283;
      }
      /**
       * @return {?}
       */


      _createClass2(RouterStateSnapshot, [{
        key: "toString",
        value: function toString() {
          return serializeNode(this._root);
        }
      }]);

      return RouterStateSnapshot;
    }(Tree);

    if (false) {}
    /**
     * @template U, T
     * @param {?} state
     * @param {?} node
     * @return {?}
     */


    function setRouterState(state, node) {
      node.value._routerState = state;
      node.children.forEach(
      /**
      * @param {?} c
      * @return {?}
      */
      function (c) {
        return setRouterState(state, c);
      });
    }
    /**
     * @param {?} node
     * @return {?}
     */


    function serializeNode(node) {
      /** @type {?} */
      var c = node.children.length > 0 ? " { ".concat(node.children.map(serializeNode).join(', '), " } ") : '';
      return "".concat(node.value).concat(c);
    }
    /**
     * The expectation is that the activate route is created with the right set of parameters.
     * So we push new values into the observables only when they are not the initial values.
     * And we detect that by checking if the snapshot field is set.
     * @param {?} route
     * @return {?}
     */


    function advanceActivatedRoute(route) {
      if (route.snapshot) {
        /** @type {?} */
        var currentSnapshot = route.snapshot;
        /** @type {?} */

        var nextSnapshot = route._futureSnapshot;
        route.snapshot = nextSnapshot;

        if (!shallowEqual(currentSnapshot.queryParams, nextSnapshot.queryParams)) {
          /** @type {?} */
          route.queryParams.next(nextSnapshot.queryParams);
        }

        if (currentSnapshot.fragment !== nextSnapshot.fragment) {
          /** @type {?} */
          route.fragment.next(nextSnapshot.fragment);
        }

        if (!shallowEqual(currentSnapshot.params, nextSnapshot.params)) {
          /** @type {?} */
          route.params.next(nextSnapshot.params);
        }

        if (!shallowEqualArrays(currentSnapshot.url, nextSnapshot.url)) {
          /** @type {?} */
          route.url.next(nextSnapshot.url);
        }

        if (!shallowEqual(currentSnapshot.data, nextSnapshot.data)) {
          /** @type {?} */
          route.data.next(nextSnapshot.data);
        }
      } else {
        route.snapshot = route._futureSnapshot; // this is for resolved data

        /** @type {?} */
        route.data.next(route._futureSnapshot.data);
      }
    }
    /**
     * @param {?} a
     * @param {?} b
     * @return {?}
     */


    function equalParamsAndUrlSegments(a, b) {
      /** @type {?} */
      var equalUrlParams = shallowEqual(a.params, b.params) && equalSegments(a.url, b.url);
      /** @type {?} */

      var parentsMismatch = !a.parent !== !b.parent;
      return equalUrlParams && !parentsMismatch && (!a.parent || equalParamsAndUrlSegments(a.parent,
      /** @type {?} */
      b.parent));
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/create_router_state.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} routeReuseStrategy
     * @param {?} curr
     * @param {?} prevState
     * @return {?}
     */


    function createRouterState(routeReuseStrategy, curr, prevState) {
      /** @type {?} */
      var root = createNode(routeReuseStrategy, curr._root, prevState ? prevState._root : undefined);
      return new RouterState(root, curr);
    }
    /**
     * @param {?} routeReuseStrategy
     * @param {?} curr
     * @param {?=} prevState
     * @return {?}
     */


    function createNode(routeReuseStrategy, curr, prevState) {
      // reuse an activated route that is currently displayed on the screen
      if (prevState && routeReuseStrategy.shouldReuseRoute(curr.value, prevState.value.snapshot)) {
        /** @type {?} */
        var value = prevState.value;
        value._futureSnapshot = curr.value;
        /** @type {?} */

        var children = createOrReuseChildren(routeReuseStrategy, curr, prevState);
        return new TreeNode(value, children); // retrieve an activated route that is used to be displayed, but is not currently displayed
      } else {
        /** @type {?} */
        var detachedRouteHandle =
        /** @type {?} */
        routeReuseStrategy.retrieve(curr.value);

        if (detachedRouteHandle) {
          /** @type {?} */
          var _tree = detachedRouteHandle.route;
          setFutureSnapshotsOfActivatedRoutes(curr, _tree);
          return _tree;
        } else {
          /** @type {?} */
          var _value4 = createActivatedRoute(curr.value);
          /** @type {?} */


          var _children2 = curr.children.map(
          /**
          * @param {?} c
          * @return {?}
          */
          function (c) {
            return createNode(routeReuseStrategy, c);
          });

          return new TreeNode(_value4, _children2);
        }
      }
    }
    /**
     * @param {?} curr
     * @param {?} result
     * @return {?}
     */


    function setFutureSnapshotsOfActivatedRoutes(curr, result) {
      if (curr.value.routeConfig !== result.value.routeConfig) {
        throw new Error('Cannot reattach ActivatedRouteSnapshot created from a different route');
      }

      if (curr.children.length !== result.children.length) {
        throw new Error('Cannot reattach ActivatedRouteSnapshot with a different number of children');
      }

      result.value._futureSnapshot = curr.value;

      for (var i = 0; i < curr.children.length; ++i) {
        setFutureSnapshotsOfActivatedRoutes(curr.children[i], result.children[i]);
      }
    }
    /**
     * @param {?} routeReuseStrategy
     * @param {?} curr
     * @param {?} prevState
     * @return {?}
     */


    function createOrReuseChildren(routeReuseStrategy, curr, prevState) {
      return curr.children.map(
      /**
      * @param {?} child
      * @return {?}
      */
      function (child) {
        var _iterator19 = _createForOfIteratorHelper(prevState.children),
            _step19;

        try {
          for (_iterator19.s(); !(_step19 = _iterator19.n()).done;) {
            var p = _step19.value;

            if (routeReuseStrategy.shouldReuseRoute(p.value.snapshot, child.value)) {
              return createNode(routeReuseStrategy, child, p);
            }
          }
        } catch (err) {
          _iterator19.e(err);
        } finally {
          _iterator19.f();
        }

        return createNode(routeReuseStrategy, child);
      });
    }
    /**
     * @param {?} c
     * @return {?}
     */


    function createActivatedRoute(c) {
      return new ActivatedRoute(new rxjs__WEBPACK_IMPORTED_MODULE_2__["BehaviorSubject"](c.url), new rxjs__WEBPACK_IMPORTED_MODULE_2__["BehaviorSubject"](c.params), new rxjs__WEBPACK_IMPORTED_MODULE_2__["BehaviorSubject"](c.queryParams), new rxjs__WEBPACK_IMPORTED_MODULE_2__["BehaviorSubject"](c.fragment), new rxjs__WEBPACK_IMPORTED_MODULE_2__["BehaviorSubject"](c.data), c.outlet, c.component, c);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/create_url_tree.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} route
     * @param {?} urlTree
     * @param {?} commands
     * @param {?} queryParams
     * @param {?} fragment
     * @return {?}
     */


    function _createUrlTree(route, urlTree, commands, queryParams, fragment) {
      if (commands.length === 0) {
        return tree(urlTree.root, urlTree.root, urlTree, queryParams, fragment);
      }
      /** @type {?} */


      var nav = computeNavigation(commands);

      if (nav.toRoot()) {
        return tree(urlTree.root, new UrlSegmentGroup([], {}), urlTree, queryParams, fragment);
      }
      /** @type {?} */


      var startingPosition = findStartingPosition(nav, urlTree, route);
      /** @type {?} */

      var segmentGroup = startingPosition.processChildren ? updateSegmentGroupChildren(startingPosition.segmentGroup, startingPosition.index, nav.commands) : updateSegmentGroup(startingPosition.segmentGroup, startingPosition.index, nav.commands);
      return tree(startingPosition.segmentGroup, segmentGroup, urlTree, queryParams, fragment);
    }
    /**
     * @param {?} command
     * @return {?}
     */


    function isMatrixParams(command) {
      return typeof command === 'object' && command != null && !command.outlets && !command.segmentPath;
    }
    /**
     * @param {?} oldSegmentGroup
     * @param {?} newSegmentGroup
     * @param {?} urlTree
     * @param {?} queryParams
     * @param {?} fragment
     * @return {?}
     */


    function tree(oldSegmentGroup, newSegmentGroup, urlTree, queryParams, fragment) {
      /** @type {?} */
      var qp = {};

      if (queryParams) {
        forEach(queryParams,
        /**
        * @param {?} value
        * @param {?} name
        * @return {?}
        */
        function (value, name) {
          qp[name] = Array.isArray(value) ? value.map(
          /**
          * @param {?} v
          * @return {?}
          */
          function (v) {
            return "".concat(v);
          }) : "".concat(value);
        });
      }

      if (urlTree.root === oldSegmentGroup) {
        return new UrlTree(newSegmentGroup, qp, fragment);
      }

      return new UrlTree(replaceSegment(urlTree.root, oldSegmentGroup, newSegmentGroup), qp, fragment);
    }
    /**
     * @param {?} current
     * @param {?} oldSegment
     * @param {?} newSegment
     * @return {?}
     */


    function replaceSegment(current, oldSegment, newSegment) {
      /** @type {?} */
      var children = {};
      forEach(current.children,
      /**
      * @param {?} c
      * @param {?} outletName
      * @return {?}
      */
      function (c, outletName) {
        if (c === oldSegment) {
          children[outletName] = newSegment;
        } else {
          children[outletName] = replaceSegment(c, oldSegment, newSegment);
        }
      });
      return new UrlSegmentGroup(current.segments, children);
    }

    var Navigation = /*#__PURE__*/function () {
      /**
       * @param {?} isAbsolute
       * @param {?} numberOfDoubleDots
       * @param {?} commands
       */
      function Navigation(isAbsolute, numberOfDoubleDots, commands) {
        _classCallCheck(this, Navigation);

        this.isAbsolute = isAbsolute;
        this.numberOfDoubleDots = numberOfDoubleDots;
        this.commands = commands;

        if (isAbsolute && commands.length > 0 && isMatrixParams(commands[0])) {
          throw new Error('Root segment cannot have matrix parameters');
        }
        /** @type {?} */


        var cmdWithOutlet = commands.find(
        /**
        * @param {?} c
        * @return {?}
        */
        function (c) {
          return typeof c === 'object' && c != null && c.outlets;
        });

        if (cmdWithOutlet && cmdWithOutlet !== last(commands)) {
          throw new Error('{outlets:{}} has to be the last command');
        }
      }
      /**
       * @return {?}
       */


      _createClass2(Navigation, [{
        key: "toRoot",
        value: function toRoot() {
          return this.isAbsolute && this.commands.length === 1 && this.commands[0] == '/';
        }
      }]);

      return Navigation;
    }();

    if (false) {}
    /**
     * Transforms commands to a normalized `Navigation`
     * @param {?} commands
     * @return {?}
     */


    function computeNavigation(commands) {
      if (typeof commands[0] === 'string' && commands.length === 1 && commands[0] === '/') {
        return new Navigation(true, 0, commands);
      }
      /** @type {?} */


      var numberOfDoubleDots = 0;
      /** @type {?} */

      var isAbsolute = false;
      /** @type {?} */

      var res = commands.reduce(
      /**
      * @param {?} res
      * @param {?} cmd
      * @param {?} cmdIdx
      * @return {?}
      */
      function (res, cmd, cmdIdx) {
        if (typeof cmd === 'object' && cmd != null) {
          if (cmd.outlets) {
            /** @type {?} */
            var outlets = {};
            forEach(cmd.outlets,
            /**
            * @param {?} commands
            * @param {?} name
            * @return {?}
            */
            function (commands, name) {
              outlets[name] = typeof commands === 'string' ? commands.split('/') : commands;
            });
            return [].concat(_toConsumableArray(res), [{
              outlets: outlets
            }]);
          }

          if (cmd.segmentPath) {
            return [].concat(_toConsumableArray(res), [cmd.segmentPath]);
          }
        }

        if (!(typeof cmd === 'string')) {
          return [].concat(_toConsumableArray(res), [cmd]);
        }

        if (cmdIdx === 0) {
          cmd.split('/').forEach(
          /**
          * @param {?} urlPart
          * @param {?} partIndex
          * @return {?}
          */
          function (urlPart, partIndex) {
            if (partIndex == 0 && urlPart === '.') {// skip './a'
            } else if (partIndex == 0 && urlPart === '') {
              //  '/a'
              isAbsolute = true;
            } else if (urlPart === '..') {
              //  '../a'
              numberOfDoubleDots++;
            } else if (urlPart != '') {
              res.push(urlPart);
            }
          });
          return res;
        }

        return [].concat(_toConsumableArray(res), [cmd]);
      }, []);
      return new Navigation(isAbsolute, numberOfDoubleDots, res);
    }

    var Position =
    /**
     * @param {?} segmentGroup
     * @param {?} processChildren
     * @param {?} index
     */
    function Position(segmentGroup, processChildren, index) {
      _classCallCheck(this, Position);

      this.segmentGroup = segmentGroup;
      this.processChildren = processChildren;
      this.index = index;
    };

    if (false) {}
    /**
     * @param {?} nav
     * @param {?} tree
     * @param {?} route
     * @return {?}
     */


    function findStartingPosition(nav, tree, route) {
      if (nav.isAbsolute) {
        return new Position(tree.root, true, 0);
      }

      if (route.snapshot._lastPathIndex === -1) {
        return new Position(route.snapshot._urlSegment, true, 0);
      }
      /** @type {?} */


      var modifier = isMatrixParams(nav.commands[0]) ? 0 : 1;
      /** @type {?} */

      var index = route.snapshot._lastPathIndex + modifier;
      return createPositionApplyingDoubleDots(route.snapshot._urlSegment, index, nav.numberOfDoubleDots);
    }
    /**
     * @param {?} group
     * @param {?} index
     * @param {?} numberOfDoubleDots
     * @return {?}
     */


    function createPositionApplyingDoubleDots(group, index, numberOfDoubleDots) {
      /** @type {?} */
      var g = group;
      /** @type {?} */

      var ci = index;
      /** @type {?} */

      var dd = numberOfDoubleDots;

      while (dd > ci) {
        dd -= ci;
        g =
        /** @type {?} */
        g.parent;

        if (!g) {
          throw new Error('Invalid number of \'../\'');
        }

        ci = g.segments.length;
      }

      return new Position(g, false, ci - dd);
    }
    /**
     * @param {?} command
     * @return {?}
     */


    function getPath(command) {
      if (typeof command === 'object' && command != null && command.outlets) {
        return command.outlets[PRIMARY_OUTLET];
      }

      return "".concat(command);
    }
    /**
     * @param {?} commands
     * @return {?}
     */


    function getOutlets(commands) {
      if (!(typeof commands[0] === 'object')) return _defineProperty({}, PRIMARY_OUTLET, commands);
      if (commands[0].outlets === undefined) return _defineProperty({}, PRIMARY_OUTLET, commands);
      return commands[0].outlets;
    }
    /**
     * @param {?} segmentGroup
     * @param {?} startIndex
     * @param {?} commands
     * @return {?}
     */


    function updateSegmentGroup(segmentGroup, startIndex, commands) {
      if (!segmentGroup) {
        segmentGroup = new UrlSegmentGroup([], {});
      }

      if (segmentGroup.segments.length === 0 && segmentGroup.hasChildren()) {
        return updateSegmentGroupChildren(segmentGroup, startIndex, commands);
      }
      /** @type {?} */


      var m = prefixedWith(segmentGroup, startIndex, commands);
      /** @type {?} */

      var slicedCommands = commands.slice(m.commandIndex);

      if (m.match && m.pathIndex < segmentGroup.segments.length) {
        /** @type {?} */
        var g = new UrlSegmentGroup(segmentGroup.segments.slice(0, m.pathIndex), {});
        g.children[PRIMARY_OUTLET] = new UrlSegmentGroup(segmentGroup.segments.slice(m.pathIndex), segmentGroup.children);
        return updateSegmentGroupChildren(g, 0, slicedCommands);
      } else if (m.match && slicedCommands.length === 0) {
        return new UrlSegmentGroup(segmentGroup.segments, {});
      } else if (m.match && !segmentGroup.hasChildren()) {
        return createNewSegmentGroup(segmentGroup, startIndex, commands);
      } else if (m.match) {
        return updateSegmentGroupChildren(segmentGroup, 0, slicedCommands);
      } else {
        return createNewSegmentGroup(segmentGroup, startIndex, commands);
      }
    }
    /**
     * @param {?} segmentGroup
     * @param {?} startIndex
     * @param {?} commands
     * @return {?}
     */


    function updateSegmentGroupChildren(segmentGroup, startIndex, commands) {
      if (commands.length === 0) {
        return new UrlSegmentGroup(segmentGroup.segments, {});
      } else {
        /** @type {?} */
        var outlets = getOutlets(commands);
        /** @type {?} */

        var children = {};
        forEach(outlets,
        /**
        * @param {?} commands
        * @param {?} outlet
        * @return {?}
        */
        function (commands, outlet) {
          if (commands !== null) {
            children[outlet] = updateSegmentGroup(segmentGroup.children[outlet], startIndex, commands);
          }
        });
        forEach(segmentGroup.children,
        /**
        * @param {?} child
        * @param {?} childOutlet
        * @return {?}
        */
        function (child, childOutlet) {
          if (outlets[childOutlet] === undefined) {
            children[childOutlet] = child;
          }
        });
        return new UrlSegmentGroup(segmentGroup.segments, children);
      }
    }
    /**
     * @param {?} segmentGroup
     * @param {?} startIndex
     * @param {?} commands
     * @return {?}
     */


    function prefixedWith(segmentGroup, startIndex, commands) {
      /** @type {?} */
      var currentCommandIndex = 0;
      /** @type {?} */

      var currentPathIndex = startIndex;
      /** @type {?} */

      var noMatch = {
        match: false,
        pathIndex: 0,
        commandIndex: 0
      };

      while (currentPathIndex < segmentGroup.segments.length) {
        if (currentCommandIndex >= commands.length) return noMatch;
        /** @type {?} */

        var path = segmentGroup.segments[currentPathIndex];
        /** @type {?} */

        var curr = getPath(commands[currentCommandIndex]);
        /** @type {?} */

        var next = currentCommandIndex < commands.length - 1 ? commands[currentCommandIndex + 1] : null;
        if (currentPathIndex > 0 && curr === undefined) break;

        if (curr && next && typeof next === 'object' && next.outlets === undefined) {
          if (!compare(curr, next, path)) return noMatch;
          currentCommandIndex += 2;
        } else {
          if (!compare(curr, {}, path)) return noMatch;
          currentCommandIndex++;
        }

        currentPathIndex++;
      }

      return {
        match: true,
        pathIndex: currentPathIndex,
        commandIndex: currentCommandIndex
      };
    }
    /**
     * @param {?} segmentGroup
     * @param {?} startIndex
     * @param {?} commands
     * @return {?}
     */


    function createNewSegmentGroup(segmentGroup, startIndex, commands) {
      /** @type {?} */
      var paths = segmentGroup.segments.slice(0, startIndex);
      /** @type {?} */

      var i = 0;

      while (i < commands.length) {
        if (typeof commands[i] === 'object' && commands[i].outlets !== undefined) {
          /** @type {?} */
          var children = createNewSegmentChildren(commands[i].outlets);
          return new UrlSegmentGroup(paths, children);
        } // if we start with an object literal, we need to reuse the path part from the segment


        if (i === 0 && isMatrixParams(commands[0])) {
          /** @type {?} */
          var p = segmentGroup.segments[startIndex];
          paths.push(new UrlSegment(p.path, commands[0]));
          i++;
          continue;
        }
        /** @type {?} */


        var curr = getPath(commands[i]);
        /** @type {?} */

        var next = i < commands.length - 1 ? commands[i + 1] : null;

        if (curr && next && isMatrixParams(next)) {
          paths.push(new UrlSegment(curr, stringify(next)));
          i += 2;
        } else {
          paths.push(new UrlSegment(curr, {}));
          i++;
        }
      }

      return new UrlSegmentGroup(paths, {});
    }
    /**
     * @param {?} outlets
     * @return {?}
     */


    function createNewSegmentChildren(outlets) {
      /** @type {?} */
      var children = {};
      forEach(outlets,
      /**
      * @param {?} commands
      * @param {?} outlet
      * @return {?}
      */
      function (commands, outlet) {
        if (commands !== null) {
          children[outlet] = createNewSegmentGroup(new UrlSegmentGroup([], {}), 0, commands);
        }
      });
      return children;
    }
    /**
     * @param {?} params
     * @return {?}
     */


    function stringify(params) {
      /** @type {?} */
      var res = {};
      forEach(params,
      /**
      * @param {?} v
      * @param {?} k
      * @return {?}
      */
      function (v, k) {
        return res[k] = "".concat(v);
      });
      return res;
    }
    /**
     * @param {?} path
     * @param {?} params
     * @param {?} segment
     * @return {?}
     */


    function compare(path, params, segment) {
      return path == segment.path && shallowEqual(params, segment.parameters);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/operators/activate_routes.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var activateRoutes =
    /**
    * @param {?} rootContexts
    * @param {?} routeReuseStrategy
    * @param {?} forwardEvent
    * @return {?}
    */
    function activateRoutes(rootContexts, routeReuseStrategy, forwardEvent) {
      return Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
      /**
      * @param {?} t
      * @return {?}
      */
      function (t) {
        new ActivateRoutes(routeReuseStrategy,
        /** @type {?} */
        t.targetRouterState, t.currentRouterState, forwardEvent).activate(rootContexts);
        return t;
      });
    };

    var ActivateRoutes = /*#__PURE__*/function () {
      /**
       * @param {?} routeReuseStrategy
       * @param {?} futureState
       * @param {?} currState
       * @param {?} forwardEvent
       */
      function ActivateRoutes(routeReuseStrategy, futureState, currState, forwardEvent) {
        _classCallCheck(this, ActivateRoutes);

        this.routeReuseStrategy = routeReuseStrategy;
        this.futureState = futureState;
        this.currState = currState;
        this.forwardEvent = forwardEvent;
      }
      /**
       * @param {?} parentContexts
       * @return {?}
       */


      _createClass2(ActivateRoutes, [{
        key: "activate",
        value: function activate(parentContexts) {
          /** @type {?} */
          var futureRoot = this.futureState._root;
          /** @type {?} */

          var currRoot = this.currState ? this.currState._root : null;
          this.deactivateChildRoutes(futureRoot, currRoot, parentContexts);
          advanceActivatedRoute(this.futureState.root);
          this.activateChildRoutes(futureRoot, currRoot, parentContexts);
        } // De-activate the child route that are not re-used for the future state

        /**
         * @private
         * @param {?} futureNode
         * @param {?} currNode
         * @param {?} contexts
         * @return {?}
         */

      }, {
        key: "deactivateChildRoutes",
        value: function deactivateChildRoutes(futureNode, currNode, contexts) {
          var _this284 = this;

          /** @type {?} */
          var children = nodeChildrenAsMap(currNode); // Recurse on the routes active in the future state to de-activate deeper children

          futureNode.children.forEach(
          /**
          * @param {?} futureChild
          * @return {?}
          */
          function (futureChild) {
            /** @type {?} */
            var childOutletName = futureChild.value.outlet;

            _this284.deactivateRoutes(futureChild, children[childOutletName], contexts);

            delete children[childOutletName];
          }); // De-activate the routes that will not be re-used

          forEach(children,
          /**
          * @param {?} v
          * @param {?} childName
          * @return {?}
          */
          function (v, childName) {
            _this284.deactivateRouteAndItsChildren(v, contexts);
          });
        }
        /**
         * @private
         * @param {?} futureNode
         * @param {?} currNode
         * @param {?} parentContext
         * @return {?}
         */

      }, {
        key: "deactivateRoutes",
        value: function deactivateRoutes(futureNode, currNode, parentContext) {
          /** @type {?} */
          var future = futureNode.value;
          /** @type {?} */

          var curr = currNode ? currNode.value : null;

          if (future === curr) {
            // Reusing the node, check to see if the children need to be de-activated
            if (future.component) {
              // If we have a normal route, we need to go through an outlet.

              /** @type {?} */
              var context = parentContext.getContext(future.outlet);

              if (context) {
                this.deactivateChildRoutes(futureNode, currNode, context.children);
              }
            } else {
              // if we have a componentless route, we recurse but keep the same outlet map.
              this.deactivateChildRoutes(futureNode, currNode, parentContext);
            }
          } else {
            if (curr) {
              // Deactivate the current route which will not be re-used
              this.deactivateRouteAndItsChildren(currNode, parentContext);
            }
          }
        }
        /**
         * @private
         * @param {?} route
         * @param {?} parentContexts
         * @return {?}
         */

      }, {
        key: "deactivateRouteAndItsChildren",
        value: function deactivateRouteAndItsChildren(route, parentContexts) {
          if (this.routeReuseStrategy.shouldDetach(route.value.snapshot)) {
            this.detachAndStoreRouteSubtree(route, parentContexts);
          } else {
            this.deactivateRouteAndOutlet(route, parentContexts);
          }
        }
        /**
         * @private
         * @param {?} route
         * @param {?} parentContexts
         * @return {?}
         */

      }, {
        key: "detachAndStoreRouteSubtree",
        value: function detachAndStoreRouteSubtree(route, parentContexts) {
          /** @type {?} */
          var context = parentContexts.getContext(route.value.outlet);

          if (context && context.outlet) {
            /** @type {?} */
            var componentRef = context.outlet.detach();
            /** @type {?} */

            var contexts = context.children.onOutletDeactivated();
            this.routeReuseStrategy.store(route.value.snapshot, {
              componentRef: componentRef,
              route: route,
              contexts: contexts
            });
          }
        }
        /**
         * @private
         * @param {?} route
         * @param {?} parentContexts
         * @return {?}
         */

      }, {
        key: "deactivateRouteAndOutlet",
        value: function deactivateRouteAndOutlet(route, parentContexts) {
          var _this285 = this;

          /** @type {?} */
          var context = parentContexts.getContext(route.value.outlet);

          if (context) {
            /** @type {?} */
            var children = nodeChildrenAsMap(route);
            /** @type {?} */

            var contexts = route.value.component ? context.children : parentContexts;
            forEach(children,
            /**
            * @param {?} v
            * @param {?} k
            * @return {?}
            */
            function (v, k) {
              return _this285.deactivateRouteAndItsChildren(v, contexts);
            });

            if (context.outlet) {
              // Destroy the component
              context.outlet.deactivate(); // Destroy the contexts for all the outlets that were in the component

              context.children.onOutletDeactivated();
            }
          }
        }
        /**
         * @private
         * @param {?} futureNode
         * @param {?} currNode
         * @param {?} contexts
         * @return {?}
         */

      }, {
        key: "activateChildRoutes",
        value: function activateChildRoutes(futureNode, currNode, contexts) {
          var _this286 = this;

          /** @type {?} */
          var children = nodeChildrenAsMap(currNode);
          futureNode.children.forEach(
          /**
          * @param {?} c
          * @return {?}
          */
          function (c) {
            _this286.activateRoutes(c, children[c.value.outlet], contexts);

            _this286.forwardEvent(new ActivationEnd(c.value.snapshot));
          });

          if (futureNode.children.length) {
            this.forwardEvent(new ChildActivationEnd(futureNode.value.snapshot));
          }
        }
        /**
         * @private
         * @param {?} futureNode
         * @param {?} currNode
         * @param {?} parentContexts
         * @return {?}
         */

      }, {
        key: "activateRoutes",
        value: function activateRoutes(futureNode, currNode, parentContexts) {
          /** @type {?} */
          var future = futureNode.value;
          /** @type {?} */

          var curr = currNode ? currNode.value : null;
          advanceActivatedRoute(future); // reusing the node

          if (future === curr) {
            if (future.component) {
              // If we have a normal route, we need to go through an outlet.

              /** @type {?} */
              var context = parentContexts.getOrCreateContext(future.outlet);
              this.activateChildRoutes(futureNode, currNode, context.children);
            } else {
              // if we have a componentless route, we recurse but keep the same outlet map.
              this.activateChildRoutes(futureNode, currNode, parentContexts);
            }
          } else {
            if (future.component) {
              // if we have a normal route, we need to place the component into the outlet and recurse.

              /** @type {?} */
              var _context3 = parentContexts.getOrCreateContext(future.outlet);

              if (this.routeReuseStrategy.shouldAttach(future.snapshot)) {
                /** @type {?} */
                var stored =
                /** @type {?} */
                this.routeReuseStrategy.retrieve(future.snapshot);
                this.routeReuseStrategy.store(future.snapshot, null);

                _context3.children.onOutletReAttached(stored.contexts);

                _context3.attachRef = stored.componentRef;
                _context3.route = stored.route.value;

                if (_context3.outlet) {
                  // Attach right away when the outlet has already been instantiated
                  // Otherwise attach from `RouterOutlet.ngOnInit` when it is instantiated
                  _context3.outlet.attach(stored.componentRef, stored.route.value);
                }

                advanceActivatedRouteNodeAndItsChildren(stored.route);
              } else {
                /** @type {?} */
                var config = parentLoadedConfig(future.snapshot);
                /** @type {?} */

                var cmpFactoryResolver = config ? config.module.componentFactoryResolver : null;
                _context3.attachRef = null;
                _context3.route = future;
                _context3.resolver = cmpFactoryResolver;

                if (_context3.outlet) {
                  // Activate the outlet when it has already been instantiated
                  // Otherwise it will get activated from its `ngOnInit` when instantiated
                  _context3.outlet.activateWith(future, cmpFactoryResolver);
                }

                this.activateChildRoutes(futureNode, null, _context3.children);
              }
            } else {
              // if we have a componentless route, we recurse but keep the same outlet map.
              this.activateChildRoutes(futureNode, null, parentContexts);
            }
          }
        }
      }]);

      return ActivateRoutes;
    }();

    if (false) {}
    /**
     * @param {?} node
     * @return {?}
     */


    function advanceActivatedRouteNodeAndItsChildren(node) {
      advanceActivatedRoute(node.value);
      node.children.forEach(advanceActivatedRouteNodeAndItsChildren);
    }
    /**
     * @param {?} snapshot
     * @return {?}
     */


    function parentLoadedConfig(snapshot) {
      for (var s = snapshot.parent; s; s = s.parent) {
        /** @type {?} */
        var route = s.routeConfig;
        if (route && route._loadedConfig) return route._loadedConfig;
        if (route && route.component) return null;
      }

      return null;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/utils/type_guards.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Simple function check, but generic so type inference will flow. Example:
     *
     * function product(a: number, b: number) {
     *   return a * b;
     * }
     *
     * if (isFunction<product>(fn)) {
     *   return fn(1, 2);
     * } else {
     *   throw "Must provide the `product` function";
     * }
     * @template T
     * @param {?} v
     * @return {?}
     */


    function isFunction(v) {
      return typeof v === 'function';
    }
    /**
     * @param {?} v
     * @return {?}
     */


    function isBoolean(v) {
      return typeof v === 'boolean';
    }
    /**
     * @param {?} v
     * @return {?}
     */


    function isUrlTree(v) {
      return v instanceof UrlTree;
    }
    /**
     * @param {?} guard
     * @return {?}
     */


    function isCanLoad(guard) {
      return guard && isFunction(guard.canLoad);
    }
    /**
     * @param {?} guard
     * @return {?}
     */


    function isCanActivate(guard) {
      return guard && isFunction(guard.canActivate);
    }
    /**
     * @param {?} guard
     * @return {?}
     */


    function isCanActivateChild(guard) {
      return guard && isFunction(guard.canActivateChild);
    }
    /**
     * @template T
     * @param {?} guard
     * @return {?}
     */


    function isCanDeactivate(guard) {
      return guard && isFunction(guard.canDeactivate);
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/apply_redirects.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var NoMatch =
    /**
     * @param {?=} segmentGroup
     */
    function NoMatch(segmentGroup) {
      _classCallCheck(this, NoMatch);

      this.segmentGroup = segmentGroup || null;
    };

    if (false) {}

    var AbsoluteRedirect =
    /**
     * @param {?} urlTree
     */
    function AbsoluteRedirect(urlTree) {
      _classCallCheck(this, AbsoluteRedirect);

      this.urlTree = urlTree;
    };

    if (false) {}
    /**
     * @param {?} segmentGroup
     * @return {?}
     */


    function noMatch(segmentGroup) {
      return new rxjs__WEBPACK_IMPORTED_MODULE_2__["Observable"](
      /**
      * @param {?} obs
      * @return {?}
      */
      function (obs) {
        return obs.error(new NoMatch(segmentGroup));
      });
    }
    /**
     * @param {?} newTree
     * @return {?}
     */


    function absoluteRedirect(newTree) {
      return new rxjs__WEBPACK_IMPORTED_MODULE_2__["Observable"](
      /**
      * @param {?} obs
      * @return {?}
      */
      function (obs) {
        return obs.error(new AbsoluteRedirect(newTree));
      });
    }
    /**
     * @param {?} redirectTo
     * @return {?}
     */


    function namedOutletsRedirect(redirectTo) {
      return new rxjs__WEBPACK_IMPORTED_MODULE_2__["Observable"](
      /**
      * @param {?} obs
      * @return {?}
      */
      function (obs) {
        return obs.error(new Error("Only absolute redirects can have named outlets. redirectTo: '".concat(redirectTo, "'")));
      });
    }
    /**
     * @param {?} route
     * @return {?}
     */


    function canLoadFails(route) {
      return new rxjs__WEBPACK_IMPORTED_MODULE_2__["Observable"](
      /**
      * @param {?} obs
      * @return {?}
      */
      function (obs) {
        return obs.error(navigationCancelingError("Cannot load children because the guard of the route \"path: '".concat(route.path, "'\" returned false")));
      });
    }
    /**
     * Returns the `UrlTree` with the redirection applied.
     *
     * Lazy modules are loaded along the way.
     * @param {?} moduleInjector
     * @param {?} configLoader
     * @param {?} urlSerializer
     * @param {?} urlTree
     * @param {?} config
     * @return {?}
     */


    function applyRedirects(moduleInjector, configLoader, urlSerializer, urlTree, config) {
      return new ApplyRedirects(moduleInjector, configLoader, urlSerializer, urlTree, config).apply();
    }

    var ApplyRedirects = /*#__PURE__*/function () {
      /**
       * @param {?} moduleInjector
       * @param {?} configLoader
       * @param {?} urlSerializer
       * @param {?} urlTree
       * @param {?} config
       */
      function ApplyRedirects(moduleInjector, configLoader, urlSerializer, urlTree, config) {
        _classCallCheck(this, ApplyRedirects);

        this.configLoader = configLoader;
        this.urlSerializer = urlSerializer;
        this.urlTree = urlTree;
        this.config = config;
        this.allowRedirects = true;
        this.ngModule = moduleInjector.get(_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModuleRef"]);
      }
      /**
       * @return {?}
       */


      _createClass2(ApplyRedirects, [{
        key: "apply",
        value: function apply() {
          var _this287 = this;

          /** @type {?} */
          var expanded$ = this.expandSegmentGroup(this.ngModule, this.config, this.urlTree.root, PRIMARY_OUTLET);
          /** @type {?} */

          var urlTrees$ = expanded$.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
          /**
          * @param {?} rootSegmentGroup
          * @return {?}
          */
          function (rootSegmentGroup) {
            return _this287.createUrlTree(rootSegmentGroup, _this287.urlTree.queryParams,
            /** @type {?} */
            _this287.urlTree.fragment);
          }));
          return urlTrees$.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["catchError"])(
          /**
          * @param {?} e
          * @return {?}
          */
          function (e) {
            if (e instanceof AbsoluteRedirect) {
              // after an absolute redirect we do not apply any more redirects!
              _this287.allowRedirects = false; // we need to run matching, so we can fetch all lazy-loaded modules

              return _this287.match(e.urlTree);
            }

            if (e instanceof NoMatch) {
              throw _this287.noMatchError(e);
            }

            throw e;
          }));
        }
        /**
         * @private
         * @param {?} tree
         * @return {?}
         */

      }, {
        key: "match",
        value: function match(tree) {
          var _this288 = this;

          /** @type {?} */
          var expanded$ = this.expandSegmentGroup(this.ngModule, this.config, tree.root, PRIMARY_OUTLET);
          /** @type {?} */

          var mapped$ = expanded$.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
          /**
          * @param {?} rootSegmentGroup
          * @return {?}
          */
          function (rootSegmentGroup) {
            return _this288.createUrlTree(rootSegmentGroup, tree.queryParams,
            /** @type {?} */
            tree.fragment);
          }));
          return mapped$.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["catchError"])(
          /**
          * @param {?} e
          * @return {?}
          */
          function (e) {
            if (e instanceof NoMatch) {
              throw _this288.noMatchError(e);
            }

            throw e;
          }));
        }
        /**
         * @private
         * @param {?} e
         * @return {?}
         */

      }, {
        key: "noMatchError",
        value: function noMatchError(e) {
          return new Error("Cannot match any routes. URL Segment: '".concat(e.segmentGroup, "'"));
        }
        /**
         * @private
         * @param {?} rootCandidate
         * @param {?} queryParams
         * @param {?} fragment
         * @return {?}
         */

      }, {
        key: "createUrlTree",
        value: function createUrlTree(rootCandidate, queryParams, fragment) {
          /** @type {?} */
          var root = rootCandidate.segments.length > 0 ? new UrlSegmentGroup([], _defineProperty({}, PRIMARY_OUTLET, rootCandidate)) : rootCandidate;
          return new UrlTree(root, queryParams, fragment);
        }
        /**
         * @private
         * @param {?} ngModule
         * @param {?} routes
         * @param {?} segmentGroup
         * @param {?} outlet
         * @return {?}
         */

      }, {
        key: "expandSegmentGroup",
        value: function expandSegmentGroup(ngModule, routes, segmentGroup, outlet) {
          if (segmentGroup.segments.length === 0 && segmentGroup.hasChildren()) {
            return this.expandChildren(ngModule, routes, segmentGroup).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
            /**
            * @param {?} children
            * @return {?}
            */
            function (children) {
              return new UrlSegmentGroup([], children);
            }));
          }

          return this.expandSegment(ngModule, segmentGroup, routes, segmentGroup.segments, outlet, true);
        } // Recursively expand segment groups for all the child outlets

        /**
         * @private
         * @param {?} ngModule
         * @param {?} routes
         * @param {?} segmentGroup
         * @return {?}
         */

      }, {
        key: "expandChildren",
        value: function expandChildren(ngModule, routes, segmentGroup) {
          var _this289 = this;

          return waitForMap(segmentGroup.children,
          /**
          * @param {?} childOutlet
          * @param {?} child
          * @return {?}
          */
          function (childOutlet, child) {
            return _this289.expandSegmentGroup(ngModule, routes, child, childOutlet);
          });
        }
        /**
         * @private
         * @param {?} ngModule
         * @param {?} segmentGroup
         * @param {?} routes
         * @param {?} segments
         * @param {?} outlet
         * @param {?} allowRedirects
         * @return {?}
         */

      }, {
        key: "expandSegment",
        value: function expandSegment(ngModule, segmentGroup, routes, segments, outlet, allowRedirects) {
          var _this290 = this;

          return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"]).apply(void 0, _toConsumableArray(routes)).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
          /**
          * @param {?} r
          * @return {?}
          */
          function (r) {
            /** @type {?} */
            var expanded$ = _this290.expandSegmentAgainstRoute(ngModule, segmentGroup, routes, r, segments, outlet, allowRedirects);

            return expanded$.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["catchError"])(
            /**
            * @param {?} e
            * @return {?}
            */
            function (e) {
              if (e instanceof NoMatch) {
                // TODO(i): this return type doesn't match the declared Observable<UrlSegmentGroup> -
                // talk to Jason
                return (
                  /** @type {?} */
                  Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(null)
                );
              }

              throw e;
            }));
          }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["concatAll"])(), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["first"])(
          /**
          * @param {?} s
          * @return {?}
          */
          function (s) {
            return !!s;
          }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["catchError"])(
          /**
          * @param {?} e
          * @param {?} _
          * @return {?}
          */
          function (e, _) {
            if (e instanceof rxjs__WEBPACK_IMPORTED_MODULE_2__["EmptyError"] || e.name === 'EmptyError') {
              if (_this290.noLeftoversInUrl(segmentGroup, segments, outlet)) {
                return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(new UrlSegmentGroup([], {}));
              }

              throw new NoMatch(segmentGroup);
            }

            throw e;
          }));
        }
        /**
         * @private
         * @param {?} segmentGroup
         * @param {?} segments
         * @param {?} outlet
         * @return {?}
         */

      }, {
        key: "noLeftoversInUrl",
        value: function noLeftoversInUrl(segmentGroup, segments, outlet) {
          return segments.length === 0 && !segmentGroup.children[outlet];
        }
        /**
         * @private
         * @param {?} ngModule
         * @param {?} segmentGroup
         * @param {?} routes
         * @param {?} route
         * @param {?} paths
         * @param {?} outlet
         * @param {?} allowRedirects
         * @return {?}
         */

      }, {
        key: "expandSegmentAgainstRoute",
        value: function expandSegmentAgainstRoute(ngModule, segmentGroup, routes, route, paths, outlet, allowRedirects) {
          if (getOutlet(route) !== outlet) {
            return noMatch(segmentGroup);
          }

          if (route.redirectTo === undefined) {
            return this.matchSegmentAgainstRoute(ngModule, segmentGroup, route, paths);
          }

          if (allowRedirects && this.allowRedirects) {
            return this.expandSegmentAgainstRouteUsingRedirect(ngModule, segmentGroup, routes, route, paths, outlet);
          }

          return noMatch(segmentGroup);
        }
        /**
         * @private
         * @param {?} ngModule
         * @param {?} segmentGroup
         * @param {?} routes
         * @param {?} route
         * @param {?} segments
         * @param {?} outlet
         * @return {?}
         */

      }, {
        key: "expandSegmentAgainstRouteUsingRedirect",
        value: function expandSegmentAgainstRouteUsingRedirect(ngModule, segmentGroup, routes, route, segments, outlet) {
          if (route.path === '**') {
            return this.expandWildCardWithParamsAgainstRouteUsingRedirect(ngModule, routes, route, outlet);
          }

          return this.expandRegularSegmentAgainstRouteUsingRedirect(ngModule, segmentGroup, routes, route, segments, outlet);
        }
        /**
         * @private
         * @param {?} ngModule
         * @param {?} routes
         * @param {?} route
         * @param {?} outlet
         * @return {?}
         */

      }, {
        key: "expandWildCardWithParamsAgainstRouteUsingRedirect",
        value: function expandWildCardWithParamsAgainstRouteUsingRedirect(ngModule, routes, route, outlet) {
          var _this291 = this;

          /** @type {?} */
          var newTree = this.applyRedirectCommands([],
          /** @type {?} */
          route.redirectTo, {});

          if (
          /** @type {?} */
          route.redirectTo.startsWith('/')) {
            return absoluteRedirect(newTree);
          }

          return this.lineralizeSegments(route, newTree).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["mergeMap"])(
          /**
          * @param {?} newSegments
          * @return {?}
          */
          function (newSegments) {
            /** @type {?} */
            var group = new UrlSegmentGroup(newSegments, {});
            return _this291.expandSegment(ngModule, group, routes, newSegments, outlet, false);
          }));
        }
        /**
         * @private
         * @param {?} ngModule
         * @param {?} segmentGroup
         * @param {?} routes
         * @param {?} route
         * @param {?} segments
         * @param {?} outlet
         * @return {?}
         */

      }, {
        key: "expandRegularSegmentAgainstRouteUsingRedirect",
        value: function expandRegularSegmentAgainstRouteUsingRedirect(ngModule, segmentGroup, routes, route, segments, outlet) {
          var _this292 = this;

          var _match = match(segmentGroup, route, segments),
              matched = _match.matched,
              consumedSegments = _match.consumedSegments,
              lastChild = _match.lastChild,
              positionalParamSegments = _match.positionalParamSegments;

          if (!matched) return noMatch(segmentGroup);
          /** @type {?} */

          var newTree = this.applyRedirectCommands(consumedSegments,
          /** @type {?} */
          route.redirectTo,
          /** @type {?} */
          positionalParamSegments);

          if (
          /** @type {?} */
          route.redirectTo.startsWith('/')) {
            return absoluteRedirect(newTree);
          }

          return this.lineralizeSegments(route, newTree).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["mergeMap"])(
          /**
          * @param {?} newSegments
          * @return {?}
          */
          function (newSegments) {
            return _this292.expandSegment(ngModule, segmentGroup, routes, newSegments.concat(segments.slice(lastChild)), outlet, false);
          }));
        }
        /**
         * @private
         * @param {?} ngModule
         * @param {?} rawSegmentGroup
         * @param {?} route
         * @param {?} segments
         * @return {?}
         */

      }, {
        key: "matchSegmentAgainstRoute",
        value: function matchSegmentAgainstRoute(ngModule, rawSegmentGroup, route, segments) {
          var _this293 = this;

          if (route.path === '**') {
            if (route.loadChildren) {
              return this.configLoader.load(ngModule.injector, route).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
              /**
              * @param {?} cfg
              * @return {?}
              */
              function (cfg) {
                route._loadedConfig = cfg;
                return new UrlSegmentGroup(segments, {});
              }));
            }

            return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(new UrlSegmentGroup(segments, {}));
          }

          var _match2 = match(rawSegmentGroup, route, segments),
              matched = _match2.matched,
              consumedSegments = _match2.consumedSegments,
              lastChild = _match2.lastChild;

          if (!matched) return noMatch(rawSegmentGroup);
          /** @type {?} */

          var rawSlicedSegments = segments.slice(lastChild);
          /** @type {?} */

          var childConfig$ = this.getChildConfig(ngModule, route, segments);
          return childConfig$.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["mergeMap"])(
          /**
          * @param {?} routerConfig
          * @return {?}
          */
          function (routerConfig) {
            /** @type {?} */
            var childModule = routerConfig.module;
            /** @type {?} */

            var childConfig = routerConfig.routes;

            var _split = split(rawSegmentGroup, consumedSegments, rawSlicedSegments, childConfig),
                segmentGroup = _split.segmentGroup,
                slicedSegments = _split.slicedSegments;

            if (slicedSegments.length === 0 && segmentGroup.hasChildren()) {
              /** @type {?} */
              var _expanded$ = _this293.expandChildren(childModule, childConfig, segmentGroup);

              return _expanded$.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
              /**
              * @param {?} children
              * @return {?}
              */
              function (children) {
                return new UrlSegmentGroup(consumedSegments, children);
              }));
            }

            if (childConfig.length === 0 && slicedSegments.length === 0) {
              return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(new UrlSegmentGroup(consumedSegments, {}));
            }
            /** @type {?} */


            var expanded$ = _this293.expandSegment(childModule, segmentGroup, childConfig, slicedSegments, PRIMARY_OUTLET, true);

            return expanded$.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
            /**
            * @param {?} cs
            * @return {?}
            */
            function (cs) {
              return new UrlSegmentGroup(consumedSegments.concat(cs.segments), cs.children);
            }));
          }));
        }
        /**
         * @private
         * @param {?} ngModule
         * @param {?} route
         * @param {?} segments
         * @return {?}
         */

      }, {
        key: "getChildConfig",
        value: function getChildConfig(ngModule, route, segments) {
          var _this294 = this;

          if (route.children) {
            // The children belong to the same module
            return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(new LoadedRouterConfig(route.children, ngModule));
          }

          if (route.loadChildren) {
            // lazy children belong to the loaded module
            if (route._loadedConfig !== undefined) {
              return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(route._loadedConfig);
            }

            return runCanLoadGuard(ngModule.injector, route, segments).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["mergeMap"])(
            /**
            * @param {?} shouldLoad
            * @return {?}
            */
            function (shouldLoad) {
              if (shouldLoad) {
                return _this294.configLoader.load(ngModule.injector, route).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
                /**
                * @param {?} cfg
                * @return {?}
                */
                function (cfg) {
                  route._loadedConfig = cfg;
                  return cfg;
                }));
              }

              return canLoadFails(route);
            }));
          }

          return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(new LoadedRouterConfig([], ngModule));
        }
        /**
         * @private
         * @param {?} route
         * @param {?} urlTree
         * @return {?}
         */

      }, {
        key: "lineralizeSegments",
        value: function lineralizeSegments(route, urlTree) {
          /** @type {?} */
          var res = [];
          /** @type {?} */

          var c = urlTree.root;

          while (true) {
            res = res.concat(c.segments);

            if (c.numberOfChildren === 0) {
              return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(res);
            }

            if (c.numberOfChildren > 1 || !c.children[PRIMARY_OUTLET]) {
              return namedOutletsRedirect(
              /** @type {?} */
              route.redirectTo);
            }

            c = c.children[PRIMARY_OUTLET];
          }
        }
        /**
         * @private
         * @param {?} segments
         * @param {?} redirectTo
         * @param {?} posParams
         * @return {?}
         */

      }, {
        key: "applyRedirectCommands",
        value: function applyRedirectCommands(segments, redirectTo, posParams) {
          return this.applyRedirectCreatreUrlTree(redirectTo, this.urlSerializer.parse(redirectTo), segments, posParams);
        }
        /**
         * @private
         * @param {?} redirectTo
         * @param {?} urlTree
         * @param {?} segments
         * @param {?} posParams
         * @return {?}
         */

      }, {
        key: "applyRedirectCreatreUrlTree",
        value: function applyRedirectCreatreUrlTree(redirectTo, urlTree, segments, posParams) {
          /** @type {?} */
          var newRoot = this.createSegmentGroup(redirectTo, urlTree.root, segments, posParams);
          return new UrlTree(newRoot, this.createQueryParams(urlTree.queryParams, this.urlTree.queryParams), urlTree.fragment);
        }
        /**
         * @private
         * @param {?} redirectToParams
         * @param {?} actualParams
         * @return {?}
         */

      }, {
        key: "createQueryParams",
        value: function createQueryParams(redirectToParams, actualParams) {
          /** @type {?} */
          var res = {};
          forEach(redirectToParams,
          /**
          * @param {?} v
          * @param {?} k
          * @return {?}
          */
          function (v, k) {
            /** @type {?} */
            var copySourceValue = typeof v === 'string' && v.startsWith(':');

            if (copySourceValue) {
              /** @type {?} */
              var sourceName = v.substring(1);
              res[k] = actualParams[sourceName];
            } else {
              res[k] = v;
            }
          });
          return res;
        }
        /**
         * @private
         * @param {?} redirectTo
         * @param {?} group
         * @param {?} segments
         * @param {?} posParams
         * @return {?}
         */

      }, {
        key: "createSegmentGroup",
        value: function createSegmentGroup(redirectTo, group, segments, posParams) {
          var _this295 = this;

          /** @type {?} */
          var updatedSegments = this.createSegments(redirectTo, group.segments, segments, posParams);
          /** @type {?} */

          var children = {};
          forEach(group.children,
          /**
          * @param {?} child
          * @param {?} name
          * @return {?}
          */
          function (child, name) {
            children[name] = _this295.createSegmentGroup(redirectTo, child, segments, posParams);
          });
          return new UrlSegmentGroup(updatedSegments, children);
        }
        /**
         * @private
         * @param {?} redirectTo
         * @param {?} redirectToSegments
         * @param {?} actualSegments
         * @param {?} posParams
         * @return {?}
         */

      }, {
        key: "createSegments",
        value: function createSegments(redirectTo, redirectToSegments, actualSegments, posParams) {
          var _this296 = this;

          return redirectToSegments.map(
          /**
          * @param {?} s
          * @return {?}
          */
          function (s) {
            return s.path.startsWith(':') ? _this296.findPosParam(redirectTo, s, posParams) : _this296.findOrReturn(s, actualSegments);
          });
        }
        /**
         * @private
         * @param {?} redirectTo
         * @param {?} redirectToUrlSegment
         * @param {?} posParams
         * @return {?}
         */

      }, {
        key: "findPosParam",
        value: function findPosParam(redirectTo, redirectToUrlSegment, posParams) {
          /** @type {?} */
          var pos = posParams[redirectToUrlSegment.path.substring(1)];
          if (!pos) throw new Error("Cannot redirect to '".concat(redirectTo, "'. Cannot find '").concat(redirectToUrlSegment.path, "'."));
          return pos;
        }
        /**
         * @private
         * @param {?} redirectToUrlSegment
         * @param {?} actualSegments
         * @return {?}
         */

      }, {
        key: "findOrReturn",
        value: function findOrReturn(redirectToUrlSegment, actualSegments) {
          /** @type {?} */
          var idx = 0;

          var _iterator20 = _createForOfIteratorHelper(actualSegments),
              _step20;

          try {
            for (_iterator20.s(); !(_step20 = _iterator20.n()).done;) {
              var s = _step20.value;

              if (s.path === redirectToUrlSegment.path) {
                actualSegments.splice(idx);
                return s;
              }

              idx++;
            }
          } catch (err) {
            _iterator20.e(err);
          } finally {
            _iterator20.f();
          }

          return redirectToUrlSegment;
        }
      }]);

      return ApplyRedirects;
    }();

    if (false) {}
    /**
     * @param {?} moduleInjector
     * @param {?} route
     * @param {?} segments
     * @return {?}
     */


    function runCanLoadGuard(moduleInjector, route, segments) {
      /** @type {?} */
      var canLoad = route.canLoad;
      if (!canLoad || canLoad.length === 0) return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(true);
      /** @type {?} */

      var obs = Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["from"])(canLoad).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
      /**
      * @param {?} injectionToken
      * @return {?}
      */
      function (injectionToken) {
        /** @type {?} */
        var guard = moduleInjector.get(injectionToken);
        /** @type {?} */

        var guardVal;

        if (isCanLoad(guard)) {
          guardVal = guard.canLoad(route, segments);
        } else if (isFunction(guard)) {
          guardVal = guard(route, segments);
        } else {
          throw new Error('Invalid CanLoad guard');
        }

        return wrapIntoObservable(guardVal);
      }));
      return obs.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["concatAll"])(), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["every"])(
      /**
      * @param {?} result
      * @return {?}
      */
      function (result) {
        return result === true;
      }));
    }
    /**
     * @param {?} segmentGroup
     * @param {?} route
     * @param {?} segments
     * @return {?}
     */


    function match(segmentGroup, route, segments) {
      if (route.path === '') {
        if (route.pathMatch === 'full' && (segmentGroup.hasChildren() || segments.length > 0)) {
          return {
            matched: false,
            consumedSegments: [],
            lastChild: 0,
            positionalParamSegments: {}
          };
        }

        return {
          matched: true,
          consumedSegments: [],
          lastChild: 0,
          positionalParamSegments: {}
        };
      }
      /** @type {?} */


      var matcher = route.matcher || defaultUrlMatcher;
      /** @type {?} */

      var res = matcher(segments, segmentGroup, route);

      if (!res) {
        return {
          matched: false,
          consumedSegments:
          /** @type {?} */
          [],
          lastChild: 0,
          positionalParamSegments: {}
        };
      }

      return {
        matched: true,
        consumedSegments:
        /** @type {?} */
        res.consumed,
        lastChild:
        /** @type {?} */
        res.consumed.length,
        positionalParamSegments:
        /** @type {?} */
        res.posParams
      };
    }
    /**
     * @param {?} segmentGroup
     * @param {?} consumedSegments
     * @param {?} slicedSegments
     * @param {?} config
     * @return {?}
     */


    function split(segmentGroup, consumedSegments, slicedSegments, config) {
      if (slicedSegments.length > 0 && containsEmptyPathRedirectsWithNamedOutlets(segmentGroup, slicedSegments, config)) {
        /** @type {?} */
        var s = new UrlSegmentGroup(consumedSegments, createChildrenForEmptySegments(config, new UrlSegmentGroup(slicedSegments, segmentGroup.children)));
        return {
          segmentGroup: mergeTrivialChildren(s),
          slicedSegments: []
        };
      }

      if (slicedSegments.length === 0 && containsEmptyPathRedirects(segmentGroup, slicedSegments, config)) {
        /** @type {?} */
        var _s2 = new UrlSegmentGroup(segmentGroup.segments, addEmptySegmentsToChildrenIfNeeded(segmentGroup, slicedSegments, config, segmentGroup.children));

        return {
          segmentGroup: mergeTrivialChildren(_s2),
          slicedSegments: slicedSegments
        };
      }

      return {
        segmentGroup: segmentGroup,
        slicedSegments: slicedSegments
      };
    }
    /**
     * @param {?} s
     * @return {?}
     */


    function mergeTrivialChildren(s) {
      if (s.numberOfChildren === 1 && s.children[PRIMARY_OUTLET]) {
        /** @type {?} */
        var c = s.children[PRIMARY_OUTLET];
        return new UrlSegmentGroup(s.segments.concat(c.segments), c.children);
      }

      return s;
    }
    /**
     * @param {?} segmentGroup
     * @param {?} slicedSegments
     * @param {?} routes
     * @param {?} children
     * @return {?}
     */


    function addEmptySegmentsToChildrenIfNeeded(segmentGroup, slicedSegments, routes, children) {
      /** @type {?} */
      var res = {};

      var _iterator21 = _createForOfIteratorHelper(routes),
          _step21;

      try {
        for (_iterator21.s(); !(_step21 = _iterator21.n()).done;) {
          var r = _step21.value;

          if (isEmptyPathRedirect(segmentGroup, slicedSegments, r) && !children[getOutlet(r)]) {
            res[getOutlet(r)] = new UrlSegmentGroup([], {});
          }
        }
      } catch (err) {
        _iterator21.e(err);
      } finally {
        _iterator21.f();
      }

      return Object.assign(Object.assign({}, children), res);
    }
    /**
     * @param {?} routes
     * @param {?} primarySegmentGroup
     * @return {?}
     */


    function createChildrenForEmptySegments(routes, primarySegmentGroup) {
      /** @type {?} */
      var res = {};
      res[PRIMARY_OUTLET] = primarySegmentGroup;

      var _iterator22 = _createForOfIteratorHelper(routes),
          _step22;

      try {
        for (_iterator22.s(); !(_step22 = _iterator22.n()).done;) {
          var r = _step22.value;

          if (r.path === '' && getOutlet(r) !== PRIMARY_OUTLET) {
            res[getOutlet(r)] = new UrlSegmentGroup([], {});
          }
        }
      } catch (err) {
        _iterator22.e(err);
      } finally {
        _iterator22.f();
      }

      return res;
    }
    /**
     * @param {?} segmentGroup
     * @param {?} segments
     * @param {?} routes
     * @return {?}
     */


    function containsEmptyPathRedirectsWithNamedOutlets(segmentGroup, segments, routes) {
      return routes.some(
      /**
      * @param {?} r
      * @return {?}
      */
      function (r) {
        return isEmptyPathRedirect(segmentGroup, segments, r) && getOutlet(r) !== PRIMARY_OUTLET;
      });
    }
    /**
     * @param {?} segmentGroup
     * @param {?} segments
     * @param {?} routes
     * @return {?}
     */


    function containsEmptyPathRedirects(segmentGroup, segments, routes) {
      return routes.some(
      /**
      * @param {?} r
      * @return {?}
      */
      function (r) {
        return isEmptyPathRedirect(segmentGroup, segments, r);
      });
    }
    /**
     * @param {?} segmentGroup
     * @param {?} segments
     * @param {?} r
     * @return {?}
     */


    function isEmptyPathRedirect(segmentGroup, segments, r) {
      if ((segmentGroup.hasChildren() || segments.length > 0) && r.pathMatch === 'full') {
        return false;
      }

      return r.path === '' && r.redirectTo !== undefined;
    }
    /**
     * @param {?} route
     * @return {?}
     */


    function getOutlet(route) {
      return route.outlet || PRIMARY_OUTLET;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/operators/apply_redirects.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} moduleInjector
     * @param {?} configLoader
     * @param {?} urlSerializer
     * @param {?} config
     * @return {?}
     */


    function applyRedirects$1(moduleInjector, configLoader, urlSerializer, config) {
      return (
        /**
        * @param {?} source
        * @return {?}
        */
        function (source) {
          return source.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["switchMap"])(
          /**
          * @param {?} t
          * @return {?}
          */
          function (t) {
            return applyRedirects(moduleInjector, configLoader, urlSerializer, t.extractedUrl, config).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
            /**
            * @param {?} urlAfterRedirects
            * @return {?}
            */
            function (urlAfterRedirects) {
              return Object.assign(Object.assign({}, t), {
                urlAfterRedirects: urlAfterRedirects
              });
            }));
          }));
        }
      );
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/utils/preactivation.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var CanActivate =
    /**
     * @param {?} path
     */
    function CanActivate(path) {
      _classCallCheck(this, CanActivate);

      this.path = path;
      this.route = this.path[this.path.length - 1];
    };

    if (false) {}

    var CanDeactivate =
    /**
     * @param {?} component
     * @param {?} route
     */
    function CanDeactivate(component, route) {
      _classCallCheck(this, CanDeactivate);

      this.component = component;
      this.route = route;
    };

    if (false) {}
    /**
     * @param {?} future
     * @param {?} curr
     * @param {?} parentContexts
     * @return {?}
     */


    function getAllRouteGuards(future, curr, parentContexts) {
      /** @type {?} */
      var futureRoot = future._root;
      /** @type {?} */

      var currRoot = curr ? curr._root : null;
      return getChildRouteGuards(futureRoot, currRoot, parentContexts, [futureRoot.value]);
    }
    /**
     * @param {?} p
     * @return {?}
     */


    function getCanActivateChild(p) {
      /** @type {?} */
      var canActivateChild = p.routeConfig ? p.routeConfig.canActivateChild : null;
      if (!canActivateChild || canActivateChild.length === 0) return null;
      return {
        node: p,
        guards: canActivateChild
      };
    }
    /**
     * @param {?} token
     * @param {?} snapshot
     * @param {?} moduleInjector
     * @return {?}
     */


    function getToken(token, snapshot, moduleInjector) {
      /** @type {?} */
      var config = getClosestLoadedConfig(snapshot);
      /** @type {?} */

      var injector = config ? config.module.injector : moduleInjector;
      return injector.get(token);
    }
    /**
     * @param {?} snapshot
     * @return {?}
     */


    function getClosestLoadedConfig(snapshot) {
      if (!snapshot) return null;

      for (var s = snapshot.parent; s; s = s.parent) {
        /** @type {?} */
        var route = s.routeConfig;
        if (route && route._loadedConfig) return route._loadedConfig;
      }

      return null;
    }
    /**
     * @param {?} futureNode
     * @param {?} currNode
     * @param {?} contexts
     * @param {?} futurePath
     * @param {?=} checks
     * @return {?}
     */


    function getChildRouteGuards(futureNode, currNode, contexts, futurePath) {
      var checks = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : {
        canDeactivateChecks: [],
        canActivateChecks: []
      };

      /** @type {?} */
      var prevChildren = nodeChildrenAsMap(currNode); // Process the children of the future route

      futureNode.children.forEach(
      /**
      * @param {?} c
      * @return {?}
      */
      function (c) {
        getRouteGuards(c, prevChildren[c.value.outlet], contexts, futurePath.concat([c.value]), checks);
        delete prevChildren[c.value.outlet];
      }); // Process any children left from the current route (not active for the future route)

      forEach(prevChildren,
      /**
      * @param {?} v
      * @param {?} k
      * @return {?}
      */
      function (v, k) {
        return deactivateRouteAndItsChildren(v,
        /** @type {?} */
        contexts.getContext(k), checks);
      });
      return checks;
    }
    /**
     * @param {?} futureNode
     * @param {?} currNode
     * @param {?} parentContexts
     * @param {?} futurePath
     * @param {?=} checks
     * @return {?}
     */


    function getRouteGuards(futureNode, currNode, parentContexts, futurePath) {
      var checks = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : {
        canDeactivateChecks: [],
        canActivateChecks: []
      };

      /** @type {?} */
      var future = futureNode.value;
      /** @type {?} */

      var curr = currNode ? currNode.value : null;
      /** @type {?} */

      var context = parentContexts ? parentContexts.getContext(futureNode.value.outlet) : null; // reusing the node

      if (curr && future.routeConfig === curr.routeConfig) {
        /** @type {?} */
        var shouldRun = shouldRunGuardsAndResolvers(curr, future,
        /** @type {?} */
        future.routeConfig.runGuardsAndResolvers);

        if (shouldRun) {
          checks.canActivateChecks.push(new CanActivate(futurePath));
        } else {
          // we need to set the data
          future.data = curr.data;
          future._resolvedData = curr._resolvedData;
        } // If we have a component, we need to go through an outlet.


        if (future.component) {
          getChildRouteGuards(futureNode, currNode, context ? context.children : null, futurePath, checks); // if we have a componentless route, we recurse but keep the same outlet map.
        } else {
          getChildRouteGuards(futureNode, currNode, parentContexts, futurePath, checks);
        }

        if (shouldRun) {
          /** @type {?} */
          var component = context && context.outlet && context.outlet.component || null;
          checks.canDeactivateChecks.push(new CanDeactivate(component, curr));
        }
      } else {
        if (curr) {
          deactivateRouteAndItsChildren(currNode, context, checks);
        }

        checks.canActivateChecks.push(new CanActivate(futurePath)); // If we have a component, we need to go through an outlet.

        if (future.component) {
          getChildRouteGuards(futureNode, null, context ? context.children : null, futurePath, checks); // if we have a componentless route, we recurse but keep the same outlet map.
        } else {
          getChildRouteGuards(futureNode, null, parentContexts, futurePath, checks);
        }
      }

      return checks;
    }
    /**
     * @param {?} curr
     * @param {?} future
     * @param {?} mode
     * @return {?}
     */


    function shouldRunGuardsAndResolvers(curr, future, mode) {
      if (typeof mode === 'function') {
        return mode(curr, future);
      }

      switch (mode) {
        case 'pathParamsChange':
          return !equalPath(curr.url, future.url);

        case 'pathParamsOrQueryParamsChange':
          return !equalPath(curr.url, future.url) || !shallowEqual(curr.queryParams, future.queryParams);

        case 'always':
          return true;

        case 'paramsOrQueryParamsChange':
          return !equalParamsAndUrlSegments(curr, future) || !shallowEqual(curr.queryParams, future.queryParams);

        case 'paramsChange':
        default:
          return !equalParamsAndUrlSegments(curr, future);
      }
    }
    /**
     * @param {?} route
     * @param {?} context
     * @param {?} checks
     * @return {?}
     */


    function deactivateRouteAndItsChildren(route, context, checks) {
      /** @type {?} */
      var children = nodeChildrenAsMap(route);
      /** @type {?} */

      var r = route.value;
      forEach(children,
      /**
      * @param {?} node
      * @param {?} childName
      * @return {?}
      */
      function (node, childName) {
        if (!r.component) {
          deactivateRouteAndItsChildren(node, context, checks);
        } else if (context) {
          deactivateRouteAndItsChildren(node, context.children.getContext(childName), checks);
        } else {
          deactivateRouteAndItsChildren(node, null, checks);
        }
      });

      if (!r.component) {
        checks.canDeactivateChecks.push(new CanDeactivate(null, r));
      } else if (context && context.outlet && context.outlet.isActivated) {
        checks.canDeactivateChecks.push(new CanDeactivate(context.outlet.component, r));
      } else {
        checks.canDeactivateChecks.push(new CanDeactivate(null, r));
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/operators/prioritized_guard_value.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /** @type {?} */


    var INITIAL_VALUE = Symbol('INITIAL_VALUE');
    /**
     * @return {?}
     */

    function prioritizedGuardValue() {
      return Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["switchMap"])(
      /**
      * @param {?} obs
      * @return {?}
      */
      function (obs) {
        return (
          /** @type {?} */
          Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["combineLatest"]).apply(void 0, _toConsumableArray(obs.map(
          /**
          * @param {?} o
          * @return {?}
          */
          function (o) {
            return o.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["take"])(1), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["startWith"])(
            /** @type {?} */
            INITIAL_VALUE));
          }))).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["scan"])(
          /**
          * @param {?} acc
          * @param {?} list
          * @return {?}
          */
          function (acc, list) {
            /** @type {?} */
            var isPending = false;
            return list.reduce(
            /**
            * @param {?} innerAcc
            * @param {?} val
            * @param {?} i
            * @return {?}
            */
            function (innerAcc, val, i) {
              if (innerAcc !== INITIAL_VALUE) return innerAcc; // Toggle pending flag if any values haven't been set yet

              if (val === INITIAL_VALUE) isPending = true; // Any other return values are only valid if we haven't yet hit a pending
              // call. This guarantees that in the case of a guard at the bottom of the
              // tree that returns a redirect, we will wait for the higher priority
              // guard at the top to finish before performing the redirect.

              if (!isPending) {
                // Early return when we hit a `false` value as that should always
                // cancel navigation
                if (val === false) return val;

                if (i === list.length - 1 || isUrlTree(val)) {
                  return val;
                }
              }

              return innerAcc;
            }, acc);
          }, INITIAL_VALUE), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["filter"])(
          /**
          * @param {?} item
          * @return {?}
          */
          function (item) {
            return item !== INITIAL_VALUE;
          }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
          /**
          * @param {?} item
          * @return {?}
          */
          function (item) {
            return isUrlTree(item) ? item : item === true;
          }), //
          Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["take"])(1))
        );
      });
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/operators/check_guards.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} moduleInjector
     * @param {?=} forwardEvent
     * @return {?}
     */


    function checkGuards(moduleInjector, forwardEvent) {
      return (
        /**
        * @param {?} source
        * @return {?}
        */
        function (source) {
          return source.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["mergeMap"])(
          /**
          * @param {?} t
          * @return {?}
          */
          function (t) {
            var targetSnapshot = t.targetSnapshot,
                currentSnapshot = t.currentSnapshot,
                _t$guards = t.guards,
                canActivateChecks = _t$guards.canActivateChecks,
                canDeactivateChecks = _t$guards.canDeactivateChecks;

            if (canDeactivateChecks.length === 0 && canActivateChecks.length === 0) {
              return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(Object.assign(Object.assign({}, t), {
                guardsResult: true
              }));
            }

            return runCanDeactivateChecks(canDeactivateChecks,
            /** @type {?} */
            targetSnapshot, currentSnapshot, moduleInjector).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["mergeMap"])(
            /**
            * @param {?} canDeactivate
            * @return {?}
            */
            function (canDeactivate) {
              return canDeactivate && isBoolean(canDeactivate) ? runCanActivateChecks(
              /** @type {?} */
              targetSnapshot, canActivateChecks, moduleInjector, forwardEvent) : Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(canDeactivate);
            }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
            /**
            * @param {?} guardsResult
            * @return {?}
            */
            function (guardsResult) {
              return Object.assign(Object.assign({}, t), {
                guardsResult: guardsResult
              });
            }));
          }));
        }
      );
    }
    /**
     * @param {?} checks
     * @param {?} futureRSS
     * @param {?} currRSS
     * @param {?} moduleInjector
     * @return {?}
     */


    function runCanDeactivateChecks(checks, futureRSS, currRSS, moduleInjector) {
      return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["from"])(checks).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["mergeMap"])(
      /**
      * @param {?} check
      * @return {?}
      */
      function (check) {
        return runCanDeactivate(check.component, check.route, currRSS, futureRSS, moduleInjector);
      }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["first"])(
      /**
      * @param {?} result
      * @return {?}
      */
      function (result) {
        return result !== true;
      },
      /** @type {?} */
      true));
    }
    /**
     * @param {?} futureSnapshot
     * @param {?} checks
     * @param {?} moduleInjector
     * @param {?=} forwardEvent
     * @return {?}
     */


    function runCanActivateChecks(futureSnapshot, checks, moduleInjector, forwardEvent) {
      return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["from"])(checks).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["concatMap"])(
      /**
      * @param {?} check
      * @return {?}
      */
      function (check) {
        return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["from"])([fireChildActivationStart(check.route.parent, forwardEvent), fireActivationStart(check.route, forwardEvent), runCanActivateChild(futureSnapshot, check.path, moduleInjector), runCanActivate(futureSnapshot, check.route, moduleInjector)]).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["concatAll"])(), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["first"])(
        /**
        * @param {?} result
        * @return {?}
        */
        function (result) {
          return result !== true;
        },
        /** @type {?} */
        true));
      }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["first"])(
      /**
      * @param {?} result
      * @return {?}
      */
      function (result) {
        return result !== true;
      },
      /** @type {?} */
      true));
    }
    /**
     * This should fire off `ActivationStart` events for each route being activated at this
     * level.
     * In other words, if you're activating `a` and `b` below, `path` will contain the
     * `ActivatedRouteSnapshot`s for both and we will fire `ActivationStart` for both. Always
     * return
     * `true` so checks continue to run.
     * @param {?} snapshot
     * @param {?=} forwardEvent
     * @return {?}
     */


    function fireActivationStart(snapshot, forwardEvent) {
      if (snapshot !== null && forwardEvent) {
        forwardEvent(new ActivationStart(snapshot));
      }

      return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(true);
    }
    /**
     * This should fire off `ChildActivationStart` events for each route being activated at this
     * level.
     * In other words, if you're activating `a` and `b` below, `path` will contain the
     * `ActivatedRouteSnapshot`s for both and we will fire `ChildActivationStart` for both. Always
     * return
     * `true` so checks continue to run.
     * @param {?} snapshot
     * @param {?=} forwardEvent
     * @return {?}
     */


    function fireChildActivationStart(snapshot, forwardEvent) {
      if (snapshot !== null && forwardEvent) {
        forwardEvent(new ChildActivationStart(snapshot));
      }

      return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(true);
    }
    /**
     * @param {?} futureRSS
     * @param {?} futureARS
     * @param {?} moduleInjector
     * @return {?}
     */


    function runCanActivate(futureRSS, futureARS, moduleInjector) {
      /** @type {?} */
      var canActivate = futureARS.routeConfig ? futureARS.routeConfig.canActivate : null;
      if (!canActivate || canActivate.length === 0) return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(true);
      /** @type {?} */

      var canActivateObservables = canActivate.map(
      /**
      * @param {?} c
      * @return {?}
      */
      function (c) {
        return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["defer"])(
        /**
        * @return {?}
        */
        function () {
          /** @type {?} */
          var guard = getToken(c, futureARS, moduleInjector);
          /** @type {?} */

          var observable;

          if (isCanActivate(guard)) {
            observable = wrapIntoObservable(guard.canActivate(futureARS, futureRSS));
          } else if (isFunction(guard)) {
            observable = wrapIntoObservable(guard(futureARS, futureRSS));
          } else {
            throw new Error('Invalid CanActivate guard');
          }

          return observable.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["first"])());
        });
      });
      return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(canActivateObservables).pipe(prioritizedGuardValue());
    }
    /**
     * @param {?} futureRSS
     * @param {?} path
     * @param {?} moduleInjector
     * @return {?}
     */


    function runCanActivateChild(futureRSS, path, moduleInjector) {
      /** @type {?} */
      var futureARS = path[path.length - 1];
      /** @type {?} */

      var canActivateChildGuards = path.slice(0, path.length - 1).reverse().map(
      /**
      * @param {?} p
      * @return {?}
      */
      function (p) {
        return getCanActivateChild(p);
      }).filter(
      /**
      * @param {?} _
      * @return {?}
      */
      function (_) {
        return _ !== null;
      });
      /** @type {?} */

      var canActivateChildGuardsMapped = canActivateChildGuards.map(
      /**
      * @param {?} d
      * @return {?}
      */
      function (d) {
        return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["defer"])(
        /**
        * @return {?}
        */
        function () {
          /** @type {?} */
          var guardsMapped = d.guards.map(
          /**
          * @param {?} c
          * @return {?}
          */
          function (c) {
            /** @type {?} */
            var guard = getToken(c, d.node, moduleInjector);
            /** @type {?} */

            var observable;

            if (isCanActivateChild(guard)) {
              observable = wrapIntoObservable(guard.canActivateChild(futureARS, futureRSS));
            } else if (isFunction(guard)) {
              observable = wrapIntoObservable(guard(futureARS, futureRSS));
            } else {
              throw new Error('Invalid CanActivateChild guard');
            }

            return observable.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["first"])());
          });
          return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(guardsMapped).pipe(prioritizedGuardValue());
        });
      });
      return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(canActivateChildGuardsMapped).pipe(prioritizedGuardValue());
    }
    /**
     * @param {?} component
     * @param {?} currARS
     * @param {?} currRSS
     * @param {?} futureRSS
     * @param {?} moduleInjector
     * @return {?}
     */


    function runCanDeactivate(component, currARS, currRSS, futureRSS, moduleInjector) {
      /** @type {?} */
      var canDeactivate = currARS && currARS.routeConfig ? currARS.routeConfig.canDeactivate : null;
      if (!canDeactivate || canDeactivate.length === 0) return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(true);
      /** @type {?} */

      var canDeactivateObservables = canDeactivate.map(
      /**
      * @param {?} c
      * @return {?}
      */
      function (c) {
        /** @type {?} */
        var guard = getToken(c, currARS, moduleInjector);
        /** @type {?} */

        var observable;

        if (isCanDeactivate(guard)) {
          observable = wrapIntoObservable(guard.canDeactivate(
          /** @type {?} */
          component, currARS, currRSS, futureRSS));
        } else if (isFunction(guard)) {
          observable = wrapIntoObservable(guard(component, currARS, currRSS, futureRSS));
        } else {
          throw new Error('Invalid CanDeactivate guard');
        }

        return observable.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["first"])());
      });
      return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(canDeactivateObservables).pipe(prioritizedGuardValue());
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/recognize.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var NoMatch$1 = function NoMatch$1() {
      _classCallCheck(this, NoMatch$1);
    };
    /**
     * @param {?} rootComponentType
     * @param {?} config
     * @param {?} urlTree
     * @param {?} url
     * @param {?=} paramsInheritanceStrategy
     * @param {?=} relativeLinkResolution
     * @return {?}
     */


    function recognize(rootComponentType, config, urlTree, url) {
      var paramsInheritanceStrategy = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : 'emptyOnly';
      var relativeLinkResolution = arguments.length > 5 && arguments[5] !== undefined ? arguments[5] : 'legacy';
      return new Recognizer(rootComponentType, config, urlTree, url, paramsInheritanceStrategy, relativeLinkResolution).recognize();
    }

    var Recognizer = /*#__PURE__*/function () {
      /**
       * @param {?} rootComponentType
       * @param {?} config
       * @param {?} urlTree
       * @param {?} url
       * @param {?} paramsInheritanceStrategy
       * @param {?} relativeLinkResolution
       */
      function Recognizer(rootComponentType, config, urlTree, url, paramsInheritanceStrategy, relativeLinkResolution) {
        _classCallCheck(this, Recognizer);

        this.rootComponentType = rootComponentType;
        this.config = config;
        this.urlTree = urlTree;
        this.url = url;
        this.paramsInheritanceStrategy = paramsInheritanceStrategy;
        this.relativeLinkResolution = relativeLinkResolution;
      }
      /**
       * @return {?}
       */


      _createClass2(Recognizer, [{
        key: "recognize",
        value: function recognize() {
          try {
            /** @type {?} */
            var rootSegmentGroup = split$1(this.urlTree.root, [], [], this.config, this.relativeLinkResolution).segmentGroup;
            /** @type {?} */

            var children = this.processSegmentGroup(this.config, rootSegmentGroup, PRIMARY_OUTLET);
            /** @type {?} */

            var root = new ActivatedRouteSnapshot([], Object.freeze({}), Object.freeze(Object.assign({}, this.urlTree.queryParams)),
            /** @type {?} */
            this.urlTree.fragment, {}, PRIMARY_OUTLET, this.rootComponentType, null, this.urlTree.root, -1, {});
            /** @type {?} */

            var rootNode = new TreeNode(root, children);
            /** @type {?} */

            var routeState = new RouterStateSnapshot(this.url, rootNode);
            this.inheritParamsAndData(routeState._root);
            return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(routeState);
          } catch (e) {
            return new rxjs__WEBPACK_IMPORTED_MODULE_2__["Observable"](
            /**
            * @param {?} obs
            * @return {?}
            */
            function (obs) {
              return obs.error(e);
            });
          }
        }
        /**
         * @param {?} routeNode
         * @return {?}
         */

      }, {
        key: "inheritParamsAndData",
        value: function inheritParamsAndData(routeNode) {
          var _this297 = this;

          /** @type {?} */
          var route = routeNode.value;
          /** @type {?} */

          var i = inheritedParamsDataResolve(route, this.paramsInheritanceStrategy);
          route.params = Object.freeze(i.params);
          route.data = Object.freeze(i.data);
          routeNode.children.forEach(
          /**
          * @param {?} n
          * @return {?}
          */
          function (n) {
            return _this297.inheritParamsAndData(n);
          });
        }
        /**
         * @param {?} config
         * @param {?} segmentGroup
         * @param {?} outlet
         * @return {?}
         */

      }, {
        key: "processSegmentGroup",
        value: function processSegmentGroup(config, segmentGroup, outlet) {
          if (segmentGroup.segments.length === 0 && segmentGroup.hasChildren()) {
            return this.processChildren(config, segmentGroup);
          }

          return this.processSegment(config, segmentGroup, segmentGroup.segments, outlet);
        }
        /**
         * @param {?} config
         * @param {?} segmentGroup
         * @return {?}
         */

      }, {
        key: "processChildren",
        value: function processChildren(config, segmentGroup) {
          var _this298 = this;

          /** @type {?} */
          var children = mapChildrenIntoArray(segmentGroup,
          /**
          * @param {?} child
          * @param {?} childOutlet
          * @return {?}
          */
          function (child, childOutlet) {
            return _this298.processSegmentGroup(config, child, childOutlet);
          });
          checkOutletNameUniqueness(children);
          sortActivatedRouteSnapshots(children);
          return children;
        }
        /**
         * @param {?} config
         * @param {?} segmentGroup
         * @param {?} segments
         * @param {?} outlet
         * @return {?}
         */

      }, {
        key: "processSegment",
        value: function processSegment(config, segmentGroup, segments, outlet) {
          var _iterator23 = _createForOfIteratorHelper(config),
              _step23;

          try {
            for (_iterator23.s(); !(_step23 = _iterator23.n()).done;) {
              var r = _step23.value;

              try {
                return this.processSegmentAgainstRoute(r, segmentGroup, segments, outlet);
              } catch (e) {
                if (!(e instanceof NoMatch$1)) throw e;
              }
            }
          } catch (err) {
            _iterator23.e(err);
          } finally {
            _iterator23.f();
          }

          if (this.noLeftoversInUrl(segmentGroup, segments, outlet)) {
            return [];
          }

          throw new NoMatch$1();
        }
        /**
         * @private
         * @param {?} segmentGroup
         * @param {?} segments
         * @param {?} outlet
         * @return {?}
         */

      }, {
        key: "noLeftoversInUrl",
        value: function noLeftoversInUrl(segmentGroup, segments, outlet) {
          return segments.length === 0 && !segmentGroup.children[outlet];
        }
        /**
         * @param {?} route
         * @param {?} rawSegment
         * @param {?} segments
         * @param {?} outlet
         * @return {?}
         */

      }, {
        key: "processSegmentAgainstRoute",
        value: function processSegmentAgainstRoute(route, rawSegment, segments, outlet) {
          if (route.redirectTo) throw new NoMatch$1();
          if ((route.outlet || PRIMARY_OUTLET) !== outlet) throw new NoMatch$1();
          /** @type {?} */

          var snapshot;
          /** @type {?} */

          var consumedSegments = [];
          /** @type {?} */

          var rawSlicedSegments = [];

          if (route.path === '**') {
            /** @type {?} */
            var params = segments.length > 0 ?
            /** @type {?} */
            last(segments).parameters : {};
            snapshot = new ActivatedRouteSnapshot(segments, params, Object.freeze(Object.assign({}, this.urlTree.queryParams)),
            /** @type {?} */
            this.urlTree.fragment, getData(route), outlet,
            /** @type {?} */
            route.component, route, getSourceSegmentGroup(rawSegment), getPathIndexShift(rawSegment) + segments.length, getResolve(route));
          } else {
            /** @type {?} */
            var result = match$1(rawSegment, route, segments);
            consumedSegments = result.consumedSegments;
            rawSlicedSegments = segments.slice(result.lastChild);
            snapshot = new ActivatedRouteSnapshot(consumedSegments, result.parameters, Object.freeze(Object.assign({}, this.urlTree.queryParams)),
            /** @type {?} */
            this.urlTree.fragment, getData(route), outlet,
            /** @type {?} */
            route.component, route, getSourceSegmentGroup(rawSegment), getPathIndexShift(rawSegment) + consumedSegments.length, getResolve(route));
          }
          /** @type {?} */


          var childConfig = getChildConfig(route);

          var _split$ = split$1(rawSegment, consumedSegments, rawSlicedSegments, childConfig, this.relativeLinkResolution),
              segmentGroup = _split$.segmentGroup,
              slicedSegments = _split$.slicedSegments;

          if (slicedSegments.length === 0 && segmentGroup.hasChildren()) {
            /** @type {?} */
            var _children3 = this.processChildren(childConfig, segmentGroup);

            return [new TreeNode(snapshot, _children3)];
          }

          if (childConfig.length === 0 && slicedSegments.length === 0) {
            return [new TreeNode(snapshot, [])];
          }
          /** @type {?} */


          var children = this.processSegment(childConfig, segmentGroup, slicedSegments, PRIMARY_OUTLET);
          return [new TreeNode(snapshot, children)];
        }
      }]);

      return Recognizer;
    }();

    if (false) {}
    /**
     * @param {?} nodes
     * @return {?}
     */


    function sortActivatedRouteSnapshots(nodes) {
      nodes.sort(
      /**
      * @param {?} a
      * @param {?} b
      * @return {?}
      */
      function (a, b) {
        if (a.value.outlet === PRIMARY_OUTLET) return -1;
        if (b.value.outlet === PRIMARY_OUTLET) return 1;
        return a.value.outlet.localeCompare(b.value.outlet);
      });
    }
    /**
     * @param {?} route
     * @return {?}
     */


    function getChildConfig(route) {
      if (route.children) {
        return route.children;
      }

      if (route.loadChildren) {
        return (
          /** @type {?} */
          route._loadedConfig.routes
        );
      }

      return [];
    }
    /**
     * @record
     */


    function MatchResult() {}

    if (false) {}
    /**
     * @param {?} segmentGroup
     * @param {?} route
     * @param {?} segments
     * @return {?}
     */


    function match$1(segmentGroup, route, segments) {
      if (route.path === '') {
        if (route.pathMatch === 'full' && (segmentGroup.hasChildren() || segments.length > 0)) {
          throw new NoMatch$1();
        }

        return {
          consumedSegments: [],
          lastChild: 0,
          parameters: {}
        };
      }
      /** @type {?} */


      var matcher = route.matcher || defaultUrlMatcher;
      /** @type {?} */

      var res = matcher(segments, segmentGroup, route);
      if (!res) throw new NoMatch$1();
      /** @type {?} */

      var posParams = {};
      forEach(
      /** @type {?} */
      res.posParams,
      /**
      * @param {?} v
      * @param {?} k
      * @return {?}
      */
      function (v, k) {
        posParams[k] = v.path;
      });
      /** @type {?} */

      var parameters = res.consumed.length > 0 ? Object.assign(Object.assign({}, posParams), res.consumed[res.consumed.length - 1].parameters) : posParams;
      return {
        consumedSegments: res.consumed,
        lastChild: res.consumed.length,
        parameters: parameters
      };
    }
    /**
     * @param {?} nodes
     * @return {?}
     */


    function checkOutletNameUniqueness(nodes) {
      /** @type {?} */
      var names = {};
      nodes.forEach(
      /**
      * @param {?} n
      * @return {?}
      */
      function (n) {
        /** @type {?} */
        var routeWithSameOutletName = names[n.value.outlet];

        if (routeWithSameOutletName) {
          /** @type {?} */
          var p = routeWithSameOutletName.url.map(
          /**
          * @param {?} s
          * @return {?}
          */
          function (s) {
            return s.toString();
          }).join('/');
          /** @type {?} */

          var c = n.value.url.map(
          /**
          * @param {?} s
          * @return {?}
          */
          function (s) {
            return s.toString();
          }).join('/');
          throw new Error("Two segments cannot have the same outlet name: '".concat(p, "' and '").concat(c, "'."));
        }

        names[n.value.outlet] = n.value;
      });
    }
    /**
     * @param {?} segmentGroup
     * @return {?}
     */


    function getSourceSegmentGroup(segmentGroup) {
      /** @type {?} */
      var s = segmentGroup;

      while (s._sourceSegment) {
        s = s._sourceSegment;
      }

      return s;
    }
    /**
     * @param {?} segmentGroup
     * @return {?}
     */


    function getPathIndexShift(segmentGroup) {
      /** @type {?} */
      var s = segmentGroup;
      /** @type {?} */

      var res = s._segmentIndexShift ? s._segmentIndexShift : 0;

      while (s._sourceSegment) {
        s = s._sourceSegment;
        res += s._segmentIndexShift ? s._segmentIndexShift : 0;
      }

      return res - 1;
    }
    /**
     * @param {?} segmentGroup
     * @param {?} consumedSegments
     * @param {?} slicedSegments
     * @param {?} config
     * @param {?} relativeLinkResolution
     * @return {?}
     */


    function split$1(segmentGroup, consumedSegments, slicedSegments, config, relativeLinkResolution) {
      if (slicedSegments.length > 0 && containsEmptyPathMatchesWithNamedOutlets(segmentGroup, slicedSegments, config)) {
        /** @type {?} */
        var _s3 = new UrlSegmentGroup(consumedSegments, createChildrenForEmptyPaths(segmentGroup, consumedSegments, config, new UrlSegmentGroup(slicedSegments, segmentGroup.children)));

        _s3._sourceSegment = segmentGroup;
        _s3._segmentIndexShift = consumedSegments.length;
        return {
          segmentGroup: _s3,
          slicedSegments: []
        };
      }

      if (slicedSegments.length === 0 && containsEmptyPathMatches(segmentGroup, slicedSegments, config)) {
        /** @type {?} */
        var _s4 = new UrlSegmentGroup(segmentGroup.segments, addEmptyPathsToChildrenIfNeeded(segmentGroup, consumedSegments, slicedSegments, config, segmentGroup.children, relativeLinkResolution));

        _s4._sourceSegment = segmentGroup;
        _s4._segmentIndexShift = consumedSegments.length;
        return {
          segmentGroup: _s4,
          slicedSegments: slicedSegments
        };
      }
      /** @type {?} */


      var s = new UrlSegmentGroup(segmentGroup.segments, segmentGroup.children);
      s._sourceSegment = segmentGroup;
      s._segmentIndexShift = consumedSegments.length;
      return {
        segmentGroup: s,
        slicedSegments: slicedSegments
      };
    }
    /**
     * @param {?} segmentGroup
     * @param {?} consumedSegments
     * @param {?} slicedSegments
     * @param {?} routes
     * @param {?} children
     * @param {?} relativeLinkResolution
     * @return {?}
     */


    function addEmptyPathsToChildrenIfNeeded(segmentGroup, consumedSegments, slicedSegments, routes, children, relativeLinkResolution) {
      /** @type {?} */
      var res = {};

      var _iterator24 = _createForOfIteratorHelper(routes),
          _step24;

      try {
        for (_iterator24.s(); !(_step24 = _iterator24.n()).done;) {
          var r = _step24.value;

          if (emptyPathMatch(segmentGroup, slicedSegments, r) && !children[getOutlet$1(r)]) {
            /** @type {?} */
            var s = new UrlSegmentGroup([], {});
            s._sourceSegment = segmentGroup;

            if (relativeLinkResolution === 'legacy') {
              s._segmentIndexShift = segmentGroup.segments.length;
            } else {
              s._segmentIndexShift = consumedSegments.length;
            }

            res[getOutlet$1(r)] = s;
          }
        }
      } catch (err) {
        _iterator24.e(err);
      } finally {
        _iterator24.f();
      }

      return Object.assign(Object.assign({}, children), res);
    }
    /**
     * @param {?} segmentGroup
     * @param {?} consumedSegments
     * @param {?} routes
     * @param {?} primarySegment
     * @return {?}
     */


    function createChildrenForEmptyPaths(segmentGroup, consumedSegments, routes, primarySegment) {
      /** @type {?} */
      var res = {};
      res[PRIMARY_OUTLET] = primarySegment;
      primarySegment._sourceSegment = segmentGroup;
      primarySegment._segmentIndexShift = consumedSegments.length;

      var _iterator25 = _createForOfIteratorHelper(routes),
          _step25;

      try {
        for (_iterator25.s(); !(_step25 = _iterator25.n()).done;) {
          var r = _step25.value;

          if (r.path === '' && getOutlet$1(r) !== PRIMARY_OUTLET) {
            /** @type {?} */
            var s = new UrlSegmentGroup([], {});
            s._sourceSegment = segmentGroup;
            s._segmentIndexShift = consumedSegments.length;
            res[getOutlet$1(r)] = s;
          }
        }
      } catch (err) {
        _iterator25.e(err);
      } finally {
        _iterator25.f();
      }

      return res;
    }
    /**
     * @param {?} segmentGroup
     * @param {?} slicedSegments
     * @param {?} routes
     * @return {?}
     */


    function containsEmptyPathMatchesWithNamedOutlets(segmentGroup, slicedSegments, routes) {
      return routes.some(
      /**
      * @param {?} r
      * @return {?}
      */
      function (r) {
        return emptyPathMatch(segmentGroup, slicedSegments, r) && getOutlet$1(r) !== PRIMARY_OUTLET;
      });
    }
    /**
     * @param {?} segmentGroup
     * @param {?} slicedSegments
     * @param {?} routes
     * @return {?}
     */


    function containsEmptyPathMatches(segmentGroup, slicedSegments, routes) {
      return routes.some(
      /**
      * @param {?} r
      * @return {?}
      */
      function (r) {
        return emptyPathMatch(segmentGroup, slicedSegments, r);
      });
    }
    /**
     * @param {?} segmentGroup
     * @param {?} slicedSegments
     * @param {?} r
     * @return {?}
     */


    function emptyPathMatch(segmentGroup, slicedSegments, r) {
      if ((segmentGroup.hasChildren() || slicedSegments.length > 0) && r.pathMatch === 'full') {
        return false;
      }

      return r.path === '' && r.redirectTo === undefined;
    }
    /**
     * @param {?} route
     * @return {?}
     */


    function getOutlet$1(route) {
      return route.outlet || PRIMARY_OUTLET;
    }
    /**
     * @param {?} route
     * @return {?}
     */


    function getData(route) {
      return route.data || {};
    }
    /**
     * @param {?} route
     * @return {?}
     */


    function getResolve(route) {
      return route.resolve || {};
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/operators/recognize.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} rootComponentType
     * @param {?} config
     * @param {?} serializer
     * @param {?} paramsInheritanceStrategy
     * @param {?} relativeLinkResolution
     * @return {?}
     */


    function recognize$1(rootComponentType, config, serializer, paramsInheritanceStrategy, relativeLinkResolution) {
      return (
        /**
        * @param {?} source
        * @return {?}
        */
        function (source) {
          return source.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["mergeMap"])(
          /**
          * @param {?} t
          * @return {?}
          */
          function (t) {
            return recognize(rootComponentType, config, t.urlAfterRedirects, serializer(t.urlAfterRedirects), paramsInheritanceStrategy, relativeLinkResolution).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
            /**
            * @param {?} targetSnapshot
            * @return {?}
            */
            function (targetSnapshot) {
              return Object.assign(Object.assign({}, t), {
                targetSnapshot: targetSnapshot
              });
            }));
          }));
        }
      );
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/operators/resolve_data.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @param {?} paramsInheritanceStrategy
     * @param {?} moduleInjector
     * @return {?}
     */


    function resolveData(paramsInheritanceStrategy, moduleInjector) {
      return (
        /**
        * @param {?} source
        * @return {?}
        */
        function (source) {
          return source.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["mergeMap"])(
          /**
          * @param {?} t
          * @return {?}
          */
          function (t) {
            var targetSnapshot = t.targetSnapshot,
                canActivateChecks = t.guards.canActivateChecks;

            if (!canActivateChecks.length) {
              return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(t);
            }

            return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["from"])(canActivateChecks).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["concatMap"])(
            /**
            * @param {?} check
            * @return {?}
            */
            function (check) {
              return runResolve(check.route,
              /** @type {?} */
              targetSnapshot, paramsInheritanceStrategy, moduleInjector);
            }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["reduce"])(
            /**
            * @param {?} _
            * @param {?} __
            * @return {?}
            */
            function (_, __) {
              return _;
            }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
            /**
            * @param {?} _
            * @return {?}
            */
            function (_) {
              return t;
            }));
          }));
        }
      );
    }
    /**
     * @param {?} futureARS
     * @param {?} futureRSS
     * @param {?} paramsInheritanceStrategy
     * @param {?} moduleInjector
     * @return {?}
     */


    function runResolve(futureARS, futureRSS, paramsInheritanceStrategy, moduleInjector) {
      /** @type {?} */
      var resolve = futureARS._resolve;
      return resolveNode(resolve, futureARS, futureRSS, moduleInjector).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
      /**
      * @param {?} resolvedData
      * @return {?}
      */
      function (resolvedData) {
        futureARS._resolvedData = resolvedData;
        futureARS.data = Object.assign(Object.assign({}, futureARS.data), inheritedParamsDataResolve(futureARS, paramsInheritanceStrategy).resolve);
        return null;
      }));
    }
    /**
     * @param {?} resolve
     * @param {?} futureARS
     * @param {?} futureRSS
     * @param {?} moduleInjector
     * @return {?}
     */


    function resolveNode(resolve, futureARS, futureRSS, moduleInjector) {
      /** @type {?} */
      var keys = Object.keys(resolve);

      if (keys.length === 0) {
        return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])({});
      }

      if (keys.length === 1) {
        /** @type {?} */
        var key = keys[0];
        return getResolver(resolve[key], futureARS, futureRSS, moduleInjector).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
        /**
        * @param {?} value
        * @return {?}
        */
        function (value) {
          return _defineProperty({}, key, value);
        }));
      }
      /** @type {?} */


      var data = {};
      /** @type {?} */

      var runningResolvers$ = Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["from"])(keys).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["mergeMap"])(
      /**
      * @param {?} key
      * @return {?}
      */
      function (key) {
        return getResolver(resolve[key], futureARS, futureRSS, moduleInjector).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
        /**
        * @param {?} value
        * @return {?}
        */
        function (value) {
          data[key] = value;
          return value;
        }));
      }));
      return runningResolvers$.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["last"])(), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
      /**
      * @return {?}
      */
      function () {
        return data;
      }));
    }
    /**
     * @param {?} injectionToken
     * @param {?} futureARS
     * @param {?} futureRSS
     * @param {?} moduleInjector
     * @return {?}
     */


    function getResolver(injectionToken, futureARS, futureRSS, moduleInjector) {
      /** @type {?} */
      var resolver = getToken(injectionToken, futureARS, moduleInjector);
      return resolver.resolve ? wrapIntoObservable(resolver.resolve(futureARS, futureRSS)) : wrapIntoObservable(resolver(futureARS, futureRSS));
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/operators/switch_tap.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Perform a side effect through a switchMap for every emission on the source Observable,
     * but return an Observable that is identical to the source. It's essentially the same as
     * the `tap` operator, but if the side effectful `next` function returns an ObservableInput,
     * it will wait before continuing with the original value.
     * @template T
     * @param {?} next
     * @return {?}
     */


    function switchTap(next) {
      return (
        /**
        * @param {?} source
        * @return {?}
        */
        function (source) {
          return source.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["switchMap"])(
          /**
          * @param {?} v
          * @return {?}
          */
          function (v) {
            /** @type {?} */
            var nextResult = next(v);

            if (nextResult) {
              return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["from"])(nextResult).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
              /**
              * @return {?}
              */
              function () {
                return v;
              }));
            }

            return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["from"])([v]);
          }));
        }
      );
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/route_reuse_strategy.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * \@description
     *
     * Provides a way to customize when activated routes get reused.
     *
     * \@publicApi
     * @abstract
     */


    var RouteReuseStrategy = function RouteReuseStrategy() {
      _classCallCheck(this, RouteReuseStrategy);
    };

    if (false) {}
    /**
     * Does not detach any subtrees. Reuses routes as long as their route config is the same.
     */


    var DefaultRouteReuseStrategy = /*#__PURE__*/function () {
      function DefaultRouteReuseStrategy() {
        _classCallCheck(this, DefaultRouteReuseStrategy);
      }

      _createClass2(DefaultRouteReuseStrategy, [{
        key: "shouldDetach",

        /**
         * @param {?} route
         * @return {?}
         */
        value: function shouldDetach(route) {
          return false;
        }
        /**
         * @param {?} route
         * @param {?} detachedTree
         * @return {?}
         */

      }, {
        key: "store",
        value: function store(route, detachedTree) {}
        /**
         * @param {?} route
         * @return {?}
         */

      }, {
        key: "shouldAttach",
        value: function shouldAttach(route) {
          return false;
        }
        /**
         * @param {?} route
         * @return {?}
         */

      }, {
        key: "retrieve",
        value: function retrieve(route) {
          return null;
        }
        /**
         * @param {?} future
         * @param {?} curr
         * @return {?}
         */

      }, {
        key: "shouldReuseRoute",
        value: function shouldReuseRoute(future, curr) {
          return future.routeConfig === curr.routeConfig;
        }
      }]);

      return DefaultRouteReuseStrategy;
    }();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/router_config_loader.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * The [DI token](guide/glossary/#di-token) for a router configuration.
     * @see `ROUTES`
     * \@publicApi
     * @type {?}
     */


    var ROUTES = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["InjectionToken"]('ROUTES');

    var RouterConfigLoader = /*#__PURE__*/function () {
      /**
       * @param {?} loader
       * @param {?} compiler
       * @param {?=} onLoadStartListener
       * @param {?=} onLoadEndListener
       */
      function RouterConfigLoader(loader, compiler, onLoadStartListener, onLoadEndListener) {
        _classCallCheck(this, RouterConfigLoader);

        this.loader = loader;
        this.compiler = compiler;
        this.onLoadStartListener = onLoadStartListener;
        this.onLoadEndListener = onLoadEndListener;
      }
      /**
       * @param {?} parentInjector
       * @param {?} route
       * @return {?}
       */


      _createClass2(RouterConfigLoader, [{
        key: "load",
        value: function load(parentInjector, route) {
          var _this299 = this;

          if (this.onLoadStartListener) {
            this.onLoadStartListener(route);
          }
          /** @type {?} */


          var moduleFactory$ = this.loadModuleFactory(
          /** @type {?} */
          route.loadChildren);
          return moduleFactory$.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
          /**
          * @param {?} factory
          * @return {?}
          */
          function (factory) {
            if (_this299.onLoadEndListener) {
              _this299.onLoadEndListener(route);
            }
            /** @type {?} */


            var module = factory.create(parentInjector);
            return new LoadedRouterConfig(flatten(module.injector.get(ROUTES)).map(standardizeConfig), module);
          }));
        }
        /**
         * @private
         * @param {?} loadChildren
         * @return {?}
         */

      }, {
        key: "loadModuleFactory",
        value: function loadModuleFactory(loadChildren) {
          var _this300 = this;

          if (typeof loadChildren === 'string') {
            return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["from"])(this.loader.load(loadChildren));
          } else {
            return wrapIntoObservable(loadChildren()).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["mergeMap"])(
            /**
            * @param {?} t
            * @return {?}
            */
            function (t) {
              if (t instanceof _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModuleFactory"]) {
                return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(t);
              } else {
                return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["from"])(_this300.compiler.compileModuleAsync(t));
              }
            }));
          }
        }
      }]);

      return RouterConfigLoader;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/url_handling_strategy.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * \@description
     *
     * Provides a way to migrate AngularJS applications to Angular.
     *
     * \@publicApi
     * @abstract
     */


    var UrlHandlingStrategy = function UrlHandlingStrategy() {
      _classCallCheck(this, UrlHandlingStrategy);
    };

    if (false) {}
    /**
     * \@publicApi
     */


    var DefaultUrlHandlingStrategy = /*#__PURE__*/function () {
      function DefaultUrlHandlingStrategy() {
        _classCallCheck(this, DefaultUrlHandlingStrategy);
      }

      _createClass2(DefaultUrlHandlingStrategy, [{
        key: "shouldProcessUrl",

        /**
         * @param {?} url
         * @return {?}
         */
        value: function shouldProcessUrl(url) {
          return true;
        }
        /**
         * @param {?} url
         * @return {?}
         */

      }, {
        key: "extract",
        value: function extract(url) {
          return url;
        }
        /**
         * @param {?} newUrlPart
         * @param {?} wholeUrl
         * @return {?}
         */

      }, {
        key: "merge",
        value: function merge(newUrlPart, wholeUrl) {
          return newUrlPart;
        }
      }]);

      return DefaultUrlHandlingStrategy;
    }();
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/router.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@description
     *
     * Options that modify the navigation strategy.
     *
     * \@publicApi
     * @record
     */


    function NavigationExtras() {}

    if (false) {}
    /**
     * @param {?} error
     * @return {?}
     */


    function defaultErrorHandler(error) {
      throw error;
    }
    /**
     * @param {?} error
     * @param {?} urlSerializer
     * @param {?} url
     * @return {?}
     */


    function defaultMalformedUriErrorHandler(error, urlSerializer, url) {
      return urlSerializer.parse('/');
    }
    /**
     * \@internal
     * @param {?} snapshot
     * @param {?} runExtras
     * @return {?}
     */


    function defaultRouterHook(snapshot, runExtras) {
      return (
        /** @type {?} */
        Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(null)
      );
    }
    /**
     * \@description
     *
     * A service that provides navigation and URL manipulation capabilities.
     *
     * @see `Route`.
     * @see [Routing and Navigation Guide](guide/router).
     *
     * \@ngModule RouterModule
     *
     * \@publicApi
     */


    var Router = /*#__PURE__*/function () {
      /**
       * Creates the router service.
       * @param {?} rootComponentType
       * @param {?} urlSerializer
       * @param {?} rootContexts
       * @param {?} location
       * @param {?} injector
       * @param {?} loader
       * @param {?} compiler
       * @param {?} config
       */
      // TODO: vsavkin make internal after the final is out.
      function Router(rootComponentType, urlSerializer, rootContexts, location, injector, loader, compiler, config) {
        var _this301 = this;

        _classCallCheck(this, Router);

        this.rootComponentType = rootComponentType;
        this.urlSerializer = urlSerializer;
        this.rootContexts = rootContexts;
        this.location = location;
        this.config = config;
        this.lastSuccessfulNavigation = null;
        this.currentNavigation = null;
        this.navigationId = 0;
        this.isNgZoneEnabled = false;
        /**
         * An event stream for routing events in this NgModule.
         */

        this.events = new rxjs__WEBPACK_IMPORTED_MODULE_2__["Subject"]();
        /**
         * A handler for navigation errors in this NgModule.
         */

        this.errorHandler = defaultErrorHandler;
        /**
         * A handler for errors thrown by `Router.parseUrl(url)`
         * when `url` contains an invalid character.
         * The most common case is a `%` sign
         * that's not encoded and is not part of a percent encoded sequence.
         */

        this.malformedUriErrorHandler = defaultMalformedUriErrorHandler;
        /**
         * True if at least one navigation event has occurred,
         * false otherwise.
         */

        this.navigated = false;
        this.lastSuccessfulId = -1;
        /**
         * Hooks that enable you to pause navigation,
         * either before or after the preactivation phase.
         * Used by `RouterModule`.
         *
         * \@internal
         */

        this.hooks = {
          beforePreactivation: defaultRouterHook,
          afterPreactivation: defaultRouterHook
        };
        /**
         * A strategy for extracting and merging URLs.
         * Used for AngularJS to Angular migrations.
         */

        this.urlHandlingStrategy = new DefaultUrlHandlingStrategy();
        /**
         * A strategy for re-using routes.
         */

        this.routeReuseStrategy = new DefaultRouteReuseStrategy();
        /**
         * How to handle a navigation request to the current URL. One of:
         * - `'ignore'` :  The router ignores the request.
         * - `'reload'` : The router reloads the URL. Use to implement a "refresh" feature.
         */

        this.onSameUrlNavigation = 'ignore';
        /**
         * How to merge parameters, data, and resolved data from parent to child
         * routes. One of:
         *
         * - `'emptyOnly'` : Inherit parent parameters, data, and resolved data
         * for path-less or component-less routes.
         * - `'always'` : Inherit parent parameters, data, and resolved data
         * for all child routes.
         */

        this.paramsInheritanceStrategy = 'emptyOnly';
        /**
         * Determines when the router updates the browser URL.
         * By default (`"deferred"`), updates the browser URL after navigation has finished.
         * Set to `'eager'` to update the browser URL at the beginning of navigation.
         * You can choose to update early so that, if navigation fails,
         * you can show an error message with the URL that failed.
         */

        this.urlUpdateStrategy = 'deferred';
        /**
         * Enables a bug fix that corrects relative link resolution in components with empty paths.
         * @see `RouterModule`
         */

        this.relativeLinkResolution = 'legacy';
        /** @type {?} */

        var onLoadStart =
        /**
        * @param {?} r
        * @return {?}
        */
        function onLoadStart(r) {
          return _this301.triggerEvent(new RouteConfigLoadStart(r));
        };
        /** @type {?} */


        var onLoadEnd =
        /**
        * @param {?} r
        * @return {?}
        */
        function onLoadEnd(r) {
          return _this301.triggerEvent(new RouteConfigLoadEnd(r));
        };

        this.ngModule = injector.get(_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModuleRef"]);
        this.console = injector.get(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵConsole"]);
        /** @type {?} */

        var ngZone = injector.get(_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]);
        this.isNgZoneEnabled = ngZone instanceof _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"];
        this.resetConfig(config);
        this.currentUrlTree = createEmptyUrlTree();
        this.rawUrlTree = this.currentUrlTree;
        this.browserUrlTree = this.currentUrlTree;
        this.configLoader = new RouterConfigLoader(loader, compiler, onLoadStart, onLoadEnd);
        this.routerState = createEmptyState(this.currentUrlTree, this.rootComponentType);
        this.transitions = new rxjs__WEBPACK_IMPORTED_MODULE_2__["BehaviorSubject"]({
          id: 0,
          currentUrlTree: this.currentUrlTree,
          currentRawUrl: this.currentUrlTree,
          extractedUrl: this.urlHandlingStrategy.extract(this.currentUrlTree),
          urlAfterRedirects: this.urlHandlingStrategy.extract(this.currentUrlTree),
          rawUrl: this.currentUrlTree,
          extras: {},
          resolve: null,
          reject: null,
          promise: Promise.resolve(true),
          source: 'imperative',
          restoredState: null,
          currentSnapshot: this.routerState.snapshot,
          targetSnapshot: null,
          currentRouterState: this.routerState,
          targetRouterState: null,
          guards: {
            canActivateChecks: [],
            canDeactivateChecks: []
          },
          guardsResult: null
        });
        this.navigations = this.setupNavigations(this.transitions);
        this.processNavigations();
      }
      /**
       * @private
       * @param {?} transitions
       * @return {?}
       */


      _createClass2(Router, [{
        key: "setupNavigations",
        value: function setupNavigations(transitions) {
          var _this302 = this;

          /** @type {?} */
          var eventsSubject =
          /** @type {?} */
          this.events;
          return (
            /** @type {?} */

            /** @type {?} */
            transitions.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["filter"])(
            /**
            * @param {?} t
            * @return {?}
            */
            function (t) {
              return t.id !== 0;
            }), // Extract URL
            Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
            /**
            * @param {?} t
            * @return {?}
            */
            function (t) {
              return (
                /** @type {?} */
                Object.assign(Object.assign({}, t), {
                  extractedUrl: _this302.urlHandlingStrategy.extract(t.rawUrl)
                })
              );
            }), // Using switchMap so we cancel executing navigations when a new one comes in
            Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["switchMap"])(
            /**
            * @param {?} t
            * @return {?}
            */
            function (t) {
              /** @type {?} */
              var completed = false;
              /** @type {?} */

              var errored = false;
              return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(t).pipe( // Store the Navigation object
              Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["tap"])(
              /**
              * @param {?} t
              * @return {?}
              */
              function (t) {
                _this302.currentNavigation = {
                  id: t.id,
                  initialUrl: t.currentRawUrl,
                  extractedUrl: t.extractedUrl,
                  trigger: t.source,
                  extras: t.extras,
                  previousNavigation: _this302.lastSuccessfulNavigation ? Object.assign(Object.assign({}, _this302.lastSuccessfulNavigation), {
                    previousNavigation: null
                  }) : null
                };
              }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["switchMap"])(
              /**
              * @param {?} t
              * @return {?}
              */
              function (t) {
                /** @type {?} */
                var urlTransition = !_this302.navigated || t.extractedUrl.toString() !== _this302.browserUrlTree.toString();
                /** @type {?} */


                var processCurrentUrl = (_this302.onSameUrlNavigation === 'reload' ? true : urlTransition) && _this302.urlHandlingStrategy.shouldProcessUrl(t.rawUrl);

                if (processCurrentUrl) {
                  return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(t).pipe( // Fire NavigationStart event
                  Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["switchMap"])(
                  /**
                  * @param {?} t
                  * @return {?}
                  */
                  function (t) {
                    /** @type {?} */
                    var transition = _this302.transitions.getValue();

                    eventsSubject.next(new NavigationStart(t.id, _this302.serializeUrl(t.extractedUrl), t.source, t.restoredState));

                    if (transition !== _this302.transitions.getValue()) {
                      return rxjs__WEBPACK_IMPORTED_MODULE_2__["EMPTY"];
                    }

                    return [t];
                  }), // This delay is required to match old behavior that forced navigation
                  // to always be async
                  Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["switchMap"])(
                  /**
                  * @param {?} t
                  * @return {?}
                  */
                  function (t) {
                    return Promise.resolve(t);
                  }), // ApplyRedirects
                  applyRedirects$1(_this302.ngModule.injector, _this302.configLoader, _this302.urlSerializer, _this302.config), // Update the currentNavigation
                  Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["tap"])(
                  /**
                  * @param {?} t
                  * @return {?}
                  */
                  function (t) {
                    _this302.currentNavigation = Object.assign(Object.assign({},
                    /** @type {?} */
                    _this302.currentNavigation), {
                      finalUrl: t.urlAfterRedirects
                    });
                  }), // Recognize
                  recognize$1(_this302.rootComponentType, _this302.config,
                  /**
                  * @param {?} url
                  * @return {?}
                  */
                  function (url) {
                    return _this302.serializeUrl(url);
                  }, _this302.paramsInheritanceStrategy, _this302.relativeLinkResolution), // Update URL if in `eager` update mode
                  Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["tap"])(
                  /**
                  * @param {?} t
                  * @return {?}
                  */
                  function (t) {
                    if (_this302.urlUpdateStrategy === 'eager') {
                      if (!t.extras.skipLocationChange) {
                        _this302.setBrowserUrl(t.urlAfterRedirects, !!t.extras.replaceUrl, t.id, t.extras.state);
                      }

                      _this302.browserUrlTree = t.urlAfterRedirects;
                    }
                  }), // Fire RoutesRecognized
                  Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["tap"])(
                  /**
                  * @param {?} t
                  * @return {?}
                  */
                  function (t) {
                    /** @type {?} */
                    var routesRecognized = new RoutesRecognized(t.id, _this302.serializeUrl(t.extractedUrl), _this302.serializeUrl(t.urlAfterRedirects),
                    /** @type {?} */
                    t.targetSnapshot);
                    eventsSubject.next(routesRecognized);
                  }));
                } else {
                  /** @type {?} */
                  var processPreviousUrl = urlTransition && _this302.rawUrlTree && _this302.urlHandlingStrategy.shouldProcessUrl(_this302.rawUrlTree);
                  /* When the current URL shouldn't be processed, but the previous one was,
                   * we handle this "error condition" by navigating to the previously
                   * successful URL, but leaving the URL intact.*/


                  if (processPreviousUrl) {
                    var id = t.id,
                        extractedUrl = t.extractedUrl,
                        source = t.source,
                        restoredState = t.restoredState,
                        extras = t.extras;
                    /** @type {?} */

                    var navStart = new NavigationStart(id, _this302.serializeUrl(extractedUrl), source, restoredState);
                    eventsSubject.next(navStart);
                    /** @type {?} */

                    var targetSnapshot = createEmptyState(extractedUrl, _this302.rootComponentType).snapshot;
                    return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(Object.assign(Object.assign({}, t), {
                      targetSnapshot: targetSnapshot,
                      urlAfterRedirects: extractedUrl,
                      extras: Object.assign(Object.assign({}, extras), {
                        skipLocationChange: false,
                        replaceUrl: false
                      })
                    }));
                  } else {
                    /* When neither the current or previous URL can be processed, do nothing
                     * other than update router's internal reference to the current "settled"
                     * URL. This way the next navigation will be coming from the current URL
                     * in the browser.
                     */
                    _this302.rawUrlTree = t.rawUrl;
                    _this302.browserUrlTree = t.urlAfterRedirects;
                    t.resolve(null);
                    return rxjs__WEBPACK_IMPORTED_MODULE_2__["EMPTY"];
                  }
                }
              }), // Before Preactivation
              switchTap(
              /**
              * @param {?} t
              * @return {?}
              */
              function (t) {
                var targetSnapshot = t.targetSnapshot,
                    navigationId = t.id,
                    appliedUrlTree = t.extractedUrl,
                    rawUrlTree = t.rawUrl,
                    _t$extras = t.extras,
                    skipLocationChange = _t$extras.skipLocationChange,
                    replaceUrl = _t$extras.replaceUrl;
                return _this302.hooks.beforePreactivation(
                /** @type {?} */
                targetSnapshot, {
                  navigationId: navigationId,
                  appliedUrlTree: appliedUrlTree,
                  rawUrlTree: rawUrlTree,
                  skipLocationChange: !!skipLocationChange,
                  replaceUrl: !!replaceUrl
                });
              }), // --- GUARDS ---
              Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["tap"])(
              /**
              * @param {?} t
              * @return {?}
              */
              function (t) {
                /** @type {?} */
                var guardsStart = new GuardsCheckStart(t.id, _this302.serializeUrl(t.extractedUrl), _this302.serializeUrl(t.urlAfterRedirects),
                /** @type {?} */
                t.targetSnapshot);

                _this302.triggerEvent(guardsStart);
              }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
              /**
              * @param {?} t
              * @return {?}
              */
              function (t) {
                return Object.assign(Object.assign({}, t), {
                  guards: getAllRouteGuards(
                  /** @type {?} */
                  t.targetSnapshot, t.currentSnapshot, _this302.rootContexts)
                });
              }), checkGuards(_this302.ngModule.injector,
              /**
              * @param {?} evt
              * @return {?}
              */
              function (evt) {
                return _this302.triggerEvent(evt);
              }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["tap"])(
              /**
              * @param {?} t
              * @return {?}
              */
              function (t) {
                if (isUrlTree(t.guardsResult)) {
                  /** @type {?} */
                  var error = navigationCancelingError("Redirecting to \"".concat(_this302.serializeUrl(t.guardsResult), "\""));
                  error.url = t.guardsResult;
                  throw error;
                }
              }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["tap"])(
              /**
              * @param {?} t
              * @return {?}
              */
              function (t) {
                /** @type {?} */
                var guardsEnd = new GuardsCheckEnd(t.id, _this302.serializeUrl(t.extractedUrl), _this302.serializeUrl(t.urlAfterRedirects),
                /** @type {?} */
                t.targetSnapshot, !!t.guardsResult);

                _this302.triggerEvent(guardsEnd);
              }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["filter"])(
              /**
              * @param {?} t
              * @return {?}
              */
              function (t) {
                if (!t.guardsResult) {
                  _this302.resetUrlToCurrentUrlTree();
                  /** @type {?} */


                  var navCancel = new NavigationCancel(t.id, _this302.serializeUrl(t.extractedUrl), '');
                  eventsSubject.next(navCancel);
                  t.resolve(false);
                  return false;
                }

                return true;
              }), // --- RESOLVE ---
              switchTap(
              /**
              * @param {?} t
              * @return {?}
              */
              function (t) {
                if (t.guards.canActivateChecks.length) {
                  return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(t).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["tap"])(
                  /**
                  * @param {?} t
                  * @return {?}
                  */
                  function (t) {
                    /** @type {?} */
                    var resolveStart = new ResolveStart(t.id, _this302.serializeUrl(t.extractedUrl), _this302.serializeUrl(t.urlAfterRedirects),
                    /** @type {?} */
                    t.targetSnapshot);

                    _this302.triggerEvent(resolveStart);
                  }), resolveData(_this302.paramsInheritanceStrategy, _this302.ngModule.injector), //
                  Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["tap"])(
                  /**
                  * @param {?} t
                  * @return {?}
                  */
                  function (t) {
                    /** @type {?} */
                    var resolveEnd = new ResolveEnd(t.id, _this302.serializeUrl(t.extractedUrl), _this302.serializeUrl(t.urlAfterRedirects),
                    /** @type {?} */
                    t.targetSnapshot);

                    _this302.triggerEvent(resolveEnd);
                  }));
                }

                return undefined;
              }), // --- AFTER PREACTIVATION ---
              switchTap(
              /**
              * @param {?} t
              * @return {?}
              */
              function (t) {
                var targetSnapshot = t.targetSnapshot,
                    navigationId = t.id,
                    appliedUrlTree = t.extractedUrl,
                    rawUrlTree = t.rawUrl,
                    _t$extras2 = t.extras,
                    skipLocationChange = _t$extras2.skipLocationChange,
                    replaceUrl = _t$extras2.replaceUrl;
                return _this302.hooks.afterPreactivation(
                /** @type {?} */
                targetSnapshot, {
                  navigationId: navigationId,
                  appliedUrlTree: appliedUrlTree,
                  rawUrlTree: rawUrlTree,
                  skipLocationChange: !!skipLocationChange,
                  replaceUrl: !!replaceUrl
                });
              }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
              /**
              * @param {?} t
              * @return {?}
              */
              function (t) {
                /** @type {?} */
                var targetRouterState = createRouterState(_this302.routeReuseStrategy,
                /** @type {?} */
                t.targetSnapshot, t.currentRouterState);
                return Object.assign(Object.assign({}, t), {
                  targetRouterState: targetRouterState
                });
              }),
              /* Once here, we are about to activate syncronously. The assumption is this
                 will succeed, and user code may read from the Router service. Therefore
                 before activation, we need to update router properties storing the current
                 URL and the RouterState, as well as updated the browser URL. All this should
                 happen *before* activating. */
              Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["tap"])(
              /**
              * @param {?} t
              * @return {?}
              */
              function (t) {
                _this302.currentUrlTree = t.urlAfterRedirects;
                _this302.rawUrlTree = _this302.urlHandlingStrategy.merge(_this302.currentUrlTree, t.rawUrl);

                /** @type {?} */
                _this302.routerState =
                /** @type {?} */
                t.targetRouterState;

                if (_this302.urlUpdateStrategy === 'deferred') {
                  if (!t.extras.skipLocationChange) {
                    _this302.setBrowserUrl(_this302.rawUrlTree, !!t.extras.replaceUrl, t.id, t.extras.state);
                  }

                  _this302.browserUrlTree = t.urlAfterRedirects;
                }
              }), activateRoutes(_this302.rootContexts, _this302.routeReuseStrategy,
              /**
              * @param {?} evt
              * @return {?}
              */
              function (evt) {
                return _this302.triggerEvent(evt);
              }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["tap"])({
                /**
                 * @return {?}
                 */
                next: function next() {
                  completed = true;
                },

                /**
                 * @return {?}
                 */
                complete: function complete() {
                  completed = true;
                }
              }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["finalize"])(
              /**
              * @return {?}
              */
              function () {
                /* When the navigation stream finishes either through error or success, we
                 * set the `completed` or `errored` flag. However, there are some situations
                 * where we could get here without either of those being set. For instance, a
                 * redirect during NavigationStart. Therefore, this is a catch-all to make
                 * sure the NavigationCancel
                 * event is fired when a navigation gets cancelled but not caught by other
                 * means. */
                if (!completed && !errored) {
                  // Must reset to current URL tree here to ensure history.state is set. On a
                  // fresh page load, if a new navigation comes in before a successful
                  // navigation completes, there will be nothing in
                  // history.state.navigationId. This can cause sync problems with AngularJS
                  // sync code which looks for a value here in order to determine whether or
                  // not to handle a given popstate event or to leave it to the Angualr
                  // router.
                  _this302.resetUrlToCurrentUrlTree();
                  /** @type {?} */


                  var navCancel = new NavigationCancel(t.id, _this302.serializeUrl(t.extractedUrl), "Navigation ID ".concat(t.id, " is not equal to the current navigation id ").concat(_this302.navigationId));
                  eventsSubject.next(navCancel);
                  t.resolve(false);
                } // currentNavigation should always be reset to null here. If navigation was
                // successful, lastSuccessfulTransition will have already been set. Therefore
                // we can safely set currentNavigation to null here.


                _this302.currentNavigation = null;
              }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["catchError"])(
              /**
              * @param {?} e
              * @return {?}
              */
              function (e) {
                errored = true;
                /* This error type is issued during Redirect, and is handled as a
                 * cancellation rather than an error. */

                if (isNavigationCancelingError(e)) {
                  /** @type {?} */
                  var redirecting = isUrlTree(e.url);

                  if (!redirecting) {
                    // Set property only if we're not redirecting. If we landed on a page and
                    // redirect to `/` route, the new navigation is going to see the `/`
                    // isn't a change from the default currentUrlTree and won't navigate.
                    // This is only applicable with initial navigation, so setting
                    // `navigated` only when not redirecting resolves this scenario.
                    _this302.navigated = true;

                    _this302.resetStateAndUrl(t.currentRouterState, t.currentUrlTree, t.rawUrl);
                  }
                  /** @type {?} */


                  var navCancel = new NavigationCancel(t.id, _this302.serializeUrl(t.extractedUrl), e.message);
                  eventsSubject.next(navCancel); // When redirecting, we need to delay resolving the navigation
                  // promise and push it to the redirect navigation

                  if (!redirecting) {
                    t.resolve(false);
                  } else {
                    // setTimeout is required so this navigation finishes with
                    // the return EMPTY below. If it isn't allowed to finish
                    // processing, there can be multiple navigations to the same
                    // URL.
                    setTimeout(
                    /**
                    * @return {?}
                    */
                    function () {
                      /** @type {?} */
                      var mergedTree = _this302.urlHandlingStrategy.merge(e.url, _this302.rawUrlTree);
                      /** @type {?} */


                      var extras = {
                        skipLocationChange: t.extras.skipLocationChange,
                        replaceUrl: _this302.urlUpdateStrategy === 'eager'
                      };
                      return _this302.scheduleNavigation(mergedTree, 'imperative', null, extras, {
                        resolve: t.resolve,
                        reject: t.reject,
                        promise: t.promise
                      });
                    }, 0);
                  }
                  /* All other errors should reset to the router's internal URL reference to
                   * the pre-error state. */

                } else {
                  _this302.resetStateAndUrl(t.currentRouterState, t.currentUrlTree, t.rawUrl);
                  /** @type {?} */


                  var navError = new NavigationError(t.id, _this302.serializeUrl(t.extractedUrl), e);
                  eventsSubject.next(navError);

                  try {
                    t.resolve(_this302.errorHandler(e));
                  } catch (ee) {
                    t.reject(ee);
                  }
                }

                return rxjs__WEBPACK_IMPORTED_MODULE_2__["EMPTY"];
              })); // TODO(jasonaden): remove cast once g3 is on updated TypeScript
            }))
          );
        }
        /**
         * \@internal
         * TODO: this should be removed once the constructor of the router made internal
         * @param {?} rootComponentType
         * @return {?}
         */

      }, {
        key: "resetRootComponentType",
        value: function resetRootComponentType(rootComponentType) {
          this.rootComponentType = rootComponentType; // TODO: vsavkin router 4.0 should make the root component set to null
          // this will simplify the lifecycle of the router.

          this.routerState.root.component = this.rootComponentType;
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "getTransition",
        value: function getTransition() {
          /** @type {?} */
          var transition = this.transitions.value; // This value needs to be set. Other values such as extractedUrl are set on initial navigation
          // but the urlAfterRedirects may not get set if we aren't processing the new URL *and* not
          // processing the previous URL.

          transition.urlAfterRedirects = this.browserUrlTree;
          return transition;
        }
        /**
         * @private
         * @param {?} t
         * @return {?}
         */

      }, {
        key: "setTransition",
        value: function setTransition(t) {
          this.transitions.next(Object.assign(Object.assign({}, this.getTransition()), t));
        }
        /**
         * Sets up the location change listener and performs the initial navigation.
         * @return {?}
         */

      }, {
        key: "initialNavigation",
        value: function initialNavigation() {
          this.setUpLocationChangeListener();

          if (this.navigationId === 0) {
            this.navigateByUrl(this.location.path(true), {
              replaceUrl: true
            });
          }
        }
        /**
         * Sets up the location change listener.
         * @return {?}
         */

      }, {
        key: "setUpLocationChangeListener",
        value: function setUpLocationChangeListener() {
          var _this303 = this;

          // Don't need to use Zone.wrap any more, because zone.js
          // already patch onPopState, so location change callback will
          // run into ngZone
          if (!this.locationSubscription) {
            this.locationSubscription =
            /** @type {?} */
            this.location.subscribe(
            /**
            * @param {?} change
            * @return {?}
            */
            function (change) {
              /** @type {?} */
              var rawUrlTree = _this303.parseUrl(change['url']);
              /** @type {?} */


              var source = change['type'] === 'popstate' ? 'popstate' : 'hashchange'; // Navigations coming from Angular router have a navigationId state property. When this
              // exists, restore the state.

              /** @type {?} */

              var state = change.state && change.state.navigationId ? change.state : null;
              setTimeout(
              /**
              * @return {?}
              */
              function () {
                _this303.scheduleNavigation(rawUrlTree, source, state, {
                  replaceUrl: true
                });
              }, 0);
            });
          }
        }
        /**
         * The current URL.
         * @return {?}
         */

      }, {
        key: "getCurrentNavigation",

        /**
         * The current Navigation object if one exists
         * @return {?}
         */
        value: function getCurrentNavigation() {
          return this.currentNavigation;
        }
        /**
         * \@internal
         * @param {?} event
         * @return {?}
         */

      }, {
        key: "triggerEvent",
        value: function triggerEvent(event) {
          /** @type {?} */
          this.events.next(event);
        }
        /**
         * Resets the configuration used for navigation and generating links.
         *
         * \@usageNotes
         *
         * ```
         * router.resetConfig([
         *  { path: 'team/:id', component: TeamCmp, children: [
         *    { path: 'simple', component: SimpleCmp },
         *    { path: 'user/:name', component: UserCmp }
         *  ]}
         * ]);
         * ```
         * @param {?} config The route array for the new configuration.
         *
         * @return {?}
         */

      }, {
        key: "resetConfig",
        value: function resetConfig(config) {
          validateConfig(config);
          this.config = config.map(standardizeConfig);
          this.navigated = false;
          this.lastSuccessfulId = -1;
        }
        /**
         * \@docsNotRequired
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this.dispose();
        }
        /**
         * Disposes of the router.
         * @return {?}
         */

      }, {
        key: "dispose",
        value: function dispose() {
          if (this.locationSubscription) {
            this.locationSubscription.unsubscribe();
            this.locationSubscription =
            /** @type {?} */
            null;
          }
        }
        /**
         * Applies an array of commands to the current URL tree and creates a new URL tree.
         *
         * When given an activated route, applies the given commands starting from the route.
         * Otherwise, applies the given command starting from the root.
         *
         * \@usageNotes
         *
         * ```
         * // create /team/33/user/11
         * router.createUrlTree(['/team', 33, 'user', 11]);
         *
         * // create /team/33;expand=true/user/11
         * router.createUrlTree(['/team', 33, {expand: true}, 'user', 11]);
         *
         * // you can collapse static segments like this (this works only with the first passed-in value):
         * router.createUrlTree(['/team/33/user', userId]);
         *
         * // If the first segment can contain slashes, and you do not want the router to split it,
         * // you can do the following:
         * router.createUrlTree([{segmentPath: '/one/two'}]);
         *
         * // create /team/33/(user/11//right:chat)
         * router.createUrlTree(['/team', 33, {outlets: {primary: 'user/11', right: 'chat'}}]);
         *
         * // remove the right secondary node
         * router.createUrlTree(['/team', 33, {outlets: {primary: 'user/11', right: null}}]);
         *
         * // assuming the current url is `/team/33/user/11` and the route points to `user/11`
         *
         * // navigate to /team/33/user/11/details
         * router.createUrlTree(['details'], {relativeTo: route});
         *
         * // navigate to /team/33/user/22
         * router.createUrlTree(['../22'], {relativeTo: route});
         *
         * // navigate to /team/44/user/22
         * router.createUrlTree(['../../team/44/user/22'], {relativeTo: route});
         * ```
         * @param {?} commands An array of commands to apply.
         * @param {?=} navigationExtras Options that control the navigation strategy. This function
         * only utilizes properties in `NavigationExtras` that would change the provided URL.
         * @return {?} The new URL tree.
         *
         */

      }, {
        key: "createUrlTree",
        value: function createUrlTree(commands) {
          var navigationExtras = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
          var relativeTo = navigationExtras.relativeTo,
              queryParams = navigationExtras.queryParams,
              fragment = navigationExtras.fragment,
              preserveQueryParams = navigationExtras.preserveQueryParams,
              queryParamsHandling = navigationExtras.queryParamsHandling,
              preserveFragment = navigationExtras.preserveFragment;

          if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["isDevMode"])() && preserveQueryParams &&
          /** @type {?} */
          console &&
          /** @type {?} */
          console.warn) {
            console.warn('preserveQueryParams is deprecated, use queryParamsHandling instead.');
          }
          /** @type {?} */


          var a = relativeTo || this.routerState.root;
          /** @type {?} */

          var f = preserveFragment ? this.currentUrlTree.fragment : fragment;
          /** @type {?} */

          var q = null;

          if (queryParamsHandling) {
            switch (queryParamsHandling) {
              case 'merge':
                q = Object.assign(Object.assign({}, this.currentUrlTree.queryParams), queryParams);
                break;

              case 'preserve':
                q = this.currentUrlTree.queryParams;
                break;

              default:
                q = queryParams || null;
            }
          } else {
            q = preserveQueryParams ? this.currentUrlTree.queryParams : queryParams || null;
          }

          if (q !== null) {
            q = this.removeEmptyProps(q);
          }

          return _createUrlTree(a, this.currentUrlTree, commands,
          /** @type {?} */
          q,
          /** @type {?} */
          f);
        }
        /**
         * Navigate based on the provided URL, which must be absolute.
         *
         * \@usageNotes
         *
         * ```
         * router.navigateByUrl("/team/33/user/11");
         *
         * // Navigate without updating the URL
         * router.navigateByUrl("/team/33/user/11", { skipLocationChange: true });
         * ```
         *
         * @param {?} url An absolute URL. The function does not apply any delta to the current URL.
         * @param {?=} extras An object containing properties that modify the navigation strategy.
         * The function ignores any properties in the `NavigationExtras` that would change the
         * provided URL.
         *
         * @return {?} A Promise that resolves to 'true' when navigation succeeds,
         * to 'false' when navigation fails, or is rejected on error.
         *
         */

      }, {
        key: "navigateByUrl",
        value: function navigateByUrl(url) {
          var extras = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {
            skipLocationChange: false
          };

          if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["isDevMode"])() && this.isNgZoneEnabled && !_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"].isInAngularZone()) {
            this.console.warn("Navigation triggered outside Angular zone, did you forget to call 'ngZone.run()'?");
          }
          /** @type {?} */


          var urlTree = isUrlTree(url) ? url : this.parseUrl(url);
          /** @type {?} */

          var mergedTree = this.urlHandlingStrategy.merge(urlTree, this.rawUrlTree);
          return this.scheduleNavigation(mergedTree, 'imperative', null, extras);
        }
        /**
         * Navigate based on the provided array of commands and a starting point.
         * If no starting route is provided, the navigation is absolute.
         *
         * Returns a promise that:
         * - resolves to 'true' when navigation succeeds,
         * - resolves to 'false' when navigation fails,
         * - is rejected when an error happens.
         *
         * \@usageNotes
         *
         * ```
         * router.navigate(['team', 33, 'user', 11], {relativeTo: route});
         *
         * // Navigate without updating the URL
         * router.navigate(['team', 33, 'user', 11], {relativeTo: route, skipLocationChange: true});
         * ```
         *
         * The first parameter of `navigate()` is a delta to be applied to the current URL
         * or the one provided in the `relativeTo` property of the second parameter (the
         * `NavigationExtras`).
         *
         * In order to affect this browser's `history.state` entry, the `state`
         * parameter can be passed. This must be an object because the router
         * will add the `navigationId` property to this object before creating
         * the new history item.
         * @param {?} commands
         * @param {?=} extras
         * @return {?}
         */

      }, {
        key: "navigate",
        value: function navigate(commands) {
          var extras = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {
            skipLocationChange: false
          };
          validateCommands(commands);
          return this.navigateByUrl(this.createUrlTree(commands, extras), extras);
        }
        /**
         * Serializes a `UrlTree` into a string
         * @param {?} url
         * @return {?}
         */

      }, {
        key: "serializeUrl",
        value: function serializeUrl(url) {
          return this.urlSerializer.serialize(url);
        }
        /**
         * Parses a string into a `UrlTree`
         * @param {?} url
         * @return {?}
         */

      }, {
        key: "parseUrl",
        value: function parseUrl(url) {
          /** @type {?} */
          var urlTree;

          try {
            urlTree = this.urlSerializer.parse(url);
          } catch (e) {
            urlTree = this.malformedUriErrorHandler(e, this.urlSerializer, url);
          }

          return urlTree;
        }
        /**
         * Returns whether the url is activated
         * @param {?} url
         * @param {?} exact
         * @return {?}
         */

      }, {
        key: "isActive",
        value: function isActive(url, exact) {
          if (isUrlTree(url)) {
            return containsTree(this.currentUrlTree, url, exact);
          }
          /** @type {?} */


          var urlTree = this.parseUrl(url);
          return containsTree(this.currentUrlTree, urlTree, exact);
        }
        /**
         * @private
         * @param {?} params
         * @return {?}
         */

      }, {
        key: "removeEmptyProps",
        value: function removeEmptyProps(params) {
          return Object.keys(params).reduce(
          /**
          * @param {?} result
          * @param {?} key
          * @return {?}
          */
          function (result, key) {
            /** @type {?} */
            var value = params[key];

            if (value !== null && value !== undefined) {
              result[key] = value;
            }

            return result;
          }, {});
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "processNavigations",
        value: function processNavigations() {
          var _this304 = this;

          this.navigations.subscribe(
          /**
          * @param {?} t
          * @return {?}
          */
          function (t) {
            _this304.navigated = true;
            _this304.lastSuccessfulId = t.id;

            /** @type {?} */
            _this304.events.next(new NavigationEnd(t.id, _this304.serializeUrl(t.extractedUrl), _this304.serializeUrl(_this304.currentUrlTree)));

            _this304.lastSuccessfulNavigation = _this304.currentNavigation;
            _this304.currentNavigation = null;
            t.resolve(true);
          },
          /**
          * @param {?} e
          * @return {?}
          */
          function (e) {
            _this304.console.warn("Unhandled Navigation Error: ");
          });
        }
        /**
         * @private
         * @param {?} rawUrl
         * @param {?} source
         * @param {?} restoredState
         * @param {?} extras
         * @param {?=} priorPromise
         * @return {?}
         */

      }, {
        key: "scheduleNavigation",
        value: function scheduleNavigation(rawUrl, source, restoredState, extras, priorPromise) {
          /** @type {?} */
          var lastNavigation = this.getTransition(); // If the user triggers a navigation imperatively (e.g., by using navigateByUrl),
          // and that navigation results in 'replaceState' that leads to the same URL,
          // we should skip those.

          if (lastNavigation && source !== 'imperative' && lastNavigation.source === 'imperative' && lastNavigation.rawUrl.toString() === rawUrl.toString()) {
            return Promise.resolve(true); // return value is not used
          } // Because of a bug in IE and Edge, the location class fires two events (popstate and
          // hashchange) every single time. The second one should be ignored. Otherwise, the URL will
          // flicker. Handles the case when a popstate was emitted first.


          if (lastNavigation && source == 'hashchange' && lastNavigation.source === 'popstate' && lastNavigation.rawUrl.toString() === rawUrl.toString()) {
            return Promise.resolve(true); // return value is not used
          } // Because of a bug in IE and Edge, the location class fires two events (popstate and
          // hashchange) every single time. The second one should be ignored. Otherwise, the URL will
          // flicker. Handles the case when a hashchange was emitted first.


          if (lastNavigation && source == 'popstate' && lastNavigation.source === 'hashchange' && lastNavigation.rawUrl.toString() === rawUrl.toString()) {
            return Promise.resolve(true); // return value is not used
          }
          /** @type {?} */


          var resolve;
          /** @type {?} */

          var reject;
          /** @type {?} */

          var promise;

          if (priorPromise) {
            resolve = priorPromise.resolve;
            reject = priorPromise.reject;
            promise = priorPromise.promise;
          } else {
            promise = new Promise(
            /**
            * @param {?} res
            * @param {?} rej
            * @return {?}
            */
            function (res, rej) {
              resolve = res;
              reject = rej;
            });
          }
          /** @type {?} */


          var id = ++this.navigationId;
          this.setTransition({
            id: id,
            source: source,
            restoredState: restoredState,
            currentUrlTree: this.currentUrlTree,
            currentRawUrl: this.rawUrlTree,
            rawUrl: rawUrl,
            extras: extras,
            resolve: resolve,
            reject: reject,
            promise: promise,
            currentSnapshot: this.routerState.snapshot,
            currentRouterState: this.routerState
          }); // Make sure that the error is propagated even though `processNavigations` catch
          // handler does not rethrow

          return promise["catch"](
          /**
          * @param {?} e
          * @return {?}
          */
          function (e) {
            return Promise.reject(e);
          });
        }
        /**
         * @private
         * @param {?} url
         * @param {?} replaceUrl
         * @param {?} id
         * @param {?=} state
         * @return {?}
         */

      }, {
        key: "setBrowserUrl",
        value: function setBrowserUrl(url, replaceUrl, id, state) {
          /** @type {?} */
          var path = this.urlSerializer.serialize(url);
          state = state || {};

          if (this.location.isCurrentPathEqualTo(path) || replaceUrl) {
            // TODO(jasonaden): Remove first `navigationId` and rely on `ng` namespace.
            this.location.replaceState(path, '', Object.assign(Object.assign({}, state), {
              navigationId: id
            }));
          } else {
            this.location.go(path, '', Object.assign(Object.assign({}, state), {
              navigationId: id
            }));
          }
        }
        /**
         * @private
         * @param {?} storedState
         * @param {?} storedUrl
         * @param {?} rawUrl
         * @return {?}
         */

      }, {
        key: "resetStateAndUrl",
        value: function resetStateAndUrl(storedState, storedUrl, rawUrl) {
          /** @type {?} */
          this.routerState = storedState;
          this.currentUrlTree = storedUrl;
          this.rawUrlTree = this.urlHandlingStrategy.merge(this.currentUrlTree, rawUrl);
          this.resetUrlToCurrentUrlTree();
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "resetUrlToCurrentUrlTree",
        value: function resetUrlToCurrentUrlTree() {
          this.location.replaceState(this.urlSerializer.serialize(this.rawUrlTree), '', {
            navigationId: this.lastSuccessfulId
          });
        }
      }, {
        key: "url",
        get: function get() {
          return this.serializeUrl(this.currentUrlTree);
        }
      }]);

      return Router;
    }();

    Router.ɵfac = function Router_Factory(t) {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinvalidFactory"]();
    };

    Router.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineDirective"]({
      type: Router
    });

    if (false) {}
    /**
     * @param {?} commands
     * @return {?}
     */


    function validateCommands(commands) {
      for (var i = 0; i < commands.length; i++) {
        /** @type {?} */
        var cmd = commands[i];

        if (cmd == null) {
          throw new Error("The requested path contains ".concat(cmd, " segment at index ").concat(i));
        }
      }
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/directives/router_link.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@description
     *
     * Lets you link to specific routes in your app.
     *
     * Consider the following route configuration:
     * `[{ path: 'user/:name', component: UserCmp }]`.
     * When linking to this `user/:name` route, you use the `RouterLink` directive.
     *
     * If the link is static, you can use the directive as follows:
     * `<a routerLink="/user/bob">link to user component</a>`
     *
     * If you use dynamic values to generate the link, you can pass an array of path
     * segments, followed by the params for each segment.
     *
     * For instance `['/team', teamId, 'user', userName, {details: true}]`
     * means that we want to generate a link to `/team/11/user/bob;details=true`.
     *
     * Multiple static segments can be merged into one
     * (e.g., `['/team/11/user', userName, {details: true}]`).
     *
     * The first segment name can be prepended with `/`, `./`, or `../`:
     * * If the first segment begins with `/`, the router will look up the route from the root of the
     *   app.
     * * If the first segment begins with `./`, or doesn't begin with a slash, the router will
     *   instead look in the children of the current activated route.
     * * And if the first segment begins with `../`, the router will go up one level.
     *
     * You can set query params and fragment as follows:
     *
     * ```
     * <a [routerLink]="['/user/bob']" [queryParams]="{debug: true}" fragment="education">
     *   link to user component
     * </a>
     * ```
     * RouterLink will use these to generate this link: `/user/bob#education?debug=true`.
     *
     * (Deprecated in v4.0.0 use `queryParamsHandling` instead) You can also tell the
     * directive to preserve the current query params and fragment:
     *
     * ```
     * <a [routerLink]="['/user/bob']" preserveQueryParams preserveFragment>
     *   link to user component
     * </a>
     * ```
     *
     * You can tell the directive how to handle queryParams. Available options are:
     *  - `'merge'`: merge the queryParams into the current queryParams
     *  - `'preserve'`: preserve the current queryParams
     *  - default/`''`: use the queryParams only
     *
     * Same options for {\@link NavigationExtras#queryParamsHandling
     * NavigationExtras#queryParamsHandling}.
     *
     * ```
     * <a [routerLink]="['/user/bob']" [queryParams]="{debug: true}" queryParamsHandling="merge">
     *   link to user component
     * </a>
     * ```
     *
     * You can provide a `state` value to be persisted to the browser's History.state
     * property (See https://developer.mozilla.org/en-US/docs/Web/API/History#Properties). It's
     * used as follows:
     *
     * ```
     * <a [routerLink]="['/user/bob']" [state]="{tracingId: 123}">
     *   link to user component
     * </a>
     * ```
     *
     * And later the value can be read from the router through `router.getCurrentNavigation`.
     * For example, to capture the `tracingId` above during the `NavigationStart` event:
     *
     * ```
     * // Get NavigationStart events
     * router.events.pipe(filter(e => e instanceof NavigationStart)).subscribe(e => {
     *   const navigation = router.getCurrentNavigation();
     *   tracingService.trace({id: navigation.extras.state.tracingId});
     * });
     * ```
     *
     * The router link directive always treats the provided input as a delta to the current url.
     *
     * For instance, if the current url is `/user/(box//aux:team)`.
     *
     * Then the following link `<a [routerLink]="['/user/jim']">Jim</a>` will generate the link
     * `/user/(jim//aux:team)`.
     *
     * See {\@link Router#createUrlTree createUrlTree} for more information.
     *
     * \@ngModule RouterModule
     *
     * \@publicApi
     */


    var RouterLink = /*#__PURE__*/function () {
      /**
       * @param {?} router
       * @param {?} route
       * @param {?} tabIndex
       * @param {?} renderer
       * @param {?} el
       */
      function RouterLink(router, route, tabIndex, renderer, el) {
        _classCallCheck(this, RouterLink);

        this.router = router;
        this.route = route;
        this.commands = [];

        if (tabIndex == null) {
          renderer.setAttribute(el.nativeElement, 'tabindex', '0');
        }
      }
      /**
       * @param {?} commands
       * @return {?}
       */


      _createClass2(RouterLink, [{
        key: "onClick",

        /**
         * @return {?}
         */
        value: function onClick() {
          /** @type {?} */
          var extras = {
            skipLocationChange: attrBoolValue(this.skipLocationChange),
            replaceUrl: attrBoolValue(this.replaceUrl),
            state: this.state
          };
          this.router.navigateByUrl(this.urlTree, extras);
          return true;
        }
        /**
         * @return {?}
         */

      }, {
        key: "routerLink",
        set: function set(commands) {
          if (commands != null) {
            this.commands = Array.isArray(commands) ? commands : [commands];
          } else {
            this.commands = [];
          }
        }
        /**
         * @deprecated 4.0.0 use `queryParamsHandling` instead.
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "preserveQueryParams",
        set: function set(value) {
          if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["isDevMode"])() &&
          /** @type {?} */
          console &&
          /** @type {?} */
          console.warn) {
            console.warn('preserveQueryParams is deprecated!, use queryParamsHandling instead.');
          }

          this.preserve = value;
        }
      }, {
        key: "urlTree",
        get: function get() {
          return this.router.createUrlTree(this.commands, {
            relativeTo: this.route,
            queryParams: this.queryParams,
            fragment: this.fragment,
            preserveQueryParams: attrBoolValue(this.preserve),
            queryParamsHandling: this.queryParamsHandling,
            preserveFragment: attrBoolValue(this.preserveFragment)
          });
        }
      }]);

      return RouterLink;
    }();

    RouterLink.ɵfac = function RouterLink_Factory(t) {
      return new (t || RouterLink)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](Router), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](ActivatedRoute), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinjectAttribute"]('tabindex'), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["Renderer2"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]));
    };

    RouterLink.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineDirective"]({
      type: RouterLink,
      selectors: [["", "routerLink", "", 5, "a", 5, "area"]],
      hostBindings: function RouterLink_HostBindings(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵlistener"]("click", function RouterLink_click_HostBindingHandler() {
            return ctx.onClick();
          });
        }
      },
      inputs: {
        routerLink: "routerLink",
        preserveQueryParams: "preserveQueryParams",
        queryParams: "queryParams",
        fragment: "fragment",
        queryParamsHandling: "queryParamsHandling",
        preserveFragment: "preserveFragment",
        skipLocationChange: "skipLocationChange",
        replaceUrl: "replaceUrl",
        state: "state"
      }
    });
    /** @nocollapse */

    RouterLink.ctorParameters = function () {
      return [{
        type: Router
      }, {
        type: ActivatedRoute
      }, {
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Attribute"],
          args: ['tabindex']
        }]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Renderer2"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]
      }];
    };

    RouterLink.propDecorators = {
      queryParams: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      fragment: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      queryParamsHandling: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      preserveFragment: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      skipLocationChange: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      replaceUrl: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      state: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      routerLink: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      preserveQueryParams: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      onClick: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["HostListener"],
        args: ['click']
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](RouterLink, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Directive"],
        args: [{
          selector: ':not(a):not(area)[routerLink]'
        }]
      }], function () {
        return [{
          type: Router
        }, {
          type: ActivatedRoute
        }, {
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Attribute"],
            args: ['tabindex']
          }]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Renderer2"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]
        }];
      }, {
        routerLink: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        preserveQueryParams: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        onClick: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["HostListener"],
          args: ['click']
        }],
        queryParams: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        fragment: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        queryParamsHandling: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        preserveFragment: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        skipLocationChange: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        replaceUrl: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        state: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * \@description
     *
     * Lets you link to specific routes in your app.
     *
     * See `RouterLink` for more information.
     *
     * \@ngModule RouterModule
     *
     * \@publicApi
     */


    var RouterLinkWithHref = /*#__PURE__*/function () {
      /**
       * @param {?} router
       * @param {?} route
       * @param {?} locationStrategy
       */
      function RouterLinkWithHref(router, route, locationStrategy) {
        var _this305 = this;

        _classCallCheck(this, RouterLinkWithHref);

        this.router = router;
        this.route = route;
        this.locationStrategy = locationStrategy;
        this.commands = [];
        this.subscription = router.events.subscribe(
        /**
        * @param {?} s
        * @return {?}
        */
        function (s) {
          if (s instanceof NavigationEnd) {
            _this305.updateTargetUrlAndHref();
          }
        });
      }
      /**
       * @param {?} commands
       * @return {?}
       */


      _createClass2(RouterLinkWithHref, [{
        key: "ngOnChanges",

        /**
         * @param {?} changes
         * @return {?}
         */
        value: function ngOnChanges(changes) {
          this.updateTargetUrlAndHref();
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this.subscription.unsubscribe();
        }
        /**
         * @param {?} button
         * @param {?} ctrlKey
         * @param {?} metaKey
         * @param {?} shiftKey
         * @return {?}
         */

      }, {
        key: "onClick",
        value: function onClick(button, ctrlKey, metaKey, shiftKey) {
          if (button !== 0 || ctrlKey || metaKey || shiftKey) {
            return true;
          }

          if (typeof this.target === 'string' && this.target != '_self') {
            return true;
          }
          /** @type {?} */


          var extras = {
            skipLocationChange: attrBoolValue(this.skipLocationChange),
            replaceUrl: attrBoolValue(this.replaceUrl),
            state: this.state
          };
          this.router.navigateByUrl(this.urlTree, extras);
          return false;
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "updateTargetUrlAndHref",
        value: function updateTargetUrlAndHref() {
          this.href = this.locationStrategy.prepareExternalUrl(this.router.serializeUrl(this.urlTree));
        }
        /**
         * @return {?}
         */

      }, {
        key: "routerLink",
        set: function set(commands) {
          if (commands != null) {
            this.commands = Array.isArray(commands) ? commands : [commands];
          } else {
            this.commands = [];
          }
        }
        /**
         * @param {?} value
         * @return {?}
         */

      }, {
        key: "preserveQueryParams",
        set: function set(value) {
          if (Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["isDevMode"])() &&
          /** @type {?} */
          console &&
          /** @type {?} */
          console.warn) {
            console.warn('preserveQueryParams is deprecated, use queryParamsHandling instead.');
          }

          this.preserve = value;
        }
      }, {
        key: "urlTree",
        get: function get() {
          return this.router.createUrlTree(this.commands, {
            relativeTo: this.route,
            queryParams: this.queryParams,
            fragment: this.fragment,
            preserveQueryParams: attrBoolValue(this.preserve),
            queryParamsHandling: this.queryParamsHandling,
            preserveFragment: attrBoolValue(this.preserveFragment)
          });
        }
      }]);

      return RouterLinkWithHref;
    }();

    RouterLinkWithHref.ɵfac = function RouterLinkWithHref_Factory(t) {
      return new (t || RouterLinkWithHref)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](Router), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](ActivatedRoute), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_common__WEBPACK_IMPORTED_MODULE_0__["LocationStrategy"]));
    };

    RouterLinkWithHref.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineDirective"]({
      type: RouterLinkWithHref,
      selectors: [["a", "routerLink", ""], ["area", "routerLink", ""]],
      hostVars: 2,
      hostBindings: function RouterLinkWithHref_HostBindings(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵlistener"]("click", function RouterLinkWithHref_click_HostBindingHandler($event) {
            return ctx.onClick($event.button, $event.ctrlKey, $event.metaKey, $event.shiftKey);
          });
        }

        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵhostProperty"]("href", ctx.href, _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵsanitizeUrl"]);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵattribute"]("target", ctx.target);
        }
      },
      inputs: {
        routerLink: "routerLink",
        preserveQueryParams: "preserveQueryParams",
        target: "target",
        queryParams: "queryParams",
        fragment: "fragment",
        queryParamsHandling: "queryParamsHandling",
        preserveFragment: "preserveFragment",
        skipLocationChange: "skipLocationChange",
        replaceUrl: "replaceUrl",
        state: "state"
      },
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵNgOnChangesFeature"]]
    });
    /** @nocollapse */

    RouterLinkWithHref.ctorParameters = function () {
      return [{
        type: Router
      }, {
        type: ActivatedRoute
      }, {
        type: _angular_common__WEBPACK_IMPORTED_MODULE_0__["LocationStrategy"]
      }];
    };

    RouterLinkWithHref.propDecorators = {
      target: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["HostBinding"],
        args: ['attr.target']
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      queryParams: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      fragment: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      queryParamsHandling: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      preserveFragment: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      skipLocationChange: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      replaceUrl: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      state: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      href: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["HostBinding"]
      }],
      routerLink: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      preserveQueryParams: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      onClick: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["HostListener"],
        args: ['click', ['$event.button', '$event.ctrlKey', '$event.metaKey', '$event.shiftKey']]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](RouterLinkWithHref, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Directive"],
        args: [{
          selector: 'a[routerLink],area[routerLink]'
        }]
      }], function () {
        return [{
          type: Router
        }, {
          type: ActivatedRoute
        }, {
          type: _angular_common__WEBPACK_IMPORTED_MODULE_0__["LocationStrategy"]
        }];
      }, {
        routerLink: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        preserveQueryParams: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        onClick: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["HostListener"],
          args: ['click', ['$event.button', '$event.ctrlKey', '$event.metaKey', '$event.shiftKey']]
        }],
        href: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["HostBinding"]
        }],
        target: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["HostBinding"],
          args: ['attr.target']
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        queryParams: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        fragment: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        queryParamsHandling: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        preserveFragment: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        skipLocationChange: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        replaceUrl: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        state: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }]
      });
    })();

    if (false) {}
    /**
     * @param {?} s
     * @return {?}
     */


    function attrBoolValue(s) {
      return s === '' || !!s;
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/directives/router_link_active.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     *
     * \@description
     *
     * Lets you add a CSS class to an element when the link's route becomes active.
     *
     * This directive lets you add a CSS class to an element when the link's route
     * becomes active.
     *
     * Consider the following example:
     *
     * ```
     * <a routerLink="/user/bob" routerLinkActive="active-link">Bob</a>
     * ```
     *
     * When the url is either '/user' or '/user/bob', the active-link class will
     * be added to the `a` tag. If the url changes, the class will be removed.
     *
     * You can set more than one class, as follows:
     *
     * ```
     * <a routerLink="/user/bob" routerLinkActive="class1 class2">Bob</a>
     * <a routerLink="/user/bob" [routerLinkActive]="['class1', 'class2']">Bob</a>
     * ```
     *
     * You can configure RouterLinkActive by passing `exact: true`. This will add the classes
     * only when the url matches the link exactly.
     *
     * ```
     * <a routerLink="/user/bob" routerLinkActive="active-link" [routerLinkActiveOptions]="{exact:
     * true}">Bob</a>
     * ```
     *
     * You can assign the RouterLinkActive instance to a template variable and directly check
     * the `isActive` status.
     * ```
     * <a routerLink="/user/bob" routerLinkActive #rla="routerLinkActive">
     *   Bob {{ rla.isActive ? '(already open)' : ''}}
     * </a>
     * ```
     *
     * Finally, you can apply the RouterLinkActive directive to an ancestor of a RouterLink.
     *
     * ```
     * <div routerLinkActive="active-link" [routerLinkActiveOptions]="{exact: true}">
     *   <a routerLink="/user/jim">Jim</a>
     *   <a routerLink="/user/bob">Bob</a>
     * </div>
     * ```
     *
     * This will set the active-link class on the div tag if the url is either '/user/jim' or
     * '/user/bob'.
     *
     * \@ngModule RouterModule
     *
     * \@publicApi
     */


    var RouterLinkActive = /*#__PURE__*/function () {
      /**
       * @param {?} router
       * @param {?} element
       * @param {?} renderer
       * @param {?=} link
       * @param {?=} linkWithHref
       */
      function RouterLinkActive(router, element, renderer, link, linkWithHref) {
        var _this306 = this;

        _classCallCheck(this, RouterLinkActive);

        this.router = router;
        this.element = element;
        this.renderer = renderer;
        this.link = link;
        this.linkWithHref = linkWithHref;
        this.classes = [];
        this.isActive = false;
        this.routerLinkActiveOptions = {
          exact: false
        };
        this.subscription = router.events.subscribe(
        /**
        * @param {?} s
        * @return {?}
        */
        function (s) {
          if (s instanceof NavigationEnd) {
            _this306.update();
          }
        });
      }
      /**
       * @return {?}
       */


      _createClass2(RouterLinkActive, [{
        key: "ngAfterContentInit",
        value: function ngAfterContentInit() {
          var _this307 = this;

          this.links.changes.subscribe(
          /**
          * @param {?} _
          * @return {?}
          */
          function (_) {
            return _this307.update();
          });
          this.linksWithHrefs.changes.subscribe(
          /**
          * @param {?} _
          * @return {?}
          */
          function (_) {
            return _this307.update();
          });
          this.update();
        }
        /**
         * @param {?} data
         * @return {?}
         */

      }, {
        key: "ngOnChanges",

        /**
         * @param {?} changes
         * @return {?}
         */
        value: function ngOnChanges(changes) {
          this.update();
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this.subscription.unsubscribe();
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "update",
        value: function update() {
          var _this308 = this;

          if (!this.links || !this.linksWithHrefs || !this.router.navigated) return;
          Promise.resolve().then(
          /**
          * @return {?}
          */
          function () {
            /** @type {?} */
            var hasActiveLinks = _this308.hasActiveLinks();

            if (_this308.isActive !== hasActiveLinks) {
              /** @type {?} */
              _this308.isActive = hasActiveLinks;

              _this308.classes.forEach(
              /**
              * @param {?} c
              * @return {?}
              */
              function (c) {
                if (hasActiveLinks) {
                  _this308.renderer.addClass(_this308.element.nativeElement, c);
                } else {
                  _this308.renderer.removeClass(_this308.element.nativeElement, c);
                }
              });
            }
          });
        }
        /**
         * @private
         * @param {?} router
         * @return {?}
         */

      }, {
        key: "isLinkActive",
        value: function isLinkActive(router) {
          var _this309 = this;

          return (
            /**
            * @param {?} link
            * @return {?}
            */
            function (link) {
              return router.isActive(link.urlTree, _this309.routerLinkActiveOptions.exact);
            }
          );
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "hasActiveLinks",
        value: function hasActiveLinks() {
          /** @type {?} */
          var isActiveCheckFn = this.isLinkActive(this.router);
          return this.link && isActiveCheckFn(this.link) || this.linkWithHref && isActiveCheckFn(this.linkWithHref) || this.links.some(isActiveCheckFn) || this.linksWithHrefs.some(isActiveCheckFn);
        }
      }, {
        key: "routerLinkActive",
        set: function set(data) {
          /** @type {?} */
          var classes = Array.isArray(data) ? data : data.split(' ');
          this.classes = classes.filter(
          /**
          * @param {?} c
          * @return {?}
          */
          function (c) {
            return !!c;
          });
        }
      }]);

      return RouterLinkActive;
    }();

    RouterLinkActive.ɵfac = function RouterLinkActive_Factory(t) {
      return new (t || RouterLinkActive)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](Router), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["Renderer2"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](RouterLink, 8), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](RouterLinkWithHref, 8));
    };

    RouterLinkActive.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineDirective"]({
      type: RouterLinkActive,
      selectors: [["", "routerLinkActive", ""]],
      contentQueries: function RouterLinkActive_ContentQueries(rf, ctx, dirIndex) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵcontentQuery"](dirIndex, RouterLink, true);

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵcontentQuery"](dirIndex, RouterLinkWithHref, true);
        }

        if (rf & 2) {
          var _t;

          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵqueryRefresh"](_t = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵloadQuery"]()) && (ctx.links = _t);
          _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵqueryRefresh"](_t = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵloadQuery"]()) && (ctx.linksWithHrefs = _t);
        }
      },
      inputs: {
        routerLinkActiveOptions: "routerLinkActiveOptions",
        routerLinkActive: "routerLinkActive"
      },
      exportAs: ["routerLinkActive"],
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵNgOnChangesFeature"]]
    });
    /** @nocollapse */

    RouterLinkActive.ctorParameters = function () {
      return [{
        type: Router
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Renderer2"]
      }, {
        type: RouterLink,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }]
      }, {
        type: RouterLinkWithHref,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }]
      }];
    };

    RouterLinkActive.propDecorators = {
      links: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ContentChildren"],
        args: [RouterLink, {
          descendants: true
        }]
      }],
      linksWithHrefs: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ContentChildren"],
        args: [RouterLinkWithHref, {
          descendants: true
        }]
      }],
      routerLinkActiveOptions: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }],
      routerLinkActive: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](RouterLinkActive, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Directive"],
        args: [{
          selector: '[routerLinkActive]',
          exportAs: 'routerLinkActive'
        }]
      }], function () {
        return [{
          type: Router
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Renderer2"]
        }, {
          type: RouterLink,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }]
        }, {
          type: RouterLinkWithHref,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }]
        }];
      }, {
        routerLinkActiveOptions: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        routerLinkActive: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Input"]
        }],
        links: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ContentChildren"],
          args: [RouterLink, {
            descendants: true
          }]
        }],
        linksWithHrefs: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ContentChildren"],
          args: [RouterLinkWithHref, {
            descendants: true
          }]
        }]
      });
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/router_outlet_context.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @license
     * Copyright Google Inc. All Rights Reserved.
     *
     * Use of this source code is governed by an MIT-style license that can be
     * found in the LICENSE file at https://angular.io/license
     */

    /**
     * Store contextual information about a `RouterOutlet`
     *
     * \@publicApi
     */


    var OutletContext = function OutletContext() {
      _classCallCheck(this, OutletContext);

      this.outlet = null;
      this.route = null;
      this.resolver = null;
      this.children = new ChildrenOutletContexts();
      this.attachRef = null;
    };

    if (false) {}
    /**
     * Store contextual information about the children (= nested) `RouterOutlet`
     *
     * \@publicApi
     */


    var ChildrenOutletContexts = /*#__PURE__*/function () {
      function ChildrenOutletContexts() {
        _classCallCheck(this, ChildrenOutletContexts);

        // contexts for child outlets, by name.
        this.contexts = new Map();
      }
      /**
       * Called when a `RouterOutlet` directive is instantiated
       * @param {?} childName
       * @param {?} outlet
       * @return {?}
       */


      _createClass2(ChildrenOutletContexts, [{
        key: "onChildOutletCreated",
        value: function onChildOutletCreated(childName, outlet) {
          /** @type {?} */
          var context = this.getOrCreateContext(childName);
          context.outlet = outlet;
          this.contexts.set(childName, context);
        }
        /**
         * Called when a `RouterOutlet` directive is destroyed.
         * We need to keep the context as the outlet could be destroyed inside a NgIf and might be
         * re-created later.
         * @param {?} childName
         * @return {?}
         */

      }, {
        key: "onChildOutletDestroyed",
        value: function onChildOutletDestroyed(childName) {
          /** @type {?} */
          var context = this.getContext(childName);

          if (context) {
            context.outlet = null;
          }
        }
        /**
         * Called when the corresponding route is deactivated during navigation.
         * Because the component get destroyed, all children outlet are destroyed.
         * @return {?}
         */

      }, {
        key: "onOutletDeactivated",
        value: function onOutletDeactivated() {
          /** @type {?} */
          var contexts = this.contexts;
          this.contexts = new Map();
          return contexts;
        }
        /**
         * @param {?} contexts
         * @return {?}
         */

      }, {
        key: "onOutletReAttached",
        value: function onOutletReAttached(contexts) {
          this.contexts = contexts;
        }
        /**
         * @param {?} childName
         * @return {?}
         */

      }, {
        key: "getOrCreateContext",
        value: function getOrCreateContext(childName) {
          /** @type {?} */
          var context = this.getContext(childName);

          if (!context) {
            context = new OutletContext();
            this.contexts.set(childName, context);
          }

          return context;
        }
        /**
         * @param {?} childName
         * @return {?}
         */

      }, {
        key: "getContext",
        value: function getContext(childName) {
          return this.contexts.get(childName) || null;
        }
      }]);

      return ChildrenOutletContexts;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/directives/router_outlet.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@description
     *
     * Acts as a placeholder that Angular dynamically fills based on the current router state.
     *
     * Each outlet can have a unique name, determined by the optional `name` attribute.
     * The name cannot be set or changed dynamically. If not set, default value is "primary".
     *
     * ```
     * <router-outlet></router-outlet>
     * <router-outlet name='left'></router-outlet>
     * <router-outlet name='right'></router-outlet>
     * ```
     *
     * A router outlet emits an activate event when a new component is instantiated,
     * and a deactivate event when a component is destroyed.
     *
     * ```
     * <router-outlet
     *   (activate)='onActivate($event)'
     *   (deactivate)='onDeactivate($event)'></router-outlet>
     * ```
     * \@ngModule RouterModule
     *
     * \@publicApi
     */


    var RouterOutlet = /*#__PURE__*/function () {
      /**
       * @param {?} parentContexts
       * @param {?} location
       * @param {?} resolver
       * @param {?} name
       * @param {?} changeDetector
       */
      function RouterOutlet(parentContexts, location, resolver, name, changeDetector) {
        _classCallCheck(this, RouterOutlet);

        this.parentContexts = parentContexts;
        this.location = location;
        this.resolver = resolver;
        this.changeDetector = changeDetector;
        this.activated = null;
        this._activatedRoute = null;
        this.activateEvents = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"]();
        this.deactivateEvents = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["EventEmitter"]();
        this.name = name || PRIMARY_OUTLET;
        parentContexts.onChildOutletCreated(this.name, this);
      }
      /**
       * @return {?}
       */


      _createClass2(RouterOutlet, [{
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this.parentContexts.onChildOutletDestroyed(this.name);
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnInit",
        value: function ngOnInit() {
          if (!this.activated) {
            // If the outlet was not instantiated at the time the route got activated we need to populate
            // the outlet when it is initialized (ie inside a NgIf)

            /** @type {?} */
            var context = this.parentContexts.getContext(this.name);

            if (context && context.route) {
              if (context.attachRef) {
                // `attachRef` is populated when there is an existing component to mount
                this.attach(context.attachRef, context.route);
              } else {
                // otherwise the component defined in the configuration is created
                this.activateWith(context.route, context.resolver || null);
              }
            }
          }
        }
        /**
         * @return {?}
         */

      }, {
        key: "detach",

        /**
         * Called when the `RouteReuseStrategy` instructs to detach the subtree
         * @return {?}
         */
        value: function detach() {
          if (!this.activated) throw new Error('Outlet is not activated');
          this.location.detach();
          /** @type {?} */

          var cmp = this.activated;
          this.activated = null;
          this._activatedRoute = null;
          return cmp;
        }
        /**
         * Called when the `RouteReuseStrategy` instructs to re-attach a previously detached subtree
         * @param {?} ref
         * @param {?} activatedRoute
         * @return {?}
         */

      }, {
        key: "attach",
        value: function attach(ref, activatedRoute) {
          this.activated = ref;
          this._activatedRoute = activatedRoute;
          this.location.insert(ref.hostView);
        }
        /**
         * @return {?}
         */

      }, {
        key: "deactivate",
        value: function deactivate() {
          if (this.activated) {
            /** @type {?} */
            var c = this.component;
            this.activated.destroy();
            this.activated = null;
            this._activatedRoute = null;
            this.deactivateEvents.emit(c);
          }
        }
        /**
         * @param {?} activatedRoute
         * @param {?} resolver
         * @return {?}
         */

      }, {
        key: "activateWith",
        value: function activateWith(activatedRoute, resolver) {
          if (this.isActivated) {
            throw new Error('Cannot activate an already activated outlet');
          }

          this._activatedRoute = activatedRoute;
          /** @type {?} */

          var snapshot = activatedRoute._futureSnapshot;
          /** @type {?} */

          var component =
          /** @type {?} */

          /** @type {?} */
          snapshot.routeConfig.component;
          resolver = resolver || this.resolver;
          /** @type {?} */

          var factory = resolver.resolveComponentFactory(component);
          /** @type {?} */

          var childContexts = this.parentContexts.getOrCreateContext(this.name).children;
          /** @type {?} */

          var injector = new OutletInjector(activatedRoute, childContexts, this.location.injector);
          this.activated = this.location.createComponent(factory, this.location.length, injector); // Calling `markForCheck` to make sure we will run the change detection when the
          // `RouterOutlet` is inside a `ChangeDetectionStrategy.OnPush` component.

          this.changeDetector.markForCheck();
          this.activateEvents.emit(this.activated.instance);
        }
      }, {
        key: "isActivated",
        get: function get() {
          return !!this.activated;
        }
        /**
         * @return {?}
         */

      }, {
        key: "component",
        get: function get() {
          if (!this.activated) throw new Error('Outlet is not activated');
          return this.activated.instance;
        }
        /**
         * @return {?}
         */

      }, {
        key: "activatedRoute",
        get: function get() {
          if (!this.activated) throw new Error('Outlet is not activated');
          return (
            /** @type {?} */
            this._activatedRoute
          );
        }
        /**
         * @return {?}
         */

      }, {
        key: "activatedRouteData",
        get: function get() {
          if (this._activatedRoute) {
            return this._activatedRoute.snapshot.data;
          }

          return {};
        }
      }]);

      return RouterOutlet;
    }();

    RouterOutlet.ɵfac = function RouterOutlet_Factory(t) {
      return new (t || RouterOutlet)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](ChildrenOutletContexts), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewContainerRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["ComponentFactoryResolver"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinjectAttribute"]('name'), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["ChangeDetectorRef"]));
    };

    RouterOutlet.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineDirective"]({
      type: RouterOutlet,
      selectors: [["router-outlet"]],
      outputs: {
        activateEvents: "activate",
        deactivateEvents: "deactivate"
      },
      exportAs: ["outlet"]
    });
    /** @nocollapse */

    RouterOutlet.ctorParameters = function () {
      return [{
        type: ChildrenOutletContexts
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewContainerRef"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ComponentFactoryResolver"]
      }, {
        type: String,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Attribute"],
          args: ['name']
        }]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ChangeDetectorRef"]
      }];
    };

    RouterOutlet.propDecorators = {
      activateEvents: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"],
        args: ['activate']
      }],
      deactivateEvents: [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"],
        args: ['deactivate']
      }]
    };
    /*@__PURE__*/

    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](RouterOutlet, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Directive"],
        args: [{
          selector: 'router-outlet',
          exportAs: 'outlet'
        }]
      }], function () {
        return [{
          type: ChildrenOutletContexts
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ViewContainerRef"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ComponentFactoryResolver"]
        }, {
          type: String,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Attribute"],
            args: ['name']
          }]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ChangeDetectorRef"]
        }];
      }, {
        activateEvents: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"],
          args: ['activate']
        }],
        deactivateEvents: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Output"],
          args: ['deactivate']
        }]
      });
    })();

    if (false) {}

    var OutletInjector = /*#__PURE__*/function () {
      /**
       * @param {?} route
       * @param {?} childContexts
       * @param {?} parent
       */
      function OutletInjector(route, childContexts, parent) {
        _classCallCheck(this, OutletInjector);

        this.route = route;
        this.childContexts = childContexts;
        this.parent = parent;
      }
      /**
       * @param {?} token
       * @param {?=} notFoundValue
       * @return {?}
       */


      _createClass2(OutletInjector, [{
        key: "get",
        value: function get(token, notFoundValue) {
          if (token === ActivatedRoute) {
            return this.route;
          }

          if (token === ChildrenOutletContexts) {
            return this.childContexts;
          }

          return this.parent.get(token, notFoundValue);
        }
      }]);

      return OutletInjector;
    }();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/router_preloader.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@description
     *
     * Provides a preloading strategy.
     *
     * \@publicApi
     * @abstract
     */


    var PreloadingStrategy = function PreloadingStrategy() {
      _classCallCheck(this, PreloadingStrategy);
    };

    if (false) {}
    /**
     * \@description
     *
     * Provides a preloading strategy that preloads all modules as quickly as possible.
     *
     * ```
     * RouteModule.forRoot(ROUTES, {preloadingStrategy: PreloadAllModules})
     * ```
     *
     * \@publicApi
     */


    var PreloadAllModules = /*#__PURE__*/function () {
      function PreloadAllModules() {
        _classCallCheck(this, PreloadAllModules);
      }

      _createClass2(PreloadAllModules, [{
        key: "preload",

        /**
         * @param {?} route
         * @param {?} fn
         * @return {?}
         */
        value: function preload(route, fn) {
          return fn().pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["catchError"])(
          /**
          * @return {?}
          */
          function () {
            return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(null);
          }));
        }
      }]);

      return PreloadAllModules;
    }();
    /**
     * \@description
     *
     * Provides a preloading strategy that does not preload any modules.
     *
     * This strategy is enabled by default.
     *
     * \@publicApi
     */


    var NoPreloading = /*#__PURE__*/function () {
      function NoPreloading() {
        _classCallCheck(this, NoPreloading);
      }

      _createClass2(NoPreloading, [{
        key: "preload",

        /**
         * @param {?} route
         * @param {?} fn
         * @return {?}
         */
        value: function preload(route, fn) {
          return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(null);
        }
      }]);

      return NoPreloading;
    }();
    /**
     * The preloader optimistically loads all router configurations to
     * make navigations into lazily-loaded sections of the application faster.
     *
     * The preloader runs in the background. When the router bootstraps, the preloader
     * starts listening to all navigation events. After every such event, the preloader
     * will check if any configurations can be loaded lazily.
     *
     * If a route is protected by `canLoad` guards, the preloaded will not load it.
     *
     * \@publicApi
     */


    var RouterPreloader = /*#__PURE__*/function () {
      /**
       * @param {?} router
       * @param {?} moduleLoader
       * @param {?} compiler
       * @param {?} injector
       * @param {?} preloadingStrategy
       */
      function RouterPreloader(router, moduleLoader, compiler, injector, preloadingStrategy) {
        _classCallCheck(this, RouterPreloader);

        this.router = router;
        this.injector = injector;
        this.preloadingStrategy = preloadingStrategy;
        /** @type {?} */

        var onStartLoad =
        /**
        * @param {?} r
        * @return {?}
        */
        function onStartLoad(r) {
          return router.triggerEvent(new RouteConfigLoadStart(r));
        };
        /** @type {?} */


        var onEndLoad =
        /**
        * @param {?} r
        * @return {?}
        */
        function onEndLoad(r) {
          return router.triggerEvent(new RouteConfigLoadEnd(r));
        };

        this.loader = new RouterConfigLoader(moduleLoader, compiler, onStartLoad, onEndLoad);
      }
      /**
       * @return {?}
       */


      _createClass2(RouterPreloader, [{
        key: "setUpPreloading",
        value: function setUpPreloading() {
          var _this310 = this;

          this.subscription = this.router.events.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["filter"])(
          /**
          * @param {?} e
          * @return {?}
          */
          function (e) {
            return e instanceof NavigationEnd;
          }), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["concatMap"])(
          /**
          * @return {?}
          */
          function () {
            return _this310.preload();
          })).subscribe(
          /**
          * @return {?}
          */
          function () {});
        }
        /**
         * @return {?}
         */

      }, {
        key: "preload",
        value: function preload() {
          /** @type {?} */
          var ngModule = this.injector.get(_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModuleRef"]);
          return this.processRoutes(ngModule, this.router.config);
        } // TODO(jasonaden): This class relies on code external to the class to call setUpPreloading. If
        // this hasn't been done, ngOnDestroy will fail as this.subscription will be undefined. This
        // should be refactored.

        /**
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          this.subscription.unsubscribe();
        }
        /**
         * @private
         * @param {?} ngModule
         * @param {?} routes
         * @return {?}
         */

      }, {
        key: "processRoutes",
        value: function processRoutes(ngModule, routes) {
          /** @type {?} */
          var res = [];

          var _iterator26 = _createForOfIteratorHelper(routes),
              _step26;

          try {
            for (_iterator26.s(); !(_step26 = _iterator26.n()).done;) {
              var route = _step26.value;

              // we already have the config loaded, just recurse
              if (route.loadChildren && !route.canLoad && route._loadedConfig) {
                /** @type {?} */
                var childConfig = route._loadedConfig;
                res.push(this.processRoutes(childConfig.module, childConfig.routes)); // no config loaded, fetch the config
              } else if (route.loadChildren && !route.canLoad) {
                res.push(this.preloadConfig(ngModule, route)); // recurse into children
              } else if (route.children) {
                res.push(this.processRoutes(ngModule, route.children));
              }
            }
          } catch (err) {
            _iterator26.e(err);
          } finally {
            _iterator26.f();
          }

          return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["from"])(res).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["mergeAll"])(), Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(
          /**
          * @param {?} _
          * @return {?}
          */
          function (_) {
            return void 0;
          }));
        }
        /**
         * @private
         * @param {?} ngModule
         * @param {?} route
         * @return {?}
         */

      }, {
        key: "preloadConfig",
        value: function preloadConfig(ngModule, route) {
          var _this311 = this;

          return this.preloadingStrategy.preload(route,
          /**
          * @return {?}
          */
          function () {
            /** @type {?} */
            var loaded$ = _this311.loader.load(ngModule.injector, route);

            return loaded$.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["mergeMap"])(
            /**
            * @param {?} config
            * @return {?}
            */
            function (config) {
              route._loadedConfig = config;
              return _this311.processRoutes(config.module, config.routes);
            }));
          });
        }
      }]);

      return RouterPreloader;
    }();

    RouterPreloader.ɵfac = function RouterPreloader_Factory(t) {
      return new (t || RouterPreloader)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](Router), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModuleFactoryLoader"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["Compiler"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["Injector"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](PreloadingStrategy));
    };

    RouterPreloader.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"]({
      token: RouterPreloader,
      factory: RouterPreloader.ɵfac
    });
    /** @nocollapse */

    RouterPreloader.ctorParameters = function () {
      return [{
        type: Router
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModuleFactoryLoader"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Compiler"]
      }, {
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injector"]
      }, {
        type: PreloadingStrategy
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](RouterPreloader, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"]
      }], function () {
        return [{
          type: Router
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModuleFactoryLoader"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Compiler"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injector"]
        }, {
          type: PreloadingStrategy
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/router_scroller.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */


    var RouterScroller = /*#__PURE__*/function () {
      /**
       * @param {?} router
       * @param {?} viewportScroller
       * @param {?=} options
       */
      function RouterScroller(router, viewportScroller) {
        var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};

        _classCallCheck(this, RouterScroller);

        this.router = router;
        this.viewportScroller = viewportScroller;
        this.options = options;
        this.lastId = 0;
        this.lastSource = 'imperative';
        this.restoredId = 0;
        this.store = {}; // Default both options to 'disabled'

        options.scrollPositionRestoration = options.scrollPositionRestoration || 'disabled';
        options.anchorScrolling = options.anchorScrolling || 'disabled';
      }
      /**
       * @return {?}
       */


      _createClass2(RouterScroller, [{
        key: "init",
        value: function init() {
          // we want to disable the automatic scrolling because having two places
          // responsible for scrolling results race conditions, especially given
          // that browser don't implement this behavior consistently
          if (this.options.scrollPositionRestoration !== 'disabled') {
            this.viewportScroller.setHistoryScrollRestoration('manual');
          }

          this.routerEventsSubscription = this.createScrollEvents();
          this.scrollEventsSubscription = this.consumeScrollEvents();
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "createScrollEvents",
        value: function createScrollEvents() {
          var _this312 = this;

          return this.router.events.subscribe(
          /**
          * @param {?} e
          * @return {?}
          */
          function (e) {
            if (e instanceof NavigationStart) {
              // store the scroll position of the current stable navigations.
              _this312.store[_this312.lastId] = _this312.viewportScroller.getScrollPosition();
              _this312.lastSource = e.navigationTrigger;
              _this312.restoredId = e.restoredState ? e.restoredState.navigationId : 0;
            } else if (e instanceof NavigationEnd) {
              _this312.lastId = e.id;

              _this312.scheduleScrollEvent(e, _this312.router.parseUrl(e.urlAfterRedirects).fragment);
            }
          });
        }
        /**
         * @private
         * @return {?}
         */

      }, {
        key: "consumeScrollEvents",
        value: function consumeScrollEvents() {
          var _this313 = this;

          return this.router.events.subscribe(
          /**
          * @param {?} e
          * @return {?}
          */
          function (e) {
            if (!(e instanceof Scroll)) return; // a popstate event. The pop state event will always ignore anchor scrolling.

            if (e.position) {
              if (_this313.options.scrollPositionRestoration === 'top') {
                _this313.viewportScroller.scrollToPosition([0, 0]);
              } else if (_this313.options.scrollPositionRestoration === 'enabled') {
                _this313.viewportScroller.scrollToPosition(e.position);
              } // imperative navigation "forward"

            } else {
              if (e.anchor && _this313.options.anchorScrolling === 'enabled') {
                _this313.viewportScroller.scrollToAnchor(e.anchor);
              } else if (_this313.options.scrollPositionRestoration !== 'disabled') {
                _this313.viewportScroller.scrollToPosition([0, 0]);
              }
            }
          });
        }
        /**
         * @private
         * @param {?} routerEvent
         * @param {?} anchor
         * @return {?}
         */

      }, {
        key: "scheduleScrollEvent",
        value: function scheduleScrollEvent(routerEvent, anchor) {
          this.router.triggerEvent(new Scroll(routerEvent, this.lastSource === 'popstate' ? this.store[this.restoredId] : null, anchor));
        }
        /**
         * @return {?}
         */

      }, {
        key: "ngOnDestroy",
        value: function ngOnDestroy() {
          if (this.routerEventsSubscription) {
            this.routerEventsSubscription.unsubscribe();
          }

          if (this.scrollEventsSubscription) {
            this.scrollEventsSubscription.unsubscribe();
          }
        }
      }]);

      return RouterScroller;
    }();

    RouterScroller.ɵfac = function RouterScroller_Factory(t) {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinvalidFactory"]();
    };

    RouterScroller.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineDirective"]({
      type: RouterScroller
    });

    if (false) {}
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/router_module.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * The directives defined in the `RouterModule`.
     * @type {?}
     */


    var ROUTER_DIRECTIVES = [RouterOutlet, RouterLink, RouterLinkWithHref, RouterLinkActive, ɵEmptyOutletComponent];
    /**
     * A [DI token](guide/glossary/#di-token) for the router service.
     *
     * \@publicApi
     * @type {?}
     */

    var ROUTER_CONFIGURATION = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["InjectionToken"]('ROUTER_CONFIGURATION');
    /**
     * \@docsNotRequired
     * @type {?}
     */

    var ROUTER_FORROOT_GUARD = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["InjectionToken"]('ROUTER_FORROOT_GUARD');
    var ɵ0 = {
      enableTracing: false
    };
    /** @type {?} */

    var ROUTER_PROVIDERS = [_angular_common__WEBPACK_IMPORTED_MODULE_0__["Location"], {
      provide: UrlSerializer,
      useClass: DefaultUrlSerializer
    }, {
      provide: Router,
      useFactory: setupRouter,
      deps: [UrlSerializer, ChildrenOutletContexts, _angular_common__WEBPACK_IMPORTED_MODULE_0__["Location"], _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injector"], _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModuleFactoryLoader"], _angular_core__WEBPACK_IMPORTED_MODULE_1__["Compiler"], ROUTES, ROUTER_CONFIGURATION, [UrlHandlingStrategy, new _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]()], [RouteReuseStrategy, new _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]()]]
    }, ChildrenOutletContexts, {
      provide: ActivatedRoute,
      useFactory: rootRoute,
      deps: [Router]
    }, {
      provide: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModuleFactoryLoader"],
      useClass: _angular_core__WEBPACK_IMPORTED_MODULE_1__["SystemJsNgModuleLoader"]
    }, RouterPreloader, NoPreloading, PreloadAllModules, {
      provide: ROUTER_CONFIGURATION,
      useValue: ɵ0
    }];
    /**
     * @return {?}
     */

    function routerNgProbeToken() {
      return new _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgProbeToken"]('Router', Router);
    }
    /**
     * \@usageNotes
     *
     * RouterModule can be imported multiple times: once per lazily-loaded bundle.
     * Since the router deals with a global shared resource--location, we cannot have
     * more than one router service active.
     *
     * That is why there are two ways to create the module: `RouterModule.forRoot` and
     * `RouterModule.forChild`.
     *
     * * `forRoot` creates a module that contains all the directives, the given routes, and the router
     *   service itself.
     * * `forChild` creates a module that contains all the directives and the given routes, but does not
     *   include the router service.
     *
     * When registered at the root, the module should be used as follows
     *
     * ```
     * \@NgModule({
     *   imports: [RouterModule.forRoot(ROUTES)]
     * })
     * class MyNgModule {}
     * ```
     *
     * For submodules and lazy loaded submodules the module should be used as follows:
     *
     * ```
     * \@NgModule({
     *   imports: [RouterModule.forChild(ROUTES)]
     * })
     * class MyNgModule {}
     * ```
     *
     * \@description
     *
     * Adds router directives and providers.
     *
     * Managing state transitions is one of the hardest parts of building applications. This is
     * especially true on the web, where you also need to ensure that the state is reflected in the URL.
     * In addition, we often want to split applications into multiple bundles and load them on demand.
     * Doing this transparently is not trivial.
     *
     * The Angular router service solves these problems. Using the router, you can declaratively specify
     * application states, manage state transitions while taking care of the URL, and load bundles on
     * demand.
     *
     * @see [Routing and Navigation](guide/router.html) for an
     * overview of how the router service should be used.
     *
     * \@publicApi
     */


    var RouterModule = /*#__PURE__*/function () {
      // Note: We are injecting the Router so it gets created eagerly...

      /**
       * @param {?} guard
       * @param {?} router
       */
      function RouterModule(guard, router) {
        _classCallCheck(this, RouterModule);
      }
      /**
       * Creates and configures a module with all the router providers and directives.
       * Optionally sets up an application listener to perform an initial navigation.
       *
       * @param {?} routes An array of `Route` objects that define the navigation paths for the application.
       * @param {?=} config An `ExtraOptions` configuration object that controls how navigation is performed.
       * @return {?} The new router module.
       */


      _createClass2(RouterModule, null, [{
        key: "forRoot",
        value: function forRoot(routes, config) {
          return {
            ngModule: RouterModule,
            providers: [ROUTER_PROVIDERS, provideRoutes(routes), {
              provide: ROUTER_FORROOT_GUARD,
              useFactory: provideForRootGuard,
              deps: [[Router, new _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"](), new _angular_core__WEBPACK_IMPORTED_MODULE_1__["SkipSelf"]()]]
            }, {
              provide: ROUTER_CONFIGURATION,
              useValue: config ? config : {}
            }, {
              provide: _angular_common__WEBPACK_IMPORTED_MODULE_0__["LocationStrategy"],
              useFactory: provideLocationStrategy,
              deps: [_angular_common__WEBPACK_IMPORTED_MODULE_0__["PlatformLocation"], [new _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"](_angular_common__WEBPACK_IMPORTED_MODULE_0__["APP_BASE_HREF"]), new _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]()], ROUTER_CONFIGURATION]
            }, {
              provide: RouterScroller,
              useFactory: createRouterScroller,
              deps: [Router, _angular_common__WEBPACK_IMPORTED_MODULE_0__["ViewportScroller"], ROUTER_CONFIGURATION]
            }, {
              provide: PreloadingStrategy,
              useExisting: config && config.preloadingStrategy ? config.preloadingStrategy : NoPreloading
            }, {
              provide: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgProbeToken"],
              multi: true,
              useFactory: routerNgProbeToken
            }, provideRouterInitializer()]
          };
        }
        /**
         * Creates a module with all the router directives and a provider registering routes.
         * @param {?} routes
         * @return {?}
         */

      }, {
        key: "forChild",
        value: function forChild(routes) {
          return {
            ngModule: RouterModule,
            providers: [provideRoutes(routes)]
          };
        }
      }]);

      return RouterModule;
    }();

    RouterModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineNgModule"]({
      type: RouterModule
    });
    RouterModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjector"]({
      factory: function RouterModule_Factory(t) {
        return new (t || RouterModule)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](ROUTER_FORROOT_GUARD, 8), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](Router, 8));
      }
    });
    /** @nocollapse */

    RouterModule.ctorParameters = function () {
      return [{
        type: undefined,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }, {
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
          args: [ROUTER_FORROOT_GUARD]
        }]
      }, {
        type: Router,
        decorators: [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
        }]
      }];
    };

    (function () {
      (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵsetNgModuleScope"](RouterModule, {
        declarations: [RouterOutlet, RouterLink, RouterLinkWithHref, RouterLinkActive, ɵEmptyOutletComponent],
        exports: [RouterOutlet, RouterLink, RouterLinkWithHref, RouterLinkActive, ɵEmptyOutletComponent]
      });
    })();
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](RouterModule, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["NgModule"],
        args: [{
          declarations: ROUTER_DIRECTIVES,
          exports: ROUTER_DIRECTIVES,
          entryComponents: [ɵEmptyOutletComponent]
        }]
      }], function () {
        return [{
          type: undefined,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }, {
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Inject"],
            args: [ROUTER_FORROOT_GUARD]
          }]
        }, {
          type: Router,
          decorators: [{
            type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Optional"]
          }]
        }];
      }, null);
    })();
    /**
     * @param {?} router
     * @param {?} viewportScroller
     * @param {?} config
     * @return {?}
     */


    function createRouterScroller(router, viewportScroller, config) {
      if (config.scrollOffset) {
        viewportScroller.setOffset(config.scrollOffset);
      }

      return new RouterScroller(router, viewportScroller, config);
    }
    /**
     * @param {?} platformLocationStrategy
     * @param {?} baseHref
     * @param {?=} options
     * @return {?}
     */


    function provideLocationStrategy(platformLocationStrategy, baseHref) {
      var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
      return options.useHash ? new _angular_common__WEBPACK_IMPORTED_MODULE_0__["HashLocationStrategy"](platformLocationStrategy, baseHref) : new _angular_common__WEBPACK_IMPORTED_MODULE_0__["PathLocationStrategy"](platformLocationStrategy, baseHref);
    }
    /**
     * @param {?} router
     * @return {?}
     */


    function provideForRootGuard(router) {
      if (router) {
        throw new Error("RouterModule.forRoot() called twice. Lazy loaded modules should use RouterModule.forChild() instead.");
      }

      return 'guarded';
    }
    /**
     * Registers a [DI provider](guide/glossary#provider) for a set of routes.
     * \@usageNotes
     *
     * ```
     * \@NgModule({
     *   imports: [RouterModule.forChild(ROUTES)],
     *   providers: [provideRoutes(EXTRA_ROUTES)]
     * })
     * class MyNgModule {}
     * ```
     *
     * \@publicApi
     * @param {?} routes The route configuration to provide.
     *
     * @return {?}
     */


    function provideRoutes(routes) {
      return [{
        provide: _angular_core__WEBPACK_IMPORTED_MODULE_1__["ANALYZE_FOR_ENTRY_COMPONENTS"],
        multi: true,
        useValue: routes
      }, {
        provide: ROUTES,
        multi: true,
        useValue: routes
      }];
    }
    /**
     * A set of configuration options for a router module, provided in the
     * `forRoot()` method.
     *
     * \@publicApi
     * @record
     */


    function ExtraOptions() {}

    if (false) {}
    /**
     * @param {?} urlSerializer
     * @param {?} contexts
     * @param {?} location
     * @param {?} injector
     * @param {?} loader
     * @param {?} compiler
     * @param {?} config
     * @param {?=} opts
     * @param {?=} urlHandlingStrategy
     * @param {?=} routeReuseStrategy
     * @return {?}
     */


    function setupRouter(urlSerializer, contexts, location, injector, loader, compiler, config) {
      var opts = arguments.length > 7 && arguments[7] !== undefined ? arguments[7] : {};
      var urlHandlingStrategy = arguments.length > 8 ? arguments[8] : undefined;
      var routeReuseStrategy = arguments.length > 9 ? arguments[9] : undefined;

      /** @type {?} */
      var router = new Router(null, urlSerializer, contexts, location, injector, loader, compiler, flatten(config));

      if (urlHandlingStrategy) {
        router.urlHandlingStrategy = urlHandlingStrategy;
      }

      if (routeReuseStrategy) {
        router.routeReuseStrategy = routeReuseStrategy;
      }

      if (opts.errorHandler) {
        router.errorHandler = opts.errorHandler;
      }

      if (opts.malformedUriErrorHandler) {
        router.malformedUriErrorHandler = opts.malformedUriErrorHandler;
      }

      if (opts.enableTracing) {
        /** @type {?} */
        var dom = Object(_angular_common__WEBPACK_IMPORTED_MODULE_0__["ɵgetDOM"])();
        router.events.subscribe(
        /**
        * @param {?} e
        * @return {?}
        */
        function (e) {
          dom.logGroup("Router Event: ".concat(
          /** @type {?} */
          e.constructor.name));
          dom.log(e.toString());
          dom.log(e);
          dom.logGroupEnd();
        });
      }

      if (opts.onSameUrlNavigation) {
        router.onSameUrlNavigation = opts.onSameUrlNavigation;
      }

      if (opts.paramsInheritanceStrategy) {
        router.paramsInheritanceStrategy = opts.paramsInheritanceStrategy;
      }

      if (opts.urlUpdateStrategy) {
        router.urlUpdateStrategy = opts.urlUpdateStrategy;
      }

      if (opts.relativeLinkResolution) {
        router.relativeLinkResolution = opts.relativeLinkResolution;
      }

      return router;
    }
    /**
     * @param {?} router
     * @return {?}
     */


    function rootRoute(router) {
      return router.routerState.root;
    }
    /**
     * Router initialization requires two steps:
     *
     * First, we start the navigation in a `APP_INITIALIZER` to block the bootstrap if
     * a resolver or a guard executes asynchronously.
     *
     * Next, we actually run activation in a `BOOTSTRAP_LISTENER`, using the
     * `afterPreactivation` hook provided by the router.
     * The router navigation starts, reaches the point when preactivation is done, and then
     * pauses. It waits for the hook to be resolved. We then resolve it only in a bootstrap listener.
     */


    var RouterInitializer = /*#__PURE__*/function () {
      /**
       * @param {?} injector
       */
      function RouterInitializer(injector) {
        _classCallCheck(this, RouterInitializer);

        this.injector = injector;
        this.initNavigation = false;
        this.resultOfPreactivationDone = new rxjs__WEBPACK_IMPORTED_MODULE_2__["Subject"]();
      }
      /**
       * @return {?}
       */


      _createClass2(RouterInitializer, [{
        key: "appInitializer",
        value: function appInitializer() {
          var _this314 = this;

          /** @type {?} */
          var p = this.injector.get(_angular_common__WEBPACK_IMPORTED_MODULE_0__["LOCATION_INITIALIZED"], Promise.resolve(null));
          return p.then(
          /**
          * @return {?}
          */
          function () {
            /** @type {?} */
            var resolve =
            /** @type {?} */
            null;
            /** @type {?} */

            var res = new Promise(
            /**
            * @param {?} r
            * @return {?}
            */
            function (r) {
              return resolve = r;
            });
            /** @type {?} */

            var router = _this314.injector.get(Router);
            /** @type {?} */


            var opts = _this314.injector.get(ROUTER_CONFIGURATION);

            if (_this314.isLegacyDisabled(opts) || _this314.isLegacyEnabled(opts)) {
              resolve(true);
            } else if (opts.initialNavigation === 'disabled') {
              router.setUpLocationChangeListener();
              resolve(true);
            } else if (opts.initialNavigation === 'enabled') {
              router.hooks.afterPreactivation =
              /**
              * @return {?}
              */
              function () {
                // only the initial navigation should be delayed
                if (!_this314.initNavigation) {
                  _this314.initNavigation = true;
                  resolve(true);
                  return _this314.resultOfPreactivationDone; // subsequent navigations should not be delayed
                } else {
                  return (
                    /** @type {?} */
                    Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["of"])(null)
                  );
                }
              };

              router.initialNavigation();
            } else {
              throw new Error("Invalid initialNavigation options: '".concat(opts.initialNavigation, "'"));
            }

            return res;
          });
        }
        /**
         * @param {?} bootstrappedComponentRef
         * @return {?}
         */

      }, {
        key: "bootstrapListener",
        value: function bootstrapListener(bootstrappedComponentRef) {
          /** @type {?} */
          var opts = this.injector.get(ROUTER_CONFIGURATION);
          /** @type {?} */

          var preloader = this.injector.get(RouterPreloader);
          /** @type {?} */

          var routerScroller = this.injector.get(RouterScroller);
          /** @type {?} */

          var router = this.injector.get(Router);
          /** @type {?} */

          var ref = this.injector.get(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ApplicationRef"]);

          if (bootstrappedComponentRef !== ref.components[0]) {
            return;
          }

          if (this.isLegacyEnabled(opts)) {
            router.initialNavigation();
          } else if (this.isLegacyDisabled(opts)) {
            router.setUpLocationChangeListener();
          }

          preloader.setUpPreloading();
          routerScroller.init();
          router.resetRootComponentType(ref.componentTypes[0]);
          this.resultOfPreactivationDone.next(
          /** @type {?} */
          null);
          this.resultOfPreactivationDone.complete();
        }
        /**
         * @private
         * @param {?} opts
         * @return {?}
         */

      }, {
        key: "isLegacyEnabled",
        value: function isLegacyEnabled(opts) {
          return opts.initialNavigation === 'legacy_enabled' || opts.initialNavigation === true || opts.initialNavigation === undefined;
        }
        /**
         * @private
         * @param {?} opts
         * @return {?}
         */

      }, {
        key: "isLegacyDisabled",
        value: function isLegacyDisabled(opts) {
          return opts.initialNavigation === 'legacy_disabled' || opts.initialNavigation === false;
        }
      }]);

      return RouterInitializer;
    }();

    RouterInitializer.ɵfac = function RouterInitializer_Factory(t) {
      return new (t || RouterInitializer)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["Injector"]));
    };

    RouterInitializer.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"]({
      token: RouterInitializer,
      factory: RouterInitializer.ɵfac
    });
    /** @nocollapse */

    RouterInitializer.ctorParameters = function () {
      return [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injector"]
      }];
    };
    /*@__PURE__*/


    (function () {
      _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵsetClassMetadata"](RouterInitializer, [{
        type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injectable"]
      }], function () {
        return [{
          type: _angular_core__WEBPACK_IMPORTED_MODULE_1__["Injector"]
        }];
      }, null);
    })();

    if (false) {}
    /**
     * @param {?} r
     * @return {?}
     */


    function getAppInitializer(r) {
      return r.appInitializer.bind(r);
    }
    /**
     * @param {?} r
     * @return {?}
     */


    function getBootstrapListener(r) {
      return r.bootstrapListener.bind(r);
    }
    /**
     * A [DI token](guide/glossary/#di-token) for the router initializer that
     * is called after the app is bootstrapped.
     *
     * \@publicApi
     * @type {?}
     */


    var ROUTER_INITIALIZER = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["InjectionToken"]('Router Initializer');
    /**
     * @return {?}
     */

    function provideRouterInitializer() {
      return [RouterInitializer, {
        provide: _angular_core__WEBPACK_IMPORTED_MODULE_1__["APP_INITIALIZER"],
        multi: true,
        useFactory: getAppInitializer,
        deps: [RouterInitializer]
      }, {
        provide: ROUTER_INITIALIZER,
        useFactory: getBootstrapListener,
        deps: [RouterInitializer]
      }, {
        provide: _angular_core__WEBPACK_IMPORTED_MODULE_1__["APP_BOOTSTRAP_LISTENER"],
        multi: true,
        useExisting: ROUTER_INITIALIZER
      }];
    }
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/version.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * \@publicApi
     * @type {?}
     */


    var VERSION = new _angular_core__WEBPACK_IMPORTED_MODULE_1__["Version"]('9.1.4');
    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/private_export.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/src/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/public_api.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * @fileoverview added by tsickle
     * Generated from: packages/router/index.ts
     * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
     */

    /**
     * Generated bundle index. Do not edit.
     */
    //# sourceMappingURL=router.js.map

    /***/
  },

  /***/
  "./node_modules/rxjs/_esm2015/index.js":
  /*!*********************************************!*\
    !*** ./node_modules/rxjs/_esm2015/index.js ***!
    \*********************************************/

  /*! exports provided: Observable, ConnectableObservable, GroupedObservable, observable, Subject, BehaviorSubject, ReplaySubject, AsyncSubject, asapScheduler, asyncScheduler, queueScheduler, animationFrameScheduler, VirtualTimeScheduler, VirtualAction, Scheduler, Subscription, Subscriber, Notification, NotificationKind, pipe, noop, identity, isObservable, ArgumentOutOfRangeError, EmptyError, ObjectUnsubscribedError, UnsubscriptionError, TimeoutError, bindCallback, bindNodeCallback, combineLatest, concat, defer, empty, forkJoin, from, fromEvent, fromEventPattern, generate, iif, interval, merge, never, of, onErrorResumeNext, pairs, partition, race, range, throwError, timer, using, zip, scheduled, EMPTY, NEVER, config */

  /***/
  function node_modulesRxjs_esm2015IndexJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony import */


    var _internal_Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./internal/Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "Observable", function () {
      return _internal_Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"];
    });
    /* harmony import */


    var _internal_observable_ConnectableObservable__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./internal/observable/ConnectableObservable */
    "./node_modules/rxjs/_esm2015/internal/observable/ConnectableObservable.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "ConnectableObservable", function () {
      return _internal_observable_ConnectableObservable__WEBPACK_IMPORTED_MODULE_1__["ConnectableObservable"];
    });
    /* harmony import */


    var _internal_operators_groupBy__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ./internal/operators/groupBy */
    "./node_modules/rxjs/_esm2015/internal/operators/groupBy.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "GroupedObservable", function () {
      return _internal_operators_groupBy__WEBPACK_IMPORTED_MODULE_2__["GroupedObservable"];
    });
    /* harmony import */


    var _internal_symbol_observable__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ./internal/symbol/observable */
    "./node_modules/rxjs/_esm2015/internal/symbol/observable.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "observable", function () {
      return _internal_symbol_observable__WEBPACK_IMPORTED_MODULE_3__["observable"];
    });
    /* harmony import */


    var _internal_Subject__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ./internal/Subject */
    "./node_modules/rxjs/_esm2015/internal/Subject.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "Subject", function () {
      return _internal_Subject__WEBPACK_IMPORTED_MODULE_4__["Subject"];
    });
    /* harmony import */


    var _internal_BehaviorSubject__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(
    /*! ./internal/BehaviorSubject */
    "./node_modules/rxjs/_esm2015/internal/BehaviorSubject.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "BehaviorSubject", function () {
      return _internal_BehaviorSubject__WEBPACK_IMPORTED_MODULE_5__["BehaviorSubject"];
    });
    /* harmony import */


    var _internal_ReplaySubject__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(
    /*! ./internal/ReplaySubject */
    "./node_modules/rxjs/_esm2015/internal/ReplaySubject.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "ReplaySubject", function () {
      return _internal_ReplaySubject__WEBPACK_IMPORTED_MODULE_6__["ReplaySubject"];
    });
    /* harmony import */


    var _internal_AsyncSubject__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(
    /*! ./internal/AsyncSubject */
    "./node_modules/rxjs/_esm2015/internal/AsyncSubject.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "AsyncSubject", function () {
      return _internal_AsyncSubject__WEBPACK_IMPORTED_MODULE_7__["AsyncSubject"];
    });
    /* harmony import */


    var _internal_scheduler_asap__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(
    /*! ./internal/scheduler/asap */
    "./node_modules/rxjs/_esm2015/internal/scheduler/asap.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "asapScheduler", function () {
      return _internal_scheduler_asap__WEBPACK_IMPORTED_MODULE_8__["asap"];
    });
    /* harmony import */


    var _internal_scheduler_async__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(
    /*! ./internal/scheduler/async */
    "./node_modules/rxjs/_esm2015/internal/scheduler/async.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "asyncScheduler", function () {
      return _internal_scheduler_async__WEBPACK_IMPORTED_MODULE_9__["async"];
    });
    /* harmony import */


    var _internal_scheduler_queue__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(
    /*! ./internal/scheduler/queue */
    "./node_modules/rxjs/_esm2015/internal/scheduler/queue.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "queueScheduler", function () {
      return _internal_scheduler_queue__WEBPACK_IMPORTED_MODULE_10__["queue"];
    });
    /* harmony import */


    var _internal_scheduler_animationFrame__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(
    /*! ./internal/scheduler/animationFrame */
    "./node_modules/rxjs/_esm2015/internal/scheduler/animationFrame.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "animationFrameScheduler", function () {
      return _internal_scheduler_animationFrame__WEBPACK_IMPORTED_MODULE_11__["animationFrame"];
    });
    /* harmony import */


    var _internal_scheduler_VirtualTimeScheduler__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(
    /*! ./internal/scheduler/VirtualTimeScheduler */
    "./node_modules/rxjs/_esm2015/internal/scheduler/VirtualTimeScheduler.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "VirtualTimeScheduler", function () {
      return _internal_scheduler_VirtualTimeScheduler__WEBPACK_IMPORTED_MODULE_12__["VirtualTimeScheduler"];
    });
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "VirtualAction", function () {
      return _internal_scheduler_VirtualTimeScheduler__WEBPACK_IMPORTED_MODULE_12__["VirtualAction"];
    });
    /* harmony import */


    var _internal_Scheduler__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(
    /*! ./internal/Scheduler */
    "./node_modules/rxjs/_esm2015/internal/Scheduler.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "Scheduler", function () {
      return _internal_Scheduler__WEBPACK_IMPORTED_MODULE_13__["Scheduler"];
    });
    /* harmony import */


    var _internal_Subscription__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(
    /*! ./internal/Subscription */
    "./node_modules/rxjs/_esm2015/internal/Subscription.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "Subscription", function () {
      return _internal_Subscription__WEBPACK_IMPORTED_MODULE_14__["Subscription"];
    });
    /* harmony import */


    var _internal_Subscriber__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(
    /*! ./internal/Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "Subscriber", function () {
      return _internal_Subscriber__WEBPACK_IMPORTED_MODULE_15__["Subscriber"];
    });
    /* harmony import */


    var _internal_Notification__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(
    /*! ./internal/Notification */
    "./node_modules/rxjs/_esm2015/internal/Notification.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "Notification", function () {
      return _internal_Notification__WEBPACK_IMPORTED_MODULE_16__["Notification"];
    });
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "NotificationKind", function () {
      return _internal_Notification__WEBPACK_IMPORTED_MODULE_16__["NotificationKind"];
    });
    /* harmony import */


    var _internal_util_pipe__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(
    /*! ./internal/util/pipe */
    "./node_modules/rxjs/_esm2015/internal/util/pipe.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "pipe", function () {
      return _internal_util_pipe__WEBPACK_IMPORTED_MODULE_17__["pipe"];
    });
    /* harmony import */


    var _internal_util_noop__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(
    /*! ./internal/util/noop */
    "./node_modules/rxjs/_esm2015/internal/util/noop.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "noop", function () {
      return _internal_util_noop__WEBPACK_IMPORTED_MODULE_18__["noop"];
    });
    /* harmony import */


    var _internal_util_identity__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(
    /*! ./internal/util/identity */
    "./node_modules/rxjs/_esm2015/internal/util/identity.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "identity", function () {
      return _internal_util_identity__WEBPACK_IMPORTED_MODULE_19__["identity"];
    });
    /* harmony import */


    var _internal_util_isObservable__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(
    /*! ./internal/util/isObservable */
    "./node_modules/rxjs/_esm2015/internal/util/isObservable.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "isObservable", function () {
      return _internal_util_isObservable__WEBPACK_IMPORTED_MODULE_20__["isObservable"];
    });
    /* harmony import */


    var _internal_util_ArgumentOutOfRangeError__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(
    /*! ./internal/util/ArgumentOutOfRangeError */
    "./node_modules/rxjs/_esm2015/internal/util/ArgumentOutOfRangeError.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "ArgumentOutOfRangeError", function () {
      return _internal_util_ArgumentOutOfRangeError__WEBPACK_IMPORTED_MODULE_21__["ArgumentOutOfRangeError"];
    });
    /* harmony import */


    var _internal_util_EmptyError__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(
    /*! ./internal/util/EmptyError */
    "./node_modules/rxjs/_esm2015/internal/util/EmptyError.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "EmptyError", function () {
      return _internal_util_EmptyError__WEBPACK_IMPORTED_MODULE_22__["EmptyError"];
    });
    /* harmony import */


    var _internal_util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(
    /*! ./internal/util/ObjectUnsubscribedError */
    "./node_modules/rxjs/_esm2015/internal/util/ObjectUnsubscribedError.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "ObjectUnsubscribedError", function () {
      return _internal_util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_23__["ObjectUnsubscribedError"];
    });
    /* harmony import */


    var _internal_util_UnsubscriptionError__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(
    /*! ./internal/util/UnsubscriptionError */
    "./node_modules/rxjs/_esm2015/internal/util/UnsubscriptionError.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "UnsubscriptionError", function () {
      return _internal_util_UnsubscriptionError__WEBPACK_IMPORTED_MODULE_24__["UnsubscriptionError"];
    });
    /* harmony import */


    var _internal_util_TimeoutError__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(
    /*! ./internal/util/TimeoutError */
    "./node_modules/rxjs/_esm2015/internal/util/TimeoutError.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "TimeoutError", function () {
      return _internal_util_TimeoutError__WEBPACK_IMPORTED_MODULE_25__["TimeoutError"];
    });
    /* harmony import */


    var _internal_observable_bindCallback__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(
    /*! ./internal/observable/bindCallback */
    "./node_modules/rxjs/_esm2015/internal/observable/bindCallback.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "bindCallback", function () {
      return _internal_observable_bindCallback__WEBPACK_IMPORTED_MODULE_26__["bindCallback"];
    });
    /* harmony import */


    var _internal_observable_bindNodeCallback__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__(
    /*! ./internal/observable/bindNodeCallback */
    "./node_modules/rxjs/_esm2015/internal/observable/bindNodeCallback.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "bindNodeCallback", function () {
      return _internal_observable_bindNodeCallback__WEBPACK_IMPORTED_MODULE_27__["bindNodeCallback"];
    });
    /* harmony import */


    var _internal_observable_combineLatest__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__(
    /*! ./internal/observable/combineLatest */
    "./node_modules/rxjs/_esm2015/internal/observable/combineLatest.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "combineLatest", function () {
      return _internal_observable_combineLatest__WEBPACK_IMPORTED_MODULE_28__["combineLatest"];
    });
    /* harmony import */


    var _internal_observable_concat__WEBPACK_IMPORTED_MODULE_29__ = __webpack_require__(
    /*! ./internal/observable/concat */
    "./node_modules/rxjs/_esm2015/internal/observable/concat.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "concat", function () {
      return _internal_observable_concat__WEBPACK_IMPORTED_MODULE_29__["concat"];
    });
    /* harmony import */


    var _internal_observable_defer__WEBPACK_IMPORTED_MODULE_30__ = __webpack_require__(
    /*! ./internal/observable/defer */
    "./node_modules/rxjs/_esm2015/internal/observable/defer.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "defer", function () {
      return _internal_observable_defer__WEBPACK_IMPORTED_MODULE_30__["defer"];
    });
    /* harmony import */


    var _internal_observable_empty__WEBPACK_IMPORTED_MODULE_31__ = __webpack_require__(
    /*! ./internal/observable/empty */
    "./node_modules/rxjs/_esm2015/internal/observable/empty.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "empty", function () {
      return _internal_observable_empty__WEBPACK_IMPORTED_MODULE_31__["empty"];
    });
    /* harmony import */


    var _internal_observable_forkJoin__WEBPACK_IMPORTED_MODULE_32__ = __webpack_require__(
    /*! ./internal/observable/forkJoin */
    "./node_modules/rxjs/_esm2015/internal/observable/forkJoin.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "forkJoin", function () {
      return _internal_observable_forkJoin__WEBPACK_IMPORTED_MODULE_32__["forkJoin"];
    });
    /* harmony import */


    var _internal_observable_from__WEBPACK_IMPORTED_MODULE_33__ = __webpack_require__(
    /*! ./internal/observable/from */
    "./node_modules/rxjs/_esm2015/internal/observable/from.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "from", function () {
      return _internal_observable_from__WEBPACK_IMPORTED_MODULE_33__["from"];
    });
    /* harmony import */


    var _internal_observable_fromEvent__WEBPACK_IMPORTED_MODULE_34__ = __webpack_require__(
    /*! ./internal/observable/fromEvent */
    "./node_modules/rxjs/_esm2015/internal/observable/fromEvent.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "fromEvent", function () {
      return _internal_observable_fromEvent__WEBPACK_IMPORTED_MODULE_34__["fromEvent"];
    });
    /* harmony import */


    var _internal_observable_fromEventPattern__WEBPACK_IMPORTED_MODULE_35__ = __webpack_require__(
    /*! ./internal/observable/fromEventPattern */
    "./node_modules/rxjs/_esm2015/internal/observable/fromEventPattern.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "fromEventPattern", function () {
      return _internal_observable_fromEventPattern__WEBPACK_IMPORTED_MODULE_35__["fromEventPattern"];
    });
    /* harmony import */


    var _internal_observable_generate__WEBPACK_IMPORTED_MODULE_36__ = __webpack_require__(
    /*! ./internal/observable/generate */
    "./node_modules/rxjs/_esm2015/internal/observable/generate.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "generate", function () {
      return _internal_observable_generate__WEBPACK_IMPORTED_MODULE_36__["generate"];
    });
    /* harmony import */


    var _internal_observable_iif__WEBPACK_IMPORTED_MODULE_37__ = __webpack_require__(
    /*! ./internal/observable/iif */
    "./node_modules/rxjs/_esm2015/internal/observable/iif.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "iif", function () {
      return _internal_observable_iif__WEBPACK_IMPORTED_MODULE_37__["iif"];
    });
    /* harmony import */


    var _internal_observable_interval__WEBPACK_IMPORTED_MODULE_38__ = __webpack_require__(
    /*! ./internal/observable/interval */
    "./node_modules/rxjs/_esm2015/internal/observable/interval.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "interval", function () {
      return _internal_observable_interval__WEBPACK_IMPORTED_MODULE_38__["interval"];
    });
    /* harmony import */


    var _internal_observable_merge__WEBPACK_IMPORTED_MODULE_39__ = __webpack_require__(
    /*! ./internal/observable/merge */
    "./node_modules/rxjs/_esm2015/internal/observable/merge.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "merge", function () {
      return _internal_observable_merge__WEBPACK_IMPORTED_MODULE_39__["merge"];
    });
    /* harmony import */


    var _internal_observable_never__WEBPACK_IMPORTED_MODULE_40__ = __webpack_require__(
    /*! ./internal/observable/never */
    "./node_modules/rxjs/_esm2015/internal/observable/never.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "never", function () {
      return _internal_observable_never__WEBPACK_IMPORTED_MODULE_40__["never"];
    });
    /* harmony import */


    var _internal_observable_of__WEBPACK_IMPORTED_MODULE_41__ = __webpack_require__(
    /*! ./internal/observable/of */
    "./node_modules/rxjs/_esm2015/internal/observable/of.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "of", function () {
      return _internal_observable_of__WEBPACK_IMPORTED_MODULE_41__["of"];
    });
    /* harmony import */


    var _internal_observable_onErrorResumeNext__WEBPACK_IMPORTED_MODULE_42__ = __webpack_require__(
    /*! ./internal/observable/onErrorResumeNext */
    "./node_modules/rxjs/_esm2015/internal/observable/onErrorResumeNext.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "onErrorResumeNext", function () {
      return _internal_observable_onErrorResumeNext__WEBPACK_IMPORTED_MODULE_42__["onErrorResumeNext"];
    });
    /* harmony import */


    var _internal_observable_pairs__WEBPACK_IMPORTED_MODULE_43__ = __webpack_require__(
    /*! ./internal/observable/pairs */
    "./node_modules/rxjs/_esm2015/internal/observable/pairs.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "pairs", function () {
      return _internal_observable_pairs__WEBPACK_IMPORTED_MODULE_43__["pairs"];
    });
    /* harmony import */


    var _internal_observable_partition__WEBPACK_IMPORTED_MODULE_44__ = __webpack_require__(
    /*! ./internal/observable/partition */
    "./node_modules/rxjs/_esm2015/internal/observable/partition.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "partition", function () {
      return _internal_observable_partition__WEBPACK_IMPORTED_MODULE_44__["partition"];
    });
    /* harmony import */


    var _internal_observable_race__WEBPACK_IMPORTED_MODULE_45__ = __webpack_require__(
    /*! ./internal/observable/race */
    "./node_modules/rxjs/_esm2015/internal/observable/race.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "race", function () {
      return _internal_observable_race__WEBPACK_IMPORTED_MODULE_45__["race"];
    });
    /* harmony import */


    var _internal_observable_range__WEBPACK_IMPORTED_MODULE_46__ = __webpack_require__(
    /*! ./internal/observable/range */
    "./node_modules/rxjs/_esm2015/internal/observable/range.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "range", function () {
      return _internal_observable_range__WEBPACK_IMPORTED_MODULE_46__["range"];
    });
    /* harmony import */


    var _internal_observable_throwError__WEBPACK_IMPORTED_MODULE_47__ = __webpack_require__(
    /*! ./internal/observable/throwError */
    "./node_modules/rxjs/_esm2015/internal/observable/throwError.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "throwError", function () {
      return _internal_observable_throwError__WEBPACK_IMPORTED_MODULE_47__["throwError"];
    });
    /* harmony import */


    var _internal_observable_timer__WEBPACK_IMPORTED_MODULE_48__ = __webpack_require__(
    /*! ./internal/observable/timer */
    "./node_modules/rxjs/_esm2015/internal/observable/timer.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "timer", function () {
      return _internal_observable_timer__WEBPACK_IMPORTED_MODULE_48__["timer"];
    });
    /* harmony import */


    var _internal_observable_using__WEBPACK_IMPORTED_MODULE_49__ = __webpack_require__(
    /*! ./internal/observable/using */
    "./node_modules/rxjs/_esm2015/internal/observable/using.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "using", function () {
      return _internal_observable_using__WEBPACK_IMPORTED_MODULE_49__["using"];
    });
    /* harmony import */


    var _internal_observable_zip__WEBPACK_IMPORTED_MODULE_50__ = __webpack_require__(
    /*! ./internal/observable/zip */
    "./node_modules/rxjs/_esm2015/internal/observable/zip.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "zip", function () {
      return _internal_observable_zip__WEBPACK_IMPORTED_MODULE_50__["zip"];
    });
    /* harmony import */


    var _internal_scheduled_scheduled__WEBPACK_IMPORTED_MODULE_51__ = __webpack_require__(
    /*! ./internal/scheduled/scheduled */
    "./node_modules/rxjs/_esm2015/internal/scheduled/scheduled.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "scheduled", function () {
      return _internal_scheduled_scheduled__WEBPACK_IMPORTED_MODULE_51__["scheduled"];
    });
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "EMPTY", function () {
      return _internal_observable_empty__WEBPACK_IMPORTED_MODULE_31__["EMPTY"];
    });
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "NEVER", function () {
      return _internal_observable_never__WEBPACK_IMPORTED_MODULE_40__["NEVER"];
    });
    /* harmony import */


    var _internal_config__WEBPACK_IMPORTED_MODULE_52__ = __webpack_require__(
    /*! ./internal/config */
    "./node_modules/rxjs/_esm2015/internal/config.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "config", function () {
      return _internal_config__WEBPACK_IMPORTED_MODULE_52__["config"];
    }); //# sourceMappingURL=index.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/AsyncSubject.js":
  /*!*************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/AsyncSubject.js ***!
    \*************************************************************/

  /*! exports provided: AsyncSubject */

  /***/
  function node_modulesRxjs_esm2015InternalAsyncSubjectJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AsyncSubject", function () {
      return AsyncSubject;
    });
    /* harmony import */


    var _Subject__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./Subject */
    "./node_modules/rxjs/_esm2015/internal/Subject.js");
    /* harmony import */


    var _Subscription__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./Subscription */
    "./node_modules/rxjs/_esm2015/internal/Subscription.js");

    var AsyncSubject = /*#__PURE__*/function (_Subject__WEBPACK_IMP) {
      _inherits(AsyncSubject, _Subject__WEBPACK_IMP);

      var _super108 = _createSuper(AsyncSubject);

      function AsyncSubject() {
        var _this315;

        _classCallCheck(this, AsyncSubject);

        _this315 = _super108.apply(this, arguments);
        _this315.value = null;
        _this315.hasNext = false;
        _this315.hasCompleted = false;
        return _this315;
      }

      _createClass2(AsyncSubject, [{
        key: "_subscribe",
        value: function _subscribe(subscriber) {
          if (this.hasError) {
            subscriber.error(this.thrownError);
            return _Subscription__WEBPACK_IMPORTED_MODULE_1__["Subscription"].EMPTY;
          } else if (this.hasCompleted && this.hasNext) {
            subscriber.next(this.value);
            subscriber.complete();
            return _Subscription__WEBPACK_IMPORTED_MODULE_1__["Subscription"].EMPTY;
          }

          return _get(_getPrototypeOf(AsyncSubject.prototype), "_subscribe", this).call(this, subscriber);
        }
      }, {
        key: "next",
        value: function next(value) {
          if (!this.hasCompleted) {
            this.value = value;
            this.hasNext = true;
          }
        }
      }, {
        key: "error",
        value: function error(_error) {
          if (!this.hasCompleted) {
            _get(_getPrototypeOf(AsyncSubject.prototype), "error", this).call(this, _error);
          }
        }
      }, {
        key: "complete",
        value: function complete() {
          this.hasCompleted = true;

          if (this.hasNext) {
            _get(_getPrototypeOf(AsyncSubject.prototype), "next", this).call(this, this.value);
          }

          _get(_getPrototypeOf(AsyncSubject.prototype), "complete", this).call(this);
        }
      }]);

      return AsyncSubject;
    }(_Subject__WEBPACK_IMPORTED_MODULE_0__["Subject"]); //# sourceMappingURL=AsyncSubject.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/BehaviorSubject.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/BehaviorSubject.js ***!
    \****************************************************************/

  /*! exports provided: BehaviorSubject */

  /***/
  function node_modulesRxjs_esm2015InternalBehaviorSubjectJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "BehaviorSubject", function () {
      return BehaviorSubject;
    });
    /* harmony import */


    var _Subject__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./Subject */
    "./node_modules/rxjs/_esm2015/internal/Subject.js");
    /* harmony import */


    var _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./util/ObjectUnsubscribedError */
    "./node_modules/rxjs/_esm2015/internal/util/ObjectUnsubscribedError.js");

    var BehaviorSubject = /*#__PURE__*/function (_Subject__WEBPACK_IMP2) {
      _inherits(BehaviorSubject, _Subject__WEBPACK_IMP2);

      var _super109 = _createSuper(BehaviorSubject);

      function BehaviorSubject(_value) {
        var _this316;

        _classCallCheck(this, BehaviorSubject);

        _this316 = _super109.call(this);
        _this316._value = _value;
        return _this316;
      }

      _createClass2(BehaviorSubject, [{
        key: "_subscribe",
        value: function _subscribe(subscriber) {
          var subscription = _get(_getPrototypeOf(BehaviorSubject.prototype), "_subscribe", this).call(this, subscriber);

          if (subscription && !subscription.closed) {
            subscriber.next(this._value);
          }

          return subscription;
        }
      }, {
        key: "getValue",
        value: function getValue() {
          if (this.hasError) {
            throw this.thrownError;
          } else if (this.closed) {
            throw new _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_1__["ObjectUnsubscribedError"]();
          } else {
            return this._value;
          }
        }
      }, {
        key: "next",
        value: function next(value) {
          _get(_getPrototypeOf(BehaviorSubject.prototype), "next", this).call(this, this._value = value);
        }
      }, {
        key: "value",
        get: function get() {
          return this.getValue();
        }
      }]);

      return BehaviorSubject;
    }(_Subject__WEBPACK_IMPORTED_MODULE_0__["Subject"]); //# sourceMappingURL=BehaviorSubject.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/InnerSubscriber.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/InnerSubscriber.js ***!
    \****************************************************************/

  /*! exports provided: InnerSubscriber */

  /***/
  function node_modulesRxjs_esm2015InternalInnerSubscriberJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "InnerSubscriber", function () {
      return InnerSubscriber;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    var InnerSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_) {
      _inherits(InnerSubscriber, _Subscriber__WEBPACK_);

      var _super110 = _createSuper(InnerSubscriber);

      function InnerSubscriber(parent, outerValue, outerIndex) {
        var _this317;

        _classCallCheck(this, InnerSubscriber);

        _this317 = _super110.call(this);
        _this317.parent = parent;
        _this317.outerValue = outerValue;
        _this317.outerIndex = outerIndex;
        _this317.index = 0;
        return _this317;
      }

      _createClass2(InnerSubscriber, [{
        key: "_next",
        value: function _next(value) {
          this.parent.notifyNext(this.outerValue, value, this.outerIndex, this.index++, this);
        }
      }, {
        key: "_error",
        value: function _error(error) {
          this.parent.notifyError(error, this);
          this.unsubscribe();
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.parent.notifyComplete(this);
          this.unsubscribe();
        }
      }]);

      return InnerSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=InnerSubscriber.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/Notification.js":
  /*!*************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/Notification.js ***!
    \*************************************************************/

  /*! exports provided: NotificationKind, Notification */

  /***/
  function node_modulesRxjs_esm2015InternalNotificationJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NotificationKind", function () {
      return NotificationKind;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Notification", function () {
      return Notification;
    });
    /* harmony import */


    var _observable_empty__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./observable/empty */
    "./node_modules/rxjs/_esm2015/internal/observable/empty.js");
    /* harmony import */


    var _observable_of__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./observable/of */
    "./node_modules/rxjs/_esm2015/internal/observable/of.js");
    /* harmony import */


    var _observable_throwError__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ./observable/throwError */
    "./node_modules/rxjs/_esm2015/internal/observable/throwError.js");

    var NotificationKind;

    (function (NotificationKind) {
      NotificationKind["NEXT"] = "N";
      NotificationKind["ERROR"] = "E";
      NotificationKind["COMPLETE"] = "C";
    })(NotificationKind || (NotificationKind = {}));

    var Notification = /*#__PURE__*/function () {
      function Notification(kind, value, error) {
        _classCallCheck(this, Notification);

        this.kind = kind;
        this.value = value;
        this.error = error;
        this.hasValue = kind === 'N';
      }

      _createClass2(Notification, [{
        key: "observe",
        value: function observe(observer) {
          switch (this.kind) {
            case 'N':
              return observer.next && observer.next(this.value);

            case 'E':
              return observer.error && observer.error(this.error);

            case 'C':
              return observer.complete && observer.complete();
          }
        }
      }, {
        key: "do",
        value: function _do(next, error, complete) {
          var kind = this.kind;

          switch (kind) {
            case 'N':
              return next && next(this.value);

            case 'E':
              return error && error(this.error);

            case 'C':
              return complete && complete();
          }
        }
      }, {
        key: "accept",
        value: function accept(nextOrObserver, error, complete) {
          if (nextOrObserver && typeof nextOrObserver.next === 'function') {
            return this.observe(nextOrObserver);
          } else {
            return this["do"](nextOrObserver, error, complete);
          }
        }
      }, {
        key: "toObservable",
        value: function toObservable() {
          var kind = this.kind;

          switch (kind) {
            case 'N':
              return Object(_observable_of__WEBPACK_IMPORTED_MODULE_1__["of"])(this.value);

            case 'E':
              return Object(_observable_throwError__WEBPACK_IMPORTED_MODULE_2__["throwError"])(this.error);

            case 'C':
              return Object(_observable_empty__WEBPACK_IMPORTED_MODULE_0__["empty"])();
          }

          throw new Error('unexpected notification kind value');
        }
      }], [{
        key: "createNext",
        value: function createNext(value) {
          if (typeof value !== 'undefined') {
            return new Notification('N', value);
          }

          return Notification.undefinedValueNotification;
        }
      }, {
        key: "createError",
        value: function createError(err) {
          return new Notification('E', undefined, err);
        }
      }, {
        key: "createComplete",
        value: function createComplete() {
          return Notification.completeNotification;
        }
      }]);

      return Notification;
    }();

    Notification.completeNotification = new Notification('C');
    Notification.undefinedValueNotification = new Notification('N', undefined); //# sourceMappingURL=Notification.js.map

    /***/
  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/Observable.js":
  /*!***********************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/Observable.js ***!
    \***********************************************************/

  /*! exports provided: Observable */

  /***/
  function node_modulesRxjs_esm2015InternalObservableJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Observable", function () {
      return Observable;
    });
    /* harmony import */


    var _util_canReportError__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./util/canReportError */
    "./node_modules/rxjs/_esm2015/internal/util/canReportError.js");
    /* harmony import */


    var _util_toSubscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./util/toSubscriber */
    "./node_modules/rxjs/_esm2015/internal/util/toSubscriber.js");
    /* harmony import */


    var _symbol_observable__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ./symbol/observable */
    "./node_modules/rxjs/_esm2015/internal/symbol/observable.js");
    /* harmony import */


    var _util_pipe__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ./util/pipe */
    "./node_modules/rxjs/_esm2015/internal/util/pipe.js");
    /* harmony import */


    var _config__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ./config */
    "./node_modules/rxjs/_esm2015/internal/config.js");

    var Observable = /*#__PURE__*/function () {
      function Observable(subscribe) {
        _classCallCheck(this, Observable);

        this._isScalar = false;

        if (subscribe) {
          this._subscribe = subscribe;
        }
      }

      _createClass2(Observable, [{
        key: "lift",
        value: function lift(operator) {
          var observable = new Observable();
          observable.source = this;
          observable.operator = operator;
          return observable;
        }
      }, {
        key: "subscribe",
        value: function subscribe(observerOrNext, error, complete) {
          var operator = this.operator;
          var sink = Object(_util_toSubscriber__WEBPACK_IMPORTED_MODULE_1__["toSubscriber"])(observerOrNext, error, complete);

          if (operator) {
            sink.add(operator.call(sink, this.source));
          } else {
            sink.add(this.source || _config__WEBPACK_IMPORTED_MODULE_4__["config"].useDeprecatedSynchronousErrorHandling && !sink.syncErrorThrowable ? this._subscribe(sink) : this._trySubscribe(sink));
          }

          if (_config__WEBPACK_IMPORTED_MODULE_4__["config"].useDeprecatedSynchronousErrorHandling) {
            if (sink.syncErrorThrowable) {
              sink.syncErrorThrowable = false;

              if (sink.syncErrorThrown) {
                throw sink.syncErrorValue;
              }
            }
          }

          return sink;
        }
      }, {
        key: "_trySubscribe",
        value: function _trySubscribe(sink) {
          try {
            return this._subscribe(sink);
          } catch (err) {
            if (_config__WEBPACK_IMPORTED_MODULE_4__["config"].useDeprecatedSynchronousErrorHandling) {
              sink.syncErrorThrown = true;
              sink.syncErrorValue = err;
            }

            if (Object(_util_canReportError__WEBPACK_IMPORTED_MODULE_0__["canReportError"])(sink)) {
              sink.error(err);
            } else {
              console.warn(err);
            }
          }
        }
      }, {
        key: "forEach",
        value: function forEach(next, promiseCtor) {
          var _this318 = this;

          promiseCtor = getPromiseCtor(promiseCtor);
          return new promiseCtor(function (resolve, reject) {
            var subscription;
            subscription = _this318.subscribe(function (value) {
              try {
                next(value);
              } catch (err) {
                reject(err);

                if (subscription) {
                  subscription.unsubscribe();
                }
              }
            }, reject, resolve);
          });
        }
      }, {
        key: "_subscribe",
        value: function _subscribe(subscriber) {
          var source = this.source;
          return source && source.subscribe(subscriber);
        }
      }, {
        key: _symbol_observable__WEBPACK_IMPORTED_MODULE_2__["observable"],
        value: function value() {
          return this;
        }
      }, {
        key: "pipe",
        value: function pipe() {
          for (var _len30 = arguments.length, operations = new Array(_len30), _key31 = 0; _key31 < _len30; _key31++) {
            operations[_key31] = arguments[_key31];
          }

          if (operations.length === 0) {
            return this;
          }

          return Object(_util_pipe__WEBPACK_IMPORTED_MODULE_3__["pipeFromArray"])(operations)(this);
        }
      }, {
        key: "toPromise",
        value: function toPromise(promiseCtor) {
          var _this319 = this;

          promiseCtor = getPromiseCtor(promiseCtor);
          return new promiseCtor(function (resolve, reject) {
            var value;

            _this319.subscribe(function (x) {
              return value = x;
            }, function (err) {
              return reject(err);
            }, function () {
              return resolve(value);
            });
          });
        }
      }]);

      return Observable;
    }();

    Observable.create = function (subscribe) {
      return new Observable(subscribe);
    };

    function getPromiseCtor(promiseCtor) {
      if (!promiseCtor) {
        promiseCtor = _config__WEBPACK_IMPORTED_MODULE_4__["config"].Promise || Promise;
      }

      if (!promiseCtor) {
        throw new Error('no Promise impl found');
      }

      return promiseCtor;
    } //# sourceMappingURL=Observable.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/Observer.js":
  /*!*********************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/Observer.js ***!
    \*********************************************************/

  /*! exports provided: empty */

  /***/
  function node_modulesRxjs_esm2015InternalObserverJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "empty", function () {
      return empty;
    });
    /* harmony import */


    var _config__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./config */
    "./node_modules/rxjs/_esm2015/internal/config.js");
    /* harmony import */


    var _util_hostReportError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./util/hostReportError */
    "./node_modules/rxjs/_esm2015/internal/util/hostReportError.js");

    var empty = {
      closed: true,
      next: function next(value) {},
      error: function error(err) {
        if (_config__WEBPACK_IMPORTED_MODULE_0__["config"].useDeprecatedSynchronousErrorHandling) {
          throw err;
        } else {
          Object(_util_hostReportError__WEBPACK_IMPORTED_MODULE_1__["hostReportError"])(err);
        }
      },
      complete: function complete() {}
    }; //# sourceMappingURL=Observer.js.map

    /***/
  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js ***!
    \****************************************************************/

  /*! exports provided: OuterSubscriber */

  /***/
  function node_modulesRxjs_esm2015InternalOuterSubscriberJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "OuterSubscriber", function () {
      return OuterSubscriber;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    var OuterSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_2) {
      _inherits(OuterSubscriber, _Subscriber__WEBPACK_2);

      var _super111 = _createSuper(OuterSubscriber);

      function OuterSubscriber() {
        _classCallCheck(this, OuterSubscriber);

        return _super111.apply(this, arguments);
      }

      _createClass2(OuterSubscriber, [{
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          this.destination.next(innerValue);
        }
      }, {
        key: "notifyError",
        value: function notifyError(error, innerSub) {
          this.destination.error(error);
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete(innerSub) {
          this.destination.complete();
        }
      }]);

      return OuterSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=OuterSubscriber.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/ReplaySubject.js":
  /*!**************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/ReplaySubject.js ***!
    \**************************************************************/

  /*! exports provided: ReplaySubject */

  /***/
  function node_modulesRxjs_esm2015InternalReplaySubjectJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ReplaySubject", function () {
      return ReplaySubject;
    });
    /* harmony import */


    var _Subject__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./Subject */
    "./node_modules/rxjs/_esm2015/internal/Subject.js");
    /* harmony import */


    var _scheduler_queue__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./scheduler/queue */
    "./node_modules/rxjs/_esm2015/internal/scheduler/queue.js");
    /* harmony import */


    var _Subscription__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ./Subscription */
    "./node_modules/rxjs/_esm2015/internal/Subscription.js");
    /* harmony import */


    var _operators_observeOn__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ./operators/observeOn */
    "./node_modules/rxjs/_esm2015/internal/operators/observeOn.js");
    /* harmony import */


    var _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ./util/ObjectUnsubscribedError */
    "./node_modules/rxjs/_esm2015/internal/util/ObjectUnsubscribedError.js");
    /* harmony import */


    var _SubjectSubscription__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(
    /*! ./SubjectSubscription */
    "./node_modules/rxjs/_esm2015/internal/SubjectSubscription.js");

    var ReplaySubject = /*#__PURE__*/function (_Subject__WEBPACK_IMP3) {
      _inherits(ReplaySubject, _Subject__WEBPACK_IMP3);

      var _super112 = _createSuper(ReplaySubject);

      function ReplaySubject() {
        var _this320;

        var bufferSize = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : Number.POSITIVE_INFINITY;
        var windowTime = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : Number.POSITIVE_INFINITY;
        var scheduler = arguments.length > 2 ? arguments[2] : undefined;

        _classCallCheck(this, ReplaySubject);

        _this320 = _super112.call(this);
        _this320.scheduler = scheduler;
        _this320._events = [];
        _this320._infiniteTimeWindow = false;
        _this320._bufferSize = bufferSize < 1 ? 1 : bufferSize;
        _this320._windowTime = windowTime < 1 ? 1 : windowTime;

        if (windowTime === Number.POSITIVE_INFINITY) {
          _this320._infiniteTimeWindow = true;
          _this320.next = _this320.nextInfiniteTimeWindow;
        } else {
          _this320.next = _this320.nextTimeWindow;
        }

        return _this320;
      }

      _createClass2(ReplaySubject, [{
        key: "nextInfiniteTimeWindow",
        value: function nextInfiniteTimeWindow(value) {
          var _events = this._events;

          _events.push(value);

          if (_events.length > this._bufferSize) {
            _events.shift();
          }

          _get(_getPrototypeOf(ReplaySubject.prototype), "next", this).call(this, value);
        }
      }, {
        key: "nextTimeWindow",
        value: function nextTimeWindow(value) {
          this._events.push(new ReplayEvent(this._getNow(), value));

          this._trimBufferThenGetEvents();

          _get(_getPrototypeOf(ReplaySubject.prototype), "next", this).call(this, value);
        }
      }, {
        key: "_subscribe",
        value: function _subscribe(subscriber) {
          var _infiniteTimeWindow = this._infiniteTimeWindow;

          var _events = _infiniteTimeWindow ? this._events : this._trimBufferThenGetEvents();

          var scheduler = this.scheduler;
          var len = _events.length;
          var subscription;

          if (this.closed) {
            throw new _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_4__["ObjectUnsubscribedError"]();
          } else if (this.isStopped || this.hasError) {
            subscription = _Subscription__WEBPACK_IMPORTED_MODULE_2__["Subscription"].EMPTY;
          } else {
            this.observers.push(subscriber);
            subscription = new _SubjectSubscription__WEBPACK_IMPORTED_MODULE_5__["SubjectSubscription"](this, subscriber);
          }

          if (scheduler) {
            subscriber.add(subscriber = new _operators_observeOn__WEBPACK_IMPORTED_MODULE_3__["ObserveOnSubscriber"](subscriber, scheduler));
          }

          if (_infiniteTimeWindow) {
            for (var i = 0; i < len && !subscriber.closed; i++) {
              subscriber.next(_events[i]);
            }
          } else {
            for (var _i30 = 0; _i30 < len && !subscriber.closed; _i30++) {
              subscriber.next(_events[_i30].value);
            }
          }

          if (this.hasError) {
            subscriber.error(this.thrownError);
          } else if (this.isStopped) {
            subscriber.complete();
          }

          return subscription;
        }
      }, {
        key: "_getNow",
        value: function _getNow() {
          return (this.scheduler || _scheduler_queue__WEBPACK_IMPORTED_MODULE_1__["queue"]).now();
        }
      }, {
        key: "_trimBufferThenGetEvents",
        value: function _trimBufferThenGetEvents() {
          var now = this._getNow();

          var _bufferSize = this._bufferSize;
          var _windowTime = this._windowTime;
          var _events = this._events;
          var eventsCount = _events.length;
          var spliceCount = 0;

          while (spliceCount < eventsCount) {
            if (now - _events[spliceCount].time < _windowTime) {
              break;
            }

            spliceCount++;
          }

          if (eventsCount > _bufferSize) {
            spliceCount = Math.max(spliceCount, eventsCount - _bufferSize);
          }

          if (spliceCount > 0) {
            _events.splice(0, spliceCount);
          }

          return _events;
        }
      }]);

      return ReplaySubject;
    }(_Subject__WEBPACK_IMPORTED_MODULE_0__["Subject"]);

    var ReplayEvent = function ReplayEvent(time, value) {
      _classCallCheck(this, ReplayEvent);

      this.time = time;
      this.value = value;
    }; //# sourceMappingURL=ReplaySubject.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/Scheduler.js":
  /*!**********************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/Scheduler.js ***!
    \**********************************************************/

  /*! exports provided: Scheduler */

  /***/
  function node_modulesRxjs_esm2015InternalSchedulerJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Scheduler", function () {
      return Scheduler;
    });

    var Scheduler = /*#__PURE__*/function () {
      function Scheduler(SchedulerAction) {
        var now = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : Scheduler.now;

        _classCallCheck(this, Scheduler);

        this.SchedulerAction = SchedulerAction;
        this.now = now;
      }

      _createClass2(Scheduler, [{
        key: "schedule",
        value: function schedule(work) {
          var delay = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
          var state = arguments.length > 2 ? arguments[2] : undefined;
          return new this.SchedulerAction(this, work).schedule(state, delay);
        }
      }]);

      return Scheduler;
    }();

    Scheduler.now = function () {
      return Date.now();
    }; //# sourceMappingURL=Scheduler.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/Subject.js":
  /*!********************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/Subject.js ***!
    \********************************************************/

  /*! exports provided: SubjectSubscriber, Subject, AnonymousSubject */

  /***/
  function node_modulesRxjs_esm2015InternalSubjectJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SubjectSubscriber", function () {
      return SubjectSubscriber;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Subject", function () {
      return Subject;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AnonymousSubject", function () {
      return AnonymousSubject;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _Subscription__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ./Subscription */
    "./node_modules/rxjs/_esm2015/internal/Subscription.js");
    /* harmony import */


    var _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ./util/ObjectUnsubscribedError */
    "./node_modules/rxjs/_esm2015/internal/util/ObjectUnsubscribedError.js");
    /* harmony import */


    var _SubjectSubscription__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ./SubjectSubscription */
    "./node_modules/rxjs/_esm2015/internal/SubjectSubscription.js");
    /* harmony import */


    var _internal_symbol_rxSubscriber__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(
    /*! ../internal/symbol/rxSubscriber */
    "./node_modules/rxjs/_esm2015/internal/symbol/rxSubscriber.js");

    var SubjectSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_3) {
      _inherits(SubjectSubscriber, _Subscriber__WEBPACK_3);

      var _super113 = _createSuper(SubjectSubscriber);

      function SubjectSubscriber(destination) {
        var _this321;

        _classCallCheck(this, SubjectSubscriber);

        _this321 = _super113.call(this, destination);
        _this321.destination = destination;
        return _this321;
      }

      return SubjectSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_1__["Subscriber"]);

    var Subject = /*#__PURE__*/function (_Observable__WEBPACK_) {
      _inherits(Subject, _Observable__WEBPACK_);

      var _super114 = _createSuper(Subject);

      function Subject() {
        var _this322;

        _classCallCheck(this, Subject);

        _this322 = _super114.call(this);
        _this322.observers = [];
        _this322.closed = false;
        _this322.isStopped = false;
        _this322.hasError = false;
        _this322.thrownError = null;
        return _this322;
      }

      _createClass2(Subject, [{
        key: _internal_symbol_rxSubscriber__WEBPACK_IMPORTED_MODULE_5__["rxSubscriber"],
        value: function value() {
          return new SubjectSubscriber(this);
        }
      }, {
        key: "lift",
        value: function lift(operator) {
          var subject = new AnonymousSubject(this, this);
          subject.operator = operator;
          return subject;
        }
      }, {
        key: "next",
        value: function next(value) {
          if (this.closed) {
            throw new _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_3__["ObjectUnsubscribedError"]();
          }

          if (!this.isStopped) {
            var observers = this.observers;
            var _len31 = observers.length;
            var copy = observers.slice();

            for (var i = 0; i < _len31; i++) {
              copy[i].next(value);
            }
          }
        }
      }, {
        key: "error",
        value: function error(err) {
          if (this.closed) {
            throw new _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_3__["ObjectUnsubscribedError"]();
          }

          this.hasError = true;
          this.thrownError = err;
          this.isStopped = true;
          var observers = this.observers;
          var len = observers.length;
          var copy = observers.slice();

          for (var i = 0; i < len; i++) {
            copy[i].error(err);
          }

          this.observers.length = 0;
        }
      }, {
        key: "complete",
        value: function complete() {
          if (this.closed) {
            throw new _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_3__["ObjectUnsubscribedError"]();
          }

          this.isStopped = true;
          var observers = this.observers;
          var len = observers.length;
          var copy = observers.slice();

          for (var i = 0; i < len; i++) {
            copy[i].complete();
          }

          this.observers.length = 0;
        }
      }, {
        key: "unsubscribe",
        value: function unsubscribe() {
          this.isStopped = true;
          this.closed = true;
          this.observers = null;
        }
      }, {
        key: "_trySubscribe",
        value: function _trySubscribe(subscriber) {
          if (this.closed) {
            throw new _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_3__["ObjectUnsubscribedError"]();
          } else {
            return _get(_getPrototypeOf(Subject.prototype), "_trySubscribe", this).call(this, subscriber);
          }
        }
      }, {
        key: "_subscribe",
        value: function _subscribe(subscriber) {
          if (this.closed) {
            throw new _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_3__["ObjectUnsubscribedError"]();
          } else if (this.hasError) {
            subscriber.error(this.thrownError);
            return _Subscription__WEBPACK_IMPORTED_MODULE_2__["Subscription"].EMPTY;
          } else if (this.isStopped) {
            subscriber.complete();
            return _Subscription__WEBPACK_IMPORTED_MODULE_2__["Subscription"].EMPTY;
          } else {
            this.observers.push(subscriber);
            return new _SubjectSubscription__WEBPACK_IMPORTED_MODULE_4__["SubjectSubscription"](this, subscriber);
          }
        }
      }, {
        key: "asObservable",
        value: function asObservable() {
          var observable = new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"]();
          observable.source = this;
          return observable;
        }
      }]);

      return Subject;
    }(_Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"]);

    Subject.create = function (destination, source) {
      return new AnonymousSubject(destination, source);
    };

    var AnonymousSubject = /*#__PURE__*/function (_Subject) {
      _inherits(AnonymousSubject, _Subject);

      var _super115 = _createSuper(AnonymousSubject);

      function AnonymousSubject(destination, source) {
        var _this323;

        _classCallCheck(this, AnonymousSubject);

        _this323 = _super115.call(this);
        _this323.destination = destination;
        _this323.source = source;
        return _this323;
      }

      _createClass2(AnonymousSubject, [{
        key: "next",
        value: function next(value) {
          var destination = this.destination;

          if (destination && destination.next) {
            destination.next(value);
          }
        }
      }, {
        key: "error",
        value: function error(err) {
          var destination = this.destination;

          if (destination && destination.error) {
            this.destination.error(err);
          }
        }
      }, {
        key: "complete",
        value: function complete() {
          var destination = this.destination;

          if (destination && destination.complete) {
            this.destination.complete();
          }
        }
      }, {
        key: "_subscribe",
        value: function _subscribe(subscriber) {
          var source = this.source;

          if (source) {
            return this.source.subscribe(subscriber);
          } else {
            return _Subscription__WEBPACK_IMPORTED_MODULE_2__["Subscription"].EMPTY;
          }
        }
      }]);

      return AnonymousSubject;
    }(Subject); //# sourceMappingURL=Subject.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/SubjectSubscription.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/SubjectSubscription.js ***!
    \********************************************************************/

  /*! exports provided: SubjectSubscription */

  /***/
  function node_modulesRxjs_esm2015InternalSubjectSubscriptionJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SubjectSubscription", function () {
      return SubjectSubscription;
    });
    /* harmony import */


    var _Subscription__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./Subscription */
    "./node_modules/rxjs/_esm2015/internal/Subscription.js");

    var SubjectSubscription = /*#__PURE__*/function (_Subscription__WEBPAC) {
      _inherits(SubjectSubscription, _Subscription__WEBPAC);

      var _super116 = _createSuper(SubjectSubscription);

      function SubjectSubscription(subject, subscriber) {
        var _this324;

        _classCallCheck(this, SubjectSubscription);

        _this324 = _super116.call(this);
        _this324.subject = subject;
        _this324.subscriber = subscriber;
        _this324.closed = false;
        return _this324;
      }

      _createClass2(SubjectSubscription, [{
        key: "unsubscribe",
        value: function unsubscribe() {
          if (this.closed) {
            return;
          }

          this.closed = true;
          var subject = this.subject;
          var observers = subject.observers;
          this.subject = null;

          if (!observers || observers.length === 0 || subject.isStopped || subject.closed) {
            return;
          }

          var subscriberIndex = observers.indexOf(this.subscriber);

          if (subscriberIndex !== -1) {
            observers.splice(subscriberIndex, 1);
          }
        }
      }]);

      return SubjectSubscription;
    }(_Subscription__WEBPACK_IMPORTED_MODULE_0__["Subscription"]); //# sourceMappingURL=SubjectSubscription.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/Subscriber.js":
  /*!***********************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/Subscriber.js ***!
    \***********************************************************/

  /*! exports provided: Subscriber, SafeSubscriber */

  /***/
  function node_modulesRxjs_esm2015InternalSubscriberJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Subscriber", function () {
      return Subscriber;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SafeSubscriber", function () {
      return SafeSubscriber;
    });
    /* harmony import */


    var _util_isFunction__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./util/isFunction */
    "./node_modules/rxjs/_esm2015/internal/util/isFunction.js");
    /* harmony import */


    var _Observer__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./Observer */
    "./node_modules/rxjs/_esm2015/internal/Observer.js");
    /* harmony import */


    var _Subscription__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ./Subscription */
    "./node_modules/rxjs/_esm2015/internal/Subscription.js");
    /* harmony import */


    var _internal_symbol_rxSubscriber__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../internal/symbol/rxSubscriber */
    "./node_modules/rxjs/_esm2015/internal/symbol/rxSubscriber.js");
    /* harmony import */


    var _config__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ./config */
    "./node_modules/rxjs/_esm2015/internal/config.js");
    /* harmony import */


    var _util_hostReportError__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(
    /*! ./util/hostReportError */
    "./node_modules/rxjs/_esm2015/internal/util/hostReportError.js");

    var Subscriber = /*#__PURE__*/function (_Subscription__WEBPAC2) {
      _inherits(Subscriber, _Subscription__WEBPAC2);

      var _super117 = _createSuper(Subscriber);

      function Subscriber(destinationOrNext, error, complete) {
        var _this325;

        _classCallCheck(this, Subscriber);

        _this325 = _super117.call(this);
        _this325.syncErrorValue = null;
        _this325.syncErrorThrown = false;
        _this325.syncErrorThrowable = false;
        _this325.isStopped = false;

        switch (arguments.length) {
          case 0:
            _this325.destination = _Observer__WEBPACK_IMPORTED_MODULE_1__["empty"];
            break;

          case 1:
            if (!destinationOrNext) {
              _this325.destination = _Observer__WEBPACK_IMPORTED_MODULE_1__["empty"];
              break;
            }

            if (typeof destinationOrNext === 'object') {
              if (destinationOrNext instanceof Subscriber) {
                _this325.syncErrorThrowable = destinationOrNext.syncErrorThrowable;
                _this325.destination = destinationOrNext;
                destinationOrNext.add(_assertThisInitialized(_this325));
              } else {
                _this325.syncErrorThrowable = true;
                _this325.destination = new SafeSubscriber(_assertThisInitialized(_this325), destinationOrNext);
              }

              break;
            }

          default:
            _this325.syncErrorThrowable = true;
            _this325.destination = new SafeSubscriber(_assertThisInitialized(_this325), destinationOrNext, error, complete);
            break;
        }

        return _this325;
      }

      _createClass2(Subscriber, [{
        key: _internal_symbol_rxSubscriber__WEBPACK_IMPORTED_MODULE_3__["rxSubscriber"],
        value: function value() {
          return this;
        }
      }, {
        key: "next",
        value: function next(value) {
          if (!this.isStopped) {
            this._next(value);
          }
        }
      }, {
        key: "error",
        value: function error(err) {
          if (!this.isStopped) {
            this.isStopped = true;

            this._error(err);
          }
        }
      }, {
        key: "complete",
        value: function complete() {
          if (!this.isStopped) {
            this.isStopped = true;

            this._complete();
          }
        }
      }, {
        key: "unsubscribe",
        value: function unsubscribe() {
          if (this.closed) {
            return;
          }

          this.isStopped = true;

          _get(_getPrototypeOf(Subscriber.prototype), "unsubscribe", this).call(this);
        }
      }, {
        key: "_next",
        value: function _next(value) {
          this.destination.next(value);
        }
      }, {
        key: "_error",
        value: function _error(err) {
          this.destination.error(err);
          this.unsubscribe();
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.destination.complete();
          this.unsubscribe();
        }
      }, {
        key: "_unsubscribeAndRecycle",
        value: function _unsubscribeAndRecycle() {
          var _parentOrParents = this._parentOrParents;
          this._parentOrParents = null;
          this.unsubscribe();
          this.closed = false;
          this.isStopped = false;
          this._parentOrParents = _parentOrParents;
          return this;
        }
      }], [{
        key: "create",
        value: function create(next, error, complete) {
          var subscriber = new Subscriber(next, error, complete);
          subscriber.syncErrorThrowable = false;
          return subscriber;
        }
      }]);

      return Subscriber;
    }(_Subscription__WEBPACK_IMPORTED_MODULE_2__["Subscription"]);

    var SafeSubscriber = /*#__PURE__*/function (_Subscriber) {
      _inherits(SafeSubscriber, _Subscriber);

      var _super118 = _createSuper(SafeSubscriber);

      function SafeSubscriber(_parentSubscriber, observerOrNext, error, complete) {
        var _this326;

        _classCallCheck(this, SafeSubscriber);

        _this326 = _super118.call(this);
        _this326._parentSubscriber = _parentSubscriber;
        var next;

        var context = _assertThisInitialized(_this326);

        if (Object(_util_isFunction__WEBPACK_IMPORTED_MODULE_0__["isFunction"])(observerOrNext)) {
          next = observerOrNext;
        } else if (observerOrNext) {
          next = observerOrNext.next;
          error = observerOrNext.error;
          complete = observerOrNext.complete;

          if (observerOrNext !== _Observer__WEBPACK_IMPORTED_MODULE_1__["empty"]) {
            context = Object.create(observerOrNext);

            if (Object(_util_isFunction__WEBPACK_IMPORTED_MODULE_0__["isFunction"])(context.unsubscribe)) {
              _this326.add(context.unsubscribe.bind(context));
            }

            context.unsubscribe = _this326.unsubscribe.bind(_assertThisInitialized(_this326));
          }
        }

        _this326._context = context;
        _this326._next = next;
        _this326._error = error;
        _this326._complete = complete;
        return _this326;
      }

      _createClass2(SafeSubscriber, [{
        key: "next",
        value: function next(value) {
          if (!this.isStopped && this._next) {
            var _parentSubscriber = this._parentSubscriber;

            if (!_config__WEBPACK_IMPORTED_MODULE_4__["config"].useDeprecatedSynchronousErrorHandling || !_parentSubscriber.syncErrorThrowable) {
              this.__tryOrUnsub(this._next, value);
            } else if (this.__tryOrSetError(_parentSubscriber, this._next, value)) {
              this.unsubscribe();
            }
          }
        }
      }, {
        key: "error",
        value: function error(err) {
          if (!this.isStopped) {
            var _parentSubscriber = this._parentSubscriber;
            var useDeprecatedSynchronousErrorHandling = _config__WEBPACK_IMPORTED_MODULE_4__["config"].useDeprecatedSynchronousErrorHandling;

            if (this._error) {
              if (!useDeprecatedSynchronousErrorHandling || !_parentSubscriber.syncErrorThrowable) {
                this.__tryOrUnsub(this._error, err);

                this.unsubscribe();
              } else {
                this.__tryOrSetError(_parentSubscriber, this._error, err);

                this.unsubscribe();
              }
            } else if (!_parentSubscriber.syncErrorThrowable) {
              this.unsubscribe();

              if (useDeprecatedSynchronousErrorHandling) {
                throw err;
              }

              Object(_util_hostReportError__WEBPACK_IMPORTED_MODULE_5__["hostReportError"])(err);
            } else {
              if (useDeprecatedSynchronousErrorHandling) {
                _parentSubscriber.syncErrorValue = err;
                _parentSubscriber.syncErrorThrown = true;
              } else {
                Object(_util_hostReportError__WEBPACK_IMPORTED_MODULE_5__["hostReportError"])(err);
              }

              this.unsubscribe();
            }
          }
        }
      }, {
        key: "complete",
        value: function complete() {
          var _this327 = this;

          if (!this.isStopped) {
            var _parentSubscriber = this._parentSubscriber;

            if (this._complete) {
              var wrappedComplete = function wrappedComplete() {
                return _this327._complete.call(_this327._context);
              };

              if (!_config__WEBPACK_IMPORTED_MODULE_4__["config"].useDeprecatedSynchronousErrorHandling || !_parentSubscriber.syncErrorThrowable) {
                this.__tryOrUnsub(wrappedComplete);

                this.unsubscribe();
              } else {
                this.__tryOrSetError(_parentSubscriber, wrappedComplete);

                this.unsubscribe();
              }
            } else {
              this.unsubscribe();
            }
          }
        }
      }, {
        key: "__tryOrUnsub",
        value: function __tryOrUnsub(fn, value) {
          try {
            fn.call(this._context, value);
          } catch (err) {
            this.unsubscribe();

            if (_config__WEBPACK_IMPORTED_MODULE_4__["config"].useDeprecatedSynchronousErrorHandling) {
              throw err;
            } else {
              Object(_util_hostReportError__WEBPACK_IMPORTED_MODULE_5__["hostReportError"])(err);
            }
          }
        }
      }, {
        key: "__tryOrSetError",
        value: function __tryOrSetError(parent, fn, value) {
          if (!_config__WEBPACK_IMPORTED_MODULE_4__["config"].useDeprecatedSynchronousErrorHandling) {
            throw new Error('bad call');
          }

          try {
            fn.call(this._context, value);
          } catch (err) {
            if (_config__WEBPACK_IMPORTED_MODULE_4__["config"].useDeprecatedSynchronousErrorHandling) {
              parent.syncErrorValue = err;
              parent.syncErrorThrown = true;
              return true;
            } else {
              Object(_util_hostReportError__WEBPACK_IMPORTED_MODULE_5__["hostReportError"])(err);
              return true;
            }
          }

          return false;
        }
      }, {
        key: "_unsubscribe",
        value: function _unsubscribe() {
          var _parentSubscriber = this._parentSubscriber;
          this._context = null;
          this._parentSubscriber = null;

          _parentSubscriber.unsubscribe();
        }
      }]);

      return SafeSubscriber;
    }(Subscriber); //# sourceMappingURL=Subscriber.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/Subscription.js":
  /*!*************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/Subscription.js ***!
    \*************************************************************/

  /*! exports provided: Subscription */

  /***/
  function node_modulesRxjs_esm2015InternalSubscriptionJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Subscription", function () {
      return Subscription;
    });
    /* harmony import */


    var _util_isArray__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./util/isArray */
    "./node_modules/rxjs/_esm2015/internal/util/isArray.js");
    /* harmony import */


    var _util_isObject__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./util/isObject */
    "./node_modules/rxjs/_esm2015/internal/util/isObject.js");
    /* harmony import */


    var _util_isFunction__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ./util/isFunction */
    "./node_modules/rxjs/_esm2015/internal/util/isFunction.js");
    /* harmony import */


    var _util_UnsubscriptionError__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ./util/UnsubscriptionError */
    "./node_modules/rxjs/_esm2015/internal/util/UnsubscriptionError.js");

    var Subscription = /*#__PURE__*/function () {
      function Subscription(unsubscribe) {
        _classCallCheck(this, Subscription);

        this.closed = false;
        this._parentOrParents = null;
        this._subscriptions = null;

        if (unsubscribe) {
          this._unsubscribe = unsubscribe;
        }
      }

      _createClass2(Subscription, [{
        key: "unsubscribe",
        value: function unsubscribe() {
          var errors;

          if (this.closed) {
            return;
          }

          var _parentOrParents = this._parentOrParents,
              _unsubscribe = this._unsubscribe,
              _subscriptions = this._subscriptions;
          this.closed = true;
          this._parentOrParents = null;
          this._subscriptions = null;

          if (_parentOrParents instanceof Subscription) {
            _parentOrParents.remove(this);
          } else if (_parentOrParents !== null) {
            for (var index = 0; index < _parentOrParents.length; ++index) {
              var parent = _parentOrParents[index];
              parent.remove(this);
            }
          }

          if (Object(_util_isFunction__WEBPACK_IMPORTED_MODULE_2__["isFunction"])(_unsubscribe)) {
            try {
              _unsubscribe.call(this);
            } catch (e) {
              errors = e instanceof _util_UnsubscriptionError__WEBPACK_IMPORTED_MODULE_3__["UnsubscriptionError"] ? flattenUnsubscriptionErrors(e.errors) : [e];
            }
          }

          if (Object(_util_isArray__WEBPACK_IMPORTED_MODULE_0__["isArray"])(_subscriptions)) {
            var _index4 = -1;

            var _len32 = _subscriptions.length;

            while (++_index4 < _len32) {
              var sub = _subscriptions[_index4];

              if (Object(_util_isObject__WEBPACK_IMPORTED_MODULE_1__["isObject"])(sub)) {
                try {
                  sub.unsubscribe();
                } catch (e) {
                  errors = errors || [];

                  if (e instanceof _util_UnsubscriptionError__WEBPACK_IMPORTED_MODULE_3__["UnsubscriptionError"]) {
                    errors = errors.concat(flattenUnsubscriptionErrors(e.errors));
                  } else {
                    errors.push(e);
                  }
                }
              }
            }
          }

          if (errors) {
            throw new _util_UnsubscriptionError__WEBPACK_IMPORTED_MODULE_3__["UnsubscriptionError"](errors);
          }
        }
      }, {
        key: "add",
        value: function add(teardown) {
          var subscription = teardown;

          if (!teardown) {
            return Subscription.EMPTY;
          }

          switch (typeof teardown) {
            case 'function':
              subscription = new Subscription(teardown);

            case 'object':
              if (subscription === this || subscription.closed || typeof subscription.unsubscribe !== 'function') {
                return subscription;
              } else if (this.closed) {
                subscription.unsubscribe();
                return subscription;
              } else if (!(subscription instanceof Subscription)) {
                var tmp = subscription;
                subscription = new Subscription();
                subscription._subscriptions = [tmp];
              }

              break;

            default:
              {
                throw new Error('unrecognized teardown ' + teardown + ' added to Subscription.');
              }
          }

          var _subscription2 = subscription,
              _parentOrParents = _subscription2._parentOrParents;

          if (_parentOrParents === null) {
            subscription._parentOrParents = this;
          } else if (_parentOrParents instanceof Subscription) {
            if (_parentOrParents === this) {
              return subscription;
            }

            subscription._parentOrParents = [_parentOrParents, this];
          } else if (_parentOrParents.indexOf(this) === -1) {
            _parentOrParents.push(this);
          } else {
            return subscription;
          }

          var subscriptions = this._subscriptions;

          if (subscriptions === null) {
            this._subscriptions = [subscription];
          } else {
            subscriptions.push(subscription);
          }

          return subscription;
        }
      }, {
        key: "remove",
        value: function remove(subscription) {
          var subscriptions = this._subscriptions;

          if (subscriptions) {
            var subscriptionIndex = subscriptions.indexOf(subscription);

            if (subscriptionIndex !== -1) {
              subscriptions.splice(subscriptionIndex, 1);
            }
          }
        }
      }]);

      return Subscription;
    }();

    Subscription.EMPTY = function (empty) {
      empty.closed = true;
      return empty;
    }(new Subscription());

    function flattenUnsubscriptionErrors(errors) {
      return errors.reduce(function (errs, err) {
        return errs.concat(err instanceof _util_UnsubscriptionError__WEBPACK_IMPORTED_MODULE_3__["UnsubscriptionError"] ? err.errors : err);
      }, []);
    } //# sourceMappingURL=Subscription.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/config.js":
  /*!*******************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/config.js ***!
    \*******************************************************/

  /*! exports provided: config */

  /***/
  function node_modulesRxjs_esm2015InternalConfigJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "config", function () {
      return config;
    });

    var _enable_super_gross_mode_that_will_cause_bad_things = false;
    var config = {
      Promise: undefined,

      set useDeprecatedSynchronousErrorHandling(value) {
        if (value) {
          var error = new Error();
          console.warn('DEPRECATED! RxJS was set to use deprecated synchronous error handling behavior by code at: \n' + error.stack);
        } else if (_enable_super_gross_mode_that_will_cause_bad_things) {
          console.log('RxJS: Back to a better error behavior. Thank you. <3');
        }

        _enable_super_gross_mode_that_will_cause_bad_things = value;
      },

      get useDeprecatedSynchronousErrorHandling() {
        return _enable_super_gross_mode_that_will_cause_bad_things;
      }

    }; //# sourceMappingURL=config.js.map

    /***/
  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/ConnectableObservable.js":
  /*!*********************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/ConnectableObservable.js ***!
    \*********************************************************************************/

  /*! exports provided: ConnectableObservable, connectableObservableDescriptor */

  /***/
  function node_modulesRxjs_esm2015InternalObservableConnectableObservableJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ConnectableObservable", function () {
      return ConnectableObservable;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "connectableObservableDescriptor", function () {
      return connectableObservableDescriptor;
    });
    /* harmony import */


    var _Subject__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subject */
    "./node_modules/rxjs/_esm2015/internal/Subject.js");
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _Subscription__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../Subscription */
    "./node_modules/rxjs/_esm2015/internal/Subscription.js");
    /* harmony import */


    var _operators_refCount__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ../operators/refCount */
    "./node_modules/rxjs/_esm2015/internal/operators/refCount.js");

    var ConnectableObservable = /*#__PURE__*/function (_Observable__WEBPACK_2) {
      _inherits(ConnectableObservable, _Observable__WEBPACK_2);

      var _super119 = _createSuper(ConnectableObservable);

      function ConnectableObservable(source, subjectFactory) {
        var _this328;

        _classCallCheck(this, ConnectableObservable);

        _this328 = _super119.call(this);
        _this328.source = source;
        _this328.subjectFactory = subjectFactory;
        _this328._refCount = 0;
        _this328._isComplete = false;
        return _this328;
      }

      _createClass2(ConnectableObservable, [{
        key: "_subscribe",
        value: function _subscribe(subscriber) {
          return this.getSubject().subscribe(subscriber);
        }
      }, {
        key: "getSubject",
        value: function getSubject() {
          var subject = this._subject;

          if (!subject || subject.isStopped) {
            this._subject = this.subjectFactory();
          }

          return this._subject;
        }
      }, {
        key: "connect",
        value: function connect() {
          var connection = this._connection;

          if (!connection) {
            this._isComplete = false;
            connection = this._connection = new _Subscription__WEBPACK_IMPORTED_MODULE_3__["Subscription"]();
            connection.add(this.source.subscribe(new ConnectableSubscriber(this.getSubject(), this)));

            if (connection.closed) {
              this._connection = null;
              connection = _Subscription__WEBPACK_IMPORTED_MODULE_3__["Subscription"].EMPTY;
            }
          }

          return connection;
        }
      }, {
        key: "refCount",
        value: function refCount() {
          return Object(_operators_refCount__WEBPACK_IMPORTED_MODULE_4__["refCount"])()(this);
        }
      }]);

      return ConnectableObservable;
    }(_Observable__WEBPACK_IMPORTED_MODULE_1__["Observable"]);

    var connectableObservableDescriptor = function () {
      var connectableProto = ConnectableObservable.prototype;
      return {
        operator: {
          value: null
        },
        _refCount: {
          value: 0,
          writable: true
        },
        _subject: {
          value: null,
          writable: true
        },
        _connection: {
          value: null,
          writable: true
        },
        _subscribe: {
          value: connectableProto._subscribe
        },
        _isComplete: {
          value: connectableProto._isComplete,
          writable: true
        },
        getSubject: {
          value: connectableProto.getSubject
        },
        connect: {
          value: connectableProto.connect
        },
        refCount: {
          value: connectableProto.refCount
        }
      };
    }();

    var ConnectableSubscriber = /*#__PURE__*/function (_Subject__WEBPACK_IMP4) {
      _inherits(ConnectableSubscriber, _Subject__WEBPACK_IMP4);

      var _super120 = _createSuper(ConnectableSubscriber);

      function ConnectableSubscriber(destination, connectable) {
        var _this329;

        _classCallCheck(this, ConnectableSubscriber);

        _this329 = _super120.call(this, destination);
        _this329.connectable = connectable;
        return _this329;
      }

      _createClass2(ConnectableSubscriber, [{
        key: "_error",
        value: function _error(err) {
          this._unsubscribe();

          _get(_getPrototypeOf(ConnectableSubscriber.prototype), "_error", this).call(this, err);
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.connectable._isComplete = true;

          this._unsubscribe();

          _get(_getPrototypeOf(ConnectableSubscriber.prototype), "_complete", this).call(this);
        }
      }, {
        key: "_unsubscribe",
        value: function _unsubscribe() {
          var connectable = this.connectable;

          if (connectable) {
            this.connectable = null;
            var connection = connectable._connection;
            connectable._refCount = 0;
            connectable._subject = null;
            connectable._connection = null;

            if (connection) {
              connection.unsubscribe();
            }
          }
        }
      }]);

      return ConnectableSubscriber;
    }(_Subject__WEBPACK_IMPORTED_MODULE_0__["SubjectSubscriber"]);

    var RefCountOperator = /*#__PURE__*/function () {
      function RefCountOperator(connectable) {
        _classCallCheck(this, RefCountOperator);

        this.connectable = connectable;
      }

      _createClass2(RefCountOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          var connectable = this.connectable;
          connectable._refCount++;
          var refCounter = new RefCountSubscriber(subscriber, connectable);
          var subscription = source.subscribe(refCounter);

          if (!refCounter.closed) {
            refCounter.connection = connectable.connect();
          }

          return subscription;
        }
      }]);

      return RefCountOperator;
    }();

    var RefCountSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_4) {
      _inherits(RefCountSubscriber, _Subscriber__WEBPACK_4);

      var _super121 = _createSuper(RefCountSubscriber);

      function RefCountSubscriber(destination, connectable) {
        var _this330;

        _classCallCheck(this, RefCountSubscriber);

        _this330 = _super121.call(this, destination);
        _this330.connectable = connectable;
        return _this330;
      }

      _createClass2(RefCountSubscriber, [{
        key: "_unsubscribe",
        value: function _unsubscribe() {
          var connectable = this.connectable;

          if (!connectable) {
            this.connection = null;
            return;
          }

          this.connectable = null;
          var refCount = connectable._refCount;

          if (refCount <= 0) {
            this.connection = null;
            return;
          }

          connectable._refCount = refCount - 1;

          if (refCount > 1) {
            this.connection = null;
            return;
          }

          var connection = this.connection;
          var sharedConnection = connectable._connection;
          this.connection = null;

          if (sharedConnection && (!connection || sharedConnection === connection)) {
            sharedConnection.unsubscribe();
          }
        }
      }]);

      return RefCountSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_2__["Subscriber"]); //# sourceMappingURL=ConnectableObservable.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/SubscribeOnObservable.js":
  /*!*********************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/SubscribeOnObservable.js ***!
    \*********************************************************************************/

  /*! exports provided: SubscribeOnObservable */

  /***/
  function node_modulesRxjs_esm2015InternalObservableSubscribeOnObservableJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SubscribeOnObservable", function () {
      return SubscribeOnObservable;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _scheduler_asap__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../scheduler/asap */
    "./node_modules/rxjs/_esm2015/internal/scheduler/asap.js");
    /* harmony import */


    var _util_isNumeric__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../util/isNumeric */
    "./node_modules/rxjs/_esm2015/internal/util/isNumeric.js");

    var SubscribeOnObservable = /*#__PURE__*/function (_Observable__WEBPACK_3) {
      _inherits(SubscribeOnObservable, _Observable__WEBPACK_3);

      var _super122 = _createSuper(SubscribeOnObservable);

      function SubscribeOnObservable(source) {
        var _this331;

        var delayTime = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
        var scheduler = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : _scheduler_asap__WEBPACK_IMPORTED_MODULE_1__["asap"];

        _classCallCheck(this, SubscribeOnObservable);

        _this331 = _super122.call(this);
        _this331.source = source;
        _this331.delayTime = delayTime;
        _this331.scheduler = scheduler;

        if (!Object(_util_isNumeric__WEBPACK_IMPORTED_MODULE_2__["isNumeric"])(delayTime) || delayTime < 0) {
          _this331.delayTime = 0;
        }

        if (!scheduler || typeof scheduler.schedule !== 'function') {
          _this331.scheduler = _scheduler_asap__WEBPACK_IMPORTED_MODULE_1__["asap"];
        }

        return _this331;
      }

      _createClass2(SubscribeOnObservable, [{
        key: "_subscribe",
        value: function _subscribe(subscriber) {
          var delay = this.delayTime;
          var source = this.source;
          var scheduler = this.scheduler;
          return scheduler.schedule(SubscribeOnObservable.dispatch, delay, {
            source: source,
            subscriber: subscriber
          });
        }
      }], [{
        key: "create",
        value: function create(source) {
          var delay = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
          var scheduler = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : _scheduler_asap__WEBPACK_IMPORTED_MODULE_1__["asap"];
          return new SubscribeOnObservable(source, delay, scheduler);
        }
      }, {
        key: "dispatch",
        value: function dispatch(arg) {
          var source = arg.source,
              subscriber = arg.subscriber;
          return this.add(source.subscribe(subscriber));
        }
      }]);

      return SubscribeOnObservable;
    }(_Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"]); //# sourceMappingURL=SubscribeOnObservable.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/bindCallback.js":
  /*!************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/bindCallback.js ***!
    \************************************************************************/

  /*! exports provided: bindCallback */

  /***/
  function node_modulesRxjs_esm2015InternalObservableBindCallbackJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "bindCallback", function () {
      return bindCallback;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _AsyncSubject__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../AsyncSubject */
    "./node_modules/rxjs/_esm2015/internal/AsyncSubject.js");
    /* harmony import */


    var _operators_map__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../operators/map */
    "./node_modules/rxjs/_esm2015/internal/operators/map.js");
    /* harmony import */


    var _util_canReportError__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../util/canReportError */
    "./node_modules/rxjs/_esm2015/internal/util/canReportError.js");
    /* harmony import */


    var _util_isArray__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ../util/isArray */
    "./node_modules/rxjs/_esm2015/internal/util/isArray.js");
    /* harmony import */


    var _util_isScheduler__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(
    /*! ../util/isScheduler */
    "./node_modules/rxjs/_esm2015/internal/util/isScheduler.js");

    function bindCallback(callbackFunc, resultSelector, scheduler) {
      if (resultSelector) {
        if (Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_5__["isScheduler"])(resultSelector)) {
          scheduler = resultSelector;
        } else {
          return function () {
            return bindCallback(callbackFunc, scheduler).apply(void 0, arguments).pipe(Object(_operators_map__WEBPACK_IMPORTED_MODULE_2__["map"])(function (args) {
              return Object(_util_isArray__WEBPACK_IMPORTED_MODULE_4__["isArray"])(args) ? resultSelector.apply(void 0, _toConsumableArray(args)) : resultSelector(args);
            }));
          };
        }
      }

      return function () {
        for (var _len33 = arguments.length, args = new Array(_len33), _key32 = 0; _key32 < _len33; _key32++) {
          args[_key32] = arguments[_key32];
        }

        var context = this;
        var subject;
        var params = {
          context: context,
          subject: subject,
          callbackFunc: callbackFunc,
          scheduler: scheduler
        };
        return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
          if (!scheduler) {
            if (!subject) {
              subject = new _AsyncSubject__WEBPACK_IMPORTED_MODULE_1__["AsyncSubject"]();

              var handler = function handler() {
                for (var _len34 = arguments.length, innerArgs = new Array(_len34), _key33 = 0; _key33 < _len34; _key33++) {
                  innerArgs[_key33] = arguments[_key33];
                }

                subject.next(innerArgs.length <= 1 ? innerArgs[0] : innerArgs);
                subject.complete();
              };

              try {
                callbackFunc.apply(context, [].concat(args, [handler]));
              } catch (err) {
                if (Object(_util_canReportError__WEBPACK_IMPORTED_MODULE_3__["canReportError"])(subject)) {
                  subject.error(err);
                } else {
                  console.warn(err);
                }
              }
            }

            return subject.subscribe(subscriber);
          } else {
            var state = {
              args: args,
              subscriber: subscriber,
              params: params
            };
            return scheduler.schedule(dispatch, 0, state);
          }
        });
      };
    }

    function dispatch(state) {
      var _this332 = this;

      var self = this;
      var args = state.args,
          subscriber = state.subscriber,
          params = state.params;
      var callbackFunc = params.callbackFunc,
          context = params.context,
          scheduler = params.scheduler;
      var subject = params.subject;

      if (!subject) {
        subject = params.subject = new _AsyncSubject__WEBPACK_IMPORTED_MODULE_1__["AsyncSubject"]();

        var handler = function handler() {
          for (var _len35 = arguments.length, innerArgs = new Array(_len35), _key34 = 0; _key34 < _len35; _key34++) {
            innerArgs[_key34] = arguments[_key34];
          }

          var value = innerArgs.length <= 1 ? innerArgs[0] : innerArgs;

          _this332.add(scheduler.schedule(dispatchNext, 0, {
            value: value,
            subject: subject
          }));
        };

        try {
          callbackFunc.apply(context, [].concat(_toConsumableArray(args), [handler]));
        } catch (err) {
          subject.error(err);
        }
      }

      this.add(subject.subscribe(subscriber));
    }

    function dispatchNext(state) {
      var value = state.value,
          subject = state.subject;
      subject.next(value);
      subject.complete();
    }

    function dispatchError(state) {
      var err = state.err,
          subject = state.subject;
      subject.error(err);
    } //# sourceMappingURL=bindCallback.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/bindNodeCallback.js":
  /*!****************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/bindNodeCallback.js ***!
    \****************************************************************************/

  /*! exports provided: bindNodeCallback */

  /***/
  function node_modulesRxjs_esm2015InternalObservableBindNodeCallbackJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "bindNodeCallback", function () {
      return bindNodeCallback;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _AsyncSubject__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../AsyncSubject */
    "./node_modules/rxjs/_esm2015/internal/AsyncSubject.js");
    /* harmony import */


    var _operators_map__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../operators/map */
    "./node_modules/rxjs/_esm2015/internal/operators/map.js");
    /* harmony import */


    var _util_canReportError__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../util/canReportError */
    "./node_modules/rxjs/_esm2015/internal/util/canReportError.js");
    /* harmony import */


    var _util_isScheduler__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ../util/isScheduler */
    "./node_modules/rxjs/_esm2015/internal/util/isScheduler.js");
    /* harmony import */


    var _util_isArray__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(
    /*! ../util/isArray */
    "./node_modules/rxjs/_esm2015/internal/util/isArray.js");

    function bindNodeCallback(callbackFunc, resultSelector, scheduler) {
      if (resultSelector) {
        if (Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_4__["isScheduler"])(resultSelector)) {
          scheduler = resultSelector;
        } else {
          return function () {
            return bindNodeCallback(callbackFunc, scheduler).apply(void 0, arguments).pipe(Object(_operators_map__WEBPACK_IMPORTED_MODULE_2__["map"])(function (args) {
              return Object(_util_isArray__WEBPACK_IMPORTED_MODULE_5__["isArray"])(args) ? resultSelector.apply(void 0, _toConsumableArray(args)) : resultSelector(args);
            }));
          };
        }
      }

      return function () {
        for (var _len36 = arguments.length, args = new Array(_len36), _key35 = 0; _key35 < _len36; _key35++) {
          args[_key35] = arguments[_key35];
        }

        var params = {
          subject: undefined,
          args: args,
          callbackFunc: callbackFunc,
          scheduler: scheduler,
          context: this
        };
        return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
          var context = params.context;
          var subject = params.subject;

          if (!scheduler) {
            if (!subject) {
              subject = params.subject = new _AsyncSubject__WEBPACK_IMPORTED_MODULE_1__["AsyncSubject"]();

              var handler = function handler() {
                for (var _len37 = arguments.length, innerArgs = new Array(_len37), _key36 = 0; _key36 < _len37; _key36++) {
                  innerArgs[_key36] = arguments[_key36];
                }

                var err = innerArgs.shift();

                if (err) {
                  subject.error(err);
                  return;
                }

                subject.next(innerArgs.length <= 1 ? innerArgs[0] : innerArgs);
                subject.complete();
              };

              try {
                callbackFunc.apply(context, [].concat(args, [handler]));
              } catch (err) {
                if (Object(_util_canReportError__WEBPACK_IMPORTED_MODULE_3__["canReportError"])(subject)) {
                  subject.error(err);
                } else {
                  console.warn(err);
                }
              }
            }

            return subject.subscribe(subscriber);
          } else {
            return scheduler.schedule(dispatch, 0, {
              params: params,
              subscriber: subscriber,
              context: context
            });
          }
        });
      };
    }

    function dispatch(state) {
      var _this333 = this;

      var params = state.params,
          subscriber = state.subscriber,
          context = state.context;
      var callbackFunc = params.callbackFunc,
          args = params.args,
          scheduler = params.scheduler;
      var subject = params.subject;

      if (!subject) {
        subject = params.subject = new _AsyncSubject__WEBPACK_IMPORTED_MODULE_1__["AsyncSubject"]();

        var handler = function handler() {
          for (var _len38 = arguments.length, innerArgs = new Array(_len38), _key37 = 0; _key37 < _len38; _key37++) {
            innerArgs[_key37] = arguments[_key37];
          }

          var err = innerArgs.shift();

          if (err) {
            _this333.add(scheduler.schedule(dispatchError, 0, {
              err: err,
              subject: subject
            }));
          } else {
            var value = innerArgs.length <= 1 ? innerArgs[0] : innerArgs;

            _this333.add(scheduler.schedule(dispatchNext, 0, {
              value: value,
              subject: subject
            }));
          }
        };

        try {
          callbackFunc.apply(context, [].concat(_toConsumableArray(args), [handler]));
        } catch (err) {
          this.add(scheduler.schedule(dispatchError, 0, {
            err: err,
            subject: subject
          }));
        }
      }

      this.add(subject.subscribe(subscriber));
    }

    function dispatchNext(arg) {
      var value = arg.value,
          subject = arg.subject;
      subject.next(value);
      subject.complete();
    }

    function dispatchError(arg) {
      var err = arg.err,
          subject = arg.subject;
      subject.error(err);
    } //# sourceMappingURL=bindNodeCallback.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/combineLatest.js":
  /*!*************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/combineLatest.js ***!
    \*************************************************************************/

  /*! exports provided: combineLatest, CombineLatestOperator, CombineLatestSubscriber */

  /***/
  function node_modulesRxjs_esm2015InternalObservableCombineLatestJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "combineLatest", function () {
      return combineLatest;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CombineLatestOperator", function () {
      return CombineLatestOperator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "CombineLatestSubscriber", function () {
      return CombineLatestSubscriber;
    });
    /* harmony import */


    var _util_isScheduler__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../util/isScheduler */
    "./node_modules/rxjs/_esm2015/internal/util/isScheduler.js");
    /* harmony import */


    var _util_isArray__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/isArray */
    "./node_modules/rxjs/_esm2015/internal/util/isArray.js");
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");
    /* harmony import */


    var _fromArray__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ./fromArray */
    "./node_modules/rxjs/_esm2015/internal/observable/fromArray.js");

    var NONE = {};

    function combineLatest() {
      for (var _len39 = arguments.length, observables = new Array(_len39), _key38 = 0; _key38 < _len39; _key38++) {
        observables[_key38] = arguments[_key38];
      }

      var resultSelector = null;
      var scheduler = null;

      if (Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_0__["isScheduler"])(observables[observables.length - 1])) {
        scheduler = observables.pop();
      }

      if (typeof observables[observables.length - 1] === 'function') {
        resultSelector = observables.pop();
      }

      if (observables.length === 1 && Object(_util_isArray__WEBPACK_IMPORTED_MODULE_1__["isArray"])(observables[0])) {
        observables = observables[0];
      }

      return Object(_fromArray__WEBPACK_IMPORTED_MODULE_4__["fromArray"])(observables, scheduler).lift(new CombineLatestOperator(resultSelector));
    }

    var CombineLatestOperator = /*#__PURE__*/function () {
      function CombineLatestOperator(resultSelector) {
        _classCallCheck(this, CombineLatestOperator);

        this.resultSelector = resultSelector;
      }

      _createClass2(CombineLatestOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new CombineLatestSubscriber(subscriber, this.resultSelector));
        }
      }]);

      return CombineLatestOperator;
    }();

    var CombineLatestSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB) {
      _inherits(CombineLatestSubscriber, _OuterSubscriber__WEB);

      var _super123 = _createSuper(CombineLatestSubscriber);

      function CombineLatestSubscriber(destination, resultSelector) {
        var _this334;

        _classCallCheck(this, CombineLatestSubscriber);

        _this334 = _super123.call(this, destination);
        _this334.resultSelector = resultSelector;
        _this334.active = 0;
        _this334.values = [];
        _this334.observables = [];
        return _this334;
      }

      _createClass2(CombineLatestSubscriber, [{
        key: "_next",
        value: function _next(observable) {
          this.values.push(NONE);
          this.observables.push(observable);
        }
      }, {
        key: "_complete",
        value: function _complete() {
          var observables = this.observables;
          var len = observables.length;

          if (len === 0) {
            this.destination.complete();
          } else {
            this.active = len;
            this.toRespond = len;

            for (var i = 0; i < len; i++) {
              var observable = observables[i];
              this.add(Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_3__["subscribeToResult"])(this, observable, observable, i));
            }
          }
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete(unused) {
          if ((this.active -= 1) === 0) {
            this.destination.complete();
          }
        }
      }, {
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          var values = this.values;
          var oldVal = values[outerIndex];
          var toRespond = !this.toRespond ? 0 : oldVal === NONE ? --this.toRespond : this.toRespond;
          values[outerIndex] = innerValue;

          if (toRespond === 0) {
            if (this.resultSelector) {
              this._tryResultSelector(values);
            } else {
              this.destination.next(values.slice());
            }
          }
        }
      }, {
        key: "_tryResultSelector",
        value: function _tryResultSelector(values) {
          var result;

          try {
            result = this.resultSelector.apply(this, values);
          } catch (err) {
            this.destination.error(err);
            return;
          }

          this.destination.next(result);
        }
      }]);

      return CombineLatestSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__["OuterSubscriber"]); //# sourceMappingURL=combineLatest.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/concat.js":
  /*!******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/concat.js ***!
    \******************************************************************/

  /*! exports provided: concat */

  /***/
  function node_modulesRxjs_esm2015InternalObservableConcatJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "concat", function () {
      return concat;
    });
    /* harmony import */


    var _of__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./of */
    "./node_modules/rxjs/_esm2015/internal/observable/of.js");
    /* harmony import */


    var _operators_concatAll__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../operators/concatAll */
    "./node_modules/rxjs/_esm2015/internal/operators/concatAll.js");

    function concat() {
      return Object(_operators_concatAll__WEBPACK_IMPORTED_MODULE_1__["concatAll"])()(Object(_of__WEBPACK_IMPORTED_MODULE_0__["of"]).apply(void 0, arguments));
    } //# sourceMappingURL=concat.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/defer.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/defer.js ***!
    \*****************************************************************/

  /*! exports provided: defer */

  /***/
  function node_modulesRxjs_esm2015InternalObservableDeferJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "defer", function () {
      return defer;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _from__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./from */
    "./node_modules/rxjs/_esm2015/internal/observable/from.js");
    /* harmony import */


    var _empty__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ./empty */
    "./node_modules/rxjs/_esm2015/internal/observable/empty.js");

    function defer(observableFactory) {
      return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
        var input;

        try {
          input = observableFactory();
        } catch (err) {
          subscriber.error(err);
          return undefined;
        }

        var source = input ? Object(_from__WEBPACK_IMPORTED_MODULE_1__["from"])(input) : Object(_empty__WEBPACK_IMPORTED_MODULE_2__["empty"])();
        return source.subscribe(subscriber);
      });
    } //# sourceMappingURL=defer.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/empty.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/empty.js ***!
    \*****************************************************************/

  /*! exports provided: EMPTY, empty */

  /***/
  function node_modulesRxjs_esm2015InternalObservableEmptyJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "EMPTY", function () {
      return EMPTY;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "empty", function () {
      return empty;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");

    var EMPTY = new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
      return subscriber.complete();
    });

    function empty(scheduler) {
      return scheduler ? emptyScheduled(scheduler) : EMPTY;
    }

    function emptyScheduled(scheduler) {
      return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
        return scheduler.schedule(function () {
          return subscriber.complete();
        });
      });
    } //# sourceMappingURL=empty.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/forkJoin.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/forkJoin.js ***!
    \********************************************************************/

  /*! exports provided: forkJoin */

  /***/
  function node_modulesRxjs_esm2015InternalObservableForkJoinJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "forkJoin", function () {
      return forkJoin;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _util_isArray__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/isArray */
    "./node_modules/rxjs/_esm2015/internal/util/isArray.js");
    /* harmony import */


    var _operators_map__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../operators/map */
    "./node_modules/rxjs/_esm2015/internal/operators/map.js");
    /* harmony import */


    var _util_isObject__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../util/isObject */
    "./node_modules/rxjs/_esm2015/internal/util/isObject.js");
    /* harmony import */


    var _from__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ./from */
    "./node_modules/rxjs/_esm2015/internal/observable/from.js");

    function forkJoin() {
      for (var _len40 = arguments.length, sources = new Array(_len40), _key39 = 0; _key39 < _len40; _key39++) {
        sources[_key39] = arguments[_key39];
      }

      if (sources.length === 1) {
        var first = sources[0];

        if (Object(_util_isArray__WEBPACK_IMPORTED_MODULE_1__["isArray"])(first)) {
          return forkJoinInternal(first, null);
        }

        if (Object(_util_isObject__WEBPACK_IMPORTED_MODULE_3__["isObject"])(first) && Object.getPrototypeOf(first) === Object.prototype) {
          var keys = Object.keys(first);
          return forkJoinInternal(keys.map(function (key) {
            return first[key];
          }), keys);
        }
      }

      if (typeof sources[sources.length - 1] === 'function') {
        var resultSelector = sources.pop();
        sources = sources.length === 1 && Object(_util_isArray__WEBPACK_IMPORTED_MODULE_1__["isArray"])(sources[0]) ? sources[0] : sources;
        return forkJoinInternal(sources, null).pipe(Object(_operators_map__WEBPACK_IMPORTED_MODULE_2__["map"])(function (args) {
          return resultSelector.apply(void 0, _toConsumableArray(args));
        }));
      }

      return forkJoinInternal(sources, null);
    }

    function forkJoinInternal(sources, keys) {
      return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
        var len = sources.length;

        if (len === 0) {
          subscriber.complete();
          return;
        }

        var values = new Array(len);
        var completed = 0;
        var emitted = 0;

        var _loop5 = function _loop5(i) {
          var source = Object(_from__WEBPACK_IMPORTED_MODULE_4__["from"])(sources[i]);
          var hasValue = false;
          subscriber.add(source.subscribe({
            next: function next(value) {
              if (!hasValue) {
                hasValue = true;
                emitted++;
              }

              values[i] = value;
            },
            error: function error(err) {
              return subscriber.error(err);
            },
            complete: function complete() {
              completed++;

              if (completed === len || !hasValue) {
                if (emitted === len) {
                  subscriber.next(keys ? keys.reduce(function (result, key, i) {
                    return result[key] = values[i], result;
                  }, {}) : values);
                }

                subscriber.complete();
              }
            }
          }));
        };

        for (var i = 0; i < len; i++) {
          _loop5(i);
        }
      });
    } //# sourceMappingURL=forkJoin.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/from.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/from.js ***!
    \****************************************************************/

  /*! exports provided: from */

  /***/
  function node_modulesRxjs_esm2015InternalObservableFromJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "from", function () {
      return from;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _util_subscribeTo__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/subscribeTo */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeTo.js");
    /* harmony import */


    var _scheduled_scheduled__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../scheduled/scheduled */
    "./node_modules/rxjs/_esm2015/internal/scheduled/scheduled.js");

    function from(input, scheduler) {
      if (!scheduler) {
        if (input instanceof _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"]) {
          return input;
        }

        return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](Object(_util_subscribeTo__WEBPACK_IMPORTED_MODULE_1__["subscribeTo"])(input));
      } else {
        return Object(_scheduled_scheduled__WEBPACK_IMPORTED_MODULE_2__["scheduled"])(input, scheduler);
      }
    } //# sourceMappingURL=from.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/fromArray.js":
  /*!*********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/fromArray.js ***!
    \*********************************************************************/

  /*! exports provided: fromArray */

  /***/
  function node_modulesRxjs_esm2015InternalObservableFromArrayJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "fromArray", function () {
      return fromArray;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _util_subscribeToArray__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/subscribeToArray */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToArray.js");
    /* harmony import */


    var _scheduled_scheduleArray__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../scheduled/scheduleArray */
    "./node_modules/rxjs/_esm2015/internal/scheduled/scheduleArray.js");

    function fromArray(input, scheduler) {
      if (!scheduler) {
        return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](Object(_util_subscribeToArray__WEBPACK_IMPORTED_MODULE_1__["subscribeToArray"])(input));
      } else {
        return Object(_scheduled_scheduleArray__WEBPACK_IMPORTED_MODULE_2__["scheduleArray"])(input, scheduler);
      }
    } //# sourceMappingURL=fromArray.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/fromEvent.js":
  /*!*********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/fromEvent.js ***!
    \*********************************************************************/

  /*! exports provided: fromEvent */

  /***/
  function node_modulesRxjs_esm2015InternalObservableFromEventJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "fromEvent", function () {
      return fromEvent;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _util_isArray__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/isArray */
    "./node_modules/rxjs/_esm2015/internal/util/isArray.js");
    /* harmony import */


    var _util_isFunction__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../util/isFunction */
    "./node_modules/rxjs/_esm2015/internal/util/isFunction.js");
    /* harmony import */


    var _operators_map__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../operators/map */
    "./node_modules/rxjs/_esm2015/internal/operators/map.js");

    var toString = function () {
      return Object.prototype.toString;
    }();

    function fromEvent(target, eventName, options, resultSelector) {
      if (Object(_util_isFunction__WEBPACK_IMPORTED_MODULE_2__["isFunction"])(options)) {
        resultSelector = options;
        options = undefined;
      }

      if (resultSelector) {
        return fromEvent(target, eventName, options).pipe(Object(_operators_map__WEBPACK_IMPORTED_MODULE_3__["map"])(function (args) {
          return Object(_util_isArray__WEBPACK_IMPORTED_MODULE_1__["isArray"])(args) ? resultSelector.apply(void 0, _toConsumableArray(args)) : resultSelector(args);
        }));
      }

      return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
        function handler(e) {
          if (arguments.length > 1) {
            subscriber.next(Array.prototype.slice.call(arguments));
          } else {
            subscriber.next(e);
          }
        }

        setupSubscription(target, eventName, handler, subscriber, options);
      });
    }

    function setupSubscription(sourceObj, eventName, handler, subscriber, options) {
      var unsubscribe;

      if (isEventTarget(sourceObj)) {
        var source = sourceObj;
        sourceObj.addEventListener(eventName, handler, options);

        unsubscribe = function unsubscribe() {
          return source.removeEventListener(eventName, handler, options);
        };
      } else if (isJQueryStyleEventEmitter(sourceObj)) {
        var _source = sourceObj;
        sourceObj.on(eventName, handler);

        unsubscribe = function unsubscribe() {
          return _source.off(eventName, handler);
        };
      } else if (isNodeStyleEventEmitter(sourceObj)) {
        var _source2 = sourceObj;
        sourceObj.addListener(eventName, handler);

        unsubscribe = function unsubscribe() {
          return _source2.removeListener(eventName, handler);
        };
      } else if (sourceObj && sourceObj.length) {
        for (var i = 0, _len41 = sourceObj.length; i < _len41; i++) {
          setupSubscription(sourceObj[i], eventName, handler, subscriber, options);
        }
      } else {
        throw new TypeError('Invalid event target');
      }

      subscriber.add(unsubscribe);
    }

    function isNodeStyleEventEmitter(sourceObj) {
      return sourceObj && typeof sourceObj.addListener === 'function' && typeof sourceObj.removeListener === 'function';
    }

    function isJQueryStyleEventEmitter(sourceObj) {
      return sourceObj && typeof sourceObj.on === 'function' && typeof sourceObj.off === 'function';
    }

    function isEventTarget(sourceObj) {
      return sourceObj && typeof sourceObj.addEventListener === 'function' && typeof sourceObj.removeEventListener === 'function';
    } //# sourceMappingURL=fromEvent.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/fromEventPattern.js":
  /*!****************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/fromEventPattern.js ***!
    \****************************************************************************/

  /*! exports provided: fromEventPattern */

  /***/
  function node_modulesRxjs_esm2015InternalObservableFromEventPatternJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "fromEventPattern", function () {
      return fromEventPattern;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _util_isArray__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/isArray */
    "./node_modules/rxjs/_esm2015/internal/util/isArray.js");
    /* harmony import */


    var _util_isFunction__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../util/isFunction */
    "./node_modules/rxjs/_esm2015/internal/util/isFunction.js");
    /* harmony import */


    var _operators_map__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../operators/map */
    "./node_modules/rxjs/_esm2015/internal/operators/map.js");

    function fromEventPattern(addHandler, removeHandler, resultSelector) {
      if (resultSelector) {
        return fromEventPattern(addHandler, removeHandler).pipe(Object(_operators_map__WEBPACK_IMPORTED_MODULE_3__["map"])(function (args) {
          return Object(_util_isArray__WEBPACK_IMPORTED_MODULE_1__["isArray"])(args) ? resultSelector.apply(void 0, _toConsumableArray(args)) : resultSelector(args);
        }));
      }

      return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
        var handler = function handler() {
          for (var _len42 = arguments.length, e = new Array(_len42), _key40 = 0; _key40 < _len42; _key40++) {
            e[_key40] = arguments[_key40];
          }

          return subscriber.next(e.length === 1 ? e[0] : e);
        };

        var retValue;

        try {
          retValue = addHandler(handler);
        } catch (err) {
          subscriber.error(err);
          return undefined;
        }

        if (!Object(_util_isFunction__WEBPACK_IMPORTED_MODULE_2__["isFunction"])(removeHandler)) {
          return undefined;
        }

        return function () {
          return removeHandler(handler, retValue);
        };
      });
    } //# sourceMappingURL=fromEventPattern.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/generate.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/generate.js ***!
    \********************************************************************/

  /*! exports provided: generate */

  /***/
  function node_modulesRxjs_esm2015InternalObservableGenerateJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "generate", function () {
      return generate;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _util_identity__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/identity */
    "./node_modules/rxjs/_esm2015/internal/util/identity.js");
    /* harmony import */


    var _util_isScheduler__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../util/isScheduler */
    "./node_modules/rxjs/_esm2015/internal/util/isScheduler.js");

    function generate(initialStateOrOptions, condition, iterate, resultSelectorOrObservable, scheduler) {
      var resultSelector;
      var initialState;

      if (arguments.length == 1) {
        var options = initialStateOrOptions;
        initialState = options.initialState;
        condition = options.condition;
        iterate = options.iterate;
        resultSelector = options.resultSelector || _util_identity__WEBPACK_IMPORTED_MODULE_1__["identity"];
        scheduler = options.scheduler;
      } else if (resultSelectorOrObservable === undefined || Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_2__["isScheduler"])(resultSelectorOrObservable)) {
        initialState = initialStateOrOptions;
        resultSelector = _util_identity__WEBPACK_IMPORTED_MODULE_1__["identity"];
        scheduler = resultSelectorOrObservable;
      } else {
        initialState = initialStateOrOptions;
        resultSelector = resultSelectorOrObservable;
      }

      return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
        var state = initialState;

        if (scheduler) {
          return scheduler.schedule(dispatch, 0, {
            subscriber: subscriber,
            iterate: iterate,
            condition: condition,
            resultSelector: resultSelector,
            state: state
          });
        }

        do {
          if (condition) {
            var conditionResult = void 0;

            try {
              conditionResult = condition(state);
            } catch (err) {
              subscriber.error(err);
              return undefined;
            }

            if (!conditionResult) {
              subscriber.complete();
              break;
            }
          }

          var value = void 0;

          try {
            value = resultSelector(state);
          } catch (err) {
            subscriber.error(err);
            return undefined;
          }

          subscriber.next(value);

          if (subscriber.closed) {
            break;
          }

          try {
            state = iterate(state);
          } catch (err) {
            subscriber.error(err);
            return undefined;
          }
        } while (true);

        return undefined;
      });
    }

    function dispatch(state) {
      var subscriber = state.subscriber,
          condition = state.condition;

      if (subscriber.closed) {
        return undefined;
      }

      if (state.needIterate) {
        try {
          state.state = state.iterate(state.state);
        } catch (err) {
          subscriber.error(err);
          return undefined;
        }
      } else {
        state.needIterate = true;
      }

      if (condition) {
        var conditionResult;

        try {
          conditionResult = condition(state.state);
        } catch (err) {
          subscriber.error(err);
          return undefined;
        }

        if (!conditionResult) {
          subscriber.complete();
          return undefined;
        }

        if (subscriber.closed) {
          return undefined;
        }
      }

      var value;

      try {
        value = state.resultSelector(state.state);
      } catch (err) {
        subscriber.error(err);
        return undefined;
      }

      if (subscriber.closed) {
        return undefined;
      }

      subscriber.next(value);

      if (subscriber.closed) {
        return undefined;
      }

      return this.schedule(state);
    } //# sourceMappingURL=generate.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/iif.js":
  /*!***************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/iif.js ***!
    \***************************************************************/

  /*! exports provided: iif */

  /***/
  function node_modulesRxjs_esm2015InternalObservableIifJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "iif", function () {
      return iif;
    });
    /* harmony import */


    var _defer__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./defer */
    "./node_modules/rxjs/_esm2015/internal/observable/defer.js");
    /* harmony import */


    var _empty__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./empty */
    "./node_modules/rxjs/_esm2015/internal/observable/empty.js");

    function iif(condition) {
      var trueResult = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : _empty__WEBPACK_IMPORTED_MODULE_1__["EMPTY"];
      var falseResult = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : _empty__WEBPACK_IMPORTED_MODULE_1__["EMPTY"];
      return Object(_defer__WEBPACK_IMPORTED_MODULE_0__["defer"])(function () {
        return condition() ? trueResult : falseResult;
      });
    } //# sourceMappingURL=iif.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/interval.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/interval.js ***!
    \********************************************************************/

  /*! exports provided: interval */

  /***/
  function node_modulesRxjs_esm2015InternalObservableIntervalJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "interval", function () {
      return interval;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _scheduler_async__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../scheduler/async */
    "./node_modules/rxjs/_esm2015/internal/scheduler/async.js");
    /* harmony import */


    var _util_isNumeric__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../util/isNumeric */
    "./node_modules/rxjs/_esm2015/internal/util/isNumeric.js");

    function interval() {
      var period = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
      var scheduler = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : _scheduler_async__WEBPACK_IMPORTED_MODULE_1__["async"];

      if (!Object(_util_isNumeric__WEBPACK_IMPORTED_MODULE_2__["isNumeric"])(period) || period < 0) {
        period = 0;
      }

      if (!scheduler || typeof scheduler.schedule !== 'function') {
        scheduler = _scheduler_async__WEBPACK_IMPORTED_MODULE_1__["async"];
      }

      return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
        subscriber.add(scheduler.schedule(dispatch, period, {
          subscriber: subscriber,
          counter: 0,
          period: period
        }));
        return subscriber;
      });
    }

    function dispatch(state) {
      var subscriber = state.subscriber,
          counter = state.counter,
          period = state.period;
      subscriber.next(counter);
      this.schedule({
        subscriber: subscriber,
        counter: counter + 1,
        period: period
      }, period);
    } //# sourceMappingURL=interval.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/merge.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/merge.js ***!
    \*****************************************************************/

  /*! exports provided: merge */

  /***/
  function node_modulesRxjs_esm2015InternalObservableMergeJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "merge", function () {
      return merge;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _util_isScheduler__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/isScheduler */
    "./node_modules/rxjs/_esm2015/internal/util/isScheduler.js");
    /* harmony import */


    var _operators_mergeAll__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../operators/mergeAll */
    "./node_modules/rxjs/_esm2015/internal/operators/mergeAll.js");
    /* harmony import */


    var _fromArray__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ./fromArray */
    "./node_modules/rxjs/_esm2015/internal/observable/fromArray.js");

    function merge() {
      var concurrent = Number.POSITIVE_INFINITY;
      var scheduler = null;

      for (var _len43 = arguments.length, observables = new Array(_len43), _key41 = 0; _key41 < _len43; _key41++) {
        observables[_key41] = arguments[_key41];
      }

      var last = observables[observables.length - 1];

      if (Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_1__["isScheduler"])(last)) {
        scheduler = observables.pop();

        if (observables.length > 1 && typeof observables[observables.length - 1] === 'number') {
          concurrent = observables.pop();
        }
      } else if (typeof last === 'number') {
        concurrent = observables.pop();
      }

      if (scheduler === null && observables.length === 1 && observables[0] instanceof _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"]) {
        return observables[0];
      }

      return Object(_operators_mergeAll__WEBPACK_IMPORTED_MODULE_2__["mergeAll"])(concurrent)(Object(_fromArray__WEBPACK_IMPORTED_MODULE_3__["fromArray"])(observables, scheduler));
    } //# sourceMappingURL=merge.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/never.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/never.js ***!
    \*****************************************************************/

  /*! exports provided: NEVER, never */

  /***/
  function node_modulesRxjs_esm2015InternalObservableNeverJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "NEVER", function () {
      return NEVER;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "never", function () {
      return never;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _util_noop__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/noop */
    "./node_modules/rxjs/_esm2015/internal/util/noop.js");

    var NEVER = new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](_util_noop__WEBPACK_IMPORTED_MODULE_1__["noop"]);

    function never() {
      return NEVER;
    } //# sourceMappingURL=never.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/of.js":
  /*!**************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/of.js ***!
    \**************************************************************/

  /*! exports provided: of */

  /***/
  function node_modulesRxjs_esm2015InternalObservableOfJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "of", function () {
      return of;
    });
    /* harmony import */


    var _util_isScheduler__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../util/isScheduler */
    "./node_modules/rxjs/_esm2015/internal/util/isScheduler.js");
    /* harmony import */


    var _fromArray__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./fromArray */
    "./node_modules/rxjs/_esm2015/internal/observable/fromArray.js");
    /* harmony import */


    var _scheduled_scheduleArray__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../scheduled/scheduleArray */
    "./node_modules/rxjs/_esm2015/internal/scheduled/scheduleArray.js");

    function of() {
      for (var _len44 = arguments.length, args = new Array(_len44), _key42 = 0; _key42 < _len44; _key42++) {
        args[_key42] = arguments[_key42];
      }

      var scheduler = args[args.length - 1];

      if (Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_0__["isScheduler"])(scheduler)) {
        args.pop();
        return Object(_scheduled_scheduleArray__WEBPACK_IMPORTED_MODULE_2__["scheduleArray"])(args, scheduler);
      } else {
        return Object(_fromArray__WEBPACK_IMPORTED_MODULE_1__["fromArray"])(args);
      }
    } //# sourceMappingURL=of.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/onErrorResumeNext.js":
  /*!*****************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/onErrorResumeNext.js ***!
    \*****************************************************************************/

  /*! exports provided: onErrorResumeNext */

  /***/
  function node_modulesRxjs_esm2015InternalObservableOnErrorResumeNextJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "onErrorResumeNext", function () {
      return onErrorResumeNext;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _from__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./from */
    "./node_modules/rxjs/_esm2015/internal/observable/from.js");
    /* harmony import */


    var _util_isArray__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../util/isArray */
    "./node_modules/rxjs/_esm2015/internal/util/isArray.js");
    /* harmony import */


    var _empty__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ./empty */
    "./node_modules/rxjs/_esm2015/internal/observable/empty.js");

    function onErrorResumeNext() {
      for (var _len45 = arguments.length, sources = new Array(_len45), _key43 = 0; _key43 < _len45; _key43++) {
        sources[_key43] = arguments[_key43];
      }

      if (sources.length === 0) {
        return _empty__WEBPACK_IMPORTED_MODULE_3__["EMPTY"];
      }

      var first = sources[0],
          remainder = sources.slice(1);

      if (sources.length === 1 && Object(_util_isArray__WEBPACK_IMPORTED_MODULE_2__["isArray"])(first)) {
        return onErrorResumeNext.apply(void 0, _toConsumableArray(first));
      }

      return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
        var subNext = function subNext() {
          return subscriber.add(onErrorResumeNext.apply(void 0, _toConsumableArray(remainder)).subscribe(subscriber));
        };

        return Object(_from__WEBPACK_IMPORTED_MODULE_1__["from"])(first).subscribe({
          next: function next(value) {
            subscriber.next(value);
          },
          error: subNext,
          complete: subNext
        });
      });
    } //# sourceMappingURL=onErrorResumeNext.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/pairs.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/pairs.js ***!
    \*****************************************************************/

  /*! exports provided: pairs, dispatch */

  /***/
  function node_modulesRxjs_esm2015InternalObservablePairsJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "pairs", function () {
      return pairs;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "dispatch", function () {
      return dispatch;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _Subscription__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../Subscription */
    "./node_modules/rxjs/_esm2015/internal/Subscription.js");

    function pairs(obj, scheduler) {
      if (!scheduler) {
        return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
          var keys = Object.keys(obj);

          for (var i = 0; i < keys.length && !subscriber.closed; i++) {
            var key = keys[i];

            if (obj.hasOwnProperty(key)) {
              subscriber.next([key, obj[key]]);
            }
          }

          subscriber.complete();
        });
      } else {
        return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
          var keys = Object.keys(obj);
          var subscription = new _Subscription__WEBPACK_IMPORTED_MODULE_1__["Subscription"]();
          subscription.add(scheduler.schedule(dispatch, 0, {
            keys: keys,
            index: 0,
            subscriber: subscriber,
            subscription: subscription,
            obj: obj
          }));
          return subscription;
        });
      }
    }

    function dispatch(state) {
      var keys = state.keys,
          index = state.index,
          subscriber = state.subscriber,
          subscription = state.subscription,
          obj = state.obj;

      if (!subscriber.closed) {
        if (index < keys.length) {
          var key = keys[index];
          subscriber.next([key, obj[key]]);
          subscription.add(this.schedule({
            keys: keys,
            index: index + 1,
            subscriber: subscriber,
            subscription: subscription,
            obj: obj
          }));
        } else {
          subscriber.complete();
        }
      }
    } //# sourceMappingURL=pairs.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/partition.js":
  /*!*********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/partition.js ***!
    \*********************************************************************/

  /*! exports provided: partition */

  /***/
  function node_modulesRxjs_esm2015InternalObservablePartitionJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "partition", function () {
      return partition;
    });
    /* harmony import */


    var _util_not__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../util/not */
    "./node_modules/rxjs/_esm2015/internal/util/not.js");
    /* harmony import */


    var _util_subscribeTo__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/subscribeTo */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeTo.js");
    /* harmony import */


    var _operators_filter__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../operators/filter */
    "./node_modules/rxjs/_esm2015/internal/operators/filter.js");
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");

    function partition(source, predicate, thisArg) {
      return [Object(_operators_filter__WEBPACK_IMPORTED_MODULE_2__["filter"])(predicate, thisArg)(new _Observable__WEBPACK_IMPORTED_MODULE_3__["Observable"](Object(_util_subscribeTo__WEBPACK_IMPORTED_MODULE_1__["subscribeTo"])(source))), Object(_operators_filter__WEBPACK_IMPORTED_MODULE_2__["filter"])(Object(_util_not__WEBPACK_IMPORTED_MODULE_0__["not"])(predicate, thisArg))(new _Observable__WEBPACK_IMPORTED_MODULE_3__["Observable"](Object(_util_subscribeTo__WEBPACK_IMPORTED_MODULE_1__["subscribeTo"])(source)))];
    } //# sourceMappingURL=partition.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/race.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/race.js ***!
    \****************************************************************/

  /*! exports provided: race, RaceOperator, RaceSubscriber */

  /***/
  function node_modulesRxjs_esm2015InternalObservableRaceJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "race", function () {
      return race;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RaceOperator", function () {
      return RaceOperator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "RaceSubscriber", function () {
      return RaceSubscriber;
    });
    /* harmony import */


    var _util_isArray__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../util/isArray */
    "./node_modules/rxjs/_esm2015/internal/util/isArray.js");
    /* harmony import */


    var _fromArray__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./fromArray */
    "./node_modules/rxjs/_esm2015/internal/observable/fromArray.js");
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function race() {
      for (var _len46 = arguments.length, observables = new Array(_len46), _key44 = 0; _key44 < _len46; _key44++) {
        observables[_key44] = arguments[_key44];
      }

      if (observables.length === 1) {
        if (Object(_util_isArray__WEBPACK_IMPORTED_MODULE_0__["isArray"])(observables[0])) {
          observables = observables[0];
        } else {
          return observables[0];
        }
      }

      return Object(_fromArray__WEBPACK_IMPORTED_MODULE_1__["fromArray"])(observables, undefined).lift(new RaceOperator());
    }

    var RaceOperator = /*#__PURE__*/function () {
      function RaceOperator() {
        _classCallCheck(this, RaceOperator);
      }

      _createClass2(RaceOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new RaceSubscriber(subscriber));
        }
      }]);

      return RaceOperator;
    }();

    var RaceSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB2) {
      _inherits(RaceSubscriber, _OuterSubscriber__WEB2);

      var _super124 = _createSuper(RaceSubscriber);

      function RaceSubscriber(destination) {
        var _this335;

        _classCallCheck(this, RaceSubscriber);

        _this335 = _super124.call(this, destination);
        _this335.hasFirst = false;
        _this335.observables = [];
        _this335.subscriptions = [];
        return _this335;
      }

      _createClass2(RaceSubscriber, [{
        key: "_next",
        value: function _next(observable) {
          this.observables.push(observable);
        }
      }, {
        key: "_complete",
        value: function _complete() {
          var observables = this.observables;
          var len = observables.length;

          if (len === 0) {
            this.destination.complete();
          } else {
            for (var i = 0; i < len && !this.hasFirst; i++) {
              var observable = observables[i];
              var subscription = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_3__["subscribeToResult"])(this, observable, observable, i);

              if (this.subscriptions) {
                this.subscriptions.push(subscription);
              }

              this.add(subscription);
            }

            this.observables = null;
          }
        }
      }, {
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          if (!this.hasFirst) {
            this.hasFirst = true;

            for (var i = 0; i < this.subscriptions.length; i++) {
              if (i !== outerIndex) {
                var subscription = this.subscriptions[i];
                subscription.unsubscribe();
                this.remove(subscription);
              }
            }

            this.subscriptions = null;
          }

          this.destination.next(innerValue);
        }
      }]);

      return RaceSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__["OuterSubscriber"]); //# sourceMappingURL=race.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/range.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/range.js ***!
    \*****************************************************************/

  /*! exports provided: range, dispatch */

  /***/
  function node_modulesRxjs_esm2015InternalObservableRangeJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "range", function () {
      return range;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "dispatch", function () {
      return dispatch;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");

    function range() {
      var start = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
      var count = arguments.length > 1 ? arguments[1] : undefined;
      var scheduler = arguments.length > 2 ? arguments[2] : undefined;
      return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
        if (count === undefined) {
          count = start;
          start = 0;
        }

        var index = 0;
        var current = start;

        if (scheduler) {
          return scheduler.schedule(dispatch, 0, {
            index: index,
            count: count,
            start: start,
            subscriber: subscriber
          });
        } else {
          do {
            if (index++ >= count) {
              subscriber.complete();
              break;
            }

            subscriber.next(current++);

            if (subscriber.closed) {
              break;
            }
          } while (true);
        }

        return undefined;
      });
    }

    function dispatch(state) {
      var start = state.start,
          index = state.index,
          count = state.count,
          subscriber = state.subscriber;

      if (index >= count) {
        subscriber.complete();
        return;
      }

      subscriber.next(start);

      if (subscriber.closed) {
        return;
      }

      state.index = index + 1;
      state.start = start + 1;
      this.schedule(state);
    } //# sourceMappingURL=range.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/throwError.js":
  /*!**********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/throwError.js ***!
    \**********************************************************************/

  /*! exports provided: throwError */

  /***/
  function node_modulesRxjs_esm2015InternalObservableThrowErrorJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "throwError", function () {
      return throwError;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");

    function throwError(error, scheduler) {
      if (!scheduler) {
        return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
          return subscriber.error(error);
        });
      } else {
        return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
          return scheduler.schedule(dispatch, 0, {
            error: error,
            subscriber: subscriber
          });
        });
      }
    }

    function dispatch(_ref17) {
      var error = _ref17.error,
          subscriber = _ref17.subscriber;
      subscriber.error(error);
    } //# sourceMappingURL=throwError.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/timer.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/timer.js ***!
    \*****************************************************************/

  /*! exports provided: timer */

  /***/
  function node_modulesRxjs_esm2015InternalObservableTimerJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "timer", function () {
      return timer;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _scheduler_async__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../scheduler/async */
    "./node_modules/rxjs/_esm2015/internal/scheduler/async.js");
    /* harmony import */


    var _util_isNumeric__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../util/isNumeric */
    "./node_modules/rxjs/_esm2015/internal/util/isNumeric.js");
    /* harmony import */


    var _util_isScheduler__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../util/isScheduler */
    "./node_modules/rxjs/_esm2015/internal/util/isScheduler.js");

    function timer() {
      var dueTime = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
      var periodOrScheduler = arguments.length > 1 ? arguments[1] : undefined;
      var scheduler = arguments.length > 2 ? arguments[2] : undefined;
      var period = -1;

      if (Object(_util_isNumeric__WEBPACK_IMPORTED_MODULE_2__["isNumeric"])(periodOrScheduler)) {
        period = Number(periodOrScheduler) < 1 && 1 || Number(periodOrScheduler);
      } else if (Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_3__["isScheduler"])(periodOrScheduler)) {
        scheduler = periodOrScheduler;
      }

      if (!Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_3__["isScheduler"])(scheduler)) {
        scheduler = _scheduler_async__WEBPACK_IMPORTED_MODULE_1__["async"];
      }

      return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
        var due = Object(_util_isNumeric__WEBPACK_IMPORTED_MODULE_2__["isNumeric"])(dueTime) ? dueTime : +dueTime - scheduler.now();
        return scheduler.schedule(dispatch, due, {
          index: 0,
          period: period,
          subscriber: subscriber
        });
      });
    }

    function dispatch(state) {
      var index = state.index,
          period = state.period,
          subscriber = state.subscriber;
      subscriber.next(index);

      if (subscriber.closed) {
        return;
      } else if (period === -1) {
        return subscriber.complete();
      }

      state.index = index + 1;
      this.schedule(state, period);
    } //# sourceMappingURL=timer.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/using.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/using.js ***!
    \*****************************************************************/

  /*! exports provided: using */

  /***/
  function node_modulesRxjs_esm2015InternalObservableUsingJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "using", function () {
      return using;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _from__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./from */
    "./node_modules/rxjs/_esm2015/internal/observable/from.js");
    /* harmony import */


    var _empty__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ./empty */
    "./node_modules/rxjs/_esm2015/internal/observable/empty.js");

    function using(resourceFactory, observableFactory) {
      return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
        var resource;

        try {
          resource = resourceFactory();
        } catch (err) {
          subscriber.error(err);
          return undefined;
        }

        var result;

        try {
          result = observableFactory(resource);
        } catch (err) {
          subscriber.error(err);
          return undefined;
        }

        var source = result ? Object(_from__WEBPACK_IMPORTED_MODULE_1__["from"])(result) : _empty__WEBPACK_IMPORTED_MODULE_2__["EMPTY"];
        var subscription = source.subscribe(subscriber);
        return function () {
          subscription.unsubscribe();

          if (resource) {
            resource.unsubscribe();
          }
        };
      });
    } //# sourceMappingURL=using.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/observable/zip.js":
  /*!***************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/observable/zip.js ***!
    \***************************************************************/

  /*! exports provided: zip, ZipOperator, ZipSubscriber */

  /***/
  function node_modulesRxjs_esm2015InternalObservableZipJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "zip", function () {
      return zip;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ZipOperator", function () {
      return ZipOperator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ZipSubscriber", function () {
      return ZipSubscriber;
    });
    /* harmony import */


    var _fromArray__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./fromArray */
    "./node_modules/rxjs/_esm2015/internal/observable/fromArray.js");
    /* harmony import */


    var _util_isArray__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/isArray */
    "./node_modules/rxjs/_esm2015/internal/util/isArray.js");
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");
    /* harmony import */


    var _internal_symbol_iterator__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(
    /*! ../../internal/symbol/iterator */
    "./node_modules/rxjs/_esm2015/internal/symbol/iterator.js");

    function zip() {
      for (var _len47 = arguments.length, observables = new Array(_len47), _key45 = 0; _key45 < _len47; _key45++) {
        observables[_key45] = arguments[_key45];
      }

      var resultSelector = observables[observables.length - 1];

      if (typeof resultSelector === 'function') {
        observables.pop();
      }

      return Object(_fromArray__WEBPACK_IMPORTED_MODULE_0__["fromArray"])(observables, undefined).lift(new ZipOperator(resultSelector));
    }

    var ZipOperator = /*#__PURE__*/function () {
      function ZipOperator(resultSelector) {
        _classCallCheck(this, ZipOperator);

        this.resultSelector = resultSelector;
      }

      _createClass2(ZipOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new ZipSubscriber(subscriber, this.resultSelector));
        }
      }]);

      return ZipOperator;
    }();

    var ZipSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_5) {
      _inherits(ZipSubscriber, _Subscriber__WEBPACK_5);

      var _super125 = _createSuper(ZipSubscriber);

      function ZipSubscriber(destination, resultSelector) {
        var _this336;

        var values = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : Object.create(null);

        _classCallCheck(this, ZipSubscriber);

        _this336 = _super125.call(this, destination);
        _this336.iterators = [];
        _this336.active = 0;
        _this336.resultSelector = typeof resultSelector === 'function' ? resultSelector : null;
        _this336.values = values;
        return _this336;
      }

      _createClass2(ZipSubscriber, [{
        key: "_next",
        value: function _next(value) {
          var iterators = this.iterators;

          if (Object(_util_isArray__WEBPACK_IMPORTED_MODULE_1__["isArray"])(value)) {
            iterators.push(new StaticArrayIterator(value));
          } else if (typeof value[_internal_symbol_iterator__WEBPACK_IMPORTED_MODULE_5__["iterator"]] === 'function') {
            iterators.push(new StaticIterator(value[_internal_symbol_iterator__WEBPACK_IMPORTED_MODULE_5__["iterator"]]()));
          } else {
            iterators.push(new ZipBufferIterator(this.destination, this, value));
          }
        }
      }, {
        key: "_complete",
        value: function _complete() {
          var iterators = this.iterators;
          var len = iterators.length;
          this.unsubscribe();

          if (len === 0) {
            this.destination.complete();
            return;
          }

          this.active = len;

          for (var i = 0; i < len; i++) {
            var iterator = iterators[i];

            if (iterator.stillUnsubscribed) {
              var destination = this.destination;
              destination.add(iterator.subscribe(iterator, i));
            } else {
              this.active--;
            }
          }
        }
      }, {
        key: "notifyInactive",
        value: function notifyInactive() {
          this.active--;

          if (this.active === 0) {
            this.destination.complete();
          }
        }
      }, {
        key: "checkIterators",
        value: function checkIterators() {
          var iterators = this.iterators;
          var len = iterators.length;
          var destination = this.destination;

          for (var i = 0; i < len; i++) {
            var iterator = iterators[i];

            if (typeof iterator.hasValue === 'function' && !iterator.hasValue()) {
              return;
            }
          }

          var shouldComplete = false;
          var args = [];

          for (var _i31 = 0; _i31 < len; _i31++) {
            var _iterator27 = iterators[_i31];

            var result = _iterator27.next();

            if (_iterator27.hasCompleted()) {
              shouldComplete = true;
            }

            if (result.done) {
              destination.complete();
              return;
            }

            args.push(result.value);
          }

          if (this.resultSelector) {
            this._tryresultSelector(args);
          } else {
            destination.next(args);
          }

          if (shouldComplete) {
            destination.complete();
          }
        }
      }, {
        key: "_tryresultSelector",
        value: function _tryresultSelector(args) {
          var result;

          try {
            result = this.resultSelector.apply(this, args);
          } catch (err) {
            this.destination.error(err);
            return;
          }

          this.destination.next(result);
        }
      }]);

      return ZipSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_2__["Subscriber"]);

    var StaticIterator = /*#__PURE__*/function () {
      function StaticIterator(iterator) {
        _classCallCheck(this, StaticIterator);

        this.iterator = iterator;
        this.nextResult = iterator.next();
      }

      _createClass2(StaticIterator, [{
        key: "hasValue",
        value: function hasValue() {
          return true;
        }
      }, {
        key: "next",
        value: function next() {
          var result = this.nextResult;
          this.nextResult = this.iterator.next();
          return result;
        }
      }, {
        key: "hasCompleted",
        value: function hasCompleted() {
          var nextResult = this.nextResult;
          return nextResult && nextResult.done;
        }
      }]);

      return StaticIterator;
    }();

    var StaticArrayIterator = /*#__PURE__*/function () {
      function StaticArrayIterator(array) {
        _classCallCheck(this, StaticArrayIterator);

        this.array = array;
        this.index = 0;
        this.length = 0;
        this.length = array.length;
      }

      _createClass2(StaticArrayIterator, [{
        key: _internal_symbol_iterator__WEBPACK_IMPORTED_MODULE_5__["iterator"],
        value: function value() {
          return this;
        }
      }, {
        key: "next",
        value: function next(value) {
          var i = this.index++;
          var array = this.array;
          return i < this.length ? {
            value: array[i],
            done: false
          } : {
            value: null,
            done: true
          };
        }
      }, {
        key: "hasValue",
        value: function hasValue() {
          return this.array.length > this.index;
        }
      }, {
        key: "hasCompleted",
        value: function hasCompleted() {
          return this.array.length === this.index;
        }
      }]);

      return StaticArrayIterator;
    }();

    var ZipBufferIterator = /*#__PURE__*/function (_OuterSubscriber__WEB3) {
      _inherits(ZipBufferIterator, _OuterSubscriber__WEB3);

      var _super126 = _createSuper(ZipBufferIterator);

      function ZipBufferIterator(destination, parent, observable) {
        var _this337;

        _classCallCheck(this, ZipBufferIterator);

        _this337 = _super126.call(this, destination);
        _this337.parent = parent;
        _this337.observable = observable;
        _this337.stillUnsubscribed = true;
        _this337.buffer = [];
        _this337.isComplete = false;
        return _this337;
      }

      _createClass2(ZipBufferIterator, [{
        key: _internal_symbol_iterator__WEBPACK_IMPORTED_MODULE_5__["iterator"],
        value: function value() {
          return this;
        }
      }, {
        key: "next",
        value: function next() {
          var buffer = this.buffer;

          if (buffer.length === 0 && this.isComplete) {
            return {
              value: null,
              done: true
            };
          } else {
            return {
              value: buffer.shift(),
              done: false
            };
          }
        }
      }, {
        key: "hasValue",
        value: function hasValue() {
          return this.buffer.length > 0;
        }
      }, {
        key: "hasCompleted",
        value: function hasCompleted() {
          return this.buffer.length === 0 && this.isComplete;
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete() {
          if (this.buffer.length > 0) {
            this.isComplete = true;
            this.parent.notifyInactive();
          } else {
            this.destination.complete();
          }
        }
      }, {
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          this.buffer.push(innerValue);
          this.parent.checkIterators();
        }
      }, {
        key: "subscribe",
        value: function subscribe(value, index) {
          return Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_4__["subscribeToResult"])(this, this.observable, this, index);
        }
      }]);

      return ZipBufferIterator;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_3__["OuterSubscriber"]); //# sourceMappingURL=zip.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/audit.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/audit.js ***!
    \****************************************************************/

  /*! exports provided: audit */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsAuditJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "audit", function () {
      return audit;
    });
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function audit(durationSelector) {
      return function auditOperatorFunction(source) {
        return source.lift(new AuditOperator(durationSelector));
      };
    }

    var AuditOperator = /*#__PURE__*/function () {
      function AuditOperator(durationSelector) {
        _classCallCheck(this, AuditOperator);

        this.durationSelector = durationSelector;
      }

      _createClass2(AuditOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new AuditSubscriber(subscriber, this.durationSelector));
        }
      }]);

      return AuditOperator;
    }();

    var AuditSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB4) {
      _inherits(AuditSubscriber, _OuterSubscriber__WEB4);

      var _super127 = _createSuper(AuditSubscriber);

      function AuditSubscriber(destination, durationSelector) {
        var _this338;

        _classCallCheck(this, AuditSubscriber);

        _this338 = _super127.call(this, destination);
        _this338.durationSelector = durationSelector;
        _this338.hasValue = false;
        return _this338;
      }

      _createClass2(AuditSubscriber, [{
        key: "_next",
        value: function _next(value) {
          this.value = value;
          this.hasValue = true;

          if (!this.throttled) {
            var duration;

            try {
              var durationSelector = this.durationSelector;
              duration = durationSelector(value);
            } catch (err) {
              return this.destination.error(err);
            }

            var innerSubscription = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__["subscribeToResult"])(this, duration);

            if (!innerSubscription || innerSubscription.closed) {
              this.clearThrottle();
            } else {
              this.add(this.throttled = innerSubscription);
            }
          }
        }
      }, {
        key: "clearThrottle",
        value: function clearThrottle() {
          var value = this.value,
              hasValue = this.hasValue,
              throttled = this.throttled;

          if (throttled) {
            this.remove(throttled);
            this.throttled = null;
            throttled.unsubscribe();
          }

          if (hasValue) {
            this.value = null;
            this.hasValue = false;
            this.destination.next(value);
          }
        }
      }, {
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex) {
          this.clearThrottle();
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete() {
          this.clearThrottle();
        }
      }]);

      return AuditSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__["OuterSubscriber"]); //# sourceMappingURL=audit.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/auditTime.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/auditTime.js ***!
    \********************************************************************/

  /*! exports provided: auditTime */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsAuditTimeJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "auditTime", function () {
      return auditTime;
    });
    /* harmony import */


    var _scheduler_async__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../scheduler/async */
    "./node_modules/rxjs/_esm2015/internal/scheduler/async.js");
    /* harmony import */


    var _audit__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./audit */
    "./node_modules/rxjs/_esm2015/internal/operators/audit.js");
    /* harmony import */


    var _observable_timer__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../observable/timer */
    "./node_modules/rxjs/_esm2015/internal/observable/timer.js");

    function auditTime(duration) {
      var scheduler = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : _scheduler_async__WEBPACK_IMPORTED_MODULE_0__["async"];
      return Object(_audit__WEBPACK_IMPORTED_MODULE_1__["audit"])(function () {
        return Object(_observable_timer__WEBPACK_IMPORTED_MODULE_2__["timer"])(duration, scheduler);
      });
    } //# sourceMappingURL=auditTime.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/buffer.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/buffer.js ***!
    \*****************************************************************/

  /*! exports provided: buffer */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsBufferJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "buffer", function () {
      return buffer;
    });
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function buffer(closingNotifier) {
      return function bufferOperatorFunction(source) {
        return source.lift(new BufferOperator(closingNotifier));
      };
    }

    var BufferOperator = /*#__PURE__*/function () {
      function BufferOperator(closingNotifier) {
        _classCallCheck(this, BufferOperator);

        this.closingNotifier = closingNotifier;
      }

      _createClass2(BufferOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new BufferSubscriber(subscriber, this.closingNotifier));
        }
      }]);

      return BufferOperator;
    }();

    var BufferSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB5) {
      _inherits(BufferSubscriber, _OuterSubscriber__WEB5);

      var _super128 = _createSuper(BufferSubscriber);

      function BufferSubscriber(destination, closingNotifier) {
        var _this339;

        _classCallCheck(this, BufferSubscriber);

        _this339 = _super128.call(this, destination);
        _this339.buffer = [];

        _this339.add(Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__["subscribeToResult"])(_assertThisInitialized(_this339), closingNotifier));

        return _this339;
      }

      _createClass2(BufferSubscriber, [{
        key: "_next",
        value: function _next(value) {
          this.buffer.push(value);
        }
      }, {
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          var buffer = this.buffer;
          this.buffer = [];
          this.destination.next(buffer);
        }
      }]);

      return BufferSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__["OuterSubscriber"]); //# sourceMappingURL=buffer.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/bufferCount.js":
  /*!**********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/bufferCount.js ***!
    \**********************************************************************/

  /*! exports provided: bufferCount */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsBufferCountJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "bufferCount", function () {
      return bufferCount;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function bufferCount(bufferSize) {
      var startBufferEvery = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
      return function bufferCountOperatorFunction(source) {
        return source.lift(new BufferCountOperator(bufferSize, startBufferEvery));
      };
    }

    var BufferCountOperator = /*#__PURE__*/function () {
      function BufferCountOperator(bufferSize, startBufferEvery) {
        _classCallCheck(this, BufferCountOperator);

        this.bufferSize = bufferSize;
        this.startBufferEvery = startBufferEvery;

        if (!startBufferEvery || bufferSize === startBufferEvery) {
          this.subscriberClass = BufferCountSubscriber;
        } else {
          this.subscriberClass = BufferSkipCountSubscriber;
        }
      }

      _createClass2(BufferCountOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new this.subscriberClass(subscriber, this.bufferSize, this.startBufferEvery));
        }
      }]);

      return BufferCountOperator;
    }();

    var BufferCountSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_6) {
      _inherits(BufferCountSubscriber, _Subscriber__WEBPACK_6);

      var _super129 = _createSuper(BufferCountSubscriber);

      function BufferCountSubscriber(destination, bufferSize) {
        var _this340;

        _classCallCheck(this, BufferCountSubscriber);

        _this340 = _super129.call(this, destination);
        _this340.bufferSize = bufferSize;
        _this340.buffer = [];
        return _this340;
      }

      _createClass2(BufferCountSubscriber, [{
        key: "_next",
        value: function _next(value) {
          var buffer = this.buffer;
          buffer.push(value);

          if (buffer.length == this.bufferSize) {
            this.destination.next(buffer);
            this.buffer = [];
          }
        }
      }, {
        key: "_complete",
        value: function _complete() {
          var buffer = this.buffer;

          if (buffer.length > 0) {
            this.destination.next(buffer);
          }

          _get(_getPrototypeOf(BufferCountSubscriber.prototype), "_complete", this).call(this);
        }
      }]);

      return BufferCountSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]);

    var BufferSkipCountSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_7) {
      _inherits(BufferSkipCountSubscriber, _Subscriber__WEBPACK_7);

      var _super130 = _createSuper(BufferSkipCountSubscriber);

      function BufferSkipCountSubscriber(destination, bufferSize, startBufferEvery) {
        var _this341;

        _classCallCheck(this, BufferSkipCountSubscriber);

        _this341 = _super130.call(this, destination);
        _this341.bufferSize = bufferSize;
        _this341.startBufferEvery = startBufferEvery;
        _this341.buffers = [];
        _this341.count = 0;
        return _this341;
      }

      _createClass2(BufferSkipCountSubscriber, [{
        key: "_next",
        value: function _next(value) {
          var bufferSize = this.bufferSize,
              startBufferEvery = this.startBufferEvery,
              buffers = this.buffers,
              count = this.count;
          this.count++;

          if (count % startBufferEvery === 0) {
            buffers.push([]);
          }

          for (var i = buffers.length; i--;) {
            var buffer = buffers[i];
            buffer.push(value);

            if (buffer.length === bufferSize) {
              buffers.splice(i, 1);
              this.destination.next(buffer);
            }
          }
        }
      }, {
        key: "_complete",
        value: function _complete() {
          var buffers = this.buffers,
              destination = this.destination;

          while (buffers.length > 0) {
            var buffer = buffers.shift();

            if (buffer.length > 0) {
              destination.next(buffer);
            }
          }

          _get(_getPrototypeOf(BufferSkipCountSubscriber.prototype), "_complete", this).call(this);
        }
      }]);

      return BufferSkipCountSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=bufferCount.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/bufferTime.js":
  /*!*********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/bufferTime.js ***!
    \*********************************************************************/

  /*! exports provided: bufferTime */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsBufferTimeJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "bufferTime", function () {
      return bufferTime;
    });
    /* harmony import */


    var _scheduler_async__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../scheduler/async */
    "./node_modules/rxjs/_esm2015/internal/scheduler/async.js");
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _util_isScheduler__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../util/isScheduler */
    "./node_modules/rxjs/_esm2015/internal/util/isScheduler.js");

    function bufferTime(bufferTimeSpan) {
      var length = arguments.length;
      var scheduler = _scheduler_async__WEBPACK_IMPORTED_MODULE_0__["async"];

      if (Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_2__["isScheduler"])(arguments[arguments.length - 1])) {
        scheduler = arguments[arguments.length - 1];
        length--;
      }

      var bufferCreationInterval = null;

      if (length >= 2) {
        bufferCreationInterval = arguments[1];
      }

      var maxBufferSize = Number.POSITIVE_INFINITY;

      if (length >= 3) {
        maxBufferSize = arguments[2];
      }

      return function bufferTimeOperatorFunction(source) {
        return source.lift(new BufferTimeOperator(bufferTimeSpan, bufferCreationInterval, maxBufferSize, scheduler));
      };
    }

    var BufferTimeOperator = /*#__PURE__*/function () {
      function BufferTimeOperator(bufferTimeSpan, bufferCreationInterval, maxBufferSize, scheduler) {
        _classCallCheck(this, BufferTimeOperator);

        this.bufferTimeSpan = bufferTimeSpan;
        this.bufferCreationInterval = bufferCreationInterval;
        this.maxBufferSize = maxBufferSize;
        this.scheduler = scheduler;
      }

      _createClass2(BufferTimeOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new BufferTimeSubscriber(subscriber, this.bufferTimeSpan, this.bufferCreationInterval, this.maxBufferSize, this.scheduler));
        }
      }]);

      return BufferTimeOperator;
    }();

    var Context = function Context() {
      _classCallCheck(this, Context);

      this.buffer = [];
    };

    var BufferTimeSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_8) {
      _inherits(BufferTimeSubscriber, _Subscriber__WEBPACK_8);

      var _super131 = _createSuper(BufferTimeSubscriber);

      function BufferTimeSubscriber(destination, bufferTimeSpan, bufferCreationInterval, maxBufferSize, scheduler) {
        var _this342;

        _classCallCheck(this, BufferTimeSubscriber);

        _this342 = _super131.call(this, destination);
        _this342.bufferTimeSpan = bufferTimeSpan;
        _this342.bufferCreationInterval = bufferCreationInterval;
        _this342.maxBufferSize = maxBufferSize;
        _this342.scheduler = scheduler;
        _this342.contexts = [];

        var context = _this342.openContext();

        _this342.timespanOnly = bufferCreationInterval == null || bufferCreationInterval < 0;

        if (_this342.timespanOnly) {
          var timeSpanOnlyState = {
            subscriber: _assertThisInitialized(_this342),
            context: context,
            bufferTimeSpan: bufferTimeSpan
          };

          _this342.add(context.closeAction = scheduler.schedule(dispatchBufferTimeSpanOnly, bufferTimeSpan, timeSpanOnlyState));
        } else {
          var closeState = {
            subscriber: _assertThisInitialized(_this342),
            context: context
          };
          var creationState = {
            bufferTimeSpan: bufferTimeSpan,
            bufferCreationInterval: bufferCreationInterval,
            subscriber: _assertThisInitialized(_this342),
            scheduler: scheduler
          };

          _this342.add(context.closeAction = scheduler.schedule(dispatchBufferClose, bufferTimeSpan, closeState));

          _this342.add(scheduler.schedule(dispatchBufferCreation, bufferCreationInterval, creationState));
        }

        return _this342;
      }

      _createClass2(BufferTimeSubscriber, [{
        key: "_next",
        value: function _next(value) {
          var contexts = this.contexts;
          var len = contexts.length;
          var filledBufferContext;

          for (var i = 0; i < len; i++) {
            var context = contexts[i];
            var buffer = context.buffer;
            buffer.push(value);

            if (buffer.length == this.maxBufferSize) {
              filledBufferContext = context;
            }
          }

          if (filledBufferContext) {
            this.onBufferFull(filledBufferContext);
          }
        }
      }, {
        key: "_error",
        value: function _error(err) {
          this.contexts.length = 0;

          _get(_getPrototypeOf(BufferTimeSubscriber.prototype), "_error", this).call(this, err);
        }
      }, {
        key: "_complete",
        value: function _complete() {
          var contexts = this.contexts,
              destination = this.destination;

          while (contexts.length > 0) {
            var context = contexts.shift();
            destination.next(context.buffer);
          }

          _get(_getPrototypeOf(BufferTimeSubscriber.prototype), "_complete", this).call(this);
        }
      }, {
        key: "_unsubscribe",
        value: function _unsubscribe() {
          this.contexts = null;
        }
      }, {
        key: "onBufferFull",
        value: function onBufferFull(context) {
          this.closeContext(context);
          var closeAction = context.closeAction;
          closeAction.unsubscribe();
          this.remove(closeAction);

          if (!this.closed && this.timespanOnly) {
            context = this.openContext();
            var bufferTimeSpan = this.bufferTimeSpan;
            var timeSpanOnlyState = {
              subscriber: this,
              context: context,
              bufferTimeSpan: bufferTimeSpan
            };
            this.add(context.closeAction = this.scheduler.schedule(dispatchBufferTimeSpanOnly, bufferTimeSpan, timeSpanOnlyState));
          }
        }
      }, {
        key: "openContext",
        value: function openContext() {
          var context = new Context();
          this.contexts.push(context);
          return context;
        }
      }, {
        key: "closeContext",
        value: function closeContext(context) {
          this.destination.next(context.buffer);
          var contexts = this.contexts;
          var spliceIndex = contexts ? contexts.indexOf(context) : -1;

          if (spliceIndex >= 0) {
            contexts.splice(contexts.indexOf(context), 1);
          }
        }
      }]);

      return BufferTimeSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_1__["Subscriber"]);

    function dispatchBufferTimeSpanOnly(state) {
      var subscriber = state.subscriber;
      var prevContext = state.context;

      if (prevContext) {
        subscriber.closeContext(prevContext);
      }

      if (!subscriber.closed) {
        state.context = subscriber.openContext();
        state.context.closeAction = this.schedule(state, state.bufferTimeSpan);
      }
    }

    function dispatchBufferCreation(state) {
      var bufferCreationInterval = state.bufferCreationInterval,
          bufferTimeSpan = state.bufferTimeSpan,
          subscriber = state.subscriber,
          scheduler = state.scheduler;
      var context = subscriber.openContext();
      var action = this;

      if (!subscriber.closed) {
        subscriber.add(context.closeAction = scheduler.schedule(dispatchBufferClose, bufferTimeSpan, {
          subscriber: subscriber,
          context: context
        }));
        action.schedule(state, bufferCreationInterval);
      }
    }

    function dispatchBufferClose(arg) {
      var subscriber = arg.subscriber,
          context = arg.context;
      subscriber.closeContext(context);
    } //# sourceMappingURL=bufferTime.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/bufferToggle.js":
  /*!***********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/bufferToggle.js ***!
    \***********************************************************************/

  /*! exports provided: bufferToggle */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsBufferToggleJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "bufferToggle", function () {
      return bufferToggle;
    });
    /* harmony import */


    var _Subscription__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscription */
    "./node_modules/rxjs/_esm2015/internal/Subscription.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");

    function bufferToggle(openings, closingSelector) {
      return function bufferToggleOperatorFunction(source) {
        return source.lift(new BufferToggleOperator(openings, closingSelector));
      };
    }

    var BufferToggleOperator = /*#__PURE__*/function () {
      function BufferToggleOperator(openings, closingSelector) {
        _classCallCheck(this, BufferToggleOperator);

        this.openings = openings;
        this.closingSelector = closingSelector;
      }

      _createClass2(BufferToggleOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new BufferToggleSubscriber(subscriber, this.openings, this.closingSelector));
        }
      }]);

      return BufferToggleOperator;
    }();

    var BufferToggleSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB6) {
      _inherits(BufferToggleSubscriber, _OuterSubscriber__WEB6);

      var _super132 = _createSuper(BufferToggleSubscriber);

      function BufferToggleSubscriber(destination, openings, closingSelector) {
        var _this343;

        _classCallCheck(this, BufferToggleSubscriber);

        _this343 = _super132.call(this, destination);
        _this343.openings = openings;
        _this343.closingSelector = closingSelector;
        _this343.contexts = [];

        _this343.add(Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__["subscribeToResult"])(_assertThisInitialized(_this343), openings));

        return _this343;
      }

      _createClass2(BufferToggleSubscriber, [{
        key: "_next",
        value: function _next(value) {
          var contexts = this.contexts;
          var len = contexts.length;

          for (var i = 0; i < len; i++) {
            contexts[i].buffer.push(value);
          }
        }
      }, {
        key: "_error",
        value: function _error(err) {
          var contexts = this.contexts;

          while (contexts.length > 0) {
            var context = contexts.shift();
            context.subscription.unsubscribe();
            context.buffer = null;
            context.subscription = null;
          }

          this.contexts = null;

          _get(_getPrototypeOf(BufferToggleSubscriber.prototype), "_error", this).call(this, err);
        }
      }, {
        key: "_complete",
        value: function _complete() {
          var contexts = this.contexts;

          while (contexts.length > 0) {
            var context = contexts.shift();
            this.destination.next(context.buffer);
            context.subscription.unsubscribe();
            context.buffer = null;
            context.subscription = null;
          }

          this.contexts = null;

          _get(_getPrototypeOf(BufferToggleSubscriber.prototype), "_complete", this).call(this);
        }
      }, {
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          outerValue ? this.closeBuffer(outerValue) : this.openBuffer(innerValue);
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete(innerSub) {
          this.closeBuffer(innerSub.context);
        }
      }, {
        key: "openBuffer",
        value: function openBuffer(value) {
          try {
            var closingSelector = this.closingSelector;
            var closingNotifier = closingSelector.call(this, value);

            if (closingNotifier) {
              this.trySubscribe(closingNotifier);
            }
          } catch (err) {
            this._error(err);
          }
        }
      }, {
        key: "closeBuffer",
        value: function closeBuffer(context) {
          var contexts = this.contexts;

          if (contexts && context) {
            var buffer = context.buffer,
                subscription = context.subscription;
            this.destination.next(buffer);
            contexts.splice(contexts.indexOf(context), 1);
            this.remove(subscription);
            subscription.unsubscribe();
          }
        }
      }, {
        key: "trySubscribe",
        value: function trySubscribe(closingNotifier) {
          var contexts = this.contexts;
          var buffer = [];
          var subscription = new _Subscription__WEBPACK_IMPORTED_MODULE_0__["Subscription"]();
          var context = {
            buffer: buffer,
            subscription: subscription
          };
          contexts.push(context);
          var innerSubscription = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__["subscribeToResult"])(this, closingNotifier, context);

          if (!innerSubscription || innerSubscription.closed) {
            this.closeBuffer(context);
          } else {
            innerSubscription.context = context;
            this.add(innerSubscription);
            subscription.add(innerSubscription);
          }
        }
      }]);

      return BufferToggleSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__["OuterSubscriber"]); //# sourceMappingURL=bufferToggle.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/bufferWhen.js":
  /*!*********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/bufferWhen.js ***!
    \*********************************************************************/

  /*! exports provided: bufferWhen */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsBufferWhenJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "bufferWhen", function () {
      return bufferWhen;
    });
    /* harmony import */


    var _Subscription__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscription */
    "./node_modules/rxjs/_esm2015/internal/Subscription.js");
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function bufferWhen(closingSelector) {
      return function (source) {
        return source.lift(new BufferWhenOperator(closingSelector));
      };
    }

    var BufferWhenOperator = /*#__PURE__*/function () {
      function BufferWhenOperator(closingSelector) {
        _classCallCheck(this, BufferWhenOperator);

        this.closingSelector = closingSelector;
      }

      _createClass2(BufferWhenOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new BufferWhenSubscriber(subscriber, this.closingSelector));
        }
      }]);

      return BufferWhenOperator;
    }();

    var BufferWhenSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB7) {
      _inherits(BufferWhenSubscriber, _OuterSubscriber__WEB7);

      var _super133 = _createSuper(BufferWhenSubscriber);

      function BufferWhenSubscriber(destination, closingSelector) {
        var _this344;

        _classCallCheck(this, BufferWhenSubscriber);

        _this344 = _super133.call(this, destination);
        _this344.closingSelector = closingSelector;
        _this344.subscribing = false;

        _this344.openBuffer();

        return _this344;
      }

      _createClass2(BufferWhenSubscriber, [{
        key: "_next",
        value: function _next(value) {
          this.buffer.push(value);
        }
      }, {
        key: "_complete",
        value: function _complete() {
          var buffer = this.buffer;

          if (buffer) {
            this.destination.next(buffer);
          }

          _get(_getPrototypeOf(BufferWhenSubscriber.prototype), "_complete", this).call(this);
        }
      }, {
        key: "_unsubscribe",
        value: function _unsubscribe() {
          this.buffer = null;
          this.subscribing = false;
        }
      }, {
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          this.openBuffer();
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete() {
          if (this.subscribing) {
            this.complete();
          } else {
            this.openBuffer();
          }
        }
      }, {
        key: "openBuffer",
        value: function openBuffer() {
          var closingSubscription = this.closingSubscription;

          if (closingSubscription) {
            this.remove(closingSubscription);
            closingSubscription.unsubscribe();
          }

          var buffer = this.buffer;

          if (this.buffer) {
            this.destination.next(buffer);
          }

          this.buffer = [];
          var closingNotifier;

          try {
            var closingSelector = this.closingSelector;
            closingNotifier = closingSelector();
          } catch (err) {
            return this.error(err);
          }

          closingSubscription = new _Subscription__WEBPACK_IMPORTED_MODULE_0__["Subscription"]();
          this.closingSubscription = closingSubscription;
          this.add(closingSubscription);
          this.subscribing = true;
          closingSubscription.add(Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_2__["subscribeToResult"])(this, closingNotifier));
          this.subscribing = false;
        }
      }]);

      return BufferWhenSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_1__["OuterSubscriber"]); //# sourceMappingURL=bufferWhen.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/catchError.js":
  /*!*********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/catchError.js ***!
    \*********************************************************************/

  /*! exports provided: catchError */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsCatchErrorJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "catchError", function () {
      return catchError;
    });
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _InnerSubscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../InnerSubscriber */
    "./node_modules/rxjs/_esm2015/internal/InnerSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function catchError(selector) {
      return function catchErrorOperatorFunction(source) {
        var operator = new CatchOperator(selector);
        var caught = source.lift(operator);
        return operator.caught = caught;
      };
    }

    var CatchOperator = /*#__PURE__*/function () {
      function CatchOperator(selector) {
        _classCallCheck(this, CatchOperator);

        this.selector = selector;
      }

      _createClass2(CatchOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new CatchSubscriber(subscriber, this.selector, this.caught));
        }
      }]);

      return CatchOperator;
    }();

    var CatchSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB8) {
      _inherits(CatchSubscriber, _OuterSubscriber__WEB8);

      var _super134 = _createSuper(CatchSubscriber);

      function CatchSubscriber(destination, selector, caught) {
        var _this345;

        _classCallCheck(this, CatchSubscriber);

        _this345 = _super134.call(this, destination);
        _this345.selector = selector;
        _this345.caught = caught;
        return _this345;
      }

      _createClass2(CatchSubscriber, [{
        key: "error",
        value: function error(err) {
          if (!this.isStopped) {
            var result;

            try {
              result = this.selector(err, this.caught);
            } catch (err2) {
              _get(_getPrototypeOf(CatchSubscriber.prototype), "error", this).call(this, err2);

              return;
            }

            this._unsubscribeAndRecycle();

            var innerSubscriber = new _InnerSubscriber__WEBPACK_IMPORTED_MODULE_1__["InnerSubscriber"](this, undefined, undefined);
            this.add(innerSubscriber);
            var innerSubscription = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_2__["subscribeToResult"])(this, result, undefined, undefined, innerSubscriber);

            if (innerSubscription !== innerSubscriber) {
              this.add(innerSubscription);
            }
          }
        }
      }]);

      return CatchSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__["OuterSubscriber"]); //# sourceMappingURL=catchError.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/combineAll.js":
  /*!*********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/combineAll.js ***!
    \*********************************************************************/

  /*! exports provided: combineAll */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsCombineAllJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "combineAll", function () {
      return combineAll;
    });
    /* harmony import */


    var _observable_combineLatest__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../observable/combineLatest */
    "./node_modules/rxjs/_esm2015/internal/observable/combineLatest.js");

    function combineAll(project) {
      return function (source) {
        return source.lift(new _observable_combineLatest__WEBPACK_IMPORTED_MODULE_0__["CombineLatestOperator"](project));
      };
    } //# sourceMappingURL=combineAll.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/combineLatest.js":
  /*!************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/combineLatest.js ***!
    \************************************************************************/

  /*! exports provided: combineLatest */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsCombineLatestJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "combineLatest", function () {
      return combineLatest;
    });
    /* harmony import */


    var _util_isArray__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../util/isArray */
    "./node_modules/rxjs/_esm2015/internal/util/isArray.js");
    /* harmony import */


    var _observable_combineLatest__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../observable/combineLatest */
    "./node_modules/rxjs/_esm2015/internal/observable/combineLatest.js");
    /* harmony import */


    var _observable_from__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../observable/from */
    "./node_modules/rxjs/_esm2015/internal/observable/from.js");

    var none = {};

    function combineLatest() {
      for (var _len48 = arguments.length, observables = new Array(_len48), _key46 = 0; _key46 < _len48; _key46++) {
        observables[_key46] = arguments[_key46];
      }

      var project = null;

      if (typeof observables[observables.length - 1] === 'function') {
        project = observables.pop();
      }

      if (observables.length === 1 && Object(_util_isArray__WEBPACK_IMPORTED_MODULE_0__["isArray"])(observables[0])) {
        observables = observables[0].slice();
      }

      return function (source) {
        return source.lift.call(Object(_observable_from__WEBPACK_IMPORTED_MODULE_2__["from"])([source].concat(_toConsumableArray(observables))), new _observable_combineLatest__WEBPACK_IMPORTED_MODULE_1__["CombineLatestOperator"](project));
      };
    } //# sourceMappingURL=combineLatest.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/concat.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/concat.js ***!
    \*****************************************************************/

  /*! exports provided: concat */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsConcatJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "concat", function () {
      return concat;
    });
    /* harmony import */


    var _observable_concat__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../observable/concat */
    "./node_modules/rxjs/_esm2015/internal/observable/concat.js");

    function concat() {
      for (var _len49 = arguments.length, observables = new Array(_len49), _key47 = 0; _key47 < _len49; _key47++) {
        observables[_key47] = arguments[_key47];
      }

      return function (source) {
        return source.lift.call(Object(_observable_concat__WEBPACK_IMPORTED_MODULE_0__["concat"]).apply(void 0, [source].concat(observables)));
      };
    } //# sourceMappingURL=concat.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/concatAll.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/concatAll.js ***!
    \********************************************************************/

  /*! exports provided: concatAll */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsConcatAllJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "concatAll", function () {
      return concatAll;
    });
    /* harmony import */


    var _mergeAll__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./mergeAll */
    "./node_modules/rxjs/_esm2015/internal/operators/mergeAll.js");

    function concatAll() {
      return Object(_mergeAll__WEBPACK_IMPORTED_MODULE_0__["mergeAll"])(1);
    } //# sourceMappingURL=concatAll.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/concatMap.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/concatMap.js ***!
    \********************************************************************/

  /*! exports provided: concatMap */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsConcatMapJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "concatMap", function () {
      return concatMap;
    });
    /* harmony import */


    var _mergeMap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./mergeMap */
    "./node_modules/rxjs/_esm2015/internal/operators/mergeMap.js");

    function concatMap(project, resultSelector) {
      return Object(_mergeMap__WEBPACK_IMPORTED_MODULE_0__["mergeMap"])(project, resultSelector, 1);
    } //# sourceMappingURL=concatMap.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/concatMapTo.js":
  /*!**********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/concatMapTo.js ***!
    \**********************************************************************/

  /*! exports provided: concatMapTo */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsConcatMapToJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "concatMapTo", function () {
      return concatMapTo;
    });
    /* harmony import */


    var _concatMap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./concatMap */
    "./node_modules/rxjs/_esm2015/internal/operators/concatMap.js");

    function concatMapTo(innerObservable, resultSelector) {
      return Object(_concatMap__WEBPACK_IMPORTED_MODULE_0__["concatMap"])(function () {
        return innerObservable;
      }, resultSelector);
    } //# sourceMappingURL=concatMapTo.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/count.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/count.js ***!
    \****************************************************************/

  /*! exports provided: count */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsCountJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "count", function () {
      return count;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function count(predicate) {
      return function (source) {
        return source.lift(new CountOperator(predicate, source));
      };
    }

    var CountOperator = /*#__PURE__*/function () {
      function CountOperator(predicate, source) {
        _classCallCheck(this, CountOperator);

        this.predicate = predicate;
        this.source = source;
      }

      _createClass2(CountOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new CountSubscriber(subscriber, this.predicate, this.source));
        }
      }]);

      return CountOperator;
    }();

    var CountSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_9) {
      _inherits(CountSubscriber, _Subscriber__WEBPACK_9);

      var _super135 = _createSuper(CountSubscriber);

      function CountSubscriber(destination, predicate, source) {
        var _this346;

        _classCallCheck(this, CountSubscriber);

        _this346 = _super135.call(this, destination);
        _this346.predicate = predicate;
        _this346.source = source;
        _this346.count = 0;
        _this346.index = 0;
        return _this346;
      }

      _createClass2(CountSubscriber, [{
        key: "_next",
        value: function _next(value) {
          if (this.predicate) {
            this._tryPredicate(value);
          } else {
            this.count++;
          }
        }
      }, {
        key: "_tryPredicate",
        value: function _tryPredicate(value) {
          var result;

          try {
            result = this.predicate(value, this.index++, this.source);
          } catch (err) {
            this.destination.error(err);
            return;
          }

          if (result) {
            this.count++;
          }
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.destination.next(this.count);
          this.destination.complete();
        }
      }]);

      return CountSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=count.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/debounce.js":
  /*!*******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/debounce.js ***!
    \*******************************************************************/

  /*! exports provided: debounce */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsDebounceJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "debounce", function () {
      return debounce;
    });
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function debounce(durationSelector) {
      return function (source) {
        return source.lift(new DebounceOperator(durationSelector));
      };
    }

    var DebounceOperator = /*#__PURE__*/function () {
      function DebounceOperator(durationSelector) {
        _classCallCheck(this, DebounceOperator);

        this.durationSelector = durationSelector;
      }

      _createClass2(DebounceOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new DebounceSubscriber(subscriber, this.durationSelector));
        }
      }]);

      return DebounceOperator;
    }();

    var DebounceSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB9) {
      _inherits(DebounceSubscriber, _OuterSubscriber__WEB9);

      var _super136 = _createSuper(DebounceSubscriber);

      function DebounceSubscriber(destination, durationSelector) {
        var _this347;

        _classCallCheck(this, DebounceSubscriber);

        _this347 = _super136.call(this, destination);
        _this347.durationSelector = durationSelector;
        _this347.hasValue = false;
        _this347.durationSubscription = null;
        return _this347;
      }

      _createClass2(DebounceSubscriber, [{
        key: "_next",
        value: function _next(value) {
          try {
            var result = this.durationSelector.call(this, value);

            if (result) {
              this._tryNext(value, result);
            }
          } catch (err) {
            this.destination.error(err);
          }
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.emitValue();
          this.destination.complete();
        }
      }, {
        key: "_tryNext",
        value: function _tryNext(value, duration) {
          var subscription = this.durationSubscription;
          this.value = value;
          this.hasValue = true;

          if (subscription) {
            subscription.unsubscribe();
            this.remove(subscription);
          }

          subscription = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__["subscribeToResult"])(this, duration);

          if (subscription && !subscription.closed) {
            this.add(this.durationSubscription = subscription);
          }
        }
      }, {
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          this.emitValue();
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete() {
          this.emitValue();
        }
      }, {
        key: "emitValue",
        value: function emitValue() {
          if (this.hasValue) {
            var value = this.value;
            var subscription = this.durationSubscription;

            if (subscription) {
              this.durationSubscription = null;
              subscription.unsubscribe();
              this.remove(subscription);
            }

            this.value = null;
            this.hasValue = false;

            _get(_getPrototypeOf(DebounceSubscriber.prototype), "_next", this).call(this, value);
          }
        }
      }]);

      return DebounceSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__["OuterSubscriber"]); //# sourceMappingURL=debounce.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/debounceTime.js":
  /*!***********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/debounceTime.js ***!
    \***********************************************************************/

  /*! exports provided: debounceTime */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsDebounceTimeJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "debounceTime", function () {
      return debounceTime;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _scheduler_async__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../scheduler/async */
    "./node_modules/rxjs/_esm2015/internal/scheduler/async.js");

    function debounceTime(dueTime) {
      var scheduler = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : _scheduler_async__WEBPACK_IMPORTED_MODULE_1__["async"];
      return function (source) {
        return source.lift(new DebounceTimeOperator(dueTime, scheduler));
      };
    }

    var DebounceTimeOperator = /*#__PURE__*/function () {
      function DebounceTimeOperator(dueTime, scheduler) {
        _classCallCheck(this, DebounceTimeOperator);

        this.dueTime = dueTime;
        this.scheduler = scheduler;
      }

      _createClass2(DebounceTimeOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new DebounceTimeSubscriber(subscriber, this.dueTime, this.scheduler));
        }
      }]);

      return DebounceTimeOperator;
    }();

    var DebounceTimeSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_10) {
      _inherits(DebounceTimeSubscriber, _Subscriber__WEBPACK_10);

      var _super137 = _createSuper(DebounceTimeSubscriber);

      function DebounceTimeSubscriber(destination, dueTime, scheduler) {
        var _this348;

        _classCallCheck(this, DebounceTimeSubscriber);

        _this348 = _super137.call(this, destination);
        _this348.dueTime = dueTime;
        _this348.scheduler = scheduler;
        _this348.debouncedSubscription = null;
        _this348.lastValue = null;
        _this348.hasValue = false;
        return _this348;
      }

      _createClass2(DebounceTimeSubscriber, [{
        key: "_next",
        value: function _next(value) {
          this.clearDebounce();
          this.lastValue = value;
          this.hasValue = true;
          this.add(this.debouncedSubscription = this.scheduler.schedule(dispatchNext, this.dueTime, this));
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.debouncedNext();
          this.destination.complete();
        }
      }, {
        key: "debouncedNext",
        value: function debouncedNext() {
          this.clearDebounce();

          if (this.hasValue) {
            var lastValue = this.lastValue;
            this.lastValue = null;
            this.hasValue = false;
            this.destination.next(lastValue);
          }
        }
      }, {
        key: "clearDebounce",
        value: function clearDebounce() {
          var debouncedSubscription = this.debouncedSubscription;

          if (debouncedSubscription !== null) {
            this.remove(debouncedSubscription);
            debouncedSubscription.unsubscribe();
            this.debouncedSubscription = null;
          }
        }
      }]);

      return DebounceTimeSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]);

    function dispatchNext(subscriber) {
      subscriber.debouncedNext();
    } //# sourceMappingURL=debounceTime.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/defaultIfEmpty.js":
  /*!*************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/defaultIfEmpty.js ***!
    \*************************************************************************/

  /*! exports provided: defaultIfEmpty */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsDefaultIfEmptyJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "defaultIfEmpty", function () {
      return defaultIfEmpty;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function defaultIfEmpty() {
      var defaultValue = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
      return function (source) {
        return source.lift(new DefaultIfEmptyOperator(defaultValue));
      };
    }

    var DefaultIfEmptyOperator = /*#__PURE__*/function () {
      function DefaultIfEmptyOperator(defaultValue) {
        _classCallCheck(this, DefaultIfEmptyOperator);

        this.defaultValue = defaultValue;
      }

      _createClass2(DefaultIfEmptyOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new DefaultIfEmptySubscriber(subscriber, this.defaultValue));
        }
      }]);

      return DefaultIfEmptyOperator;
    }();

    var DefaultIfEmptySubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_11) {
      _inherits(DefaultIfEmptySubscriber, _Subscriber__WEBPACK_11);

      var _super138 = _createSuper(DefaultIfEmptySubscriber);

      function DefaultIfEmptySubscriber(destination, defaultValue) {
        var _this349;

        _classCallCheck(this, DefaultIfEmptySubscriber);

        _this349 = _super138.call(this, destination);
        _this349.defaultValue = defaultValue;
        _this349.isEmpty = true;
        return _this349;
      }

      _createClass2(DefaultIfEmptySubscriber, [{
        key: "_next",
        value: function _next(value) {
          this.isEmpty = false;
          this.destination.next(value);
        }
      }, {
        key: "_complete",
        value: function _complete() {
          if (this.isEmpty) {
            this.destination.next(this.defaultValue);
          }

          this.destination.complete();
        }
      }]);

      return DefaultIfEmptySubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=defaultIfEmpty.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/delay.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/delay.js ***!
    \****************************************************************/

  /*! exports provided: delay */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsDelayJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "delay", function () {
      return delay;
    });
    /* harmony import */


    var _scheduler_async__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../scheduler/async */
    "./node_modules/rxjs/_esm2015/internal/scheduler/async.js");
    /* harmony import */


    var _util_isDate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/isDate */
    "./node_modules/rxjs/_esm2015/internal/util/isDate.js");
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _Notification__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../Notification */
    "./node_modules/rxjs/_esm2015/internal/Notification.js");

    function delay(delay) {
      var scheduler = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : _scheduler_async__WEBPACK_IMPORTED_MODULE_0__["async"];
      var absoluteDelay = Object(_util_isDate__WEBPACK_IMPORTED_MODULE_1__["isDate"])(delay);
      var delayFor = absoluteDelay ? +delay - scheduler.now() : Math.abs(delay);
      return function (source) {
        return source.lift(new DelayOperator(delayFor, scheduler));
      };
    }

    var DelayOperator = /*#__PURE__*/function () {
      function DelayOperator(delay, scheduler) {
        _classCallCheck(this, DelayOperator);

        this.delay = delay;
        this.scheduler = scheduler;
      }

      _createClass2(DelayOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new DelaySubscriber(subscriber, this.delay, this.scheduler));
        }
      }]);

      return DelayOperator;
    }();

    var DelaySubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_12) {
      _inherits(DelaySubscriber, _Subscriber__WEBPACK_12);

      var _super139 = _createSuper(DelaySubscriber);

      function DelaySubscriber(destination, delay, scheduler) {
        var _this350;

        _classCallCheck(this, DelaySubscriber);

        _this350 = _super139.call(this, destination);
        _this350.delay = delay;
        _this350.scheduler = scheduler;
        _this350.queue = [];
        _this350.active = false;
        _this350.errored = false;
        return _this350;
      }

      _createClass2(DelaySubscriber, [{
        key: "_schedule",
        value: function _schedule(scheduler) {
          this.active = true;
          var destination = this.destination;
          destination.add(scheduler.schedule(DelaySubscriber.dispatch, this.delay, {
            source: this,
            destination: this.destination,
            scheduler: scheduler
          }));
        }
      }, {
        key: "scheduleNotification",
        value: function scheduleNotification(notification) {
          if (this.errored === true) {
            return;
          }

          var scheduler = this.scheduler;
          var message = new DelayMessage(scheduler.now() + this.delay, notification);
          this.queue.push(message);

          if (this.active === false) {
            this._schedule(scheduler);
          }
        }
      }, {
        key: "_next",
        value: function _next(value) {
          this.scheduleNotification(_Notification__WEBPACK_IMPORTED_MODULE_3__["Notification"].createNext(value));
        }
      }, {
        key: "_error",
        value: function _error(err) {
          this.errored = true;
          this.queue = [];
          this.destination.error(err);
          this.unsubscribe();
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.scheduleNotification(_Notification__WEBPACK_IMPORTED_MODULE_3__["Notification"].createComplete());
          this.unsubscribe();
        }
      }], [{
        key: "dispatch",
        value: function dispatch(state) {
          var source = state.source;
          var queue = source.queue;
          var scheduler = state.scheduler;
          var destination = state.destination;

          while (queue.length > 0 && queue[0].time - scheduler.now() <= 0) {
            queue.shift().notification.observe(destination);
          }

          if (queue.length > 0) {
            var _delay2 = Math.max(0, queue[0].time - scheduler.now());

            this.schedule(state, _delay2);
          } else {
            this.unsubscribe();
            source.active = false;
          }
        }
      }]);

      return DelaySubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_2__["Subscriber"]);

    var DelayMessage = function DelayMessage(time, notification) {
      _classCallCheck(this, DelayMessage);

      this.time = time;
      this.notification = notification;
    }; //# sourceMappingURL=delay.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/delayWhen.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/delayWhen.js ***!
    \********************************************************************/

  /*! exports provided: delayWhen */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsDelayWhenJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "delayWhen", function () {
      return delayWhen;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function delayWhen(delayDurationSelector, subscriptionDelay) {
      if (subscriptionDelay) {
        return function (source) {
          return new SubscriptionDelayObservable(source, subscriptionDelay).lift(new DelayWhenOperator(delayDurationSelector));
        };
      }

      return function (source) {
        return source.lift(new DelayWhenOperator(delayDurationSelector));
      };
    }

    var DelayWhenOperator = /*#__PURE__*/function () {
      function DelayWhenOperator(delayDurationSelector) {
        _classCallCheck(this, DelayWhenOperator);

        this.delayDurationSelector = delayDurationSelector;
      }

      _createClass2(DelayWhenOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new DelayWhenSubscriber(subscriber, this.delayDurationSelector));
        }
      }]);

      return DelayWhenOperator;
    }();

    var DelayWhenSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB10) {
      _inherits(DelayWhenSubscriber, _OuterSubscriber__WEB10);

      var _super140 = _createSuper(DelayWhenSubscriber);

      function DelayWhenSubscriber(destination, delayDurationSelector) {
        var _this351;

        _classCallCheck(this, DelayWhenSubscriber);

        _this351 = _super140.call(this, destination);
        _this351.delayDurationSelector = delayDurationSelector;
        _this351.completed = false;
        _this351.delayNotifierSubscriptions = [];
        _this351.index = 0;
        return _this351;
      }

      _createClass2(DelayWhenSubscriber, [{
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          this.destination.next(outerValue);
          this.removeSubscription(innerSub);
          this.tryComplete();
        }
      }, {
        key: "notifyError",
        value: function notifyError(error, innerSub) {
          this._error(error);
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete(innerSub) {
          var value = this.removeSubscription(innerSub);

          if (value) {
            this.destination.next(value);
          }

          this.tryComplete();
        }
      }, {
        key: "_next",
        value: function _next(value) {
          var index = this.index++;

          try {
            var delayNotifier = this.delayDurationSelector(value, index);

            if (delayNotifier) {
              this.tryDelay(delayNotifier, value);
            }
          } catch (err) {
            this.destination.error(err);
          }
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.completed = true;
          this.tryComplete();
          this.unsubscribe();
        }
      }, {
        key: "removeSubscription",
        value: function removeSubscription(subscription) {
          subscription.unsubscribe();
          var subscriptionIdx = this.delayNotifierSubscriptions.indexOf(subscription);

          if (subscriptionIdx !== -1) {
            this.delayNotifierSubscriptions.splice(subscriptionIdx, 1);
          }

          return subscription.outerValue;
        }
      }, {
        key: "tryDelay",
        value: function tryDelay(delayNotifier, value) {
          var notifierSubscription = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_3__["subscribeToResult"])(this, delayNotifier, value);

          if (notifierSubscription && !notifierSubscription.closed) {
            var destination = this.destination;
            destination.add(notifierSubscription);
            this.delayNotifierSubscriptions.push(notifierSubscription);
          }
        }
      }, {
        key: "tryComplete",
        value: function tryComplete() {
          if (this.completed && this.delayNotifierSubscriptions.length === 0) {
            this.destination.complete();
          }
        }
      }]);

      return DelayWhenSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__["OuterSubscriber"]);

    var SubscriptionDelayObservable = /*#__PURE__*/function (_Observable__WEBPACK_4) {
      _inherits(SubscriptionDelayObservable, _Observable__WEBPACK_4);

      var _super141 = _createSuper(SubscriptionDelayObservable);

      function SubscriptionDelayObservable(source, subscriptionDelay) {
        var _this352;

        _classCallCheck(this, SubscriptionDelayObservable);

        _this352 = _super141.call(this);
        _this352.source = source;
        _this352.subscriptionDelay = subscriptionDelay;
        return _this352;
      }

      _createClass2(SubscriptionDelayObservable, [{
        key: "_subscribe",
        value: function _subscribe(subscriber) {
          this.subscriptionDelay.subscribe(new SubscriptionDelaySubscriber(subscriber, this.source));
        }
      }]);

      return SubscriptionDelayObservable;
    }(_Observable__WEBPACK_IMPORTED_MODULE_1__["Observable"]);

    var SubscriptionDelaySubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_13) {
      _inherits(SubscriptionDelaySubscriber, _Subscriber__WEBPACK_13);

      var _super142 = _createSuper(SubscriptionDelaySubscriber);

      function SubscriptionDelaySubscriber(parent, source) {
        var _this353;

        _classCallCheck(this, SubscriptionDelaySubscriber);

        _this353 = _super142.call(this);
        _this353.parent = parent;
        _this353.source = source;
        _this353.sourceSubscribed = false;
        return _this353;
      }

      _createClass2(SubscriptionDelaySubscriber, [{
        key: "_next",
        value: function _next(unused) {
          this.subscribeToSource();
        }
      }, {
        key: "_error",
        value: function _error(err) {
          this.unsubscribe();
          this.parent.error(err);
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.unsubscribe();
          this.subscribeToSource();
        }
      }, {
        key: "subscribeToSource",
        value: function subscribeToSource() {
          if (!this.sourceSubscribed) {
            this.sourceSubscribed = true;
            this.unsubscribe();
            this.source.subscribe(this.parent);
          }
        }
      }]);

      return SubscriptionDelaySubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=delayWhen.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/dematerialize.js":
  /*!************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/dematerialize.js ***!
    \************************************************************************/

  /*! exports provided: dematerialize */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsDematerializeJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "dematerialize", function () {
      return dematerialize;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function dematerialize() {
      return function dematerializeOperatorFunction(source) {
        return source.lift(new DeMaterializeOperator());
      };
    }

    var DeMaterializeOperator = /*#__PURE__*/function () {
      function DeMaterializeOperator() {
        _classCallCheck(this, DeMaterializeOperator);
      }

      _createClass2(DeMaterializeOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new DeMaterializeSubscriber(subscriber));
        }
      }]);

      return DeMaterializeOperator;
    }();

    var DeMaterializeSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_14) {
      _inherits(DeMaterializeSubscriber, _Subscriber__WEBPACK_14);

      var _super143 = _createSuper(DeMaterializeSubscriber);

      function DeMaterializeSubscriber(destination) {
        _classCallCheck(this, DeMaterializeSubscriber);

        return _super143.call(this, destination);
      }

      _createClass2(DeMaterializeSubscriber, [{
        key: "_next",
        value: function _next(value) {
          value.observe(this.destination);
        }
      }]);

      return DeMaterializeSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=dematerialize.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/distinct.js":
  /*!*******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/distinct.js ***!
    \*******************************************************************/

  /*! exports provided: distinct, DistinctSubscriber */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsDistinctJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "distinct", function () {
      return distinct;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "DistinctSubscriber", function () {
      return DistinctSubscriber;
    });
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function distinct(keySelector, flushes) {
      return function (source) {
        return source.lift(new DistinctOperator(keySelector, flushes));
      };
    }

    var DistinctOperator = /*#__PURE__*/function () {
      function DistinctOperator(keySelector, flushes) {
        _classCallCheck(this, DistinctOperator);

        this.keySelector = keySelector;
        this.flushes = flushes;
      }

      _createClass2(DistinctOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new DistinctSubscriber(subscriber, this.keySelector, this.flushes));
        }
      }]);

      return DistinctOperator;
    }();

    var DistinctSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB11) {
      _inherits(DistinctSubscriber, _OuterSubscriber__WEB11);

      var _super144 = _createSuper(DistinctSubscriber);

      function DistinctSubscriber(destination, keySelector, flushes) {
        var _this354;

        _classCallCheck(this, DistinctSubscriber);

        _this354 = _super144.call(this, destination);
        _this354.keySelector = keySelector;
        _this354.values = new Set();

        if (flushes) {
          _this354.add(Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__["subscribeToResult"])(_assertThisInitialized(_this354), flushes));
        }

        return _this354;
      }

      _createClass2(DistinctSubscriber, [{
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          this.values.clear();
        }
      }, {
        key: "notifyError",
        value: function notifyError(error, innerSub) {
          this._error(error);
        }
      }, {
        key: "_next",
        value: function _next(value) {
          if (this.keySelector) {
            this._useKeySelector(value);
          } else {
            this._finalizeNext(value, value);
          }
        }
      }, {
        key: "_useKeySelector",
        value: function _useKeySelector(value) {
          var key;
          var destination = this.destination;

          try {
            key = this.keySelector(value);
          } catch (err) {
            destination.error(err);
            return;
          }

          this._finalizeNext(key, value);
        }
      }, {
        key: "_finalizeNext",
        value: function _finalizeNext(key, value) {
          var values = this.values;

          if (!values.has(key)) {
            values.add(key);
            this.destination.next(value);
          }
        }
      }]);

      return DistinctSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__["OuterSubscriber"]); //# sourceMappingURL=distinct.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/distinctUntilChanged.js":
  /*!*******************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/distinctUntilChanged.js ***!
    \*******************************************************************************/

  /*! exports provided: distinctUntilChanged */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsDistinctUntilChangedJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "distinctUntilChanged", function () {
      return distinctUntilChanged;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function distinctUntilChanged(compare, keySelector) {
      return function (source) {
        return source.lift(new DistinctUntilChangedOperator(compare, keySelector));
      };
    }

    var DistinctUntilChangedOperator = /*#__PURE__*/function () {
      function DistinctUntilChangedOperator(compare, keySelector) {
        _classCallCheck(this, DistinctUntilChangedOperator);

        this.compare = compare;
        this.keySelector = keySelector;
      }

      _createClass2(DistinctUntilChangedOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new DistinctUntilChangedSubscriber(subscriber, this.compare, this.keySelector));
        }
      }]);

      return DistinctUntilChangedOperator;
    }();

    var DistinctUntilChangedSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_15) {
      _inherits(DistinctUntilChangedSubscriber, _Subscriber__WEBPACK_15);

      var _super145 = _createSuper(DistinctUntilChangedSubscriber);

      function DistinctUntilChangedSubscriber(destination, compare, keySelector) {
        var _this355;

        _classCallCheck(this, DistinctUntilChangedSubscriber);

        _this355 = _super145.call(this, destination);
        _this355.keySelector = keySelector;
        _this355.hasKey = false;

        if (typeof compare === 'function') {
          _this355.compare = compare;
        }

        return _this355;
      }

      _createClass2(DistinctUntilChangedSubscriber, [{
        key: "compare",
        value: function compare(x, y) {
          return x === y;
        }
      }, {
        key: "_next",
        value: function _next(value) {
          var key;

          try {
            var keySelector = this.keySelector;
            key = keySelector ? keySelector(value) : value;
          } catch (err) {
            return this.destination.error(err);
          }

          var result = false;

          if (this.hasKey) {
            try {
              var compare = this.compare;
              result = compare(this.key, key);
            } catch (err) {
              return this.destination.error(err);
            }
          } else {
            this.hasKey = true;
          }

          if (!result) {
            this.key = key;
            this.destination.next(value);
          }
        }
      }]);

      return DistinctUntilChangedSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=distinctUntilChanged.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/distinctUntilKeyChanged.js":
  /*!**********************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/distinctUntilKeyChanged.js ***!
    \**********************************************************************************/

  /*! exports provided: distinctUntilKeyChanged */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsDistinctUntilKeyChangedJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "distinctUntilKeyChanged", function () {
      return distinctUntilKeyChanged;
    });
    /* harmony import */


    var _distinctUntilChanged__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./distinctUntilChanged */
    "./node_modules/rxjs/_esm2015/internal/operators/distinctUntilChanged.js");

    function distinctUntilKeyChanged(key, compare) {
      return Object(_distinctUntilChanged__WEBPACK_IMPORTED_MODULE_0__["distinctUntilChanged"])(function (x, y) {
        return compare ? compare(x[key], y[key]) : x[key] === y[key];
      });
    } //# sourceMappingURL=distinctUntilKeyChanged.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/elementAt.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/elementAt.js ***!
    \********************************************************************/

  /*! exports provided: elementAt */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsElementAtJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "elementAt", function () {
      return elementAt;
    });
    /* harmony import */


    var _util_ArgumentOutOfRangeError__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../util/ArgumentOutOfRangeError */
    "./node_modules/rxjs/_esm2015/internal/util/ArgumentOutOfRangeError.js");
    /* harmony import */


    var _filter__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./filter */
    "./node_modules/rxjs/_esm2015/internal/operators/filter.js");
    /* harmony import */


    var _throwIfEmpty__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ./throwIfEmpty */
    "./node_modules/rxjs/_esm2015/internal/operators/throwIfEmpty.js");
    /* harmony import */


    var _defaultIfEmpty__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ./defaultIfEmpty */
    "./node_modules/rxjs/_esm2015/internal/operators/defaultIfEmpty.js");
    /* harmony import */


    var _take__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ./take */
    "./node_modules/rxjs/_esm2015/internal/operators/take.js");

    function elementAt(index, defaultValue) {
      if (index < 0) {
        throw new _util_ArgumentOutOfRangeError__WEBPACK_IMPORTED_MODULE_0__["ArgumentOutOfRangeError"]();
      }

      var hasDefaultValue = arguments.length >= 2;
      return function (source) {
        return source.pipe(Object(_filter__WEBPACK_IMPORTED_MODULE_1__["filter"])(function (v, i) {
          return i === index;
        }), Object(_take__WEBPACK_IMPORTED_MODULE_4__["take"])(1), hasDefaultValue ? Object(_defaultIfEmpty__WEBPACK_IMPORTED_MODULE_3__["defaultIfEmpty"])(defaultValue) : Object(_throwIfEmpty__WEBPACK_IMPORTED_MODULE_2__["throwIfEmpty"])(function () {
          return new _util_ArgumentOutOfRangeError__WEBPACK_IMPORTED_MODULE_0__["ArgumentOutOfRangeError"]();
        }));
      };
    } //# sourceMappingURL=elementAt.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/endWith.js":
  /*!******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/endWith.js ***!
    \******************************************************************/

  /*! exports provided: endWith */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsEndWithJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "endWith", function () {
      return endWith;
    });
    /* harmony import */


    var _observable_concat__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../observable/concat */
    "./node_modules/rxjs/_esm2015/internal/observable/concat.js");
    /* harmony import */


    var _observable_of__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../observable/of */
    "./node_modules/rxjs/_esm2015/internal/observable/of.js");

    function endWith() {
      for (var _len50 = arguments.length, array = new Array(_len50), _key48 = 0; _key48 < _len50; _key48++) {
        array[_key48] = arguments[_key48];
      }

      return function (source) {
        return Object(_observable_concat__WEBPACK_IMPORTED_MODULE_0__["concat"])(source, Object(_observable_of__WEBPACK_IMPORTED_MODULE_1__["of"]).apply(void 0, array));
      };
    } //# sourceMappingURL=endWith.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/every.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/every.js ***!
    \****************************************************************/

  /*! exports provided: every */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsEveryJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "every", function () {
      return every;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function every(predicate, thisArg) {
      return function (source) {
        return source.lift(new EveryOperator(predicate, thisArg, source));
      };
    }

    var EveryOperator = /*#__PURE__*/function () {
      function EveryOperator(predicate, thisArg, source) {
        _classCallCheck(this, EveryOperator);

        this.predicate = predicate;
        this.thisArg = thisArg;
        this.source = source;
      }

      _createClass2(EveryOperator, [{
        key: "call",
        value: function call(observer, source) {
          return source.subscribe(new EverySubscriber(observer, this.predicate, this.thisArg, this.source));
        }
      }]);

      return EveryOperator;
    }();

    var EverySubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_16) {
      _inherits(EverySubscriber, _Subscriber__WEBPACK_16);

      var _super146 = _createSuper(EverySubscriber);

      function EverySubscriber(destination, predicate, thisArg, source) {
        var _this356;

        _classCallCheck(this, EverySubscriber);

        _this356 = _super146.call(this, destination);
        _this356.predicate = predicate;
        _this356.thisArg = thisArg;
        _this356.source = source;
        _this356.index = 0;
        _this356.thisArg = thisArg || _assertThisInitialized(_this356);
        return _this356;
      }

      _createClass2(EverySubscriber, [{
        key: "notifyComplete",
        value: function notifyComplete(everyValueMatch) {
          this.destination.next(everyValueMatch);
          this.destination.complete();
        }
      }, {
        key: "_next",
        value: function _next(value) {
          var result = false;

          try {
            result = this.predicate.call(this.thisArg, value, this.index++, this.source);
          } catch (err) {
            this.destination.error(err);
            return;
          }

          if (!result) {
            this.notifyComplete(false);
          }
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.notifyComplete(true);
        }
      }]);

      return EverySubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=every.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/exhaust.js":
  /*!******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/exhaust.js ***!
    \******************************************************************/

  /*! exports provided: exhaust */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsExhaustJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "exhaust", function () {
      return exhaust;
    });
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function exhaust() {
      return function (source) {
        return source.lift(new SwitchFirstOperator());
      };
    }

    var SwitchFirstOperator = /*#__PURE__*/function () {
      function SwitchFirstOperator() {
        _classCallCheck(this, SwitchFirstOperator);
      }

      _createClass2(SwitchFirstOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new SwitchFirstSubscriber(subscriber));
        }
      }]);

      return SwitchFirstOperator;
    }();

    var SwitchFirstSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB12) {
      _inherits(SwitchFirstSubscriber, _OuterSubscriber__WEB12);

      var _super147 = _createSuper(SwitchFirstSubscriber);

      function SwitchFirstSubscriber(destination) {
        var _this357;

        _classCallCheck(this, SwitchFirstSubscriber);

        _this357 = _super147.call(this, destination);
        _this357.hasCompleted = false;
        _this357.hasSubscription = false;
        return _this357;
      }

      _createClass2(SwitchFirstSubscriber, [{
        key: "_next",
        value: function _next(value) {
          if (!this.hasSubscription) {
            this.hasSubscription = true;
            this.add(Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__["subscribeToResult"])(this, value));
          }
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.hasCompleted = true;

          if (!this.hasSubscription) {
            this.destination.complete();
          }
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete(innerSub) {
          this.remove(innerSub);
          this.hasSubscription = false;

          if (this.hasCompleted) {
            this.destination.complete();
          }
        }
      }]);

      return SwitchFirstSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__["OuterSubscriber"]); //# sourceMappingURL=exhaust.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/exhaustMap.js":
  /*!*********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/exhaustMap.js ***!
    \*********************************************************************/

  /*! exports provided: exhaustMap */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsExhaustMapJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "exhaustMap", function () {
      return exhaustMap;
    });
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _InnerSubscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../InnerSubscriber */
    "./node_modules/rxjs/_esm2015/internal/InnerSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");
    /* harmony import */


    var _map__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ./map */
    "./node_modules/rxjs/_esm2015/internal/operators/map.js");
    /* harmony import */


    var _observable_from__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ../observable/from */
    "./node_modules/rxjs/_esm2015/internal/observable/from.js");

    function exhaustMap(project, resultSelector) {
      if (resultSelector) {
        return function (source) {
          return source.pipe(exhaustMap(function (a, i) {
            return Object(_observable_from__WEBPACK_IMPORTED_MODULE_4__["from"])(project(a, i)).pipe(Object(_map__WEBPACK_IMPORTED_MODULE_3__["map"])(function (b, ii) {
              return resultSelector(a, b, i, ii);
            }));
          }));
        };
      }

      return function (source) {
        return source.lift(new ExhaustMapOperator(project));
      };
    }

    var ExhaustMapOperator = /*#__PURE__*/function () {
      function ExhaustMapOperator(project) {
        _classCallCheck(this, ExhaustMapOperator);

        this.project = project;
      }

      _createClass2(ExhaustMapOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new ExhaustMapSubscriber(subscriber, this.project));
        }
      }]);

      return ExhaustMapOperator;
    }();

    var ExhaustMapSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB13) {
      _inherits(ExhaustMapSubscriber, _OuterSubscriber__WEB13);

      var _super148 = _createSuper(ExhaustMapSubscriber);

      function ExhaustMapSubscriber(destination, project) {
        var _this358;

        _classCallCheck(this, ExhaustMapSubscriber);

        _this358 = _super148.call(this, destination);
        _this358.project = project;
        _this358.hasSubscription = false;
        _this358.hasCompleted = false;
        _this358.index = 0;
        return _this358;
      }

      _createClass2(ExhaustMapSubscriber, [{
        key: "_next",
        value: function _next(value) {
          if (!this.hasSubscription) {
            this.tryNext(value);
          }
        }
      }, {
        key: "tryNext",
        value: function tryNext(value) {
          var result;
          var index = this.index++;

          try {
            result = this.project(value, index);
          } catch (err) {
            this.destination.error(err);
            return;
          }

          this.hasSubscription = true;

          this._innerSub(result, value, index);
        }
      }, {
        key: "_innerSub",
        value: function _innerSub(result, value, index) {
          var innerSubscriber = new _InnerSubscriber__WEBPACK_IMPORTED_MODULE_1__["InnerSubscriber"](this, value, index);
          var destination = this.destination;
          destination.add(innerSubscriber);
          var innerSubscription = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_2__["subscribeToResult"])(this, result, undefined, undefined, innerSubscriber);

          if (innerSubscription !== innerSubscriber) {
            destination.add(innerSubscription);
          }
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.hasCompleted = true;

          if (!this.hasSubscription) {
            this.destination.complete();
          }

          this.unsubscribe();
        }
      }, {
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          this.destination.next(innerValue);
        }
      }, {
        key: "notifyError",
        value: function notifyError(err) {
          this.destination.error(err);
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete(innerSub) {
          var destination = this.destination;
          destination.remove(innerSub);
          this.hasSubscription = false;

          if (this.hasCompleted) {
            this.destination.complete();
          }
        }
      }]);

      return ExhaustMapSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__["OuterSubscriber"]); //# sourceMappingURL=exhaustMap.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/expand.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/expand.js ***!
    \*****************************************************************/

  /*! exports provided: expand, ExpandOperator, ExpandSubscriber */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsExpandJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "expand", function () {
      return expand;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ExpandOperator", function () {
      return ExpandOperator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ExpandSubscriber", function () {
      return ExpandSubscriber;
    });
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function expand(project) {
      var concurrent = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : Number.POSITIVE_INFINITY;
      var scheduler = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : undefined;
      concurrent = (concurrent || 0) < 1 ? Number.POSITIVE_INFINITY : concurrent;
      return function (source) {
        return source.lift(new ExpandOperator(project, concurrent, scheduler));
      };
    }

    var ExpandOperator = /*#__PURE__*/function () {
      function ExpandOperator(project, concurrent, scheduler) {
        _classCallCheck(this, ExpandOperator);

        this.project = project;
        this.concurrent = concurrent;
        this.scheduler = scheduler;
      }

      _createClass2(ExpandOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new ExpandSubscriber(subscriber, this.project, this.concurrent, this.scheduler));
        }
      }]);

      return ExpandOperator;
    }();

    var ExpandSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB14) {
      _inherits(ExpandSubscriber, _OuterSubscriber__WEB14);

      var _super149 = _createSuper(ExpandSubscriber);

      function ExpandSubscriber(destination, project, concurrent, scheduler) {
        var _this359;

        _classCallCheck(this, ExpandSubscriber);

        _this359 = _super149.call(this, destination);
        _this359.project = project;
        _this359.concurrent = concurrent;
        _this359.scheduler = scheduler;
        _this359.index = 0;
        _this359.active = 0;
        _this359.hasCompleted = false;

        if (concurrent < Number.POSITIVE_INFINITY) {
          _this359.buffer = [];
        }

        return _this359;
      }

      _createClass2(ExpandSubscriber, [{
        key: "_next",
        value: function _next(value) {
          var destination = this.destination;

          if (destination.closed) {
            this._complete();

            return;
          }

          var index = this.index++;

          if (this.active < this.concurrent) {
            destination.next(value);

            try {
              var project = this.project;
              var result = project(value, index);

              if (!this.scheduler) {
                this.subscribeToProjection(result, value, index);
              } else {
                var state = {
                  subscriber: this,
                  result: result,
                  value: value,
                  index: index
                };
                var _destination = this.destination;

                _destination.add(this.scheduler.schedule(ExpandSubscriber.dispatch, 0, state));
              }
            } catch (e) {
              destination.error(e);
            }
          } else {
            this.buffer.push(value);
          }
        }
      }, {
        key: "subscribeToProjection",
        value: function subscribeToProjection(result, value, index) {
          this.active++;
          var destination = this.destination;
          destination.add(Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__["subscribeToResult"])(this, result, value, index));
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.hasCompleted = true;

          if (this.hasCompleted && this.active === 0) {
            this.destination.complete();
          }

          this.unsubscribe();
        }
      }, {
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          this._next(innerValue);
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete(innerSub) {
          var buffer = this.buffer;
          var destination = this.destination;
          destination.remove(innerSub);
          this.active--;

          if (buffer && buffer.length > 0) {
            this._next(buffer.shift());
          }

          if (this.hasCompleted && this.active === 0) {
            this.destination.complete();
          }
        }
      }], [{
        key: "dispatch",
        value: function dispatch(arg) {
          var subscriber = arg.subscriber,
              result = arg.result,
              value = arg.value,
              index = arg.index;
          subscriber.subscribeToProjection(result, value, index);
        }
      }]);

      return ExpandSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__["OuterSubscriber"]); //# sourceMappingURL=expand.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/filter.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/filter.js ***!
    \*****************************************************************/

  /*! exports provided: filter */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsFilterJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "filter", function () {
      return filter;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function filter(predicate, thisArg) {
      return function filterOperatorFunction(source) {
        return source.lift(new FilterOperator(predicate, thisArg));
      };
    }

    var FilterOperator = /*#__PURE__*/function () {
      function FilterOperator(predicate, thisArg) {
        _classCallCheck(this, FilterOperator);

        this.predicate = predicate;
        this.thisArg = thisArg;
      }

      _createClass2(FilterOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new FilterSubscriber(subscriber, this.predicate, this.thisArg));
        }
      }]);

      return FilterOperator;
    }();

    var FilterSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_17) {
      _inherits(FilterSubscriber, _Subscriber__WEBPACK_17);

      var _super150 = _createSuper(FilterSubscriber);

      function FilterSubscriber(destination, predicate, thisArg) {
        var _this360;

        _classCallCheck(this, FilterSubscriber);

        _this360 = _super150.call(this, destination);
        _this360.predicate = predicate;
        _this360.thisArg = thisArg;
        _this360.count = 0;
        return _this360;
      }

      _createClass2(FilterSubscriber, [{
        key: "_next",
        value: function _next(value) {
          var result;

          try {
            result = this.predicate.call(this.thisArg, value, this.count++);
          } catch (err) {
            this.destination.error(err);
            return;
          }

          if (result) {
            this.destination.next(value);
          }
        }
      }]);

      return FilterSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=filter.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/finalize.js":
  /*!*******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/finalize.js ***!
    \*******************************************************************/

  /*! exports provided: finalize */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsFinalizeJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "finalize", function () {
      return finalize;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _Subscription__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../Subscription */
    "./node_modules/rxjs/_esm2015/internal/Subscription.js");

    function finalize(callback) {
      return function (source) {
        return source.lift(new FinallyOperator(callback));
      };
    }

    var FinallyOperator = /*#__PURE__*/function () {
      function FinallyOperator(callback) {
        _classCallCheck(this, FinallyOperator);

        this.callback = callback;
      }

      _createClass2(FinallyOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new FinallySubscriber(subscriber, this.callback));
        }
      }]);

      return FinallyOperator;
    }();

    var FinallySubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_18) {
      _inherits(FinallySubscriber, _Subscriber__WEBPACK_18);

      var _super151 = _createSuper(FinallySubscriber);

      function FinallySubscriber(destination, callback) {
        var _this361;

        _classCallCheck(this, FinallySubscriber);

        _this361 = _super151.call(this, destination);

        _this361.add(new _Subscription__WEBPACK_IMPORTED_MODULE_1__["Subscription"](callback));

        return _this361;
      }

      return FinallySubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=finalize.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/find.js":
  /*!***************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/find.js ***!
    \***************************************************************/

  /*! exports provided: find, FindValueOperator, FindValueSubscriber */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsFindJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "find", function () {
      return find;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FindValueOperator", function () {
      return FindValueOperator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "FindValueSubscriber", function () {
      return FindValueSubscriber;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function find(predicate, thisArg) {
      if (typeof predicate !== 'function') {
        throw new TypeError('predicate is not a function');
      }

      return function (source) {
        return source.lift(new FindValueOperator(predicate, source, false, thisArg));
      };
    }

    var FindValueOperator = /*#__PURE__*/function () {
      function FindValueOperator(predicate, source, yieldIndex, thisArg) {
        _classCallCheck(this, FindValueOperator);

        this.predicate = predicate;
        this.source = source;
        this.yieldIndex = yieldIndex;
        this.thisArg = thisArg;
      }

      _createClass2(FindValueOperator, [{
        key: "call",
        value: function call(observer, source) {
          return source.subscribe(new FindValueSubscriber(observer, this.predicate, this.source, this.yieldIndex, this.thisArg));
        }
      }]);

      return FindValueOperator;
    }();

    var FindValueSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_19) {
      _inherits(FindValueSubscriber, _Subscriber__WEBPACK_19);

      var _super152 = _createSuper(FindValueSubscriber);

      function FindValueSubscriber(destination, predicate, source, yieldIndex, thisArg) {
        var _this362;

        _classCallCheck(this, FindValueSubscriber);

        _this362 = _super152.call(this, destination);
        _this362.predicate = predicate;
        _this362.source = source;
        _this362.yieldIndex = yieldIndex;
        _this362.thisArg = thisArg;
        _this362.index = 0;
        return _this362;
      }

      _createClass2(FindValueSubscriber, [{
        key: "notifyComplete",
        value: function notifyComplete(value) {
          var destination = this.destination;
          destination.next(value);
          destination.complete();
          this.unsubscribe();
        }
      }, {
        key: "_next",
        value: function _next(value) {
          var predicate = this.predicate,
              thisArg = this.thisArg;
          var index = this.index++;

          try {
            var result = predicate.call(thisArg || this, value, index, this.source);

            if (result) {
              this.notifyComplete(this.yieldIndex ? index : value);
            }
          } catch (err) {
            this.destination.error(err);
          }
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.notifyComplete(this.yieldIndex ? -1 : undefined);
        }
      }]);

      return FindValueSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=find.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/findIndex.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/findIndex.js ***!
    \********************************************************************/

  /*! exports provided: findIndex */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsFindIndexJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "findIndex", function () {
      return findIndex;
    });
    /* harmony import */


    var _operators_find__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../operators/find */
    "./node_modules/rxjs/_esm2015/internal/operators/find.js");

    function findIndex(predicate, thisArg) {
      return function (source) {
        return source.lift(new _operators_find__WEBPACK_IMPORTED_MODULE_0__["FindValueOperator"](predicate, source, true, thisArg));
      };
    } //# sourceMappingURL=findIndex.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/first.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/first.js ***!
    \****************************************************************/

  /*! exports provided: first */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsFirstJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "first", function () {
      return first;
    });
    /* harmony import */


    var _util_EmptyError__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../util/EmptyError */
    "./node_modules/rxjs/_esm2015/internal/util/EmptyError.js");
    /* harmony import */


    var _filter__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./filter */
    "./node_modules/rxjs/_esm2015/internal/operators/filter.js");
    /* harmony import */


    var _take__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ./take */
    "./node_modules/rxjs/_esm2015/internal/operators/take.js");
    /* harmony import */


    var _defaultIfEmpty__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ./defaultIfEmpty */
    "./node_modules/rxjs/_esm2015/internal/operators/defaultIfEmpty.js");
    /* harmony import */


    var _throwIfEmpty__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ./throwIfEmpty */
    "./node_modules/rxjs/_esm2015/internal/operators/throwIfEmpty.js");
    /* harmony import */


    var _util_identity__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(
    /*! ../util/identity */
    "./node_modules/rxjs/_esm2015/internal/util/identity.js");

    function first(predicate, defaultValue) {
      var hasDefaultValue = arguments.length >= 2;
      return function (source) {
        return source.pipe(predicate ? Object(_filter__WEBPACK_IMPORTED_MODULE_1__["filter"])(function (v, i) {
          return predicate(v, i, source);
        }) : _util_identity__WEBPACK_IMPORTED_MODULE_5__["identity"], Object(_take__WEBPACK_IMPORTED_MODULE_2__["take"])(1), hasDefaultValue ? Object(_defaultIfEmpty__WEBPACK_IMPORTED_MODULE_3__["defaultIfEmpty"])(defaultValue) : Object(_throwIfEmpty__WEBPACK_IMPORTED_MODULE_4__["throwIfEmpty"])(function () {
          return new _util_EmptyError__WEBPACK_IMPORTED_MODULE_0__["EmptyError"]();
        }));
      };
    } //# sourceMappingURL=first.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/groupBy.js":
  /*!******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/groupBy.js ***!
    \******************************************************************/

  /*! exports provided: groupBy, GroupedObservable */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsGroupByJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "groupBy", function () {
      return groupBy;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "GroupedObservable", function () {
      return GroupedObservable;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _Subscription__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../Subscription */
    "./node_modules/rxjs/_esm2015/internal/Subscription.js");
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _Subject__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../Subject */
    "./node_modules/rxjs/_esm2015/internal/Subject.js");

    function groupBy(keySelector, elementSelector, durationSelector, subjectSelector) {
      return function (source) {
        return source.lift(new GroupByOperator(keySelector, elementSelector, durationSelector, subjectSelector));
      };
    }

    var GroupByOperator = /*#__PURE__*/function () {
      function GroupByOperator(keySelector, elementSelector, durationSelector, subjectSelector) {
        _classCallCheck(this, GroupByOperator);

        this.keySelector = keySelector;
        this.elementSelector = elementSelector;
        this.durationSelector = durationSelector;
        this.subjectSelector = subjectSelector;
      }

      _createClass2(GroupByOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new GroupBySubscriber(subscriber, this.keySelector, this.elementSelector, this.durationSelector, this.subjectSelector));
        }
      }]);

      return GroupByOperator;
    }();

    var GroupBySubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_20) {
      _inherits(GroupBySubscriber, _Subscriber__WEBPACK_20);

      var _super153 = _createSuper(GroupBySubscriber);

      function GroupBySubscriber(destination, keySelector, elementSelector, durationSelector, subjectSelector) {
        var _this363;

        _classCallCheck(this, GroupBySubscriber);

        _this363 = _super153.call(this, destination);
        _this363.keySelector = keySelector;
        _this363.elementSelector = elementSelector;
        _this363.durationSelector = durationSelector;
        _this363.subjectSelector = subjectSelector;
        _this363.groups = null;
        _this363.attemptedToUnsubscribe = false;
        _this363.count = 0;
        return _this363;
      }

      _createClass2(GroupBySubscriber, [{
        key: "_next",
        value: function _next(value) {
          var key;

          try {
            key = this.keySelector(value);
          } catch (err) {
            this.error(err);
            return;
          }

          this._group(value, key);
        }
      }, {
        key: "_group",
        value: function _group(value, key) {
          var groups = this.groups;

          if (!groups) {
            groups = this.groups = new Map();
          }

          var group = groups.get(key);
          var element;

          if (this.elementSelector) {
            try {
              element = this.elementSelector(value);
            } catch (err) {
              this.error(err);
            }
          } else {
            element = value;
          }

          if (!group) {
            group = this.subjectSelector ? this.subjectSelector() : new _Subject__WEBPACK_IMPORTED_MODULE_3__["Subject"]();
            groups.set(key, group);
            var groupedObservable = new GroupedObservable(key, group, this);
            this.destination.next(groupedObservable);

            if (this.durationSelector) {
              var duration;

              try {
                duration = this.durationSelector(new GroupedObservable(key, group));
              } catch (err) {
                this.error(err);
                return;
              }

              this.add(duration.subscribe(new GroupDurationSubscriber(key, group, this)));
            }
          }

          if (!group.closed) {
            group.next(element);
          }
        }
      }, {
        key: "_error",
        value: function _error(err) {
          var groups = this.groups;

          if (groups) {
            groups.forEach(function (group, key) {
              group.error(err);
            });
            groups.clear();
          }

          this.destination.error(err);
        }
      }, {
        key: "_complete",
        value: function _complete() {
          var groups = this.groups;

          if (groups) {
            groups.forEach(function (group, key) {
              group.complete();
            });
            groups.clear();
          }

          this.destination.complete();
        }
      }, {
        key: "removeGroup",
        value: function removeGroup(key) {
          this.groups["delete"](key);
        }
      }, {
        key: "unsubscribe",
        value: function unsubscribe() {
          if (!this.closed) {
            this.attemptedToUnsubscribe = true;

            if (this.count === 0) {
              _get(_getPrototypeOf(GroupBySubscriber.prototype), "unsubscribe", this).call(this);
            }
          }
        }
      }]);

      return GroupBySubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]);

    var GroupDurationSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_21) {
      _inherits(GroupDurationSubscriber, _Subscriber__WEBPACK_21);

      var _super154 = _createSuper(GroupDurationSubscriber);

      function GroupDurationSubscriber(key, group, parent) {
        var _this364;

        _classCallCheck(this, GroupDurationSubscriber);

        _this364 = _super154.call(this, group);
        _this364.key = key;
        _this364.group = group;
        _this364.parent = parent;
        return _this364;
      }

      _createClass2(GroupDurationSubscriber, [{
        key: "_next",
        value: function _next(value) {
          this.complete();
        }
      }, {
        key: "_unsubscribe",
        value: function _unsubscribe() {
          var parent = this.parent,
              key = this.key;
          this.key = this.parent = null;

          if (parent) {
            parent.removeGroup(key);
          }
        }
      }]);

      return GroupDurationSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]);

    var GroupedObservable = /*#__PURE__*/function (_Observable__WEBPACK_5) {
      _inherits(GroupedObservable, _Observable__WEBPACK_5);

      var _super155 = _createSuper(GroupedObservable);

      function GroupedObservable(key, groupSubject, refCountSubscription) {
        var _this365;

        _classCallCheck(this, GroupedObservable);

        _this365 = _super155.call(this);
        _this365.key = key;
        _this365.groupSubject = groupSubject;
        _this365.refCountSubscription = refCountSubscription;
        return _this365;
      }

      _createClass2(GroupedObservable, [{
        key: "_subscribe",
        value: function _subscribe(subscriber) {
          var subscription = new _Subscription__WEBPACK_IMPORTED_MODULE_1__["Subscription"]();
          var refCountSubscription = this.refCountSubscription,
              groupSubject = this.groupSubject;

          if (refCountSubscription && !refCountSubscription.closed) {
            subscription.add(new InnerRefCountSubscription(refCountSubscription));
          }

          subscription.add(groupSubject.subscribe(subscriber));
          return subscription;
        }
      }]);

      return GroupedObservable;
    }(_Observable__WEBPACK_IMPORTED_MODULE_2__["Observable"]);

    var InnerRefCountSubscription = /*#__PURE__*/function (_Subscription__WEBPAC3) {
      _inherits(InnerRefCountSubscription, _Subscription__WEBPAC3);

      var _super156 = _createSuper(InnerRefCountSubscription);

      function InnerRefCountSubscription(parent) {
        var _this366;

        _classCallCheck(this, InnerRefCountSubscription);

        _this366 = _super156.call(this);
        _this366.parent = parent;
        parent.count++;
        return _this366;
      }

      _createClass2(InnerRefCountSubscription, [{
        key: "unsubscribe",
        value: function unsubscribe() {
          var parent = this.parent;

          if (!parent.closed && !this.closed) {
            _get(_getPrototypeOf(InnerRefCountSubscription.prototype), "unsubscribe", this).call(this);

            parent.count -= 1;

            if (parent.count === 0 && parent.attemptedToUnsubscribe) {
              parent.unsubscribe();
            }
          }
        }
      }]);

      return InnerRefCountSubscription;
    }(_Subscription__WEBPACK_IMPORTED_MODULE_1__["Subscription"]); //# sourceMappingURL=groupBy.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/ignoreElements.js":
  /*!*************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/ignoreElements.js ***!
    \*************************************************************************/

  /*! exports provided: ignoreElements */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsIgnoreElementsJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ignoreElements", function () {
      return ignoreElements;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function ignoreElements() {
      return function ignoreElementsOperatorFunction(source) {
        return source.lift(new IgnoreElementsOperator());
      };
    }

    var IgnoreElementsOperator = /*#__PURE__*/function () {
      function IgnoreElementsOperator() {
        _classCallCheck(this, IgnoreElementsOperator);
      }

      _createClass2(IgnoreElementsOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new IgnoreElementsSubscriber(subscriber));
        }
      }]);

      return IgnoreElementsOperator;
    }();

    var IgnoreElementsSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_22) {
      _inherits(IgnoreElementsSubscriber, _Subscriber__WEBPACK_22);

      var _super157 = _createSuper(IgnoreElementsSubscriber);

      function IgnoreElementsSubscriber() {
        _classCallCheck(this, IgnoreElementsSubscriber);

        return _super157.apply(this, arguments);
      }

      _createClass2(IgnoreElementsSubscriber, [{
        key: "_next",
        value: function _next(unused) {}
      }]);

      return IgnoreElementsSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=ignoreElements.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/isEmpty.js":
  /*!******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/isEmpty.js ***!
    \******************************************************************/

  /*! exports provided: isEmpty */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsIsEmptyJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "isEmpty", function () {
      return isEmpty;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function isEmpty() {
      return function (source) {
        return source.lift(new IsEmptyOperator());
      };
    }

    var IsEmptyOperator = /*#__PURE__*/function () {
      function IsEmptyOperator() {
        _classCallCheck(this, IsEmptyOperator);
      }

      _createClass2(IsEmptyOperator, [{
        key: "call",
        value: function call(observer, source) {
          return source.subscribe(new IsEmptySubscriber(observer));
        }
      }]);

      return IsEmptyOperator;
    }();

    var IsEmptySubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_23) {
      _inherits(IsEmptySubscriber, _Subscriber__WEBPACK_23);

      var _super158 = _createSuper(IsEmptySubscriber);

      function IsEmptySubscriber(destination) {
        _classCallCheck(this, IsEmptySubscriber);

        return _super158.call(this, destination);
      }

      _createClass2(IsEmptySubscriber, [{
        key: "notifyComplete",
        value: function notifyComplete(isEmpty) {
          var destination = this.destination;
          destination.next(isEmpty);
          destination.complete();
        }
      }, {
        key: "_next",
        value: function _next(value) {
          this.notifyComplete(false);
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.notifyComplete(true);
        }
      }]);

      return IsEmptySubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=isEmpty.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/last.js":
  /*!***************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/last.js ***!
    \***************************************************************/

  /*! exports provided: last */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsLastJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "last", function () {
      return last;
    });
    /* harmony import */


    var _util_EmptyError__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../util/EmptyError */
    "./node_modules/rxjs/_esm2015/internal/util/EmptyError.js");
    /* harmony import */


    var _filter__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./filter */
    "./node_modules/rxjs/_esm2015/internal/operators/filter.js");
    /* harmony import */


    var _takeLast__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ./takeLast */
    "./node_modules/rxjs/_esm2015/internal/operators/takeLast.js");
    /* harmony import */


    var _throwIfEmpty__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ./throwIfEmpty */
    "./node_modules/rxjs/_esm2015/internal/operators/throwIfEmpty.js");
    /* harmony import */


    var _defaultIfEmpty__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ./defaultIfEmpty */
    "./node_modules/rxjs/_esm2015/internal/operators/defaultIfEmpty.js");
    /* harmony import */


    var _util_identity__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(
    /*! ../util/identity */
    "./node_modules/rxjs/_esm2015/internal/util/identity.js");

    function last(predicate, defaultValue) {
      var hasDefaultValue = arguments.length >= 2;
      return function (source) {
        return source.pipe(predicate ? Object(_filter__WEBPACK_IMPORTED_MODULE_1__["filter"])(function (v, i) {
          return predicate(v, i, source);
        }) : _util_identity__WEBPACK_IMPORTED_MODULE_5__["identity"], Object(_takeLast__WEBPACK_IMPORTED_MODULE_2__["takeLast"])(1), hasDefaultValue ? Object(_defaultIfEmpty__WEBPACK_IMPORTED_MODULE_4__["defaultIfEmpty"])(defaultValue) : Object(_throwIfEmpty__WEBPACK_IMPORTED_MODULE_3__["throwIfEmpty"])(function () {
          return new _util_EmptyError__WEBPACK_IMPORTED_MODULE_0__["EmptyError"]();
        }));
      };
    } //# sourceMappingURL=last.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/map.js":
  /*!**************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/map.js ***!
    \**************************************************************/

  /*! exports provided: map, MapOperator */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsMapJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "map", function () {
      return map;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MapOperator", function () {
      return MapOperator;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function map(project, thisArg) {
      return function mapOperation(source) {
        if (typeof project !== 'function') {
          throw new TypeError('argument is not a function. Are you looking for `mapTo()`?');
        }

        return source.lift(new MapOperator(project, thisArg));
      };
    }

    var MapOperator = /*#__PURE__*/function () {
      function MapOperator(project, thisArg) {
        _classCallCheck(this, MapOperator);

        this.project = project;
        this.thisArg = thisArg;
      }

      _createClass2(MapOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new MapSubscriber(subscriber, this.project, this.thisArg));
        }
      }]);

      return MapOperator;
    }();

    var MapSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_24) {
      _inherits(MapSubscriber, _Subscriber__WEBPACK_24);

      var _super159 = _createSuper(MapSubscriber);

      function MapSubscriber(destination, project, thisArg) {
        var _this367;

        _classCallCheck(this, MapSubscriber);

        _this367 = _super159.call(this, destination);
        _this367.project = project;
        _this367.count = 0;
        _this367.thisArg = thisArg || _assertThisInitialized(_this367);
        return _this367;
      }

      _createClass2(MapSubscriber, [{
        key: "_next",
        value: function _next(value) {
          var result;

          try {
            result = this.project.call(this.thisArg, value, this.count++);
          } catch (err) {
            this.destination.error(err);
            return;
          }

          this.destination.next(result);
        }
      }]);

      return MapSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=map.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/mapTo.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/mapTo.js ***!
    \****************************************************************/

  /*! exports provided: mapTo */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsMapToJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "mapTo", function () {
      return mapTo;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function mapTo(value) {
      return function (source) {
        return source.lift(new MapToOperator(value));
      };
    }

    var MapToOperator = /*#__PURE__*/function () {
      function MapToOperator(value) {
        _classCallCheck(this, MapToOperator);

        this.value = value;
      }

      _createClass2(MapToOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new MapToSubscriber(subscriber, this.value));
        }
      }]);

      return MapToOperator;
    }();

    var MapToSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_25) {
      _inherits(MapToSubscriber, _Subscriber__WEBPACK_25);

      var _super160 = _createSuper(MapToSubscriber);

      function MapToSubscriber(destination, value) {
        var _this368;

        _classCallCheck(this, MapToSubscriber);

        _this368 = _super160.call(this, destination);
        _this368.value = value;
        return _this368;
      }

      _createClass2(MapToSubscriber, [{
        key: "_next",
        value: function _next(x) {
          this.destination.next(this.value);
        }
      }]);

      return MapToSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=mapTo.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/materialize.js":
  /*!**********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/materialize.js ***!
    \**********************************************************************/

  /*! exports provided: materialize */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsMaterializeJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "materialize", function () {
      return materialize;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _Notification__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../Notification */
    "./node_modules/rxjs/_esm2015/internal/Notification.js");

    function materialize() {
      return function materializeOperatorFunction(source) {
        return source.lift(new MaterializeOperator());
      };
    }

    var MaterializeOperator = /*#__PURE__*/function () {
      function MaterializeOperator() {
        _classCallCheck(this, MaterializeOperator);
      }

      _createClass2(MaterializeOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new MaterializeSubscriber(subscriber));
        }
      }]);

      return MaterializeOperator;
    }();

    var MaterializeSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_26) {
      _inherits(MaterializeSubscriber, _Subscriber__WEBPACK_26);

      var _super161 = _createSuper(MaterializeSubscriber);

      function MaterializeSubscriber(destination) {
        _classCallCheck(this, MaterializeSubscriber);

        return _super161.call(this, destination);
      }

      _createClass2(MaterializeSubscriber, [{
        key: "_next",
        value: function _next(value) {
          this.destination.next(_Notification__WEBPACK_IMPORTED_MODULE_1__["Notification"].createNext(value));
        }
      }, {
        key: "_error",
        value: function _error(err) {
          var destination = this.destination;
          destination.next(_Notification__WEBPACK_IMPORTED_MODULE_1__["Notification"].createError(err));
          destination.complete();
        }
      }, {
        key: "_complete",
        value: function _complete() {
          var destination = this.destination;
          destination.next(_Notification__WEBPACK_IMPORTED_MODULE_1__["Notification"].createComplete());
          destination.complete();
        }
      }]);

      return MaterializeSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=materialize.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/max.js":
  /*!**************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/max.js ***!
    \**************************************************************/

  /*! exports provided: max */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsMaxJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "max", function () {
      return max;
    });
    /* harmony import */


    var _reduce__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./reduce */
    "./node_modules/rxjs/_esm2015/internal/operators/reduce.js");

    function max(comparer) {
      var max = typeof comparer === 'function' ? function (x, y) {
        return comparer(x, y) > 0 ? x : y;
      } : function (x, y) {
        return x > y ? x : y;
      };
      return Object(_reduce__WEBPACK_IMPORTED_MODULE_0__["reduce"])(max);
    } //# sourceMappingURL=max.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/merge.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/merge.js ***!
    \****************************************************************/

  /*! exports provided: merge */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsMergeJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "merge", function () {
      return merge;
    });
    /* harmony import */


    var _observable_merge__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../observable/merge */
    "./node_modules/rxjs/_esm2015/internal/observable/merge.js");

    function merge() {
      for (var _len51 = arguments.length, observables = new Array(_len51), _key49 = 0; _key49 < _len51; _key49++) {
        observables[_key49] = arguments[_key49];
      }

      return function (source) {
        return source.lift.call(Object(_observable_merge__WEBPACK_IMPORTED_MODULE_0__["merge"]).apply(void 0, [source].concat(observables)));
      };
    } //# sourceMappingURL=merge.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/mergeAll.js":
  /*!*******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/mergeAll.js ***!
    \*******************************************************************/

  /*! exports provided: mergeAll */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsMergeAllJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "mergeAll", function () {
      return mergeAll;
    });
    /* harmony import */


    var _mergeMap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./mergeMap */
    "./node_modules/rxjs/_esm2015/internal/operators/mergeMap.js");
    /* harmony import */


    var _util_identity__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/identity */
    "./node_modules/rxjs/_esm2015/internal/util/identity.js");

    function mergeAll() {
      var concurrent = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : Number.POSITIVE_INFINITY;
      return Object(_mergeMap__WEBPACK_IMPORTED_MODULE_0__["mergeMap"])(_util_identity__WEBPACK_IMPORTED_MODULE_1__["identity"], concurrent);
    } //# sourceMappingURL=mergeAll.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/mergeMap.js":
  /*!*******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/mergeMap.js ***!
    \*******************************************************************/

  /*! exports provided: mergeMap, MergeMapOperator, MergeMapSubscriber */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsMergeMapJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "mergeMap", function () {
      return mergeMap;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MergeMapOperator", function () {
      return MergeMapOperator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MergeMapSubscriber", function () {
      return MergeMapSubscriber;
    });
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _InnerSubscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../InnerSubscriber */
    "./node_modules/rxjs/_esm2015/internal/InnerSubscriber.js");
    /* harmony import */


    var _map__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ./map */
    "./node_modules/rxjs/_esm2015/internal/operators/map.js");
    /* harmony import */


    var _observable_from__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ../observable/from */
    "./node_modules/rxjs/_esm2015/internal/observable/from.js");

    function mergeMap(project, resultSelector) {
      var concurrent = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : Number.POSITIVE_INFINITY;

      if (typeof resultSelector === 'function') {
        return function (source) {
          return source.pipe(mergeMap(function (a, i) {
            return Object(_observable_from__WEBPACK_IMPORTED_MODULE_4__["from"])(project(a, i)).pipe(Object(_map__WEBPACK_IMPORTED_MODULE_3__["map"])(function (b, ii) {
              return resultSelector(a, b, i, ii);
            }));
          }, concurrent));
        };
      } else if (typeof resultSelector === 'number') {
        concurrent = resultSelector;
      }

      return function (source) {
        return source.lift(new MergeMapOperator(project, concurrent));
      };
    }

    var MergeMapOperator = /*#__PURE__*/function () {
      function MergeMapOperator(project) {
        var concurrent = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : Number.POSITIVE_INFINITY;

        _classCallCheck(this, MergeMapOperator);

        this.project = project;
        this.concurrent = concurrent;
      }

      _createClass2(MergeMapOperator, [{
        key: "call",
        value: function call(observer, source) {
          return source.subscribe(new MergeMapSubscriber(observer, this.project, this.concurrent));
        }
      }]);

      return MergeMapOperator;
    }();

    var MergeMapSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB15) {
      _inherits(MergeMapSubscriber, _OuterSubscriber__WEB15);

      var _super162 = _createSuper(MergeMapSubscriber);

      function MergeMapSubscriber(destination, project) {
        var _this369;

        var concurrent = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : Number.POSITIVE_INFINITY;

        _classCallCheck(this, MergeMapSubscriber);

        _this369 = _super162.call(this, destination);
        _this369.project = project;
        _this369.concurrent = concurrent;
        _this369.hasCompleted = false;
        _this369.buffer = [];
        _this369.active = 0;
        _this369.index = 0;
        return _this369;
      }

      _createClass2(MergeMapSubscriber, [{
        key: "_next",
        value: function _next(value) {
          if (this.active < this.concurrent) {
            this._tryNext(value);
          } else {
            this.buffer.push(value);
          }
        }
      }, {
        key: "_tryNext",
        value: function _tryNext(value) {
          var result;
          var index = this.index++;

          try {
            result = this.project(value, index);
          } catch (err) {
            this.destination.error(err);
            return;
          }

          this.active++;

          this._innerSub(result, value, index);
        }
      }, {
        key: "_innerSub",
        value: function _innerSub(ish, value, index) {
          var innerSubscriber = new _InnerSubscriber__WEBPACK_IMPORTED_MODULE_2__["InnerSubscriber"](this, value, index);
          var destination = this.destination;
          destination.add(innerSubscriber);
          var innerSubscription = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_0__["subscribeToResult"])(this, ish, undefined, undefined, innerSubscriber);

          if (innerSubscription !== innerSubscriber) {
            destination.add(innerSubscription);
          }
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.hasCompleted = true;

          if (this.active === 0 && this.buffer.length === 0) {
            this.destination.complete();
          }

          this.unsubscribe();
        }
      }, {
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          this.destination.next(innerValue);
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete(innerSub) {
          var buffer = this.buffer;
          this.remove(innerSub);
          this.active--;

          if (buffer.length > 0) {
            this._next(buffer.shift());
          } else if (this.active === 0 && this.hasCompleted) {
            this.destination.complete();
          }
        }
      }]);

      return MergeMapSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_1__["OuterSubscriber"]); //# sourceMappingURL=mergeMap.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/mergeMapTo.js":
  /*!*********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/mergeMapTo.js ***!
    \*********************************************************************/

  /*! exports provided: mergeMapTo */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsMergeMapToJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "mergeMapTo", function () {
      return mergeMapTo;
    });
    /* harmony import */


    var _mergeMap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./mergeMap */
    "./node_modules/rxjs/_esm2015/internal/operators/mergeMap.js");

    function mergeMapTo(innerObservable, resultSelector) {
      var concurrent = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : Number.POSITIVE_INFINITY;

      if (typeof resultSelector === 'function') {
        return Object(_mergeMap__WEBPACK_IMPORTED_MODULE_0__["mergeMap"])(function () {
          return innerObservable;
        }, resultSelector, concurrent);
      }

      if (typeof resultSelector === 'number') {
        concurrent = resultSelector;
      }

      return Object(_mergeMap__WEBPACK_IMPORTED_MODULE_0__["mergeMap"])(function () {
        return innerObservable;
      }, concurrent);
    } //# sourceMappingURL=mergeMapTo.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/mergeScan.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/mergeScan.js ***!
    \********************************************************************/

  /*! exports provided: mergeScan, MergeScanOperator, MergeScanSubscriber */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsMergeScanJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "mergeScan", function () {
      return mergeScan;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MergeScanOperator", function () {
      return MergeScanOperator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MergeScanSubscriber", function () {
      return MergeScanSubscriber;
    });
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _InnerSubscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../InnerSubscriber */
    "./node_modules/rxjs/_esm2015/internal/InnerSubscriber.js");

    function mergeScan(accumulator, seed) {
      var concurrent = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : Number.POSITIVE_INFINITY;
      return function (source) {
        return source.lift(new MergeScanOperator(accumulator, seed, concurrent));
      };
    }

    var MergeScanOperator = /*#__PURE__*/function () {
      function MergeScanOperator(accumulator, seed, concurrent) {
        _classCallCheck(this, MergeScanOperator);

        this.accumulator = accumulator;
        this.seed = seed;
        this.concurrent = concurrent;
      }

      _createClass2(MergeScanOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new MergeScanSubscriber(subscriber, this.accumulator, this.seed, this.concurrent));
        }
      }]);

      return MergeScanOperator;
    }();

    var MergeScanSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB16) {
      _inherits(MergeScanSubscriber, _OuterSubscriber__WEB16);

      var _super163 = _createSuper(MergeScanSubscriber);

      function MergeScanSubscriber(destination, accumulator, acc, concurrent) {
        var _this370;

        _classCallCheck(this, MergeScanSubscriber);

        _this370 = _super163.call(this, destination);
        _this370.accumulator = accumulator;
        _this370.acc = acc;
        _this370.concurrent = concurrent;
        _this370.hasValue = false;
        _this370.hasCompleted = false;
        _this370.buffer = [];
        _this370.active = 0;
        _this370.index = 0;
        return _this370;
      }

      _createClass2(MergeScanSubscriber, [{
        key: "_next",
        value: function _next(value) {
          if (this.active < this.concurrent) {
            var index = this.index++;
            var destination = this.destination;
            var ish;

            try {
              var accumulator = this.accumulator;
              ish = accumulator(this.acc, value, index);
            } catch (e) {
              return destination.error(e);
            }

            this.active++;

            this._innerSub(ish, value, index);
          } else {
            this.buffer.push(value);
          }
        }
      }, {
        key: "_innerSub",
        value: function _innerSub(ish, value, index) {
          var innerSubscriber = new _InnerSubscriber__WEBPACK_IMPORTED_MODULE_2__["InnerSubscriber"](this, value, index);
          var destination = this.destination;
          destination.add(innerSubscriber);
          var innerSubscription = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_0__["subscribeToResult"])(this, ish, undefined, undefined, innerSubscriber);

          if (innerSubscription !== innerSubscriber) {
            destination.add(innerSubscription);
          }
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.hasCompleted = true;

          if (this.active === 0 && this.buffer.length === 0) {
            if (this.hasValue === false) {
              this.destination.next(this.acc);
            }

            this.destination.complete();
          }

          this.unsubscribe();
        }
      }, {
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          var destination = this.destination;
          this.acc = innerValue;
          this.hasValue = true;
          destination.next(innerValue);
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete(innerSub) {
          var buffer = this.buffer;
          var destination = this.destination;
          destination.remove(innerSub);
          this.active--;

          if (buffer.length > 0) {
            this._next(buffer.shift());
          } else if (this.active === 0 && this.hasCompleted) {
            if (this.hasValue === false) {
              this.destination.next(this.acc);
            }

            this.destination.complete();
          }
        }
      }]);

      return MergeScanSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_1__["OuterSubscriber"]); //# sourceMappingURL=mergeScan.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/min.js":
  /*!**************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/min.js ***!
    \**************************************************************/

  /*! exports provided: min */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsMinJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "min", function () {
      return min;
    });
    /* harmony import */


    var _reduce__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./reduce */
    "./node_modules/rxjs/_esm2015/internal/operators/reduce.js");

    function min(comparer) {
      var min = typeof comparer === 'function' ? function (x, y) {
        return comparer(x, y) < 0 ? x : y;
      } : function (x, y) {
        return x < y ? x : y;
      };
      return Object(_reduce__WEBPACK_IMPORTED_MODULE_0__["reduce"])(min);
    } //# sourceMappingURL=min.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/multicast.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/multicast.js ***!
    \********************************************************************/

  /*! exports provided: multicast, MulticastOperator */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsMulticastJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "multicast", function () {
      return multicast;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "MulticastOperator", function () {
      return MulticastOperator;
    });
    /* harmony import */


    var _observable_ConnectableObservable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../observable/ConnectableObservable */
    "./node_modules/rxjs/_esm2015/internal/observable/ConnectableObservable.js");

    function multicast(subjectOrSubjectFactory, selector) {
      return function multicastOperatorFunction(source) {
        var subjectFactory;

        if (typeof subjectOrSubjectFactory === 'function') {
          subjectFactory = subjectOrSubjectFactory;
        } else {
          subjectFactory = function subjectFactory() {
            return subjectOrSubjectFactory;
          };
        }

        if (typeof selector === 'function') {
          return source.lift(new MulticastOperator(subjectFactory, selector));
        }

        var connectable = Object.create(source, _observable_ConnectableObservable__WEBPACK_IMPORTED_MODULE_0__["connectableObservableDescriptor"]);
        connectable.source = source;
        connectable.subjectFactory = subjectFactory;
        return connectable;
      };
    }

    var MulticastOperator = /*#__PURE__*/function () {
      function MulticastOperator(subjectFactory, selector) {
        _classCallCheck(this, MulticastOperator);

        this.subjectFactory = subjectFactory;
        this.selector = selector;
      }

      _createClass2(MulticastOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          var selector = this.selector;
          var subject = this.subjectFactory();
          var subscription = selector(subject).subscribe(subscriber);
          subscription.add(source.subscribe(subject));
          return subscription;
        }
      }]);

      return MulticastOperator;
    }(); //# sourceMappingURL=multicast.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/observeOn.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/observeOn.js ***!
    \********************************************************************/

  /*! exports provided: observeOn, ObserveOnOperator, ObserveOnSubscriber, ObserveOnMessage */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsObserveOnJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "observeOn", function () {
      return observeOn;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ObserveOnOperator", function () {
      return ObserveOnOperator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ObserveOnSubscriber", function () {
      return ObserveOnSubscriber;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ObserveOnMessage", function () {
      return ObserveOnMessage;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _Notification__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../Notification */
    "./node_modules/rxjs/_esm2015/internal/Notification.js");

    function observeOn(scheduler) {
      var delay = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
      return function observeOnOperatorFunction(source) {
        return source.lift(new ObserveOnOperator(scheduler, delay));
      };
    }

    var ObserveOnOperator = /*#__PURE__*/function () {
      function ObserveOnOperator(scheduler) {
        var delay = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;

        _classCallCheck(this, ObserveOnOperator);

        this.scheduler = scheduler;
        this.delay = delay;
      }

      _createClass2(ObserveOnOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new ObserveOnSubscriber(subscriber, this.scheduler, this.delay));
        }
      }]);

      return ObserveOnOperator;
    }();

    var ObserveOnSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_27) {
      _inherits(ObserveOnSubscriber, _Subscriber__WEBPACK_27);

      var _super164 = _createSuper(ObserveOnSubscriber);

      function ObserveOnSubscriber(destination, scheduler) {
        var _this371;

        var delay = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;

        _classCallCheck(this, ObserveOnSubscriber);

        _this371 = _super164.call(this, destination);
        _this371.scheduler = scheduler;
        _this371.delay = delay;
        return _this371;
      }

      _createClass2(ObserveOnSubscriber, [{
        key: "scheduleMessage",
        value: function scheduleMessage(notification) {
          var destination = this.destination;
          destination.add(this.scheduler.schedule(ObserveOnSubscriber.dispatch, this.delay, new ObserveOnMessage(notification, this.destination)));
        }
      }, {
        key: "_next",
        value: function _next(value) {
          this.scheduleMessage(_Notification__WEBPACK_IMPORTED_MODULE_1__["Notification"].createNext(value));
        }
      }, {
        key: "_error",
        value: function _error(err) {
          this.scheduleMessage(_Notification__WEBPACK_IMPORTED_MODULE_1__["Notification"].createError(err));
          this.unsubscribe();
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.scheduleMessage(_Notification__WEBPACK_IMPORTED_MODULE_1__["Notification"].createComplete());
          this.unsubscribe();
        }
      }], [{
        key: "dispatch",
        value: function dispatch(arg) {
          var notification = arg.notification,
              destination = arg.destination;
          notification.observe(destination);
          this.unsubscribe();
        }
      }]);

      return ObserveOnSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]);

    var ObserveOnMessage = function ObserveOnMessage(notification, destination) {
      _classCallCheck(this, ObserveOnMessage);

      this.notification = notification;
      this.destination = destination;
    }; //# sourceMappingURL=observeOn.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/onErrorResumeNext.js":
  /*!****************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/onErrorResumeNext.js ***!
    \****************************************************************************/

  /*! exports provided: onErrorResumeNext, onErrorResumeNextStatic */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsOnErrorResumeNextJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "onErrorResumeNext", function () {
      return onErrorResumeNext;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "onErrorResumeNextStatic", function () {
      return onErrorResumeNextStatic;
    });
    /* harmony import */


    var _observable_from__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../observable/from */
    "./node_modules/rxjs/_esm2015/internal/observable/from.js");
    /* harmony import */


    var _util_isArray__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/isArray */
    "./node_modules/rxjs/_esm2015/internal/util/isArray.js");
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _InnerSubscriber__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../InnerSubscriber */
    "./node_modules/rxjs/_esm2015/internal/InnerSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function onErrorResumeNext() {
      for (var _len52 = arguments.length, nextSources = new Array(_len52), _key50 = 0; _key50 < _len52; _key50++) {
        nextSources[_key50] = arguments[_key50];
      }

      if (nextSources.length === 1 && Object(_util_isArray__WEBPACK_IMPORTED_MODULE_1__["isArray"])(nextSources[0])) {
        nextSources = nextSources[0];
      }

      return function (source) {
        return source.lift(new OnErrorResumeNextOperator(nextSources));
      };
    }

    function onErrorResumeNextStatic() {
      for (var _len53 = arguments.length, nextSources = new Array(_len53), _key51 = 0; _key51 < _len53; _key51++) {
        nextSources[_key51] = arguments[_key51];
      }

      var source = null;

      if (nextSources.length === 1 && Object(_util_isArray__WEBPACK_IMPORTED_MODULE_1__["isArray"])(nextSources[0])) {
        nextSources = nextSources[0];
      }

      source = nextSources.shift();
      return Object(_observable_from__WEBPACK_IMPORTED_MODULE_0__["from"])(source, null).lift(new OnErrorResumeNextOperator(nextSources));
    }

    var OnErrorResumeNextOperator = /*#__PURE__*/function () {
      function OnErrorResumeNextOperator(nextSources) {
        _classCallCheck(this, OnErrorResumeNextOperator);

        this.nextSources = nextSources;
      }

      _createClass2(OnErrorResumeNextOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new OnErrorResumeNextSubscriber(subscriber, this.nextSources));
        }
      }]);

      return OnErrorResumeNextOperator;
    }();

    var OnErrorResumeNextSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB17) {
      _inherits(OnErrorResumeNextSubscriber, _OuterSubscriber__WEB17);

      var _super165 = _createSuper(OnErrorResumeNextSubscriber);

      function OnErrorResumeNextSubscriber(destination, nextSources) {
        var _this372;

        _classCallCheck(this, OnErrorResumeNextSubscriber);

        _this372 = _super165.call(this, destination);
        _this372.destination = destination;
        _this372.nextSources = nextSources;
        return _this372;
      }

      _createClass2(OnErrorResumeNextSubscriber, [{
        key: "notifyError",
        value: function notifyError(error, innerSub) {
          this.subscribeToNextSource();
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete(innerSub) {
          this.subscribeToNextSource();
        }
      }, {
        key: "_error",
        value: function _error(err) {
          this.subscribeToNextSource();
          this.unsubscribe();
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.subscribeToNextSource();
          this.unsubscribe();
        }
      }, {
        key: "subscribeToNextSource",
        value: function subscribeToNextSource() {
          var next = this.nextSources.shift();

          if (!!next) {
            var innerSubscriber = new _InnerSubscriber__WEBPACK_IMPORTED_MODULE_3__["InnerSubscriber"](this, undefined, undefined);
            var destination = this.destination;
            destination.add(innerSubscriber);
            var innerSubscription = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_4__["subscribeToResult"])(this, next, undefined, undefined, innerSubscriber);

            if (innerSubscription !== innerSubscriber) {
              destination.add(innerSubscription);
            }
          } else {
            this.destination.complete();
          }
        }
      }]);

      return OnErrorResumeNextSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__["OuterSubscriber"]); //# sourceMappingURL=onErrorResumeNext.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/pairwise.js":
  /*!*******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/pairwise.js ***!
    \*******************************************************************/

  /*! exports provided: pairwise */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsPairwiseJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "pairwise", function () {
      return pairwise;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function pairwise() {
      return function (source) {
        return source.lift(new PairwiseOperator());
      };
    }

    var PairwiseOperator = /*#__PURE__*/function () {
      function PairwiseOperator() {
        _classCallCheck(this, PairwiseOperator);
      }

      _createClass2(PairwiseOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new PairwiseSubscriber(subscriber));
        }
      }]);

      return PairwiseOperator;
    }();

    var PairwiseSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_28) {
      _inherits(PairwiseSubscriber, _Subscriber__WEBPACK_28);

      var _super166 = _createSuper(PairwiseSubscriber);

      function PairwiseSubscriber(destination) {
        var _this373;

        _classCallCheck(this, PairwiseSubscriber);

        _this373 = _super166.call(this, destination);
        _this373.hasPrev = false;
        return _this373;
      }

      _createClass2(PairwiseSubscriber, [{
        key: "_next",
        value: function _next(value) {
          var pair;

          if (this.hasPrev) {
            pair = [this.prev, value];
          } else {
            this.hasPrev = true;
          }

          this.prev = value;

          if (pair) {
            this.destination.next(pair);
          }
        }
      }]);

      return PairwiseSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=pairwise.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/partition.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/partition.js ***!
    \********************************************************************/

  /*! exports provided: partition */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsPartitionJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "partition", function () {
      return partition;
    });
    /* harmony import */


    var _util_not__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../util/not */
    "./node_modules/rxjs/_esm2015/internal/util/not.js");
    /* harmony import */


    var _filter__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./filter */
    "./node_modules/rxjs/_esm2015/internal/operators/filter.js");

    function partition(predicate, thisArg) {
      return function (source) {
        return [Object(_filter__WEBPACK_IMPORTED_MODULE_1__["filter"])(predicate, thisArg)(source), Object(_filter__WEBPACK_IMPORTED_MODULE_1__["filter"])(Object(_util_not__WEBPACK_IMPORTED_MODULE_0__["not"])(predicate, thisArg))(source)];
      };
    } //# sourceMappingURL=partition.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/pluck.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/pluck.js ***!
    \****************************************************************/

  /*! exports provided: pluck */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsPluckJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "pluck", function () {
      return pluck;
    });
    /* harmony import */


    var _map__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./map */
    "./node_modules/rxjs/_esm2015/internal/operators/map.js");

    function pluck() {
      for (var _len54 = arguments.length, properties = new Array(_len54), _key52 = 0; _key52 < _len54; _key52++) {
        properties[_key52] = arguments[_key52];
      }

      var length = properties.length;

      if (length === 0) {
        throw new Error('list of properties cannot be empty.');
      }

      return function (source) {
        return Object(_map__WEBPACK_IMPORTED_MODULE_0__["map"])(plucker(properties, length))(source);
      };
    }

    function plucker(props, length) {
      var mapper = function mapper(x) {
        var currentProp = x;

        for (var i = 0; i < length; i++) {
          var p = currentProp[props[i]];

          if (typeof p !== 'undefined') {
            currentProp = p;
          } else {
            return undefined;
          }
        }

        return currentProp;
      };

      return mapper;
    } //# sourceMappingURL=pluck.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/publish.js":
  /*!******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/publish.js ***!
    \******************************************************************/

  /*! exports provided: publish */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsPublishJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "publish", function () {
      return publish;
    });
    /* harmony import */


    var _Subject__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subject */
    "./node_modules/rxjs/_esm2015/internal/Subject.js");
    /* harmony import */


    var _multicast__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./multicast */
    "./node_modules/rxjs/_esm2015/internal/operators/multicast.js");

    function publish(selector) {
      return selector ? Object(_multicast__WEBPACK_IMPORTED_MODULE_1__["multicast"])(function () {
        return new _Subject__WEBPACK_IMPORTED_MODULE_0__["Subject"]();
      }, selector) : Object(_multicast__WEBPACK_IMPORTED_MODULE_1__["multicast"])(new _Subject__WEBPACK_IMPORTED_MODULE_0__["Subject"]());
    } //# sourceMappingURL=publish.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/publishBehavior.js":
  /*!**************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/publishBehavior.js ***!
    \**************************************************************************/

  /*! exports provided: publishBehavior */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsPublishBehaviorJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "publishBehavior", function () {
      return publishBehavior;
    });
    /* harmony import */


    var _BehaviorSubject__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../BehaviorSubject */
    "./node_modules/rxjs/_esm2015/internal/BehaviorSubject.js");
    /* harmony import */


    var _multicast__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./multicast */
    "./node_modules/rxjs/_esm2015/internal/operators/multicast.js");

    function publishBehavior(value) {
      return function (source) {
        return Object(_multicast__WEBPACK_IMPORTED_MODULE_1__["multicast"])(new _BehaviorSubject__WEBPACK_IMPORTED_MODULE_0__["BehaviorSubject"](value))(source);
      };
    } //# sourceMappingURL=publishBehavior.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/publishLast.js":
  /*!**********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/publishLast.js ***!
    \**********************************************************************/

  /*! exports provided: publishLast */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsPublishLastJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "publishLast", function () {
      return publishLast;
    });
    /* harmony import */


    var _AsyncSubject__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../AsyncSubject */
    "./node_modules/rxjs/_esm2015/internal/AsyncSubject.js");
    /* harmony import */


    var _multicast__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./multicast */
    "./node_modules/rxjs/_esm2015/internal/operators/multicast.js");

    function publishLast() {
      return function (source) {
        return Object(_multicast__WEBPACK_IMPORTED_MODULE_1__["multicast"])(new _AsyncSubject__WEBPACK_IMPORTED_MODULE_0__["AsyncSubject"]())(source);
      };
    } //# sourceMappingURL=publishLast.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/publishReplay.js":
  /*!************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/publishReplay.js ***!
    \************************************************************************/

  /*! exports provided: publishReplay */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsPublishReplayJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "publishReplay", function () {
      return publishReplay;
    });
    /* harmony import */


    var _ReplaySubject__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../ReplaySubject */
    "./node_modules/rxjs/_esm2015/internal/ReplaySubject.js");
    /* harmony import */


    var _multicast__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./multicast */
    "./node_modules/rxjs/_esm2015/internal/operators/multicast.js");

    function publishReplay(bufferSize, windowTime, selectorOrScheduler, scheduler) {
      if (selectorOrScheduler && typeof selectorOrScheduler !== 'function') {
        scheduler = selectorOrScheduler;
      }

      var selector = typeof selectorOrScheduler === 'function' ? selectorOrScheduler : undefined;
      var subject = new _ReplaySubject__WEBPACK_IMPORTED_MODULE_0__["ReplaySubject"](bufferSize, windowTime, scheduler);
      return function (source) {
        return Object(_multicast__WEBPACK_IMPORTED_MODULE_1__["multicast"])(function () {
          return subject;
        }, selector)(source);
      };
    } //# sourceMappingURL=publishReplay.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/race.js":
  /*!***************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/race.js ***!
    \***************************************************************/

  /*! exports provided: race */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsRaceJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "race", function () {
      return race;
    });
    /* harmony import */


    var _util_isArray__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../util/isArray */
    "./node_modules/rxjs/_esm2015/internal/util/isArray.js");
    /* harmony import */


    var _observable_race__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../observable/race */
    "./node_modules/rxjs/_esm2015/internal/observable/race.js");

    function race() {
      for (var _len55 = arguments.length, observables = new Array(_len55), _key53 = 0; _key53 < _len55; _key53++) {
        observables[_key53] = arguments[_key53];
      }

      return function raceOperatorFunction(source) {
        if (observables.length === 1 && Object(_util_isArray__WEBPACK_IMPORTED_MODULE_0__["isArray"])(observables[0])) {
          observables = observables[0];
        }

        return source.lift.call(Object(_observable_race__WEBPACK_IMPORTED_MODULE_1__["race"]).apply(void 0, [source].concat(_toConsumableArray(observables))));
      };
    } //# sourceMappingURL=race.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/reduce.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/reduce.js ***!
    \*****************************************************************/

  /*! exports provided: reduce */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsReduceJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "reduce", function () {
      return reduce;
    });
    /* harmony import */


    var _scan__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./scan */
    "./node_modules/rxjs/_esm2015/internal/operators/scan.js");
    /* harmony import */


    var _takeLast__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./takeLast */
    "./node_modules/rxjs/_esm2015/internal/operators/takeLast.js");
    /* harmony import */


    var _defaultIfEmpty__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ./defaultIfEmpty */
    "./node_modules/rxjs/_esm2015/internal/operators/defaultIfEmpty.js");
    /* harmony import */


    var _util_pipe__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../util/pipe */
    "./node_modules/rxjs/_esm2015/internal/util/pipe.js");

    function reduce(accumulator, seed) {
      if (arguments.length >= 2) {
        return function reduceOperatorFunctionWithSeed(source) {
          return Object(_util_pipe__WEBPACK_IMPORTED_MODULE_3__["pipe"])(Object(_scan__WEBPACK_IMPORTED_MODULE_0__["scan"])(accumulator, seed), Object(_takeLast__WEBPACK_IMPORTED_MODULE_1__["takeLast"])(1), Object(_defaultIfEmpty__WEBPACK_IMPORTED_MODULE_2__["defaultIfEmpty"])(seed))(source);
        };
      }

      return function reduceOperatorFunction(source) {
        return Object(_util_pipe__WEBPACK_IMPORTED_MODULE_3__["pipe"])(Object(_scan__WEBPACK_IMPORTED_MODULE_0__["scan"])(function (acc, value, index) {
          return accumulator(acc, value, index + 1);
        }), Object(_takeLast__WEBPACK_IMPORTED_MODULE_1__["takeLast"])(1))(source);
      };
    } //# sourceMappingURL=reduce.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/refCount.js":
  /*!*******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/refCount.js ***!
    \*******************************************************************/

  /*! exports provided: refCount */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsRefCountJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "refCount", function () {
      return refCount;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function refCount() {
      return function refCountOperatorFunction(source) {
        return source.lift(new RefCountOperator(source));
      };
    }

    var RefCountOperator = /*#__PURE__*/function () {
      function RefCountOperator(connectable) {
        _classCallCheck(this, RefCountOperator);

        this.connectable = connectable;
      }

      _createClass2(RefCountOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          var connectable = this.connectable;
          connectable._refCount++;
          var refCounter = new RefCountSubscriber(subscriber, connectable);
          var subscription = source.subscribe(refCounter);

          if (!refCounter.closed) {
            refCounter.connection = connectable.connect();
          }

          return subscription;
        }
      }]);

      return RefCountOperator;
    }();

    var RefCountSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_29) {
      _inherits(RefCountSubscriber, _Subscriber__WEBPACK_29);

      var _super167 = _createSuper(RefCountSubscriber);

      function RefCountSubscriber(destination, connectable) {
        var _this374;

        _classCallCheck(this, RefCountSubscriber);

        _this374 = _super167.call(this, destination);
        _this374.connectable = connectable;
        return _this374;
      }

      _createClass2(RefCountSubscriber, [{
        key: "_unsubscribe",
        value: function _unsubscribe() {
          var connectable = this.connectable;

          if (!connectable) {
            this.connection = null;
            return;
          }

          this.connectable = null;
          var refCount = connectable._refCount;

          if (refCount <= 0) {
            this.connection = null;
            return;
          }

          connectable._refCount = refCount - 1;

          if (refCount > 1) {
            this.connection = null;
            return;
          }

          var connection = this.connection;
          var sharedConnection = connectable._connection;
          this.connection = null;

          if (sharedConnection && (!connection || sharedConnection === connection)) {
            sharedConnection.unsubscribe();
          }
        }
      }]);

      return RefCountSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=refCount.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/repeat.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/repeat.js ***!
    \*****************************************************************/

  /*! exports provided: repeat */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsRepeatJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "repeat", function () {
      return repeat;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _observable_empty__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../observable/empty */
    "./node_modules/rxjs/_esm2015/internal/observable/empty.js");

    function repeat() {
      var count = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : -1;
      return function (source) {
        if (count === 0) {
          return Object(_observable_empty__WEBPACK_IMPORTED_MODULE_1__["empty"])();
        } else if (count < 0) {
          return source.lift(new RepeatOperator(-1, source));
        } else {
          return source.lift(new RepeatOperator(count - 1, source));
        }
      };
    }

    var RepeatOperator = /*#__PURE__*/function () {
      function RepeatOperator(count, source) {
        _classCallCheck(this, RepeatOperator);

        this.count = count;
        this.source = source;
      }

      _createClass2(RepeatOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new RepeatSubscriber(subscriber, this.count, this.source));
        }
      }]);

      return RepeatOperator;
    }();

    var RepeatSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_30) {
      _inherits(RepeatSubscriber, _Subscriber__WEBPACK_30);

      var _super168 = _createSuper(RepeatSubscriber);

      function RepeatSubscriber(destination, count, source) {
        var _this375;

        _classCallCheck(this, RepeatSubscriber);

        _this375 = _super168.call(this, destination);
        _this375.count = count;
        _this375.source = source;
        return _this375;
      }

      _createClass2(RepeatSubscriber, [{
        key: "complete",
        value: function complete() {
          if (!this.isStopped) {
            var source = this.source,
                count = this.count;

            if (count === 0) {
              return _get(_getPrototypeOf(RepeatSubscriber.prototype), "complete", this).call(this);
            } else if (count > -1) {
              this.count = count - 1;
            }

            source.subscribe(this._unsubscribeAndRecycle());
          }
        }
      }]);

      return RepeatSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=repeat.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/repeatWhen.js":
  /*!*********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/repeatWhen.js ***!
    \*********************************************************************/

  /*! exports provided: repeatWhen */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsRepeatWhenJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "repeatWhen", function () {
      return repeatWhen;
    });
    /* harmony import */


    var _Subject__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subject */
    "./node_modules/rxjs/_esm2015/internal/Subject.js");
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function repeatWhen(notifier) {
      return function (source) {
        return source.lift(new RepeatWhenOperator(notifier));
      };
    }

    var RepeatWhenOperator = /*#__PURE__*/function () {
      function RepeatWhenOperator(notifier) {
        _classCallCheck(this, RepeatWhenOperator);

        this.notifier = notifier;
      }

      _createClass2(RepeatWhenOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new RepeatWhenSubscriber(subscriber, this.notifier, source));
        }
      }]);

      return RepeatWhenOperator;
    }();

    var RepeatWhenSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB18) {
      _inherits(RepeatWhenSubscriber, _OuterSubscriber__WEB18);

      var _super169 = _createSuper(RepeatWhenSubscriber);

      function RepeatWhenSubscriber(destination, notifier, source) {
        var _this376;

        _classCallCheck(this, RepeatWhenSubscriber);

        _this376 = _super169.call(this, destination);
        _this376.notifier = notifier;
        _this376.source = source;
        _this376.sourceIsBeingSubscribedTo = true;
        return _this376;
      }

      _createClass2(RepeatWhenSubscriber, [{
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          this.sourceIsBeingSubscribedTo = true;
          this.source.subscribe(this);
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete(innerSub) {
          if (this.sourceIsBeingSubscribedTo === false) {
            return _get(_getPrototypeOf(RepeatWhenSubscriber.prototype), "complete", this).call(this);
          }
        }
      }, {
        key: "complete",
        value: function complete() {
          this.sourceIsBeingSubscribedTo = false;

          if (!this.isStopped) {
            if (!this.retries) {
              this.subscribeToRetries();
            }

            if (!this.retriesSubscription || this.retriesSubscription.closed) {
              return _get(_getPrototypeOf(RepeatWhenSubscriber.prototype), "complete", this).call(this);
            }

            this._unsubscribeAndRecycle();

            this.notifications.next();
          }
        }
      }, {
        key: "_unsubscribe",
        value: function _unsubscribe() {
          var notifications = this.notifications,
              retriesSubscription = this.retriesSubscription;

          if (notifications) {
            notifications.unsubscribe();
            this.notifications = null;
          }

          if (retriesSubscription) {
            retriesSubscription.unsubscribe();
            this.retriesSubscription = null;
          }

          this.retries = null;
        }
      }, {
        key: "_unsubscribeAndRecycle",
        value: function _unsubscribeAndRecycle() {
          var _unsubscribe = this._unsubscribe;
          this._unsubscribe = null;

          _get(_getPrototypeOf(RepeatWhenSubscriber.prototype), "_unsubscribeAndRecycle", this).call(this);

          this._unsubscribe = _unsubscribe;
          return this;
        }
      }, {
        key: "subscribeToRetries",
        value: function subscribeToRetries() {
          this.notifications = new _Subject__WEBPACK_IMPORTED_MODULE_0__["Subject"]();
          var retries;

          try {
            var notifier = this.notifier;
            retries = notifier(this.notifications);
          } catch (e) {
            return _get(_getPrototypeOf(RepeatWhenSubscriber.prototype), "complete", this).call(this);
          }

          this.retries = retries;
          this.retriesSubscription = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_2__["subscribeToResult"])(this, retries);
        }
      }]);

      return RepeatWhenSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_1__["OuterSubscriber"]); //# sourceMappingURL=repeatWhen.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/retry.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/retry.js ***!
    \****************************************************************/

  /*! exports provided: retry */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsRetryJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "retry", function () {
      return retry;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function retry() {
      var count = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : -1;
      return function (source) {
        return source.lift(new RetryOperator(count, source));
      };
    }

    var RetryOperator = /*#__PURE__*/function () {
      function RetryOperator(count, source) {
        _classCallCheck(this, RetryOperator);

        this.count = count;
        this.source = source;
      }

      _createClass2(RetryOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new RetrySubscriber(subscriber, this.count, this.source));
        }
      }]);

      return RetryOperator;
    }();

    var RetrySubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_31) {
      _inherits(RetrySubscriber, _Subscriber__WEBPACK_31);

      var _super170 = _createSuper(RetrySubscriber);

      function RetrySubscriber(destination, count, source) {
        var _this377;

        _classCallCheck(this, RetrySubscriber);

        _this377 = _super170.call(this, destination);
        _this377.count = count;
        _this377.source = source;
        return _this377;
      }

      _createClass2(RetrySubscriber, [{
        key: "error",
        value: function error(err) {
          if (!this.isStopped) {
            var source = this.source,
                count = this.count;

            if (count === 0) {
              return _get(_getPrototypeOf(RetrySubscriber.prototype), "error", this).call(this, err);
            } else if (count > -1) {
              this.count = count - 1;
            }

            source.subscribe(this._unsubscribeAndRecycle());
          }
        }
      }]);

      return RetrySubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=retry.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/retryWhen.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/retryWhen.js ***!
    \********************************************************************/

  /*! exports provided: retryWhen */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsRetryWhenJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "retryWhen", function () {
      return retryWhen;
    });
    /* harmony import */


    var _Subject__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subject */
    "./node_modules/rxjs/_esm2015/internal/Subject.js");
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function retryWhen(notifier) {
      return function (source) {
        return source.lift(new RetryWhenOperator(notifier, source));
      };
    }

    var RetryWhenOperator = /*#__PURE__*/function () {
      function RetryWhenOperator(notifier, source) {
        _classCallCheck(this, RetryWhenOperator);

        this.notifier = notifier;
        this.source = source;
      }

      _createClass2(RetryWhenOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new RetryWhenSubscriber(subscriber, this.notifier, this.source));
        }
      }]);

      return RetryWhenOperator;
    }();

    var RetryWhenSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB19) {
      _inherits(RetryWhenSubscriber, _OuterSubscriber__WEB19);

      var _super171 = _createSuper(RetryWhenSubscriber);

      function RetryWhenSubscriber(destination, notifier, source) {
        var _this378;

        _classCallCheck(this, RetryWhenSubscriber);

        _this378 = _super171.call(this, destination);
        _this378.notifier = notifier;
        _this378.source = source;
        return _this378;
      }

      _createClass2(RetryWhenSubscriber, [{
        key: "error",
        value: function error(err) {
          if (!this.isStopped) {
            var errors = this.errors;
            var retries = this.retries;
            var retriesSubscription = this.retriesSubscription;

            if (!retries) {
              errors = new _Subject__WEBPACK_IMPORTED_MODULE_0__["Subject"]();

              try {
                var notifier = this.notifier;
                retries = notifier(errors);
              } catch (e) {
                return _get(_getPrototypeOf(RetryWhenSubscriber.prototype), "error", this).call(this, e);
              }

              retriesSubscription = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_2__["subscribeToResult"])(this, retries);
            } else {
              this.errors = null;
              this.retriesSubscription = null;
            }

            this._unsubscribeAndRecycle();

            this.errors = errors;
            this.retries = retries;
            this.retriesSubscription = retriesSubscription;
            errors.next(err);
          }
        }
      }, {
        key: "_unsubscribe",
        value: function _unsubscribe() {
          var errors = this.errors,
              retriesSubscription = this.retriesSubscription;

          if (errors) {
            errors.unsubscribe();
            this.errors = null;
          }

          if (retriesSubscription) {
            retriesSubscription.unsubscribe();
            this.retriesSubscription = null;
          }

          this.retries = null;
        }
      }, {
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          var _unsubscribe = this._unsubscribe;
          this._unsubscribe = null;

          this._unsubscribeAndRecycle();

          this._unsubscribe = _unsubscribe;
          this.source.subscribe(this);
        }
      }]);

      return RetryWhenSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_1__["OuterSubscriber"]); //# sourceMappingURL=retryWhen.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/sample.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/sample.js ***!
    \*****************************************************************/

  /*! exports provided: sample */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsSampleJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "sample", function () {
      return sample;
    });
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function sample(notifier) {
      return function (source) {
        return source.lift(new SampleOperator(notifier));
      };
    }

    var SampleOperator = /*#__PURE__*/function () {
      function SampleOperator(notifier) {
        _classCallCheck(this, SampleOperator);

        this.notifier = notifier;
      }

      _createClass2(SampleOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          var sampleSubscriber = new SampleSubscriber(subscriber);
          var subscription = source.subscribe(sampleSubscriber);
          subscription.add(Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__["subscribeToResult"])(sampleSubscriber, this.notifier));
          return subscription;
        }
      }]);

      return SampleOperator;
    }();

    var SampleSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB20) {
      _inherits(SampleSubscriber, _OuterSubscriber__WEB20);

      var _super172 = _createSuper(SampleSubscriber);

      function SampleSubscriber() {
        var _this379;

        _classCallCheck(this, SampleSubscriber);

        _this379 = _super172.apply(this, arguments);
        _this379.hasValue = false;
        return _this379;
      }

      _createClass2(SampleSubscriber, [{
        key: "_next",
        value: function _next(value) {
          this.value = value;
          this.hasValue = true;
        }
      }, {
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          this.emitValue();
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete() {
          this.emitValue();
        }
      }, {
        key: "emitValue",
        value: function emitValue() {
          if (this.hasValue) {
            this.hasValue = false;
            this.destination.next(this.value);
          }
        }
      }]);

      return SampleSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__["OuterSubscriber"]); //# sourceMappingURL=sample.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/sampleTime.js":
  /*!*********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/sampleTime.js ***!
    \*********************************************************************/

  /*! exports provided: sampleTime */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsSampleTimeJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "sampleTime", function () {
      return sampleTime;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _scheduler_async__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../scheduler/async */
    "./node_modules/rxjs/_esm2015/internal/scheduler/async.js");

    function sampleTime(period) {
      var scheduler = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : _scheduler_async__WEBPACK_IMPORTED_MODULE_1__["async"];
      return function (source) {
        return source.lift(new SampleTimeOperator(period, scheduler));
      };
    }

    var SampleTimeOperator = /*#__PURE__*/function () {
      function SampleTimeOperator(period, scheduler) {
        _classCallCheck(this, SampleTimeOperator);

        this.period = period;
        this.scheduler = scheduler;
      }

      _createClass2(SampleTimeOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new SampleTimeSubscriber(subscriber, this.period, this.scheduler));
        }
      }]);

      return SampleTimeOperator;
    }();

    var SampleTimeSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_32) {
      _inherits(SampleTimeSubscriber, _Subscriber__WEBPACK_32);

      var _super173 = _createSuper(SampleTimeSubscriber);

      function SampleTimeSubscriber(destination, period, scheduler) {
        var _this380;

        _classCallCheck(this, SampleTimeSubscriber);

        _this380 = _super173.call(this, destination);
        _this380.period = period;
        _this380.scheduler = scheduler;
        _this380.hasValue = false;

        _this380.add(scheduler.schedule(dispatchNotification, period, {
          subscriber: _assertThisInitialized(_this380),
          period: period
        }));

        return _this380;
      }

      _createClass2(SampleTimeSubscriber, [{
        key: "_next",
        value: function _next(value) {
          this.lastValue = value;
          this.hasValue = true;
        }
      }, {
        key: "notifyNext",
        value: function notifyNext() {
          if (this.hasValue) {
            this.hasValue = false;
            this.destination.next(this.lastValue);
          }
        }
      }]);

      return SampleTimeSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]);

    function dispatchNotification(state) {
      var subscriber = state.subscriber,
          period = state.period;
      subscriber.notifyNext();
      this.schedule(state, period);
    } //# sourceMappingURL=sampleTime.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/scan.js":
  /*!***************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/scan.js ***!
    \***************************************************************/

  /*! exports provided: scan */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsScanJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "scan", function () {
      return scan;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function scan(accumulator, seed) {
      var hasSeed = false;

      if (arguments.length >= 2) {
        hasSeed = true;
      }

      return function scanOperatorFunction(source) {
        return source.lift(new ScanOperator(accumulator, seed, hasSeed));
      };
    }

    var ScanOperator = /*#__PURE__*/function () {
      function ScanOperator(accumulator, seed) {
        var hasSeed = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;

        _classCallCheck(this, ScanOperator);

        this.accumulator = accumulator;
        this.seed = seed;
        this.hasSeed = hasSeed;
      }

      _createClass2(ScanOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new ScanSubscriber(subscriber, this.accumulator, this.seed, this.hasSeed));
        }
      }]);

      return ScanOperator;
    }();

    var ScanSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_33) {
      _inherits(ScanSubscriber, _Subscriber__WEBPACK_33);

      var _super174 = _createSuper(ScanSubscriber);

      function ScanSubscriber(destination, accumulator, _seed, hasSeed) {
        var _this381;

        _classCallCheck(this, ScanSubscriber);

        _this381 = _super174.call(this, destination);
        _this381.accumulator = accumulator;
        _this381._seed = _seed;
        _this381.hasSeed = hasSeed;
        _this381.index = 0;
        return _this381;
      }

      _createClass2(ScanSubscriber, [{
        key: "_next",
        value: function _next(value) {
          if (!this.hasSeed) {
            this.seed = value;
            this.destination.next(value);
          } else {
            return this._tryNext(value);
          }
        }
      }, {
        key: "_tryNext",
        value: function _tryNext(value) {
          var index = this.index++;
          var result;

          try {
            result = this.accumulator(this.seed, value, index);
          } catch (err) {
            this.destination.error(err);
          }

          this.seed = result;
          this.destination.next(result);
        }
      }, {
        key: "seed",
        get: function get() {
          return this._seed;
        },
        set: function set(value) {
          this.hasSeed = true;
          this._seed = value;
        }
      }]);

      return ScanSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=scan.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/sequenceEqual.js":
  /*!************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/sequenceEqual.js ***!
    \************************************************************************/

  /*! exports provided: sequenceEqual, SequenceEqualOperator, SequenceEqualSubscriber */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsSequenceEqualJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "sequenceEqual", function () {
      return sequenceEqual;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SequenceEqualOperator", function () {
      return SequenceEqualOperator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "SequenceEqualSubscriber", function () {
      return SequenceEqualSubscriber;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function sequenceEqual(compareTo, comparator) {
      return function (source) {
        return source.lift(new SequenceEqualOperator(compareTo, comparator));
      };
    }

    var SequenceEqualOperator = /*#__PURE__*/function () {
      function SequenceEqualOperator(compareTo, comparator) {
        _classCallCheck(this, SequenceEqualOperator);

        this.compareTo = compareTo;
        this.comparator = comparator;
      }

      _createClass2(SequenceEqualOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new SequenceEqualSubscriber(subscriber, this.compareTo, this.comparator));
        }
      }]);

      return SequenceEqualOperator;
    }();

    var SequenceEqualSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_34) {
      _inherits(SequenceEqualSubscriber, _Subscriber__WEBPACK_34);

      var _super175 = _createSuper(SequenceEqualSubscriber);

      function SequenceEqualSubscriber(destination, compareTo, comparator) {
        var _this382;

        _classCallCheck(this, SequenceEqualSubscriber);

        _this382 = _super175.call(this, destination);
        _this382.compareTo = compareTo;
        _this382.comparator = comparator;
        _this382._a = [];
        _this382._b = [];
        _this382._oneComplete = false;

        _this382.destination.add(compareTo.subscribe(new SequenceEqualCompareToSubscriber(destination, _assertThisInitialized(_this382))));

        return _this382;
      }

      _createClass2(SequenceEqualSubscriber, [{
        key: "_next",
        value: function _next(value) {
          if (this._oneComplete && this._b.length === 0) {
            this.emit(false);
          } else {
            this._a.push(value);

            this.checkValues();
          }
        }
      }, {
        key: "_complete",
        value: function _complete() {
          if (this._oneComplete) {
            this.emit(this._a.length === 0 && this._b.length === 0);
          } else {
            this._oneComplete = true;
          }

          this.unsubscribe();
        }
      }, {
        key: "checkValues",
        value: function checkValues() {
          var _a = this._a,
              _b = this._b,
              comparator = this.comparator;

          while (_a.length > 0 && _b.length > 0) {
            var a = _a.shift();

            var b = _b.shift();

            var areEqual = false;

            try {
              areEqual = comparator ? comparator(a, b) : a === b;
            } catch (e) {
              this.destination.error(e);
            }

            if (!areEqual) {
              this.emit(false);
            }
          }
        }
      }, {
        key: "emit",
        value: function emit(value) {
          var destination = this.destination;
          destination.next(value);
          destination.complete();
        }
      }, {
        key: "nextB",
        value: function nextB(value) {
          if (this._oneComplete && this._a.length === 0) {
            this.emit(false);
          } else {
            this._b.push(value);

            this.checkValues();
          }
        }
      }, {
        key: "completeB",
        value: function completeB() {
          if (this._oneComplete) {
            this.emit(this._a.length === 0 && this._b.length === 0);
          } else {
            this._oneComplete = true;
          }
        }
      }]);

      return SequenceEqualSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]);

    var SequenceEqualCompareToSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_35) {
      _inherits(SequenceEqualCompareToSubscriber, _Subscriber__WEBPACK_35);

      var _super176 = _createSuper(SequenceEqualCompareToSubscriber);

      function SequenceEqualCompareToSubscriber(destination, parent) {
        var _this383;

        _classCallCheck(this, SequenceEqualCompareToSubscriber);

        _this383 = _super176.call(this, destination);
        _this383.parent = parent;
        return _this383;
      }

      _createClass2(SequenceEqualCompareToSubscriber, [{
        key: "_next",
        value: function _next(value) {
          this.parent.nextB(value);
        }
      }, {
        key: "_error",
        value: function _error(err) {
          this.parent.error(err);
          this.unsubscribe();
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.parent.completeB();
          this.unsubscribe();
        }
      }]);

      return SequenceEqualCompareToSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=sequenceEqual.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/share.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/share.js ***!
    \****************************************************************/

  /*! exports provided: share */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsShareJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "share", function () {
      return share;
    });
    /* harmony import */


    var _multicast__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./multicast */
    "./node_modules/rxjs/_esm2015/internal/operators/multicast.js");
    /* harmony import */


    var _refCount__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./refCount */
    "./node_modules/rxjs/_esm2015/internal/operators/refCount.js");
    /* harmony import */


    var _Subject__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../Subject */
    "./node_modules/rxjs/_esm2015/internal/Subject.js");

    function shareSubjectFactory() {
      return new _Subject__WEBPACK_IMPORTED_MODULE_2__["Subject"]();
    }

    function share() {
      return function (source) {
        return Object(_refCount__WEBPACK_IMPORTED_MODULE_1__["refCount"])()(Object(_multicast__WEBPACK_IMPORTED_MODULE_0__["multicast"])(shareSubjectFactory)(source));
      };
    } //# sourceMappingURL=share.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/shareReplay.js":
  /*!**********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/shareReplay.js ***!
    \**********************************************************************/

  /*! exports provided: shareReplay */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsShareReplayJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "shareReplay", function () {
      return shareReplay;
    });
    /* harmony import */


    var _ReplaySubject__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../ReplaySubject */
    "./node_modules/rxjs/_esm2015/internal/ReplaySubject.js");

    function shareReplay(configOrBufferSize, windowTime, scheduler) {
      var config;

      if (configOrBufferSize && typeof configOrBufferSize === 'object') {
        config = configOrBufferSize;
      } else {
        config = {
          bufferSize: configOrBufferSize,
          windowTime: windowTime,
          refCount: false,
          scheduler: scheduler
        };
      }

      return function (source) {
        return source.lift(shareReplayOperator(config));
      };
    }

    function shareReplayOperator(_ref18) {
      var _ref18$bufferSize = _ref18.bufferSize,
          bufferSize = _ref18$bufferSize === void 0 ? Number.POSITIVE_INFINITY : _ref18$bufferSize,
          _ref18$windowTime = _ref18.windowTime,
          windowTime = _ref18$windowTime === void 0 ? Number.POSITIVE_INFINITY : _ref18$windowTime,
          useRefCount = _ref18.refCount,
          scheduler = _ref18.scheduler;
      var subject;
      var refCount = 0;
      var subscription;
      var hasError = false;
      var isComplete = false;
      return function shareReplayOperation(source) {
        refCount++;

        if (!subject || hasError) {
          hasError = false;
          subject = new _ReplaySubject__WEBPACK_IMPORTED_MODULE_0__["ReplaySubject"](bufferSize, windowTime, scheduler);
          subscription = source.subscribe({
            next: function next(value) {
              subject.next(value);
            },
            error: function error(err) {
              hasError = true;
              subject.error(err);
            },
            complete: function complete() {
              isComplete = true;
              subscription = undefined;
              subject.complete();
            }
          });
        }

        var innerSub = subject.subscribe(this);
        this.add(function () {
          refCount--;
          innerSub.unsubscribe();

          if (subscription && !isComplete && useRefCount && refCount === 0) {
            subscription.unsubscribe();
            subscription = undefined;
            subject = undefined;
          }
        });
      };
    } //# sourceMappingURL=shareReplay.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/single.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/single.js ***!
    \*****************************************************************/

  /*! exports provided: single */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsSingleJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "single", function () {
      return single;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _util_EmptyError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/EmptyError */
    "./node_modules/rxjs/_esm2015/internal/util/EmptyError.js");

    function single(predicate) {
      return function (source) {
        return source.lift(new SingleOperator(predicate, source));
      };
    }

    var SingleOperator = /*#__PURE__*/function () {
      function SingleOperator(predicate, source) {
        _classCallCheck(this, SingleOperator);

        this.predicate = predicate;
        this.source = source;
      }

      _createClass2(SingleOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new SingleSubscriber(subscriber, this.predicate, this.source));
        }
      }]);

      return SingleOperator;
    }();

    var SingleSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_36) {
      _inherits(SingleSubscriber, _Subscriber__WEBPACK_36);

      var _super177 = _createSuper(SingleSubscriber);

      function SingleSubscriber(destination, predicate, source) {
        var _this384;

        _classCallCheck(this, SingleSubscriber);

        _this384 = _super177.call(this, destination);
        _this384.predicate = predicate;
        _this384.source = source;
        _this384.seenValue = false;
        _this384.index = 0;
        return _this384;
      }

      _createClass2(SingleSubscriber, [{
        key: "applySingleValue",
        value: function applySingleValue(value) {
          if (this.seenValue) {
            this.destination.error('Sequence contains more than one element');
          } else {
            this.seenValue = true;
            this.singleValue = value;
          }
        }
      }, {
        key: "_next",
        value: function _next(value) {
          var index = this.index++;

          if (this.predicate) {
            this.tryNext(value, index);
          } else {
            this.applySingleValue(value);
          }
        }
      }, {
        key: "tryNext",
        value: function tryNext(value, index) {
          try {
            if (this.predicate(value, index, this.source)) {
              this.applySingleValue(value);
            }
          } catch (err) {
            this.destination.error(err);
          }
        }
      }, {
        key: "_complete",
        value: function _complete() {
          var destination = this.destination;

          if (this.index > 0) {
            destination.next(this.seenValue ? this.singleValue : undefined);
            destination.complete();
          } else {
            destination.error(new _util_EmptyError__WEBPACK_IMPORTED_MODULE_1__["EmptyError"]());
          }
        }
      }]);

      return SingleSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=single.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/skip.js":
  /*!***************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/skip.js ***!
    \***************************************************************/

  /*! exports provided: skip */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsSkipJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "skip", function () {
      return skip;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function skip(count) {
      return function (source) {
        return source.lift(new SkipOperator(count));
      };
    }

    var SkipOperator = /*#__PURE__*/function () {
      function SkipOperator(total) {
        _classCallCheck(this, SkipOperator);

        this.total = total;
      }

      _createClass2(SkipOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new SkipSubscriber(subscriber, this.total));
        }
      }]);

      return SkipOperator;
    }();

    var SkipSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_37) {
      _inherits(SkipSubscriber, _Subscriber__WEBPACK_37);

      var _super178 = _createSuper(SkipSubscriber);

      function SkipSubscriber(destination, total) {
        var _this385;

        _classCallCheck(this, SkipSubscriber);

        _this385 = _super178.call(this, destination);
        _this385.total = total;
        _this385.count = 0;
        return _this385;
      }

      _createClass2(SkipSubscriber, [{
        key: "_next",
        value: function _next(x) {
          if (++this.count > this.total) {
            this.destination.next(x);
          }
        }
      }]);

      return SkipSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=skip.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/skipLast.js":
  /*!*******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/skipLast.js ***!
    \*******************************************************************/

  /*! exports provided: skipLast */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsSkipLastJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "skipLast", function () {
      return skipLast;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _util_ArgumentOutOfRangeError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/ArgumentOutOfRangeError */
    "./node_modules/rxjs/_esm2015/internal/util/ArgumentOutOfRangeError.js");

    function skipLast(count) {
      return function (source) {
        return source.lift(new SkipLastOperator(count));
      };
    }

    var SkipLastOperator = /*#__PURE__*/function () {
      function SkipLastOperator(_skipCount) {
        _classCallCheck(this, SkipLastOperator);

        this._skipCount = _skipCount;

        if (this._skipCount < 0) {
          throw new _util_ArgumentOutOfRangeError__WEBPACK_IMPORTED_MODULE_1__["ArgumentOutOfRangeError"]();
        }
      }

      _createClass2(SkipLastOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          if (this._skipCount === 0) {
            return source.subscribe(new _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"](subscriber));
          } else {
            return source.subscribe(new SkipLastSubscriber(subscriber, this._skipCount));
          }
        }
      }]);

      return SkipLastOperator;
    }();

    var SkipLastSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_38) {
      _inherits(SkipLastSubscriber, _Subscriber__WEBPACK_38);

      var _super179 = _createSuper(SkipLastSubscriber);

      function SkipLastSubscriber(destination, _skipCount) {
        var _this386;

        _classCallCheck(this, SkipLastSubscriber);

        _this386 = _super179.call(this, destination);
        _this386._skipCount = _skipCount;
        _this386._count = 0;
        _this386._ring = new Array(_skipCount);
        return _this386;
      }

      _createClass2(SkipLastSubscriber, [{
        key: "_next",
        value: function _next(value) {
          var skipCount = this._skipCount;
          var count = this._count++;

          if (count < skipCount) {
            this._ring[count] = value;
          } else {
            var currentIndex = count % skipCount;
            var ring = this._ring;
            var oldValue = ring[currentIndex];
            ring[currentIndex] = value;
            this.destination.next(oldValue);
          }
        }
      }]);

      return SkipLastSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=skipLast.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/skipUntil.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/skipUntil.js ***!
    \********************************************************************/

  /*! exports provided: skipUntil */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsSkipUntilJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "skipUntil", function () {
      return skipUntil;
    });
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _InnerSubscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../InnerSubscriber */
    "./node_modules/rxjs/_esm2015/internal/InnerSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function skipUntil(notifier) {
      return function (source) {
        return source.lift(new SkipUntilOperator(notifier));
      };
    }

    var SkipUntilOperator = /*#__PURE__*/function () {
      function SkipUntilOperator(notifier) {
        _classCallCheck(this, SkipUntilOperator);

        this.notifier = notifier;
      }

      _createClass2(SkipUntilOperator, [{
        key: "call",
        value: function call(destination, source) {
          return source.subscribe(new SkipUntilSubscriber(destination, this.notifier));
        }
      }]);

      return SkipUntilOperator;
    }();

    var SkipUntilSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB21) {
      _inherits(SkipUntilSubscriber, _OuterSubscriber__WEB21);

      var _super180 = _createSuper(SkipUntilSubscriber);

      function SkipUntilSubscriber(destination, notifier) {
        var _this387;

        _classCallCheck(this, SkipUntilSubscriber);

        _this387 = _super180.call(this, destination);
        _this387.hasValue = false;
        var innerSubscriber = new _InnerSubscriber__WEBPACK_IMPORTED_MODULE_1__["InnerSubscriber"](_assertThisInitialized(_this387), undefined, undefined);

        _this387.add(innerSubscriber);

        _this387.innerSubscription = innerSubscriber;
        var innerSubscription = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_2__["subscribeToResult"])(_assertThisInitialized(_this387), notifier, undefined, undefined, innerSubscriber);

        if (innerSubscription !== innerSubscriber) {
          _this387.add(innerSubscription);

          _this387.innerSubscription = innerSubscription;
        }

        return _this387;
      }

      _createClass2(SkipUntilSubscriber, [{
        key: "_next",
        value: function _next(value) {
          if (this.hasValue) {
            _get(_getPrototypeOf(SkipUntilSubscriber.prototype), "_next", this).call(this, value);
          }
        }
      }, {
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          this.hasValue = true;

          if (this.innerSubscription) {
            this.innerSubscription.unsubscribe();
          }
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete() {}
      }]);

      return SkipUntilSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__["OuterSubscriber"]); //# sourceMappingURL=skipUntil.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/skipWhile.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/skipWhile.js ***!
    \********************************************************************/

  /*! exports provided: skipWhile */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsSkipWhileJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "skipWhile", function () {
      return skipWhile;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function skipWhile(predicate) {
      return function (source) {
        return source.lift(new SkipWhileOperator(predicate));
      };
    }

    var SkipWhileOperator = /*#__PURE__*/function () {
      function SkipWhileOperator(predicate) {
        _classCallCheck(this, SkipWhileOperator);

        this.predicate = predicate;
      }

      _createClass2(SkipWhileOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new SkipWhileSubscriber(subscriber, this.predicate));
        }
      }]);

      return SkipWhileOperator;
    }();

    var SkipWhileSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_39) {
      _inherits(SkipWhileSubscriber, _Subscriber__WEBPACK_39);

      var _super181 = _createSuper(SkipWhileSubscriber);

      function SkipWhileSubscriber(destination, predicate) {
        var _this388;

        _classCallCheck(this, SkipWhileSubscriber);

        _this388 = _super181.call(this, destination);
        _this388.predicate = predicate;
        _this388.skipping = true;
        _this388.index = 0;
        return _this388;
      }

      _createClass2(SkipWhileSubscriber, [{
        key: "_next",
        value: function _next(value) {
          var destination = this.destination;

          if (this.skipping) {
            this.tryCallPredicate(value);
          }

          if (!this.skipping) {
            destination.next(value);
          }
        }
      }, {
        key: "tryCallPredicate",
        value: function tryCallPredicate(value) {
          try {
            var result = this.predicate(value, this.index++);
            this.skipping = Boolean(result);
          } catch (err) {
            this.destination.error(err);
          }
        }
      }]);

      return SkipWhileSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=skipWhile.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/startWith.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/startWith.js ***!
    \********************************************************************/

  /*! exports provided: startWith */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsStartWithJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "startWith", function () {
      return startWith;
    });
    /* harmony import */


    var _observable_concat__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../observable/concat */
    "./node_modules/rxjs/_esm2015/internal/observable/concat.js");
    /* harmony import */


    var _util_isScheduler__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/isScheduler */
    "./node_modules/rxjs/_esm2015/internal/util/isScheduler.js");

    function startWith() {
      for (var _len56 = arguments.length, array = new Array(_len56), _key54 = 0; _key54 < _len56; _key54++) {
        array[_key54] = arguments[_key54];
      }

      var scheduler = array[array.length - 1];

      if (Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_1__["isScheduler"])(scheduler)) {
        array.pop();
        return function (source) {
          return Object(_observable_concat__WEBPACK_IMPORTED_MODULE_0__["concat"])(array, source, scheduler);
        };
      } else {
        return function (source) {
          return Object(_observable_concat__WEBPACK_IMPORTED_MODULE_0__["concat"])(array, source);
        };
      }
    } //# sourceMappingURL=startWith.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/subscribeOn.js":
  /*!**********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/subscribeOn.js ***!
    \**********************************************************************/

  /*! exports provided: subscribeOn */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsSubscribeOnJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "subscribeOn", function () {
      return subscribeOn;
    });
    /* harmony import */


    var _observable_SubscribeOnObservable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../observable/SubscribeOnObservable */
    "./node_modules/rxjs/_esm2015/internal/observable/SubscribeOnObservable.js");

    function subscribeOn(scheduler) {
      var delay = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
      return function subscribeOnOperatorFunction(source) {
        return source.lift(new SubscribeOnOperator(scheduler, delay));
      };
    }

    var SubscribeOnOperator = /*#__PURE__*/function () {
      function SubscribeOnOperator(scheduler, delay) {
        _classCallCheck(this, SubscribeOnOperator);

        this.scheduler = scheduler;
        this.delay = delay;
      }

      _createClass2(SubscribeOnOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return new _observable_SubscribeOnObservable__WEBPACK_IMPORTED_MODULE_0__["SubscribeOnObservable"](source, this.delay, this.scheduler).subscribe(subscriber);
        }
      }]);

      return SubscribeOnOperator;
    }(); //# sourceMappingURL=subscribeOn.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/switchAll.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/switchAll.js ***!
    \********************************************************************/

  /*! exports provided: switchAll */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsSwitchAllJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "switchAll", function () {
      return switchAll;
    });
    /* harmony import */


    var _switchMap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./switchMap */
    "./node_modules/rxjs/_esm2015/internal/operators/switchMap.js");
    /* harmony import */


    var _util_identity__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/identity */
    "./node_modules/rxjs/_esm2015/internal/util/identity.js");

    function switchAll() {
      return Object(_switchMap__WEBPACK_IMPORTED_MODULE_0__["switchMap"])(_util_identity__WEBPACK_IMPORTED_MODULE_1__["identity"]);
    } //# sourceMappingURL=switchAll.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/switchMap.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/switchMap.js ***!
    \********************************************************************/

  /*! exports provided: switchMap */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsSwitchMapJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "switchMap", function () {
      return switchMap;
    });
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _InnerSubscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../InnerSubscriber */
    "./node_modules/rxjs/_esm2015/internal/InnerSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");
    /* harmony import */


    var _map__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ./map */
    "./node_modules/rxjs/_esm2015/internal/operators/map.js");
    /* harmony import */


    var _observable_from__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ../observable/from */
    "./node_modules/rxjs/_esm2015/internal/observable/from.js");

    function switchMap(project, resultSelector) {
      if (typeof resultSelector === 'function') {
        return function (source) {
          return source.pipe(switchMap(function (a, i) {
            return Object(_observable_from__WEBPACK_IMPORTED_MODULE_4__["from"])(project(a, i)).pipe(Object(_map__WEBPACK_IMPORTED_MODULE_3__["map"])(function (b, ii) {
              return resultSelector(a, b, i, ii);
            }));
          }));
        };
      }

      return function (source) {
        return source.lift(new SwitchMapOperator(project));
      };
    }

    var SwitchMapOperator = /*#__PURE__*/function () {
      function SwitchMapOperator(project) {
        _classCallCheck(this, SwitchMapOperator);

        this.project = project;
      }

      _createClass2(SwitchMapOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new SwitchMapSubscriber(subscriber, this.project));
        }
      }]);

      return SwitchMapOperator;
    }();

    var SwitchMapSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB22) {
      _inherits(SwitchMapSubscriber, _OuterSubscriber__WEB22);

      var _super182 = _createSuper(SwitchMapSubscriber);

      function SwitchMapSubscriber(destination, project) {
        var _this389;

        _classCallCheck(this, SwitchMapSubscriber);

        _this389 = _super182.call(this, destination);
        _this389.project = project;
        _this389.index = 0;
        return _this389;
      }

      _createClass2(SwitchMapSubscriber, [{
        key: "_next",
        value: function _next(value) {
          var result;
          var index = this.index++;

          try {
            result = this.project(value, index);
          } catch (error) {
            this.destination.error(error);
            return;
          }

          this._innerSub(result, value, index);
        }
      }, {
        key: "_innerSub",
        value: function _innerSub(result, value, index) {
          var innerSubscription = this.innerSubscription;

          if (innerSubscription) {
            innerSubscription.unsubscribe();
          }

          var innerSubscriber = new _InnerSubscriber__WEBPACK_IMPORTED_MODULE_1__["InnerSubscriber"](this, value, index);
          var destination = this.destination;
          destination.add(innerSubscriber);
          this.innerSubscription = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_2__["subscribeToResult"])(this, result, undefined, undefined, innerSubscriber);

          if (this.innerSubscription !== innerSubscriber) {
            destination.add(this.innerSubscription);
          }
        }
      }, {
        key: "_complete",
        value: function _complete() {
          var innerSubscription = this.innerSubscription;

          if (!innerSubscription || innerSubscription.closed) {
            _get(_getPrototypeOf(SwitchMapSubscriber.prototype), "_complete", this).call(this);
          }

          this.unsubscribe();
        }
      }, {
        key: "_unsubscribe",
        value: function _unsubscribe() {
          this.innerSubscription = null;
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete(innerSub) {
          var destination = this.destination;
          destination.remove(innerSub);
          this.innerSubscription = null;

          if (this.isStopped) {
            _get(_getPrototypeOf(SwitchMapSubscriber.prototype), "_complete", this).call(this);
          }
        }
      }, {
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          this.destination.next(innerValue);
        }
      }]);

      return SwitchMapSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__["OuterSubscriber"]); //# sourceMappingURL=switchMap.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/switchMapTo.js":
  /*!**********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/switchMapTo.js ***!
    \**********************************************************************/

  /*! exports provided: switchMapTo */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsSwitchMapToJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "switchMapTo", function () {
      return switchMapTo;
    });
    /* harmony import */


    var _switchMap__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./switchMap */
    "./node_modules/rxjs/_esm2015/internal/operators/switchMap.js");

    function switchMapTo(innerObservable, resultSelector) {
      return resultSelector ? Object(_switchMap__WEBPACK_IMPORTED_MODULE_0__["switchMap"])(function () {
        return innerObservable;
      }, resultSelector) : Object(_switchMap__WEBPACK_IMPORTED_MODULE_0__["switchMap"])(function () {
        return innerObservable;
      });
    } //# sourceMappingURL=switchMapTo.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/take.js":
  /*!***************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/take.js ***!
    \***************************************************************/

  /*! exports provided: take */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsTakeJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "take", function () {
      return take;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _util_ArgumentOutOfRangeError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/ArgumentOutOfRangeError */
    "./node_modules/rxjs/_esm2015/internal/util/ArgumentOutOfRangeError.js");
    /* harmony import */


    var _observable_empty__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../observable/empty */
    "./node_modules/rxjs/_esm2015/internal/observable/empty.js");

    function take(count) {
      return function (source) {
        if (count === 0) {
          return Object(_observable_empty__WEBPACK_IMPORTED_MODULE_2__["empty"])();
        } else {
          return source.lift(new TakeOperator(count));
        }
      };
    }

    var TakeOperator = /*#__PURE__*/function () {
      function TakeOperator(total) {
        _classCallCheck(this, TakeOperator);

        this.total = total;

        if (this.total < 0) {
          throw new _util_ArgumentOutOfRangeError__WEBPACK_IMPORTED_MODULE_1__["ArgumentOutOfRangeError"]();
        }
      }

      _createClass2(TakeOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new TakeSubscriber(subscriber, this.total));
        }
      }]);

      return TakeOperator;
    }();

    var TakeSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_40) {
      _inherits(TakeSubscriber, _Subscriber__WEBPACK_40);

      var _super183 = _createSuper(TakeSubscriber);

      function TakeSubscriber(destination, total) {
        var _this390;

        _classCallCheck(this, TakeSubscriber);

        _this390 = _super183.call(this, destination);
        _this390.total = total;
        _this390.count = 0;
        return _this390;
      }

      _createClass2(TakeSubscriber, [{
        key: "_next",
        value: function _next(value) {
          var total = this.total;
          var count = ++this.count;

          if (count <= total) {
            this.destination.next(value);

            if (count === total) {
              this.destination.complete();
              this.unsubscribe();
            }
          }
        }
      }]);

      return TakeSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=take.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/takeLast.js":
  /*!*******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/takeLast.js ***!
    \*******************************************************************/

  /*! exports provided: takeLast */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsTakeLastJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "takeLast", function () {
      return takeLast;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _util_ArgumentOutOfRangeError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/ArgumentOutOfRangeError */
    "./node_modules/rxjs/_esm2015/internal/util/ArgumentOutOfRangeError.js");
    /* harmony import */


    var _observable_empty__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../observable/empty */
    "./node_modules/rxjs/_esm2015/internal/observable/empty.js");

    function takeLast(count) {
      return function takeLastOperatorFunction(source) {
        if (count === 0) {
          return Object(_observable_empty__WEBPACK_IMPORTED_MODULE_2__["empty"])();
        } else {
          return source.lift(new TakeLastOperator(count));
        }
      };
    }

    var TakeLastOperator = /*#__PURE__*/function () {
      function TakeLastOperator(total) {
        _classCallCheck(this, TakeLastOperator);

        this.total = total;

        if (this.total < 0) {
          throw new _util_ArgumentOutOfRangeError__WEBPACK_IMPORTED_MODULE_1__["ArgumentOutOfRangeError"]();
        }
      }

      _createClass2(TakeLastOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new TakeLastSubscriber(subscriber, this.total));
        }
      }]);

      return TakeLastOperator;
    }();

    var TakeLastSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_41) {
      _inherits(TakeLastSubscriber, _Subscriber__WEBPACK_41);

      var _super184 = _createSuper(TakeLastSubscriber);

      function TakeLastSubscriber(destination, total) {
        var _this391;

        _classCallCheck(this, TakeLastSubscriber);

        _this391 = _super184.call(this, destination);
        _this391.total = total;
        _this391.ring = new Array();
        _this391.count = 0;
        return _this391;
      }

      _createClass2(TakeLastSubscriber, [{
        key: "_next",
        value: function _next(value) {
          var ring = this.ring;
          var total = this.total;
          var count = this.count++;

          if (ring.length < total) {
            ring.push(value);
          } else {
            var index = count % total;
            ring[index] = value;
          }
        }
      }, {
        key: "_complete",
        value: function _complete() {
          var destination = this.destination;
          var count = this.count;

          if (count > 0) {
            var total = this.count >= this.total ? this.total : this.count;
            var ring = this.ring;

            for (var i = 0; i < total; i++) {
              var idx = count++ % total;
              destination.next(ring[idx]);
            }
          }

          destination.complete();
        }
      }]);

      return TakeLastSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=takeLast.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/takeUntil.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/takeUntil.js ***!
    \********************************************************************/

  /*! exports provided: takeUntil */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsTakeUntilJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "takeUntil", function () {
      return takeUntil;
    });
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function takeUntil(notifier) {
      return function (source) {
        return source.lift(new TakeUntilOperator(notifier));
      };
    }

    var TakeUntilOperator = /*#__PURE__*/function () {
      function TakeUntilOperator(notifier) {
        _classCallCheck(this, TakeUntilOperator);

        this.notifier = notifier;
      }

      _createClass2(TakeUntilOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          var takeUntilSubscriber = new TakeUntilSubscriber(subscriber);
          var notifierSubscription = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__["subscribeToResult"])(takeUntilSubscriber, this.notifier);

          if (notifierSubscription && !takeUntilSubscriber.seenValue) {
            takeUntilSubscriber.add(notifierSubscription);
            return source.subscribe(takeUntilSubscriber);
          }

          return takeUntilSubscriber;
        }
      }]);

      return TakeUntilOperator;
    }();

    var TakeUntilSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB23) {
      _inherits(TakeUntilSubscriber, _OuterSubscriber__WEB23);

      var _super185 = _createSuper(TakeUntilSubscriber);

      function TakeUntilSubscriber(destination) {
        var _this392;

        _classCallCheck(this, TakeUntilSubscriber);

        _this392 = _super185.call(this, destination);
        _this392.seenValue = false;
        return _this392;
      }

      _createClass2(TakeUntilSubscriber, [{
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          this.seenValue = true;
          this.complete();
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete() {}
      }]);

      return TakeUntilSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__["OuterSubscriber"]); //# sourceMappingURL=takeUntil.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/takeWhile.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/takeWhile.js ***!
    \********************************************************************/

  /*! exports provided: takeWhile */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsTakeWhileJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "takeWhile", function () {
      return takeWhile;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function takeWhile(predicate) {
      var inclusive = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
      return function (source) {
        return source.lift(new TakeWhileOperator(predicate, inclusive));
      };
    }

    var TakeWhileOperator = /*#__PURE__*/function () {
      function TakeWhileOperator(predicate, inclusive) {
        _classCallCheck(this, TakeWhileOperator);

        this.predicate = predicate;
        this.inclusive = inclusive;
      }

      _createClass2(TakeWhileOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new TakeWhileSubscriber(subscriber, this.predicate, this.inclusive));
        }
      }]);

      return TakeWhileOperator;
    }();

    var TakeWhileSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_42) {
      _inherits(TakeWhileSubscriber, _Subscriber__WEBPACK_42);

      var _super186 = _createSuper(TakeWhileSubscriber);

      function TakeWhileSubscriber(destination, predicate, inclusive) {
        var _this393;

        _classCallCheck(this, TakeWhileSubscriber);

        _this393 = _super186.call(this, destination);
        _this393.predicate = predicate;
        _this393.inclusive = inclusive;
        _this393.index = 0;
        return _this393;
      }

      _createClass2(TakeWhileSubscriber, [{
        key: "_next",
        value: function _next(value) {
          var destination = this.destination;
          var result;

          try {
            result = this.predicate(value, this.index++);
          } catch (err) {
            destination.error(err);
            return;
          }

          this.nextOrComplete(value, result);
        }
      }, {
        key: "nextOrComplete",
        value: function nextOrComplete(value, predicateResult) {
          var destination = this.destination;

          if (Boolean(predicateResult)) {
            destination.next(value);
          } else {
            if (this.inclusive) {
              destination.next(value);
            }

            destination.complete();
          }
        }
      }]);

      return TakeWhileSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=takeWhile.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/tap.js":
  /*!**************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/tap.js ***!
    \**************************************************************/

  /*! exports provided: tap */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsTapJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "tap", function () {
      return tap;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _util_noop__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/noop */
    "./node_modules/rxjs/_esm2015/internal/util/noop.js");
    /* harmony import */


    var _util_isFunction__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../util/isFunction */
    "./node_modules/rxjs/_esm2015/internal/util/isFunction.js");

    function tap(nextOrObserver, error, complete) {
      return function tapOperatorFunction(source) {
        return source.lift(new DoOperator(nextOrObserver, error, complete));
      };
    }

    var DoOperator = /*#__PURE__*/function () {
      function DoOperator(nextOrObserver, error, complete) {
        _classCallCheck(this, DoOperator);

        this.nextOrObserver = nextOrObserver;
        this.error = error;
        this.complete = complete;
      }

      _createClass2(DoOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new TapSubscriber(subscriber, this.nextOrObserver, this.error, this.complete));
        }
      }]);

      return DoOperator;
    }();

    var TapSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_43) {
      _inherits(TapSubscriber, _Subscriber__WEBPACK_43);

      var _super187 = _createSuper(TapSubscriber);

      function TapSubscriber(destination, observerOrNext, error, complete) {
        var _this394;

        _classCallCheck(this, TapSubscriber);

        _this394 = _super187.call(this, destination);
        _this394._tapNext = _util_noop__WEBPACK_IMPORTED_MODULE_1__["noop"];
        _this394._tapError = _util_noop__WEBPACK_IMPORTED_MODULE_1__["noop"];
        _this394._tapComplete = _util_noop__WEBPACK_IMPORTED_MODULE_1__["noop"];
        _this394._tapError = error || _util_noop__WEBPACK_IMPORTED_MODULE_1__["noop"];
        _this394._tapComplete = complete || _util_noop__WEBPACK_IMPORTED_MODULE_1__["noop"];

        if (Object(_util_isFunction__WEBPACK_IMPORTED_MODULE_2__["isFunction"])(observerOrNext)) {
          _this394._context = _assertThisInitialized(_this394);
          _this394._tapNext = observerOrNext;
        } else if (observerOrNext) {
          _this394._context = observerOrNext;
          _this394._tapNext = observerOrNext.next || _util_noop__WEBPACK_IMPORTED_MODULE_1__["noop"];
          _this394._tapError = observerOrNext.error || _util_noop__WEBPACK_IMPORTED_MODULE_1__["noop"];
          _this394._tapComplete = observerOrNext.complete || _util_noop__WEBPACK_IMPORTED_MODULE_1__["noop"];
        }

        return _this394;
      }

      _createClass2(TapSubscriber, [{
        key: "_next",
        value: function _next(value) {
          try {
            this._tapNext.call(this._context, value);
          } catch (err) {
            this.destination.error(err);
            return;
          }

          this.destination.next(value);
        }
      }, {
        key: "_error",
        value: function _error(err) {
          try {
            this._tapError.call(this._context, err);
          } catch (err) {
            this.destination.error(err);
            return;
          }

          this.destination.error(err);
        }
      }, {
        key: "_complete",
        value: function _complete() {
          try {
            this._tapComplete.call(this._context);
          } catch (err) {
            this.destination.error(err);
            return;
          }

          return this.destination.complete();
        }
      }]);

      return TapSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=tap.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/throttle.js":
  /*!*******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/throttle.js ***!
    \*******************************************************************/

  /*! exports provided: defaultThrottleConfig, throttle */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsThrottleJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "defaultThrottleConfig", function () {
      return defaultThrottleConfig;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "throttle", function () {
      return throttle;
    });
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    var defaultThrottleConfig = {
      leading: true,
      trailing: false
    };

    function throttle(durationSelector) {
      var config = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : defaultThrottleConfig;
      return function (source) {
        return source.lift(new ThrottleOperator(durationSelector, config.leading, config.trailing));
      };
    }

    var ThrottleOperator = /*#__PURE__*/function () {
      function ThrottleOperator(durationSelector, leading, trailing) {
        _classCallCheck(this, ThrottleOperator);

        this.durationSelector = durationSelector;
        this.leading = leading;
        this.trailing = trailing;
      }

      _createClass2(ThrottleOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new ThrottleSubscriber(subscriber, this.durationSelector, this.leading, this.trailing));
        }
      }]);

      return ThrottleOperator;
    }();

    var ThrottleSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB24) {
      _inherits(ThrottleSubscriber, _OuterSubscriber__WEB24);

      var _super188 = _createSuper(ThrottleSubscriber);

      function ThrottleSubscriber(destination, durationSelector, _leading, _trailing) {
        var _this395;

        _classCallCheck(this, ThrottleSubscriber);

        _this395 = _super188.call(this, destination);
        _this395.destination = destination;
        _this395.durationSelector = durationSelector;
        _this395._leading = _leading;
        _this395._trailing = _trailing;
        _this395._hasValue = false;
        return _this395;
      }

      _createClass2(ThrottleSubscriber, [{
        key: "_next",
        value: function _next(value) {
          this._hasValue = true;
          this._sendValue = value;

          if (!this._throttled) {
            if (this._leading) {
              this.send();
            } else {
              this.throttle(value);
            }
          }
        }
      }, {
        key: "send",
        value: function send() {
          var _hasValue = this._hasValue,
              _sendValue = this._sendValue;

          if (_hasValue) {
            this.destination.next(_sendValue);
            this.throttle(_sendValue);
          }

          this._hasValue = false;
          this._sendValue = null;
        }
      }, {
        key: "throttle",
        value: function throttle(value) {
          var duration = this.tryDurationSelector(value);

          if (!!duration) {
            this.add(this._throttled = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__["subscribeToResult"])(this, duration));
          }
        }
      }, {
        key: "tryDurationSelector",
        value: function tryDurationSelector(value) {
          try {
            return this.durationSelector(value);
          } catch (err) {
            this.destination.error(err);
            return null;
          }
        }
      }, {
        key: "throttlingDone",
        value: function throttlingDone() {
          var _throttled = this._throttled,
              _trailing = this._trailing;

          if (_throttled) {
            _throttled.unsubscribe();
          }

          this._throttled = null;

          if (_trailing) {
            this.send();
          }
        }
      }, {
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          this.throttlingDone();
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete() {
          this.throttlingDone();
        }
      }]);

      return ThrottleSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__["OuterSubscriber"]); //# sourceMappingURL=throttle.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/throttleTime.js":
  /*!***********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/throttleTime.js ***!
    \***********************************************************************/

  /*! exports provided: throttleTime */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsThrottleTimeJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "throttleTime", function () {
      return throttleTime;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _scheduler_async__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../scheduler/async */
    "./node_modules/rxjs/_esm2015/internal/scheduler/async.js");
    /* harmony import */


    var _throttle__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ./throttle */
    "./node_modules/rxjs/_esm2015/internal/operators/throttle.js");

    function throttleTime(duration) {
      var scheduler = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : _scheduler_async__WEBPACK_IMPORTED_MODULE_1__["async"];
      var config = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : _throttle__WEBPACK_IMPORTED_MODULE_2__["defaultThrottleConfig"];
      return function (source) {
        return source.lift(new ThrottleTimeOperator(duration, scheduler, config.leading, config.trailing));
      };
    }

    var ThrottleTimeOperator = /*#__PURE__*/function () {
      function ThrottleTimeOperator(duration, scheduler, leading, trailing) {
        _classCallCheck(this, ThrottleTimeOperator);

        this.duration = duration;
        this.scheduler = scheduler;
        this.leading = leading;
        this.trailing = trailing;
      }

      _createClass2(ThrottleTimeOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new ThrottleTimeSubscriber(subscriber, this.duration, this.scheduler, this.leading, this.trailing));
        }
      }]);

      return ThrottleTimeOperator;
    }();

    var ThrottleTimeSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_44) {
      _inherits(ThrottleTimeSubscriber, _Subscriber__WEBPACK_44);

      var _super189 = _createSuper(ThrottleTimeSubscriber);

      function ThrottleTimeSubscriber(destination, duration, scheduler, leading, trailing) {
        var _this396;

        _classCallCheck(this, ThrottleTimeSubscriber);

        _this396 = _super189.call(this, destination);
        _this396.duration = duration;
        _this396.scheduler = scheduler;
        _this396.leading = leading;
        _this396.trailing = trailing;
        _this396._hasTrailingValue = false;
        _this396._trailingValue = null;
        return _this396;
      }

      _createClass2(ThrottleTimeSubscriber, [{
        key: "_next",
        value: function _next(value) {
          if (this.throttled) {
            if (this.trailing) {
              this._trailingValue = value;
              this._hasTrailingValue = true;
            }
          } else {
            this.add(this.throttled = this.scheduler.schedule(dispatchNext, this.duration, {
              subscriber: this
            }));

            if (this.leading) {
              this.destination.next(value);
            } else if (this.trailing) {
              this._trailingValue = value;
              this._hasTrailingValue = true;
            }
          }
        }
      }, {
        key: "_complete",
        value: function _complete() {
          if (this._hasTrailingValue) {
            this.destination.next(this._trailingValue);
            this.destination.complete();
          } else {
            this.destination.complete();
          }
        }
      }, {
        key: "clearThrottle",
        value: function clearThrottle() {
          var throttled = this.throttled;

          if (throttled) {
            if (this.trailing && this._hasTrailingValue) {
              this.destination.next(this._trailingValue);
              this._trailingValue = null;
              this._hasTrailingValue = false;
            }

            throttled.unsubscribe();
            this.remove(throttled);
            this.throttled = null;
          }
        }
      }]);

      return ThrottleTimeSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]);

    function dispatchNext(arg) {
      var subscriber = arg.subscriber;
      subscriber.clearThrottle();
    } //# sourceMappingURL=throttleTime.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/throwIfEmpty.js":
  /*!***********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/throwIfEmpty.js ***!
    \***********************************************************************/

  /*! exports provided: throwIfEmpty */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsThrowIfEmptyJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "throwIfEmpty", function () {
      return throwIfEmpty;
    });
    /* harmony import */


    var _util_EmptyError__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../util/EmptyError */
    "./node_modules/rxjs/_esm2015/internal/util/EmptyError.js");
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function throwIfEmpty() {
      var errorFactory = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : defaultErrorFactory;
      return function (source) {
        return source.lift(new ThrowIfEmptyOperator(errorFactory));
      };
    }

    var ThrowIfEmptyOperator = /*#__PURE__*/function () {
      function ThrowIfEmptyOperator(errorFactory) {
        _classCallCheck(this, ThrowIfEmptyOperator);

        this.errorFactory = errorFactory;
      }

      _createClass2(ThrowIfEmptyOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new ThrowIfEmptySubscriber(subscriber, this.errorFactory));
        }
      }]);

      return ThrowIfEmptyOperator;
    }();

    var ThrowIfEmptySubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_45) {
      _inherits(ThrowIfEmptySubscriber, _Subscriber__WEBPACK_45);

      var _super190 = _createSuper(ThrowIfEmptySubscriber);

      function ThrowIfEmptySubscriber(destination, errorFactory) {
        var _this397;

        _classCallCheck(this, ThrowIfEmptySubscriber);

        _this397 = _super190.call(this, destination);
        _this397.errorFactory = errorFactory;
        _this397.hasValue = false;
        return _this397;
      }

      _createClass2(ThrowIfEmptySubscriber, [{
        key: "_next",
        value: function _next(value) {
          this.hasValue = true;
          this.destination.next(value);
        }
      }, {
        key: "_complete",
        value: function _complete() {
          if (!this.hasValue) {
            var _err;

            try {
              _err = this.errorFactory();
            } catch (e) {
              _err = e;
            }

            this.destination.error(_err);
          } else {
            return this.destination.complete();
          }
        }
      }]);

      return ThrowIfEmptySubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_1__["Subscriber"]);

    function defaultErrorFactory() {
      return new _util_EmptyError__WEBPACK_IMPORTED_MODULE_0__["EmptyError"]();
    } //# sourceMappingURL=throwIfEmpty.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/timeInterval.js":
  /*!***********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/timeInterval.js ***!
    \***********************************************************************/

  /*! exports provided: timeInterval, TimeInterval */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsTimeIntervalJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "timeInterval", function () {
      return timeInterval;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "TimeInterval", function () {
      return TimeInterval;
    });
    /* harmony import */


    var _scheduler_async__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../scheduler/async */
    "./node_modules/rxjs/_esm2015/internal/scheduler/async.js");
    /* harmony import */


    var _scan__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./scan */
    "./node_modules/rxjs/_esm2015/internal/operators/scan.js");
    /* harmony import */


    var _observable_defer__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../observable/defer */
    "./node_modules/rxjs/_esm2015/internal/observable/defer.js");
    /* harmony import */


    var _map__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ./map */
    "./node_modules/rxjs/_esm2015/internal/operators/map.js");

    function timeInterval() {
      var scheduler = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : _scheduler_async__WEBPACK_IMPORTED_MODULE_0__["async"];
      return function (source) {
        return Object(_observable_defer__WEBPACK_IMPORTED_MODULE_2__["defer"])(function () {
          return source.pipe(Object(_scan__WEBPACK_IMPORTED_MODULE_1__["scan"])(function (_ref19, value) {
            var current = _ref19.current;
            return {
              value: value,
              current: scheduler.now(),
              last: current
            };
          }, {
            current: scheduler.now(),
            value: undefined,
            last: undefined
          }), Object(_map__WEBPACK_IMPORTED_MODULE_3__["map"])(function (_ref20) {
            var current = _ref20.current,
                last = _ref20.last,
                value = _ref20.value;
            return new TimeInterval(value, current - last);
          }));
        });
      };
    }

    var TimeInterval = function TimeInterval(value, interval) {
      _classCallCheck(this, TimeInterval);

      this.value = value;
      this.interval = interval;
    }; //# sourceMappingURL=timeInterval.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/timeout.js":
  /*!******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/timeout.js ***!
    \******************************************************************/

  /*! exports provided: timeout */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsTimeoutJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "timeout", function () {
      return timeout;
    });
    /* harmony import */


    var _scheduler_async__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../scheduler/async */
    "./node_modules/rxjs/_esm2015/internal/scheduler/async.js");
    /* harmony import */


    var _util_TimeoutError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/TimeoutError */
    "./node_modules/rxjs/_esm2015/internal/util/TimeoutError.js");
    /* harmony import */


    var _timeoutWith__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ./timeoutWith */
    "./node_modules/rxjs/_esm2015/internal/operators/timeoutWith.js");
    /* harmony import */


    var _observable_throwError__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../observable/throwError */
    "./node_modules/rxjs/_esm2015/internal/observable/throwError.js");

    function timeout(due) {
      var scheduler = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : _scheduler_async__WEBPACK_IMPORTED_MODULE_0__["async"];
      return Object(_timeoutWith__WEBPACK_IMPORTED_MODULE_2__["timeoutWith"])(due, Object(_observable_throwError__WEBPACK_IMPORTED_MODULE_3__["throwError"])(new _util_TimeoutError__WEBPACK_IMPORTED_MODULE_1__["TimeoutError"]()), scheduler);
    } //# sourceMappingURL=timeout.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/timeoutWith.js":
  /*!**********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/timeoutWith.js ***!
    \**********************************************************************/

  /*! exports provided: timeoutWith */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsTimeoutWithJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "timeoutWith", function () {
      return timeoutWith;
    });
    /* harmony import */


    var _scheduler_async__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../scheduler/async */
    "./node_modules/rxjs/_esm2015/internal/scheduler/async.js");
    /* harmony import */


    var _util_isDate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/isDate */
    "./node_modules/rxjs/_esm2015/internal/util/isDate.js");
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function timeoutWith(due, withObservable) {
      var scheduler = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : _scheduler_async__WEBPACK_IMPORTED_MODULE_0__["async"];
      return function (source) {
        var absoluteTimeout = Object(_util_isDate__WEBPACK_IMPORTED_MODULE_1__["isDate"])(due);
        var waitFor = absoluteTimeout ? +due - scheduler.now() : Math.abs(due);
        return source.lift(new TimeoutWithOperator(waitFor, absoluteTimeout, withObservable, scheduler));
      };
    }

    var TimeoutWithOperator = /*#__PURE__*/function () {
      function TimeoutWithOperator(waitFor, absoluteTimeout, withObservable, scheduler) {
        _classCallCheck(this, TimeoutWithOperator);

        this.waitFor = waitFor;
        this.absoluteTimeout = absoluteTimeout;
        this.withObservable = withObservable;
        this.scheduler = scheduler;
      }

      _createClass2(TimeoutWithOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new TimeoutWithSubscriber(subscriber, this.absoluteTimeout, this.waitFor, this.withObservable, this.scheduler));
        }
      }]);

      return TimeoutWithOperator;
    }();

    var TimeoutWithSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB25) {
      _inherits(TimeoutWithSubscriber, _OuterSubscriber__WEB25);

      var _super191 = _createSuper(TimeoutWithSubscriber);

      function TimeoutWithSubscriber(destination, absoluteTimeout, waitFor, withObservable, scheduler) {
        var _this398;

        _classCallCheck(this, TimeoutWithSubscriber);

        _this398 = _super191.call(this, destination);
        _this398.absoluteTimeout = absoluteTimeout;
        _this398.waitFor = waitFor;
        _this398.withObservable = withObservable;
        _this398.scheduler = scheduler;
        _this398.action = null;

        _this398.scheduleTimeout();

        return _this398;
      }

      _createClass2(TimeoutWithSubscriber, [{
        key: "scheduleTimeout",
        value: function scheduleTimeout() {
          var action = this.action;

          if (action) {
            this.action = action.schedule(this, this.waitFor);
          } else {
            this.add(this.action = this.scheduler.schedule(TimeoutWithSubscriber.dispatchTimeout, this.waitFor, this));
          }
        }
      }, {
        key: "_next",
        value: function _next(value) {
          if (!this.absoluteTimeout) {
            this.scheduleTimeout();
          }

          _get(_getPrototypeOf(TimeoutWithSubscriber.prototype), "_next", this).call(this, value);
        }
      }, {
        key: "_unsubscribe",
        value: function _unsubscribe() {
          this.action = null;
          this.scheduler = null;
          this.withObservable = null;
        }
      }], [{
        key: "dispatchTimeout",
        value: function dispatchTimeout(subscriber) {
          var withObservable = subscriber.withObservable;

          subscriber._unsubscribeAndRecycle();

          subscriber.add(Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_3__["subscribeToResult"])(subscriber, withObservable));
        }
      }]);

      return TimeoutWithSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__["OuterSubscriber"]); //# sourceMappingURL=timeoutWith.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/timestamp.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/timestamp.js ***!
    \********************************************************************/

  /*! exports provided: timestamp, Timestamp */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsTimestampJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "timestamp", function () {
      return timestamp;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Timestamp", function () {
      return Timestamp;
    });
    /* harmony import */


    var _scheduler_async__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../scheduler/async */
    "./node_modules/rxjs/_esm2015/internal/scheduler/async.js");
    /* harmony import */


    var _map__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./map */
    "./node_modules/rxjs/_esm2015/internal/operators/map.js");

    function timestamp() {
      var scheduler = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : _scheduler_async__WEBPACK_IMPORTED_MODULE_0__["async"];
      return Object(_map__WEBPACK_IMPORTED_MODULE_1__["map"])(function (value) {
        return new Timestamp(value, scheduler.now());
      });
    }

    var Timestamp = function Timestamp(value, timestamp) {
      _classCallCheck(this, Timestamp);

      this.value = value;
      this.timestamp = timestamp;
    }; //# sourceMappingURL=timestamp.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/toArray.js":
  /*!******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/toArray.js ***!
    \******************************************************************/

  /*! exports provided: toArray */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsToArrayJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "toArray", function () {
      return toArray;
    });
    /* harmony import */


    var _reduce__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./reduce */
    "./node_modules/rxjs/_esm2015/internal/operators/reduce.js");

    function toArrayReducer(arr, item, index) {
      if (index === 0) {
        return [item];
      }

      arr.push(item);
      return arr;
    }

    function toArray() {
      return Object(_reduce__WEBPACK_IMPORTED_MODULE_0__["reduce"])(toArrayReducer, []);
    } //# sourceMappingURL=toArray.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/window.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/window.js ***!
    \*****************************************************************/

  /*! exports provided: window */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsWindowJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "window", function () {
      return window;
    });
    /* harmony import */


    var _Subject__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subject */
    "./node_modules/rxjs/_esm2015/internal/Subject.js");
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function window(windowBoundaries) {
      return function windowOperatorFunction(source) {
        return source.lift(new WindowOperator(windowBoundaries));
      };
    }

    var WindowOperator = /*#__PURE__*/function () {
      function WindowOperator(windowBoundaries) {
        _classCallCheck(this, WindowOperator);

        this.windowBoundaries = windowBoundaries;
      }

      _createClass2(WindowOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          var windowSubscriber = new WindowSubscriber(subscriber);
          var sourceSubscription = source.subscribe(windowSubscriber);

          if (!sourceSubscription.closed) {
            windowSubscriber.add(Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_2__["subscribeToResult"])(windowSubscriber, this.windowBoundaries));
          }

          return sourceSubscription;
        }
      }]);

      return WindowOperator;
    }();

    var WindowSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB26) {
      _inherits(WindowSubscriber, _OuterSubscriber__WEB26);

      var _super192 = _createSuper(WindowSubscriber);

      function WindowSubscriber(destination) {
        var _this399;

        _classCallCheck(this, WindowSubscriber);

        _this399 = _super192.call(this, destination);
        _this399.window = new _Subject__WEBPACK_IMPORTED_MODULE_0__["Subject"]();
        destination.next(_this399.window);
        return _this399;
      }

      _createClass2(WindowSubscriber, [{
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          this.openWindow();
        }
      }, {
        key: "notifyError",
        value: function notifyError(error, innerSub) {
          this._error(error);
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete(innerSub) {
          this._complete();
        }
      }, {
        key: "_next",
        value: function _next(value) {
          this.window.next(value);
        }
      }, {
        key: "_error",
        value: function _error(err) {
          this.window.error(err);
          this.destination.error(err);
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.window.complete();
          this.destination.complete();
        }
      }, {
        key: "_unsubscribe",
        value: function _unsubscribe() {
          this.window = null;
        }
      }, {
        key: "openWindow",
        value: function openWindow() {
          var prevWindow = this.window;

          if (prevWindow) {
            prevWindow.complete();
          }

          var destination = this.destination;
          var newWindow = this.window = new _Subject__WEBPACK_IMPORTED_MODULE_0__["Subject"]();
          destination.next(newWindow);
        }
      }]);

      return WindowSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_1__["OuterSubscriber"]); //# sourceMappingURL=window.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/windowCount.js":
  /*!**********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/windowCount.js ***!
    \**********************************************************************/

  /*! exports provided: windowCount */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsWindowCountJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "windowCount", function () {
      return windowCount;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _Subject__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../Subject */
    "./node_modules/rxjs/_esm2015/internal/Subject.js");

    function windowCount(windowSize) {
      var startWindowEvery = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
      return function windowCountOperatorFunction(source) {
        return source.lift(new WindowCountOperator(windowSize, startWindowEvery));
      };
    }

    var WindowCountOperator = /*#__PURE__*/function () {
      function WindowCountOperator(windowSize, startWindowEvery) {
        _classCallCheck(this, WindowCountOperator);

        this.windowSize = windowSize;
        this.startWindowEvery = startWindowEvery;
      }

      _createClass2(WindowCountOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new WindowCountSubscriber(subscriber, this.windowSize, this.startWindowEvery));
        }
      }]);

      return WindowCountOperator;
    }();

    var WindowCountSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_46) {
      _inherits(WindowCountSubscriber, _Subscriber__WEBPACK_46);

      var _super193 = _createSuper(WindowCountSubscriber);

      function WindowCountSubscriber(destination, windowSize, startWindowEvery) {
        var _this400;

        _classCallCheck(this, WindowCountSubscriber);

        _this400 = _super193.call(this, destination);
        _this400.destination = destination;
        _this400.windowSize = windowSize;
        _this400.startWindowEvery = startWindowEvery;
        _this400.windows = [new _Subject__WEBPACK_IMPORTED_MODULE_1__["Subject"]()];
        _this400.count = 0;
        destination.next(_this400.windows[0]);
        return _this400;
      }

      _createClass2(WindowCountSubscriber, [{
        key: "_next",
        value: function _next(value) {
          var startWindowEvery = this.startWindowEvery > 0 ? this.startWindowEvery : this.windowSize;
          var destination = this.destination;
          var windowSize = this.windowSize;
          var windows = this.windows;
          var len = windows.length;

          for (var i = 0; i < len && !this.closed; i++) {
            windows[i].next(value);
          }

          var c = this.count - windowSize + 1;

          if (c >= 0 && c % startWindowEvery === 0 && !this.closed) {
            windows.shift().complete();
          }

          if (++this.count % startWindowEvery === 0 && !this.closed) {
            var _window2 = new _Subject__WEBPACK_IMPORTED_MODULE_1__["Subject"]();

            windows.push(_window2);
            destination.next(_window2);
          }
        }
      }, {
        key: "_error",
        value: function _error(err) {
          var windows = this.windows;

          if (windows) {
            while (windows.length > 0 && !this.closed) {
              windows.shift().error(err);
            }
          }

          this.destination.error(err);
        }
      }, {
        key: "_complete",
        value: function _complete() {
          var windows = this.windows;

          if (windows) {
            while (windows.length > 0 && !this.closed) {
              windows.shift().complete();
            }
          }

          this.destination.complete();
        }
      }, {
        key: "_unsubscribe",
        value: function _unsubscribe() {
          this.count = 0;
          this.windows = null;
        }
      }]);

      return WindowCountSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]); //# sourceMappingURL=windowCount.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/windowTime.js":
  /*!*********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/windowTime.js ***!
    \*********************************************************************/

  /*! exports provided: windowTime */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsWindowTimeJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "windowTime", function () {
      return windowTime;
    });
    /* harmony import */


    var _Subject__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subject */
    "./node_modules/rxjs/_esm2015/internal/Subject.js");
    /* harmony import */


    var _scheduler_async__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../scheduler/async */
    "./node_modules/rxjs/_esm2015/internal/scheduler/async.js");
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _util_isNumeric__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../util/isNumeric */
    "./node_modules/rxjs/_esm2015/internal/util/isNumeric.js");
    /* harmony import */


    var _util_isScheduler__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ../util/isScheduler */
    "./node_modules/rxjs/_esm2015/internal/util/isScheduler.js");

    function windowTime(windowTimeSpan) {
      var scheduler = _scheduler_async__WEBPACK_IMPORTED_MODULE_1__["async"];
      var windowCreationInterval = null;
      var maxWindowSize = Number.POSITIVE_INFINITY;

      if (Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_4__["isScheduler"])(arguments[3])) {
        scheduler = arguments[3];
      }

      if (Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_4__["isScheduler"])(arguments[2])) {
        scheduler = arguments[2];
      } else if (Object(_util_isNumeric__WEBPACK_IMPORTED_MODULE_3__["isNumeric"])(arguments[2])) {
        maxWindowSize = arguments[2];
      }

      if (Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_4__["isScheduler"])(arguments[1])) {
        scheduler = arguments[1];
      } else if (Object(_util_isNumeric__WEBPACK_IMPORTED_MODULE_3__["isNumeric"])(arguments[1])) {
        windowCreationInterval = arguments[1];
      }

      return function windowTimeOperatorFunction(source) {
        return source.lift(new WindowTimeOperator(windowTimeSpan, windowCreationInterval, maxWindowSize, scheduler));
      };
    }

    var WindowTimeOperator = /*#__PURE__*/function () {
      function WindowTimeOperator(windowTimeSpan, windowCreationInterval, maxWindowSize, scheduler) {
        _classCallCheck(this, WindowTimeOperator);

        this.windowTimeSpan = windowTimeSpan;
        this.windowCreationInterval = windowCreationInterval;
        this.maxWindowSize = maxWindowSize;
        this.scheduler = scheduler;
      }

      _createClass2(WindowTimeOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new WindowTimeSubscriber(subscriber, this.windowTimeSpan, this.windowCreationInterval, this.maxWindowSize, this.scheduler));
        }
      }]);

      return WindowTimeOperator;
    }();

    var CountedSubject = /*#__PURE__*/function (_Subject__WEBPACK_IMP5) {
      _inherits(CountedSubject, _Subject__WEBPACK_IMP5);

      var _super194 = _createSuper(CountedSubject);

      function CountedSubject() {
        var _this401;

        _classCallCheck(this, CountedSubject);

        _this401 = _super194.apply(this, arguments);
        _this401._numberOfNextedValues = 0;
        return _this401;
      }

      _createClass2(CountedSubject, [{
        key: "next",
        value: function next(value) {
          this._numberOfNextedValues++;

          _get(_getPrototypeOf(CountedSubject.prototype), "next", this).call(this, value);
        }
      }, {
        key: "numberOfNextedValues",
        get: function get() {
          return this._numberOfNextedValues;
        }
      }]);

      return CountedSubject;
    }(_Subject__WEBPACK_IMPORTED_MODULE_0__["Subject"]);

    var WindowTimeSubscriber = /*#__PURE__*/function (_Subscriber__WEBPACK_47) {
      _inherits(WindowTimeSubscriber, _Subscriber__WEBPACK_47);

      var _super195 = _createSuper(WindowTimeSubscriber);

      function WindowTimeSubscriber(destination, windowTimeSpan, windowCreationInterval, maxWindowSize, scheduler) {
        var _this402;

        _classCallCheck(this, WindowTimeSubscriber);

        _this402 = _super195.call(this, destination);
        _this402.destination = destination;
        _this402.windowTimeSpan = windowTimeSpan;
        _this402.windowCreationInterval = windowCreationInterval;
        _this402.maxWindowSize = maxWindowSize;
        _this402.scheduler = scheduler;
        _this402.windows = [];

        var window = _this402.openWindow();

        if (windowCreationInterval !== null && windowCreationInterval >= 0) {
          var closeState = {
            subscriber: _assertThisInitialized(_this402),
            window: window,
            context: null
          };
          var creationState = {
            windowTimeSpan: windowTimeSpan,
            windowCreationInterval: windowCreationInterval,
            subscriber: _assertThisInitialized(_this402),
            scheduler: scheduler
          };

          _this402.add(scheduler.schedule(dispatchWindowClose, windowTimeSpan, closeState));

          _this402.add(scheduler.schedule(dispatchWindowCreation, windowCreationInterval, creationState));
        } else {
          var timeSpanOnlyState = {
            subscriber: _assertThisInitialized(_this402),
            window: window,
            windowTimeSpan: windowTimeSpan
          };

          _this402.add(scheduler.schedule(dispatchWindowTimeSpanOnly, windowTimeSpan, timeSpanOnlyState));
        }

        return _this402;
      }

      _createClass2(WindowTimeSubscriber, [{
        key: "_next",
        value: function _next(value) {
          var windows = this.windows;
          var len = windows.length;

          for (var i = 0; i < len; i++) {
            var _window3 = windows[i];

            if (!_window3.closed) {
              _window3.next(value);

              if (_window3.numberOfNextedValues >= this.maxWindowSize) {
                this.closeWindow(_window3);
              }
            }
          }
        }
      }, {
        key: "_error",
        value: function _error(err) {
          var windows = this.windows;

          while (windows.length > 0) {
            windows.shift().error(err);
          }

          this.destination.error(err);
        }
      }, {
        key: "_complete",
        value: function _complete() {
          var windows = this.windows;

          while (windows.length > 0) {
            var _window4 = windows.shift();

            if (!_window4.closed) {
              _window4.complete();
            }
          }

          this.destination.complete();
        }
      }, {
        key: "openWindow",
        value: function openWindow() {
          var window = new CountedSubject();
          this.windows.push(window);
          var destination = this.destination;
          destination.next(window);
          return window;
        }
      }, {
        key: "closeWindow",
        value: function closeWindow(window) {
          window.complete();
          var windows = this.windows;
          windows.splice(windows.indexOf(window), 1);
        }
      }]);

      return WindowTimeSubscriber;
    }(_Subscriber__WEBPACK_IMPORTED_MODULE_2__["Subscriber"]);

    function dispatchWindowTimeSpanOnly(state) {
      var subscriber = state.subscriber,
          windowTimeSpan = state.windowTimeSpan,
          window = state.window;

      if (window) {
        subscriber.closeWindow(window);
      }

      state.window = subscriber.openWindow();
      this.schedule(state, windowTimeSpan);
    }

    function dispatchWindowCreation(state) {
      var windowTimeSpan = state.windowTimeSpan,
          subscriber = state.subscriber,
          scheduler = state.scheduler,
          windowCreationInterval = state.windowCreationInterval;
      var window = subscriber.openWindow();
      var action = this;
      var context = {
        action: action,
        subscription: null
      };
      var timeSpanState = {
        subscriber: subscriber,
        window: window,
        context: context
      };
      context.subscription = scheduler.schedule(dispatchWindowClose, windowTimeSpan, timeSpanState);
      action.add(context.subscription);
      action.schedule(state, windowCreationInterval);
    }

    function dispatchWindowClose(state) {
      var subscriber = state.subscriber,
          window = state.window,
          context = state.context;

      if (context && context.action && context.subscription) {
        context.action.remove(context.subscription);
      }

      subscriber.closeWindow(window);
    } //# sourceMappingURL=windowTime.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/windowToggle.js":
  /*!***********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/windowToggle.js ***!
    \***********************************************************************/

  /*! exports provided: windowToggle */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsWindowToggleJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "windowToggle", function () {
      return windowToggle;
    });
    /* harmony import */


    var _Subject__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subject */
    "./node_modules/rxjs/_esm2015/internal/Subject.js");
    /* harmony import */


    var _Subscription__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../Subscription */
    "./node_modules/rxjs/_esm2015/internal/Subscription.js");
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function windowToggle(openings, closingSelector) {
      return function (source) {
        return source.lift(new WindowToggleOperator(openings, closingSelector));
      };
    }

    var WindowToggleOperator = /*#__PURE__*/function () {
      function WindowToggleOperator(openings, closingSelector) {
        _classCallCheck(this, WindowToggleOperator);

        this.openings = openings;
        this.closingSelector = closingSelector;
      }

      _createClass2(WindowToggleOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new WindowToggleSubscriber(subscriber, this.openings, this.closingSelector));
        }
      }]);

      return WindowToggleOperator;
    }();

    var WindowToggleSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB27) {
      _inherits(WindowToggleSubscriber, _OuterSubscriber__WEB27);

      var _super196 = _createSuper(WindowToggleSubscriber);

      function WindowToggleSubscriber(destination, openings, closingSelector) {
        var _this403;

        _classCallCheck(this, WindowToggleSubscriber);

        _this403 = _super196.call(this, destination);
        _this403.openings = openings;
        _this403.closingSelector = closingSelector;
        _this403.contexts = [];

        _this403.add(_this403.openSubscription = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_3__["subscribeToResult"])(_assertThisInitialized(_this403), openings, openings));

        return _this403;
      }

      _createClass2(WindowToggleSubscriber, [{
        key: "_next",
        value: function _next(value) {
          var contexts = this.contexts;

          if (contexts) {
            var _len57 = contexts.length;

            for (var i = 0; i < _len57; i++) {
              contexts[i].window.next(value);
            }
          }
        }
      }, {
        key: "_error",
        value: function _error(err) {
          var contexts = this.contexts;
          this.contexts = null;

          if (contexts) {
            var _len58 = contexts.length;
            var index = -1;

            while (++index < _len58) {
              var context = contexts[index];
              context.window.error(err);
              context.subscription.unsubscribe();
            }
          }

          _get(_getPrototypeOf(WindowToggleSubscriber.prototype), "_error", this).call(this, err);
        }
      }, {
        key: "_complete",
        value: function _complete() {
          var contexts = this.contexts;
          this.contexts = null;

          if (contexts) {
            var _len59 = contexts.length;
            var index = -1;

            while (++index < _len59) {
              var context = contexts[index];
              context.window.complete();
              context.subscription.unsubscribe();
            }
          }

          _get(_getPrototypeOf(WindowToggleSubscriber.prototype), "_complete", this).call(this);
        }
      }, {
        key: "_unsubscribe",
        value: function _unsubscribe() {
          var contexts = this.contexts;
          this.contexts = null;

          if (contexts) {
            var _len60 = contexts.length;
            var index = -1;

            while (++index < _len60) {
              var context = contexts[index];
              context.window.unsubscribe();
              context.subscription.unsubscribe();
            }
          }
        }
      }, {
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          if (outerValue === this.openings) {
            var closingNotifier;

            try {
              var closingSelector = this.closingSelector;
              closingNotifier = closingSelector(innerValue);
            } catch (e) {
              return this.error(e);
            }

            var _window5 = new _Subject__WEBPACK_IMPORTED_MODULE_0__["Subject"]();

            var subscription = new _Subscription__WEBPACK_IMPORTED_MODULE_1__["Subscription"]();
            var context = {
              window: _window5,
              subscription: subscription
            };
            this.contexts.push(context);
            var innerSubscription = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_3__["subscribeToResult"])(this, closingNotifier, context);

            if (innerSubscription.closed) {
              this.closeWindow(this.contexts.length - 1);
            } else {
              innerSubscription.context = context;
              subscription.add(innerSubscription);
            }

            this.destination.next(_window5);
          } else {
            this.closeWindow(this.contexts.indexOf(outerValue));
          }
        }
      }, {
        key: "notifyError",
        value: function notifyError(err) {
          this.error(err);
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete(inner) {
          if (inner !== this.openSubscription) {
            this.closeWindow(this.contexts.indexOf(inner.context));
          }
        }
      }, {
        key: "closeWindow",
        value: function closeWindow(index) {
          if (index === -1) {
            return;
          }

          var contexts = this.contexts;
          var context = contexts[index];
          var window = context.window,
              subscription = context.subscription;
          contexts.splice(index, 1);
          window.complete();
          subscription.unsubscribe();
        }
      }]);

      return WindowToggleSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__["OuterSubscriber"]); //# sourceMappingURL=windowToggle.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/windowWhen.js":
  /*!*********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/windowWhen.js ***!
    \*********************************************************************/

  /*! exports provided: windowWhen */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsWindowWhenJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "windowWhen", function () {
      return windowWhen;
    });
    /* harmony import */


    var _Subject__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subject */
    "./node_modules/rxjs/_esm2015/internal/Subject.js");
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function windowWhen(closingSelector) {
      return function windowWhenOperatorFunction(source) {
        return source.lift(new WindowOperator(closingSelector));
      };
    }

    var WindowOperator = /*#__PURE__*/function () {
      function WindowOperator(closingSelector) {
        _classCallCheck(this, WindowOperator);

        this.closingSelector = closingSelector;
      }

      _createClass2(WindowOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new WindowSubscriber(subscriber, this.closingSelector));
        }
      }]);

      return WindowOperator;
    }();

    var WindowSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB28) {
      _inherits(WindowSubscriber, _OuterSubscriber__WEB28);

      var _super197 = _createSuper(WindowSubscriber);

      function WindowSubscriber(destination, closingSelector) {
        var _this404;

        _classCallCheck(this, WindowSubscriber);

        _this404 = _super197.call(this, destination);
        _this404.destination = destination;
        _this404.closingSelector = closingSelector;

        _this404.openWindow();

        return _this404;
      }

      _createClass2(WindowSubscriber, [{
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          this.openWindow(innerSub);
        }
      }, {
        key: "notifyError",
        value: function notifyError(error, innerSub) {
          this._error(error);
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete(innerSub) {
          this.openWindow(innerSub);
        }
      }, {
        key: "_next",
        value: function _next(value) {
          this.window.next(value);
        }
      }, {
        key: "_error",
        value: function _error(err) {
          this.window.error(err);
          this.destination.error(err);
          this.unsubscribeClosingNotification();
        }
      }, {
        key: "_complete",
        value: function _complete() {
          this.window.complete();
          this.destination.complete();
          this.unsubscribeClosingNotification();
        }
      }, {
        key: "unsubscribeClosingNotification",
        value: function unsubscribeClosingNotification() {
          if (this.closingNotification) {
            this.closingNotification.unsubscribe();
          }
        }
      }, {
        key: "openWindow",
        value: function openWindow() {
          var innerSub = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;

          if (innerSub) {
            this.remove(innerSub);
            innerSub.unsubscribe();
          }

          var prevWindow = this.window;

          if (prevWindow) {
            prevWindow.complete();
          }

          var window = this.window = new _Subject__WEBPACK_IMPORTED_MODULE_0__["Subject"]();
          this.destination.next(window);
          var closingNotifier;

          try {
            var closingSelector = this.closingSelector;
            closingNotifier = closingSelector();
          } catch (e) {
            this.destination.error(e);
            this.window.error(e);
            return;
          }

          this.add(this.closingNotification = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_2__["subscribeToResult"])(this, closingNotifier));
        }
      }]);

      return WindowSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_1__["OuterSubscriber"]); //# sourceMappingURL=windowWhen.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/withLatestFrom.js":
  /*!*************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/withLatestFrom.js ***!
    \*************************************************************************/

  /*! exports provided: withLatestFrom */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsWithLatestFromJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "withLatestFrom", function () {
      return withLatestFrom;
    });
    /* harmony import */


    var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../OuterSubscriber */
    "./node_modules/rxjs/_esm2015/internal/OuterSubscriber.js");
    /* harmony import */


    var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../util/subscribeToResult */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js");

    function withLatestFrom() {
      for (var _len61 = arguments.length, args = new Array(_len61), _key55 = 0; _key55 < _len61; _key55++) {
        args[_key55] = arguments[_key55];
      }

      return function (source) {
        var project;

        if (typeof args[args.length - 1] === 'function') {
          project = args.pop();
        }

        var observables = args;
        return source.lift(new WithLatestFromOperator(observables, project));
      };
    }

    var WithLatestFromOperator = /*#__PURE__*/function () {
      function WithLatestFromOperator(observables, project) {
        _classCallCheck(this, WithLatestFromOperator);

        this.observables = observables;
        this.project = project;
      }

      _createClass2(WithLatestFromOperator, [{
        key: "call",
        value: function call(subscriber, source) {
          return source.subscribe(new WithLatestFromSubscriber(subscriber, this.observables, this.project));
        }
      }]);

      return WithLatestFromOperator;
    }();

    var WithLatestFromSubscriber = /*#__PURE__*/function (_OuterSubscriber__WEB29) {
      _inherits(WithLatestFromSubscriber, _OuterSubscriber__WEB29);

      var _super198 = _createSuper(WithLatestFromSubscriber);

      function WithLatestFromSubscriber(destination, observables, project) {
        var _this405;

        _classCallCheck(this, WithLatestFromSubscriber);

        _this405 = _super198.call(this, destination);
        _this405.observables = observables;
        _this405.project = project;
        _this405.toRespond = [];
        var len = observables.length;
        _this405.values = new Array(len);

        for (var i = 0; i < len; i++) {
          _this405.toRespond.push(i);
        }

        for (var _i32 = 0; _i32 < len; _i32++) {
          var observable = observables[_i32];

          _this405.add(Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__["subscribeToResult"])(_assertThisInitialized(_this405), observable, observable, _i32));
        }

        return _this405;
      }

      _createClass2(WithLatestFromSubscriber, [{
        key: "notifyNext",
        value: function notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {
          this.values[outerIndex] = innerValue;
          var toRespond = this.toRespond;

          if (toRespond.length > 0) {
            var found = toRespond.indexOf(outerIndex);

            if (found !== -1) {
              toRespond.splice(found, 1);
            }
          }
        }
      }, {
        key: "notifyComplete",
        value: function notifyComplete() {}
      }, {
        key: "_next",
        value: function _next(value) {
          if (this.toRespond.length === 0) {
            var args = [value].concat(_toConsumableArray(this.values));

            if (this.project) {
              this._tryProject(args);
            } else {
              this.destination.next(args);
            }
          }
        }
      }, {
        key: "_tryProject",
        value: function _tryProject(args) {
          var result;

          try {
            result = this.project.apply(this, args);
          } catch (err) {
            this.destination.error(err);
            return;
          }

          this.destination.next(result);
        }
      }]);

      return WithLatestFromSubscriber;
    }(_OuterSubscriber__WEBPACK_IMPORTED_MODULE_0__["OuterSubscriber"]); //# sourceMappingURL=withLatestFrom.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/zip.js":
  /*!**************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/zip.js ***!
    \**************************************************************/

  /*! exports provided: zip */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsZipJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "zip", function () {
      return zip;
    });
    /* harmony import */


    var _observable_zip__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../observable/zip */
    "./node_modules/rxjs/_esm2015/internal/observable/zip.js");

    function zip() {
      for (var _len62 = arguments.length, observables = new Array(_len62), _key56 = 0; _key56 < _len62; _key56++) {
        observables[_key56] = arguments[_key56];
      }

      return function zipOperatorFunction(source) {
        return source.lift.call(Object(_observable_zip__WEBPACK_IMPORTED_MODULE_0__["zip"]).apply(void 0, [source].concat(observables)));
      };
    } //# sourceMappingURL=zip.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/operators/zipAll.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/operators/zipAll.js ***!
    \*****************************************************************/

  /*! exports provided: zipAll */

  /***/
  function node_modulesRxjs_esm2015InternalOperatorsZipAllJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "zipAll", function () {
      return zipAll;
    });
    /* harmony import */


    var _observable_zip__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../observable/zip */
    "./node_modules/rxjs/_esm2015/internal/observable/zip.js");

    function zipAll(project) {
      return function (source) {
        return source.lift(new _observable_zip__WEBPACK_IMPORTED_MODULE_0__["ZipOperator"](project));
      };
    } //# sourceMappingURL=zipAll.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/scheduled/scheduleArray.js":
  /*!************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/scheduled/scheduleArray.js ***!
    \************************************************************************/

  /*! exports provided: scheduleArray */

  /***/
  function node_modulesRxjs_esm2015InternalScheduledScheduleArrayJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "scheduleArray", function () {
      return scheduleArray;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _Subscription__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../Subscription */
    "./node_modules/rxjs/_esm2015/internal/Subscription.js");

    function scheduleArray(input, scheduler) {
      return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
        var sub = new _Subscription__WEBPACK_IMPORTED_MODULE_1__["Subscription"]();
        var i = 0;
        sub.add(scheduler.schedule(function () {
          if (i === input.length) {
            subscriber.complete();
            return;
          }

          subscriber.next(input[i++]);

          if (!subscriber.closed) {
            sub.add(this.schedule());
          }
        }));
        return sub;
      });
    } //# sourceMappingURL=scheduleArray.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/scheduled/scheduleIterable.js":
  /*!***************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/scheduled/scheduleIterable.js ***!
    \***************************************************************************/

  /*! exports provided: scheduleIterable */

  /***/
  function node_modulesRxjs_esm2015InternalScheduledScheduleIterableJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "scheduleIterable", function () {
      return scheduleIterable;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _Subscription__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../Subscription */
    "./node_modules/rxjs/_esm2015/internal/Subscription.js");
    /* harmony import */


    var _symbol_iterator__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../symbol/iterator */
    "./node_modules/rxjs/_esm2015/internal/symbol/iterator.js");

    function scheduleIterable(input, scheduler) {
      if (!input) {
        throw new Error('Iterable cannot be null');
      }

      return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
        var sub = new _Subscription__WEBPACK_IMPORTED_MODULE_1__["Subscription"]();
        var iterator;
        sub.add(function () {
          if (iterator && typeof iterator["return"] === 'function') {
            iterator["return"]();
          }
        });
        sub.add(scheduler.schedule(function () {
          iterator = input[_symbol_iterator__WEBPACK_IMPORTED_MODULE_2__["iterator"]]();
          sub.add(scheduler.schedule(function () {
            if (subscriber.closed) {
              return;
            }

            var value;
            var done;

            try {
              var result = iterator.next();
              value = result.value;
              done = result.done;
            } catch (err) {
              subscriber.error(err);
              return;
            }

            if (done) {
              subscriber.complete();
            } else {
              subscriber.next(value);
              this.schedule();
            }
          }));
        }));
        return sub;
      });
    } //# sourceMappingURL=scheduleIterable.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/scheduled/scheduleObservable.js":
  /*!*****************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/scheduled/scheduleObservable.js ***!
    \*****************************************************************************/

  /*! exports provided: scheduleObservable */

  /***/
  function node_modulesRxjs_esm2015InternalScheduledScheduleObservableJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "scheduleObservable", function () {
      return scheduleObservable;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _Subscription__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../Subscription */
    "./node_modules/rxjs/_esm2015/internal/Subscription.js");
    /* harmony import */


    var _symbol_observable__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../symbol/observable */
    "./node_modules/rxjs/_esm2015/internal/symbol/observable.js");

    function scheduleObservable(input, scheduler) {
      return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
        var sub = new _Subscription__WEBPACK_IMPORTED_MODULE_1__["Subscription"]();
        sub.add(scheduler.schedule(function () {
          var observable = input[_symbol_observable__WEBPACK_IMPORTED_MODULE_2__["observable"]]();

          sub.add(observable.subscribe({
            next: function next(value) {
              sub.add(scheduler.schedule(function () {
                return subscriber.next(value);
              }));
            },
            error: function error(err) {
              sub.add(scheduler.schedule(function () {
                return subscriber.error(err);
              }));
            },
            complete: function complete() {
              sub.add(scheduler.schedule(function () {
                return subscriber.complete();
              }));
            }
          }));
        }));
        return sub;
      });
    } //# sourceMappingURL=scheduleObservable.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/scheduled/schedulePromise.js":
  /*!**************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/scheduled/schedulePromise.js ***!
    \**************************************************************************/

  /*! exports provided: schedulePromise */

  /***/
  function node_modulesRxjs_esm2015InternalScheduledSchedulePromiseJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "schedulePromise", function () {
      return schedulePromise;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");
    /* harmony import */


    var _Subscription__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../Subscription */
    "./node_modules/rxjs/_esm2015/internal/Subscription.js");

    function schedulePromise(input, scheduler) {
      return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](function (subscriber) {
        var sub = new _Subscription__WEBPACK_IMPORTED_MODULE_1__["Subscription"]();
        sub.add(scheduler.schedule(function () {
          return input.then(function (value) {
            sub.add(scheduler.schedule(function () {
              subscriber.next(value);
              sub.add(scheduler.schedule(function () {
                return subscriber.complete();
              }));
            }));
          }, function (err) {
            sub.add(scheduler.schedule(function () {
              return subscriber.error(err);
            }));
          });
        }));
        return sub;
      });
    } //# sourceMappingURL=schedulePromise.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/scheduled/scheduled.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/scheduled/scheduled.js ***!
    \********************************************************************/

  /*! exports provided: scheduled */

  /***/
  function node_modulesRxjs_esm2015InternalScheduledScheduledJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "scheduled", function () {
      return scheduled;
    });
    /* harmony import */


    var _scheduleObservable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./scheduleObservable */
    "./node_modules/rxjs/_esm2015/internal/scheduled/scheduleObservable.js");
    /* harmony import */


    var _schedulePromise__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./schedulePromise */
    "./node_modules/rxjs/_esm2015/internal/scheduled/schedulePromise.js");
    /* harmony import */


    var _scheduleArray__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ./scheduleArray */
    "./node_modules/rxjs/_esm2015/internal/scheduled/scheduleArray.js");
    /* harmony import */


    var _scheduleIterable__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ./scheduleIterable */
    "./node_modules/rxjs/_esm2015/internal/scheduled/scheduleIterable.js");
    /* harmony import */


    var _util_isInteropObservable__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ../util/isInteropObservable */
    "./node_modules/rxjs/_esm2015/internal/util/isInteropObservable.js");
    /* harmony import */


    var _util_isPromise__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(
    /*! ../util/isPromise */
    "./node_modules/rxjs/_esm2015/internal/util/isPromise.js");
    /* harmony import */


    var _util_isArrayLike__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(
    /*! ../util/isArrayLike */
    "./node_modules/rxjs/_esm2015/internal/util/isArrayLike.js");
    /* harmony import */


    var _util_isIterable__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(
    /*! ../util/isIterable */
    "./node_modules/rxjs/_esm2015/internal/util/isIterable.js");

    function scheduled(input, scheduler) {
      if (input != null) {
        if (Object(_util_isInteropObservable__WEBPACK_IMPORTED_MODULE_4__["isInteropObservable"])(input)) {
          return Object(_scheduleObservable__WEBPACK_IMPORTED_MODULE_0__["scheduleObservable"])(input, scheduler);
        } else if (Object(_util_isPromise__WEBPACK_IMPORTED_MODULE_5__["isPromise"])(input)) {
          return Object(_schedulePromise__WEBPACK_IMPORTED_MODULE_1__["schedulePromise"])(input, scheduler);
        } else if (Object(_util_isArrayLike__WEBPACK_IMPORTED_MODULE_6__["isArrayLike"])(input)) {
          return Object(_scheduleArray__WEBPACK_IMPORTED_MODULE_2__["scheduleArray"])(input, scheduler);
        } else if (Object(_util_isIterable__WEBPACK_IMPORTED_MODULE_7__["isIterable"])(input) || typeof input === 'string') {
          return Object(_scheduleIterable__WEBPACK_IMPORTED_MODULE_3__["scheduleIterable"])(input, scheduler);
        }
      }

      throw new TypeError((input !== null && typeof input || input) + ' is not observable');
    } //# sourceMappingURL=scheduled.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/scheduler/Action.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/scheduler/Action.js ***!
    \*****************************************************************/

  /*! exports provided: Action */

  /***/
  function node_modulesRxjs_esm2015InternalSchedulerActionJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Action", function () {
      return Action;
    });
    /* harmony import */


    var _Subscription__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscription */
    "./node_modules/rxjs/_esm2015/internal/Subscription.js");

    var Action = /*#__PURE__*/function (_Subscription__WEBPAC4) {
      _inherits(Action, _Subscription__WEBPAC4);

      var _super199 = _createSuper(Action);

      function Action(scheduler, work) {
        _classCallCheck(this, Action);

        return _super199.call(this);
      }

      _createClass2(Action, [{
        key: "schedule",
        value: function schedule(state) {
          var delay = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
          return this;
        }
      }]);

      return Action;
    }(_Subscription__WEBPACK_IMPORTED_MODULE_0__["Subscription"]); //# sourceMappingURL=Action.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/scheduler/AnimationFrameAction.js":
  /*!*******************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/scheduler/AnimationFrameAction.js ***!
    \*******************************************************************************/

  /*! exports provided: AnimationFrameAction */

  /***/
  function node_modulesRxjs_esm2015InternalSchedulerAnimationFrameActionJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AnimationFrameAction", function () {
      return AnimationFrameAction;
    });
    /* harmony import */


    var _AsyncAction__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./AsyncAction */
    "./node_modules/rxjs/_esm2015/internal/scheduler/AsyncAction.js");

    var AnimationFrameAction = /*#__PURE__*/function (_AsyncAction__WEBPACK) {
      _inherits(AnimationFrameAction, _AsyncAction__WEBPACK);

      var _super200 = _createSuper(AnimationFrameAction);

      function AnimationFrameAction(scheduler, work) {
        var _this406;

        _classCallCheck(this, AnimationFrameAction);

        _this406 = _super200.call(this, scheduler, work);
        _this406.scheduler = scheduler;
        _this406.work = work;
        return _this406;
      }

      _createClass2(AnimationFrameAction, [{
        key: "requestAsyncId",
        value: function requestAsyncId(scheduler, id) {
          var delay = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;

          if (delay !== null && delay > 0) {
            return _get(_getPrototypeOf(AnimationFrameAction.prototype), "requestAsyncId", this).call(this, scheduler, id, delay);
          }

          scheduler.actions.push(this);
          return scheduler.scheduled || (scheduler.scheduled = requestAnimationFrame(function () {
            return scheduler.flush(null);
          }));
        }
      }, {
        key: "recycleAsyncId",
        value: function recycleAsyncId(scheduler, id) {
          var delay = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;

          if (delay !== null && delay > 0 || delay === null && this.delay > 0) {
            return _get(_getPrototypeOf(AnimationFrameAction.prototype), "recycleAsyncId", this).call(this, scheduler, id, delay);
          }

          if (scheduler.actions.length === 0) {
            cancelAnimationFrame(id);
            scheduler.scheduled = undefined;
          }

          return undefined;
        }
      }]);

      return AnimationFrameAction;
    }(_AsyncAction__WEBPACK_IMPORTED_MODULE_0__["AsyncAction"]); //# sourceMappingURL=AnimationFrameAction.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/scheduler/AnimationFrameScheduler.js":
  /*!**********************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/scheduler/AnimationFrameScheduler.js ***!
    \**********************************************************************************/

  /*! exports provided: AnimationFrameScheduler */

  /***/
  function node_modulesRxjs_esm2015InternalSchedulerAnimationFrameSchedulerJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AnimationFrameScheduler", function () {
      return AnimationFrameScheduler;
    });
    /* harmony import */


    var _AsyncScheduler__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./AsyncScheduler */
    "./node_modules/rxjs/_esm2015/internal/scheduler/AsyncScheduler.js");

    var AnimationFrameScheduler = /*#__PURE__*/function (_AsyncScheduler__WEBP) {
      _inherits(AnimationFrameScheduler, _AsyncScheduler__WEBP);

      var _super201 = _createSuper(AnimationFrameScheduler);

      function AnimationFrameScheduler() {
        _classCallCheck(this, AnimationFrameScheduler);

        return _super201.apply(this, arguments);
      }

      _createClass2(AnimationFrameScheduler, [{
        key: "flush",
        value: function flush(action) {
          this.active = true;
          this.scheduled = undefined;
          var actions = this.actions;
          var error;
          var index = -1;
          var count = actions.length;
          action = action || actions.shift();

          do {
            if (error = action.execute(action.state, action.delay)) {
              break;
            }
          } while (++index < count && (action = actions.shift()));

          this.active = false;

          if (error) {
            while (++index < count && (action = actions.shift())) {
              action.unsubscribe();
            }

            throw error;
          }
        }
      }]);

      return AnimationFrameScheduler;
    }(_AsyncScheduler__WEBPACK_IMPORTED_MODULE_0__["AsyncScheduler"]); //# sourceMappingURL=AnimationFrameScheduler.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/scheduler/AsapAction.js":
  /*!*********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/scheduler/AsapAction.js ***!
    \*********************************************************************/

  /*! exports provided: AsapAction */

  /***/
  function node_modulesRxjs_esm2015InternalSchedulerAsapActionJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AsapAction", function () {
      return AsapAction;
    });
    /* harmony import */


    var _util_Immediate__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../util/Immediate */
    "./node_modules/rxjs/_esm2015/internal/util/Immediate.js");
    /* harmony import */


    var _AsyncAction__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./AsyncAction */
    "./node_modules/rxjs/_esm2015/internal/scheduler/AsyncAction.js");

    var AsapAction = /*#__PURE__*/function (_AsyncAction__WEBPACK2) {
      _inherits(AsapAction, _AsyncAction__WEBPACK2);

      var _super202 = _createSuper(AsapAction);

      function AsapAction(scheduler, work) {
        var _this407;

        _classCallCheck(this, AsapAction);

        _this407 = _super202.call(this, scheduler, work);
        _this407.scheduler = scheduler;
        _this407.work = work;
        return _this407;
      }

      _createClass2(AsapAction, [{
        key: "requestAsyncId",
        value: function requestAsyncId(scheduler, id) {
          var delay = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;

          if (delay !== null && delay > 0) {
            return _get(_getPrototypeOf(AsapAction.prototype), "requestAsyncId", this).call(this, scheduler, id, delay);
          }

          scheduler.actions.push(this);
          return scheduler.scheduled || (scheduler.scheduled = _util_Immediate__WEBPACK_IMPORTED_MODULE_0__["Immediate"].setImmediate(scheduler.flush.bind(scheduler, null)));
        }
      }, {
        key: "recycleAsyncId",
        value: function recycleAsyncId(scheduler, id) {
          var delay = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;

          if (delay !== null && delay > 0 || delay === null && this.delay > 0) {
            return _get(_getPrototypeOf(AsapAction.prototype), "recycleAsyncId", this).call(this, scheduler, id, delay);
          }

          if (scheduler.actions.length === 0) {
            _util_Immediate__WEBPACK_IMPORTED_MODULE_0__["Immediate"].clearImmediate(id);

            scheduler.scheduled = undefined;
          }

          return undefined;
        }
      }]);

      return AsapAction;
    }(_AsyncAction__WEBPACK_IMPORTED_MODULE_1__["AsyncAction"]); //# sourceMappingURL=AsapAction.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/scheduler/AsapScheduler.js":
  /*!************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/scheduler/AsapScheduler.js ***!
    \************************************************************************/

  /*! exports provided: AsapScheduler */

  /***/
  function node_modulesRxjs_esm2015InternalSchedulerAsapSchedulerJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AsapScheduler", function () {
      return AsapScheduler;
    });
    /* harmony import */


    var _AsyncScheduler__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./AsyncScheduler */
    "./node_modules/rxjs/_esm2015/internal/scheduler/AsyncScheduler.js");

    var AsapScheduler = /*#__PURE__*/function (_AsyncScheduler__WEBP2) {
      _inherits(AsapScheduler, _AsyncScheduler__WEBP2);

      var _super203 = _createSuper(AsapScheduler);

      function AsapScheduler() {
        _classCallCheck(this, AsapScheduler);

        return _super203.apply(this, arguments);
      }

      _createClass2(AsapScheduler, [{
        key: "flush",
        value: function flush(action) {
          this.active = true;
          this.scheduled = undefined;
          var actions = this.actions;
          var error;
          var index = -1;
          var count = actions.length;
          action = action || actions.shift();

          do {
            if (error = action.execute(action.state, action.delay)) {
              break;
            }
          } while (++index < count && (action = actions.shift()));

          this.active = false;

          if (error) {
            while (++index < count && (action = actions.shift())) {
              action.unsubscribe();
            }

            throw error;
          }
        }
      }]);

      return AsapScheduler;
    }(_AsyncScheduler__WEBPACK_IMPORTED_MODULE_0__["AsyncScheduler"]); //# sourceMappingURL=AsapScheduler.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/scheduler/AsyncAction.js":
  /*!**********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/scheduler/AsyncAction.js ***!
    \**********************************************************************/

  /*! exports provided: AsyncAction */

  /***/
  function node_modulesRxjs_esm2015InternalSchedulerAsyncActionJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AsyncAction", function () {
      return AsyncAction;
    });
    /* harmony import */


    var _Action__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./Action */
    "./node_modules/rxjs/_esm2015/internal/scheduler/Action.js");

    var AsyncAction = /*#__PURE__*/function (_Action__WEBPACK_IMPO) {
      _inherits(AsyncAction, _Action__WEBPACK_IMPO);

      var _super204 = _createSuper(AsyncAction);

      function AsyncAction(scheduler, work) {
        var _this408;

        _classCallCheck(this, AsyncAction);

        _this408 = _super204.call(this, scheduler, work);
        _this408.scheduler = scheduler;
        _this408.work = work;
        _this408.pending = false;
        return _this408;
      }

      _createClass2(AsyncAction, [{
        key: "schedule",
        value: function schedule(state) {
          var delay = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;

          if (this.closed) {
            return this;
          }

          this.state = state;
          var id = this.id;
          var scheduler = this.scheduler;

          if (id != null) {
            this.id = this.recycleAsyncId(scheduler, id, delay);
          }

          this.pending = true;
          this.delay = delay;
          this.id = this.id || this.requestAsyncId(scheduler, this.id, delay);
          return this;
        }
      }, {
        key: "requestAsyncId",
        value: function requestAsyncId(scheduler, id) {
          var delay = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;
          return setInterval(scheduler.flush.bind(scheduler, this), delay);
        }
      }, {
        key: "recycleAsyncId",
        value: function recycleAsyncId(scheduler, id) {
          var delay = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;

          if (delay !== null && this.delay === delay && this.pending === false) {
            return id;
          }

          clearInterval(id);
          return undefined;
        }
      }, {
        key: "execute",
        value: function execute(state, delay) {
          if (this.closed) {
            return new Error('executing a cancelled action');
          }

          this.pending = false;

          var error = this._execute(state, delay);

          if (error) {
            return error;
          } else if (this.pending === false && this.id != null) {
            this.id = this.recycleAsyncId(this.scheduler, this.id, null);
          }
        }
      }, {
        key: "_execute",
        value: function _execute(state, delay) {
          var errored = false;
          var errorValue = undefined;

          try {
            this.work(state);
          } catch (e) {
            errored = true;
            errorValue = !!e && e || new Error(e);
          }

          if (errored) {
            this.unsubscribe();
            return errorValue;
          }
        }
      }, {
        key: "_unsubscribe",
        value: function _unsubscribe() {
          var id = this.id;
          var scheduler = this.scheduler;
          var actions = scheduler.actions;
          var index = actions.indexOf(this);
          this.work = null;
          this.state = null;
          this.pending = false;
          this.scheduler = null;

          if (index !== -1) {
            actions.splice(index, 1);
          }

          if (id != null) {
            this.id = this.recycleAsyncId(scheduler, id, null);
          }

          this.delay = null;
        }
      }]);

      return AsyncAction;
    }(_Action__WEBPACK_IMPORTED_MODULE_0__["Action"]); //# sourceMappingURL=AsyncAction.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/scheduler/AsyncScheduler.js":
  /*!*************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/scheduler/AsyncScheduler.js ***!
    \*************************************************************************/

  /*! exports provided: AsyncScheduler */

  /***/
  function node_modulesRxjs_esm2015InternalSchedulerAsyncSchedulerJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "AsyncScheduler", function () {
      return AsyncScheduler;
    });
    /* harmony import */


    var _Scheduler__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Scheduler */
    "./node_modules/rxjs/_esm2015/internal/Scheduler.js");

    var AsyncScheduler = /*#__PURE__*/function (_Scheduler__WEBPACK_I) {
      _inherits(AsyncScheduler, _Scheduler__WEBPACK_I);

      var _super205 = _createSuper(AsyncScheduler);

      function AsyncScheduler(SchedulerAction) {
        var _this409;

        var now = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : _Scheduler__WEBPACK_IMPORTED_MODULE_0__["Scheduler"].now;

        _classCallCheck(this, AsyncScheduler);

        _this409 = _super205.call(this, SchedulerAction, function () {
          if (AsyncScheduler.delegate && AsyncScheduler.delegate !== _assertThisInitialized(_this409)) {
            return AsyncScheduler.delegate.now();
          } else {
            return now();
          }
        });
        _this409.actions = [];
        _this409.active = false;
        _this409.scheduled = undefined;
        return _this409;
      }

      _createClass2(AsyncScheduler, [{
        key: "schedule",
        value: function schedule(work) {
          var delay = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
          var state = arguments.length > 2 ? arguments[2] : undefined;

          if (AsyncScheduler.delegate && AsyncScheduler.delegate !== this) {
            return AsyncScheduler.delegate.schedule(work, delay, state);
          } else {
            return _get(_getPrototypeOf(AsyncScheduler.prototype), "schedule", this).call(this, work, delay, state);
          }
        }
      }, {
        key: "flush",
        value: function flush(action) {
          var actions = this.actions;

          if (this.active) {
            actions.push(action);
            return;
          }

          var error;
          this.active = true;

          do {
            if (error = action.execute(action.state, action.delay)) {
              break;
            }
          } while (action = actions.shift());

          this.active = false;

          if (error) {
            while (action = actions.shift()) {
              action.unsubscribe();
            }

            throw error;
          }
        }
      }]);

      return AsyncScheduler;
    }(_Scheduler__WEBPACK_IMPORTED_MODULE_0__["Scheduler"]); //# sourceMappingURL=AsyncScheduler.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/scheduler/QueueAction.js":
  /*!**********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/scheduler/QueueAction.js ***!
    \**********************************************************************/

  /*! exports provided: QueueAction */

  /***/
  function node_modulesRxjs_esm2015InternalSchedulerQueueActionJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "QueueAction", function () {
      return QueueAction;
    });
    /* harmony import */


    var _AsyncAction__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./AsyncAction */
    "./node_modules/rxjs/_esm2015/internal/scheduler/AsyncAction.js");

    var QueueAction = /*#__PURE__*/function (_AsyncAction__WEBPACK3) {
      _inherits(QueueAction, _AsyncAction__WEBPACK3);

      var _super206 = _createSuper(QueueAction);

      function QueueAction(scheduler, work) {
        var _this410;

        _classCallCheck(this, QueueAction);

        _this410 = _super206.call(this, scheduler, work);
        _this410.scheduler = scheduler;
        _this410.work = work;
        return _this410;
      }

      _createClass2(QueueAction, [{
        key: "schedule",
        value: function schedule(state) {
          var delay = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;

          if (delay > 0) {
            return _get(_getPrototypeOf(QueueAction.prototype), "schedule", this).call(this, state, delay);
          }

          this.delay = delay;
          this.state = state;
          this.scheduler.flush(this);
          return this;
        }
      }, {
        key: "execute",
        value: function execute(state, delay) {
          return delay > 0 || this.closed ? _get(_getPrototypeOf(QueueAction.prototype), "execute", this).call(this, state, delay) : this._execute(state, delay);
        }
      }, {
        key: "requestAsyncId",
        value: function requestAsyncId(scheduler, id) {
          var delay = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;

          if (delay !== null && delay > 0 || delay === null && this.delay > 0) {
            return _get(_getPrototypeOf(QueueAction.prototype), "requestAsyncId", this).call(this, scheduler, id, delay);
          }

          return scheduler.flush(this);
        }
      }]);

      return QueueAction;
    }(_AsyncAction__WEBPACK_IMPORTED_MODULE_0__["AsyncAction"]); //# sourceMappingURL=QueueAction.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/scheduler/QueueScheduler.js":
  /*!*************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/scheduler/QueueScheduler.js ***!
    \*************************************************************************/

  /*! exports provided: QueueScheduler */

  /***/
  function node_modulesRxjs_esm2015InternalSchedulerQueueSchedulerJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "QueueScheduler", function () {
      return QueueScheduler;
    });
    /* harmony import */


    var _AsyncScheduler__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./AsyncScheduler */
    "./node_modules/rxjs/_esm2015/internal/scheduler/AsyncScheduler.js");

    var QueueScheduler = /*#__PURE__*/function (_AsyncScheduler__WEBP3) {
      _inherits(QueueScheduler, _AsyncScheduler__WEBP3);

      var _super207 = _createSuper(QueueScheduler);

      function QueueScheduler() {
        _classCallCheck(this, QueueScheduler);

        return _super207.apply(this, arguments);
      }

      return QueueScheduler;
    }(_AsyncScheduler__WEBPACK_IMPORTED_MODULE_0__["AsyncScheduler"]); //# sourceMappingURL=QueueScheduler.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/scheduler/VirtualTimeScheduler.js":
  /*!*******************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/scheduler/VirtualTimeScheduler.js ***!
    \*******************************************************************************/

  /*! exports provided: VirtualTimeScheduler, VirtualAction */

  /***/
  function node_modulesRxjs_esm2015InternalSchedulerVirtualTimeSchedulerJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "VirtualTimeScheduler", function () {
      return VirtualTimeScheduler;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "VirtualAction", function () {
      return VirtualAction;
    });
    /* harmony import */


    var _AsyncAction__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./AsyncAction */
    "./node_modules/rxjs/_esm2015/internal/scheduler/AsyncAction.js");
    /* harmony import */


    var _AsyncScheduler__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./AsyncScheduler */
    "./node_modules/rxjs/_esm2015/internal/scheduler/AsyncScheduler.js");

    var VirtualTimeScheduler = /*#__PURE__*/function (_AsyncScheduler__WEBP4) {
      _inherits(VirtualTimeScheduler, _AsyncScheduler__WEBP4);

      var _super208 = _createSuper(VirtualTimeScheduler);

      function VirtualTimeScheduler() {
        var _this411;

        var SchedulerAction = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : VirtualAction;
        var maxFrames = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : Number.POSITIVE_INFINITY;

        _classCallCheck(this, VirtualTimeScheduler);

        _this411 = _super208.call(this, SchedulerAction, function () {
          return _this411.frame;
        });
        _this411.maxFrames = maxFrames;
        _this411.frame = 0;
        _this411.index = -1;
        return _this411;
      }

      _createClass2(VirtualTimeScheduler, [{
        key: "flush",
        value: function flush() {
          var actions = this.actions,
              maxFrames = this.maxFrames;
          var error, action;

          while ((action = actions[0]) && action.delay <= maxFrames) {
            actions.shift();
            this.frame = action.delay;

            if (error = action.execute(action.state, action.delay)) {
              break;
            }
          }

          if (error) {
            while (action = actions.shift()) {
              action.unsubscribe();
            }

            throw error;
          }
        }
      }]);

      return VirtualTimeScheduler;
    }(_AsyncScheduler__WEBPACK_IMPORTED_MODULE_1__["AsyncScheduler"]);

    VirtualTimeScheduler.frameTimeFactor = 10;

    var VirtualAction = /*#__PURE__*/function (_AsyncAction__WEBPACK4) {
      _inherits(VirtualAction, _AsyncAction__WEBPACK4);

      var _super209 = _createSuper(VirtualAction);

      function VirtualAction(scheduler, work) {
        var _this412;

        var index = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : scheduler.index += 1;

        _classCallCheck(this, VirtualAction);

        _this412 = _super209.call(this, scheduler, work);
        _this412.scheduler = scheduler;
        _this412.work = work;
        _this412.index = index;
        _this412.active = true;
        _this412.index = scheduler.index = index;
        return _this412;
      }

      _createClass2(VirtualAction, [{
        key: "schedule",
        value: function schedule(state) {
          var delay = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;

          if (!this.id) {
            return _get(_getPrototypeOf(VirtualAction.prototype), "schedule", this).call(this, state, delay);
          }

          this.active = false;
          var action = new VirtualAction(this.scheduler, this.work);
          this.add(action);
          return action.schedule(state, delay);
        }
      }, {
        key: "requestAsyncId",
        value: function requestAsyncId(scheduler, id) {
          var delay = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;
          this.delay = scheduler.frame + delay;
          var actions = scheduler.actions;
          actions.push(this);
          actions.sort(VirtualAction.sortActions);
          return true;
        }
      }, {
        key: "recycleAsyncId",
        value: function recycleAsyncId(scheduler, id) {
          var delay = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;
          return undefined;
        }
      }, {
        key: "_execute",
        value: function _execute(state, delay) {
          if (this.active === true) {
            return _get(_getPrototypeOf(VirtualAction.prototype), "_execute", this).call(this, state, delay);
          }
        }
      }], [{
        key: "sortActions",
        value: function sortActions(a, b) {
          if (a.delay === b.delay) {
            if (a.index === b.index) {
              return 0;
            } else if (a.index > b.index) {
              return 1;
            } else {
              return -1;
            }
          } else if (a.delay > b.delay) {
            return 1;
          } else {
            return -1;
          }
        }
      }]);

      return VirtualAction;
    }(_AsyncAction__WEBPACK_IMPORTED_MODULE_0__["AsyncAction"]); //# sourceMappingURL=VirtualTimeScheduler.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/scheduler/animationFrame.js":
  /*!*************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/scheduler/animationFrame.js ***!
    \*************************************************************************/

  /*! exports provided: animationFrame */

  /***/
  function node_modulesRxjs_esm2015InternalSchedulerAnimationFrameJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "animationFrame", function () {
      return animationFrame;
    });
    /* harmony import */


    var _AnimationFrameAction__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./AnimationFrameAction */
    "./node_modules/rxjs/_esm2015/internal/scheduler/AnimationFrameAction.js");
    /* harmony import */


    var _AnimationFrameScheduler__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./AnimationFrameScheduler */
    "./node_modules/rxjs/_esm2015/internal/scheduler/AnimationFrameScheduler.js");

    var animationFrame = new _AnimationFrameScheduler__WEBPACK_IMPORTED_MODULE_1__["AnimationFrameScheduler"](_AnimationFrameAction__WEBPACK_IMPORTED_MODULE_0__["AnimationFrameAction"]); //# sourceMappingURL=animationFrame.js.map

    /***/
  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/scheduler/asap.js":
  /*!***************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/scheduler/asap.js ***!
    \***************************************************************/

  /*! exports provided: asap */

  /***/
  function node_modulesRxjs_esm2015InternalSchedulerAsapJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "asap", function () {
      return asap;
    });
    /* harmony import */


    var _AsapAction__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./AsapAction */
    "./node_modules/rxjs/_esm2015/internal/scheduler/AsapAction.js");
    /* harmony import */


    var _AsapScheduler__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./AsapScheduler */
    "./node_modules/rxjs/_esm2015/internal/scheduler/AsapScheduler.js");

    var asap = new _AsapScheduler__WEBPACK_IMPORTED_MODULE_1__["AsapScheduler"](_AsapAction__WEBPACK_IMPORTED_MODULE_0__["AsapAction"]); //# sourceMappingURL=asap.js.map

    /***/
  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/scheduler/async.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/scheduler/async.js ***!
    \****************************************************************/

  /*! exports provided: async */

  /***/
  function node_modulesRxjs_esm2015InternalSchedulerAsyncJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "async", function () {
      return async;
    });
    /* harmony import */


    var _AsyncAction__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./AsyncAction */
    "./node_modules/rxjs/_esm2015/internal/scheduler/AsyncAction.js");
    /* harmony import */


    var _AsyncScheduler__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./AsyncScheduler */
    "./node_modules/rxjs/_esm2015/internal/scheduler/AsyncScheduler.js");

    var async = new _AsyncScheduler__WEBPACK_IMPORTED_MODULE_1__["AsyncScheduler"](_AsyncAction__WEBPACK_IMPORTED_MODULE_0__["AsyncAction"]); //# sourceMappingURL=async.js.map

    /***/
  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/scheduler/queue.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/scheduler/queue.js ***!
    \****************************************************************/

  /*! exports provided: queue */

  /***/
  function node_modulesRxjs_esm2015InternalSchedulerQueueJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "queue", function () {
      return queue;
    });
    /* harmony import */


    var _QueueAction__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./QueueAction */
    "./node_modules/rxjs/_esm2015/internal/scheduler/QueueAction.js");
    /* harmony import */


    var _QueueScheduler__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./QueueScheduler */
    "./node_modules/rxjs/_esm2015/internal/scheduler/QueueScheduler.js");

    var queue = new _QueueScheduler__WEBPACK_IMPORTED_MODULE_1__["QueueScheduler"](_QueueAction__WEBPACK_IMPORTED_MODULE_0__["QueueAction"]); //# sourceMappingURL=queue.js.map

    /***/
  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/symbol/iterator.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/symbol/iterator.js ***!
    \****************************************************************/

  /*! exports provided: getSymbolIterator, iterator, $$iterator */

  /***/
  function node_modulesRxjs_esm2015InternalSymbolIteratorJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "getSymbolIterator", function () {
      return getSymbolIterator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "iterator", function () {
      return iterator;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "$$iterator", function () {
      return $$iterator;
    });

    function getSymbolIterator() {
      if (typeof Symbol !== 'function' || !Symbol.iterator) {
        return '@@iterator';
      }

      return Symbol.iterator;
    }

    var iterator = getSymbolIterator();
    var $$iterator = iterator; //# sourceMappingURL=iterator.js.map

    /***/
  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/symbol/observable.js":
  /*!******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/symbol/observable.js ***!
    \******************************************************************/

  /*! exports provided: observable */

  /***/
  function node_modulesRxjs_esm2015InternalSymbolObservableJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "observable", function () {
      return observable;
    });

    var observable = function () {
      return typeof Symbol === 'function' && Symbol.observable || '@@observable';
    }(); //# sourceMappingURL=observable.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/symbol/rxSubscriber.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/symbol/rxSubscriber.js ***!
    \********************************************************************/

  /*! exports provided: rxSubscriber, $$rxSubscriber */

  /***/
  function node_modulesRxjs_esm2015InternalSymbolRxSubscriberJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "rxSubscriber", function () {
      return rxSubscriber;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "$$rxSubscriber", function () {
      return $$rxSubscriber;
    });

    var rxSubscriber = function () {
      return typeof Symbol === 'function' ? Symbol('rxSubscriber') : '@@rxSubscriber_' + Math.random();
    }();

    var $$rxSubscriber = rxSubscriber; //# sourceMappingURL=rxSubscriber.js.map

    /***/
  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/ArgumentOutOfRangeError.js":
  /*!*****************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/ArgumentOutOfRangeError.js ***!
    \*****************************************************************************/

  /*! exports provided: ArgumentOutOfRangeError */

  /***/
  function node_modulesRxjs_esm2015InternalUtilArgumentOutOfRangeErrorJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ArgumentOutOfRangeError", function () {
      return ArgumentOutOfRangeError;
    });

    var ArgumentOutOfRangeErrorImpl = function () {
      function ArgumentOutOfRangeErrorImpl() {
        Error.call(this);
        this.message = 'argument out of range';
        this.name = 'ArgumentOutOfRangeError';
        return this;
      }

      ArgumentOutOfRangeErrorImpl.prototype = Object.create(Error.prototype);
      return ArgumentOutOfRangeErrorImpl;
    }();

    var ArgumentOutOfRangeError = ArgumentOutOfRangeErrorImpl; //# sourceMappingURL=ArgumentOutOfRangeError.js.map

    /***/
  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/EmptyError.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/EmptyError.js ***!
    \****************************************************************/

  /*! exports provided: EmptyError */

  /***/
  function node_modulesRxjs_esm2015InternalUtilEmptyErrorJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "EmptyError", function () {
      return EmptyError;
    });

    var EmptyErrorImpl = function () {
      function EmptyErrorImpl() {
        Error.call(this);
        this.message = 'no elements in sequence';
        this.name = 'EmptyError';
        return this;
      }

      EmptyErrorImpl.prototype = Object.create(Error.prototype);
      return EmptyErrorImpl;
    }();

    var EmptyError = EmptyErrorImpl; //# sourceMappingURL=EmptyError.js.map

    /***/
  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/Immediate.js":
  /*!***************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/Immediate.js ***!
    \***************************************************************/

  /*! exports provided: Immediate, TestTools */

  /***/
  function node_modulesRxjs_esm2015InternalUtilImmediateJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "Immediate", function () {
      return Immediate;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "TestTools", function () {
      return TestTools;
    });

    var nextHandle = 1;

    var RESOLVED = function () {
      return Promise.resolve();
    }();

    var activeHandles = {};

    function findAndClearHandle(handle) {
      if (handle in activeHandles) {
        delete activeHandles[handle];
        return true;
      }

      return false;
    }

    var Immediate = {
      setImmediate: function setImmediate(cb) {
        var handle = nextHandle++;
        activeHandles[handle] = true;
        RESOLVED.then(function () {
          return findAndClearHandle(handle) && cb();
        });
        return handle;
      },
      clearImmediate: function clearImmediate(handle) {
        findAndClearHandle(handle);
      }
    };
    var TestTools = {
      pending: function pending() {
        return Object.keys(activeHandles).length;
      }
    }; //# sourceMappingURL=Immediate.js.map

    /***/
  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/ObjectUnsubscribedError.js":
  /*!*****************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/ObjectUnsubscribedError.js ***!
    \*****************************************************************************/

  /*! exports provided: ObjectUnsubscribedError */

  /***/
  function node_modulesRxjs_esm2015InternalUtilObjectUnsubscribedErrorJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "ObjectUnsubscribedError", function () {
      return ObjectUnsubscribedError;
    });

    var ObjectUnsubscribedErrorImpl = function () {
      function ObjectUnsubscribedErrorImpl() {
        Error.call(this);
        this.message = 'object unsubscribed';
        this.name = 'ObjectUnsubscribedError';
        return this;
      }

      ObjectUnsubscribedErrorImpl.prototype = Object.create(Error.prototype);
      return ObjectUnsubscribedErrorImpl;
    }();

    var ObjectUnsubscribedError = ObjectUnsubscribedErrorImpl; //# sourceMappingURL=ObjectUnsubscribedError.js.map

    /***/
  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/TimeoutError.js":
  /*!******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/TimeoutError.js ***!
    \******************************************************************/

  /*! exports provided: TimeoutError */

  /***/
  function node_modulesRxjs_esm2015InternalUtilTimeoutErrorJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "TimeoutError", function () {
      return TimeoutError;
    });

    var TimeoutErrorImpl = function () {
      function TimeoutErrorImpl() {
        Error.call(this);
        this.message = 'Timeout has occurred';
        this.name = 'TimeoutError';
        return this;
      }

      TimeoutErrorImpl.prototype = Object.create(Error.prototype);
      return TimeoutErrorImpl;
    }();

    var TimeoutError = TimeoutErrorImpl; //# sourceMappingURL=TimeoutError.js.map

    /***/
  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/UnsubscriptionError.js":
  /*!*************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/UnsubscriptionError.js ***!
    \*************************************************************************/

  /*! exports provided: UnsubscriptionError */

  /***/
  function node_modulesRxjs_esm2015InternalUtilUnsubscriptionErrorJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "UnsubscriptionError", function () {
      return UnsubscriptionError;
    });

    var UnsubscriptionErrorImpl = function () {
      function UnsubscriptionErrorImpl(errors) {
        Error.call(this);
        this.message = errors ? "".concat(errors.length, " errors occurred during unsubscription:\n").concat(errors.map(function (err, i) {
          return "".concat(i + 1, ") ").concat(err.toString());
        }).join('\n  ')) : '';
        this.name = 'UnsubscriptionError';
        this.errors = errors;
        return this;
      }

      UnsubscriptionErrorImpl.prototype = Object.create(Error.prototype);
      return UnsubscriptionErrorImpl;
    }();

    var UnsubscriptionError = UnsubscriptionErrorImpl; //# sourceMappingURL=UnsubscriptionError.js.map

    /***/
  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/canReportError.js":
  /*!********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/canReportError.js ***!
    \********************************************************************/

  /*! exports provided: canReportError */

  /***/
  function node_modulesRxjs_esm2015InternalUtilCanReportErrorJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "canReportError", function () {
      return canReportError;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");

    function canReportError(observer) {
      while (observer) {
        var _observer = observer,
            closed = _observer.closed,
            destination = _observer.destination,
            isStopped = _observer.isStopped;

        if (closed || isStopped) {
          return false;
        } else if (destination && destination instanceof _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]) {
          observer = destination;
        } else {
          observer = null;
        }
      }

      return true;
    } //# sourceMappingURL=canReportError.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/hostReportError.js":
  /*!*********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/hostReportError.js ***!
    \*********************************************************************/

  /*! exports provided: hostReportError */

  /***/
  function node_modulesRxjs_esm2015InternalUtilHostReportErrorJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "hostReportError", function () {
      return hostReportError;
    });

    function hostReportError(err) {
      setTimeout(function () {
        throw err;
      }, 0);
    } //# sourceMappingURL=hostReportError.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/identity.js":
  /*!**************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/identity.js ***!
    \**************************************************************/

  /*! exports provided: identity */

  /***/
  function node_modulesRxjs_esm2015InternalUtilIdentityJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "identity", function () {
      return identity;
    });

    function identity(x) {
      return x;
    } //# sourceMappingURL=identity.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/isArray.js":
  /*!*************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/isArray.js ***!
    \*************************************************************/

  /*! exports provided: isArray */

  /***/
  function node_modulesRxjs_esm2015InternalUtilIsArrayJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "isArray", function () {
      return isArray;
    });

    var isArray = function () {
      return Array.isArray || function (x) {
        return x && typeof x.length === 'number';
      };
    }(); //# sourceMappingURL=isArray.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/isArrayLike.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/isArrayLike.js ***!
    \*****************************************************************/

  /*! exports provided: isArrayLike */

  /***/
  function node_modulesRxjs_esm2015InternalUtilIsArrayLikeJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "isArrayLike", function () {
      return isArrayLike;
    });

    var isArrayLike = function isArrayLike(x) {
      return x && typeof x.length === 'number' && typeof x !== 'function';
    }; //# sourceMappingURL=isArrayLike.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/isDate.js":
  /*!************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/isDate.js ***!
    \************************************************************/

  /*! exports provided: isDate */

  /***/
  function node_modulesRxjs_esm2015InternalUtilIsDateJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "isDate", function () {
      return isDate;
    });

    function isDate(value) {
      return value instanceof Date && !isNaN(+value);
    } //# sourceMappingURL=isDate.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/isFunction.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/isFunction.js ***!
    \****************************************************************/

  /*! exports provided: isFunction */

  /***/
  function node_modulesRxjs_esm2015InternalUtilIsFunctionJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "isFunction", function () {
      return isFunction;
    });

    function isFunction(x) {
      return typeof x === 'function';
    } //# sourceMappingURL=isFunction.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/isInteropObservable.js":
  /*!*************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/isInteropObservable.js ***!
    \*************************************************************************/

  /*! exports provided: isInteropObservable */

  /***/
  function node_modulesRxjs_esm2015InternalUtilIsInteropObservableJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "isInteropObservable", function () {
      return isInteropObservable;
    });
    /* harmony import */


    var _symbol_observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../symbol/observable */
    "./node_modules/rxjs/_esm2015/internal/symbol/observable.js");

    function isInteropObservable(input) {
      return input && typeof input[_symbol_observable__WEBPACK_IMPORTED_MODULE_0__["observable"]] === 'function';
    } //# sourceMappingURL=isInteropObservable.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/isIterable.js":
  /*!****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/isIterable.js ***!
    \****************************************************************/

  /*! exports provided: isIterable */

  /***/
  function node_modulesRxjs_esm2015InternalUtilIsIterableJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "isIterable", function () {
      return isIterable;
    });
    /* harmony import */


    var _symbol_iterator__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../symbol/iterator */
    "./node_modules/rxjs/_esm2015/internal/symbol/iterator.js");

    function isIterable(input) {
      return input && typeof input[_symbol_iterator__WEBPACK_IMPORTED_MODULE_0__["iterator"]] === 'function';
    } //# sourceMappingURL=isIterable.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/isNumeric.js":
  /*!***************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/isNumeric.js ***!
    \***************************************************************/

  /*! exports provided: isNumeric */

  /***/
  function node_modulesRxjs_esm2015InternalUtilIsNumericJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "isNumeric", function () {
      return isNumeric;
    });
    /* harmony import */


    var _isArray__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./isArray */
    "./node_modules/rxjs/_esm2015/internal/util/isArray.js");

    function isNumeric(val) {
      return !Object(_isArray__WEBPACK_IMPORTED_MODULE_0__["isArray"])(val) && val - parseFloat(val) + 1 >= 0;
    } //# sourceMappingURL=isNumeric.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/isObject.js":
  /*!**************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/isObject.js ***!
    \**************************************************************/

  /*! exports provided: isObject */

  /***/
  function node_modulesRxjs_esm2015InternalUtilIsObjectJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "isObject", function () {
      return isObject;
    });

    function isObject(x) {
      return x !== null && typeof x === 'object';
    } //# sourceMappingURL=isObject.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/isObservable.js":
  /*!******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/isObservable.js ***!
    \******************************************************************/

  /*! exports provided: isObservable */

  /***/
  function node_modulesRxjs_esm2015InternalUtilIsObservableJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "isObservable", function () {
      return isObservable;
    });
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");

    function isObservable(obj) {
      return !!obj && (obj instanceof _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"] || typeof obj.lift === 'function' && typeof obj.subscribe === 'function');
    } //# sourceMappingURL=isObservable.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/isPromise.js":
  /*!***************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/isPromise.js ***!
    \***************************************************************/

  /*! exports provided: isPromise */

  /***/
  function node_modulesRxjs_esm2015InternalUtilIsPromiseJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "isPromise", function () {
      return isPromise;
    });

    function isPromise(value) {
      return !!value && typeof value.subscribe !== 'function' && typeof value.then === 'function';
    } //# sourceMappingURL=isPromise.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/isScheduler.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/isScheduler.js ***!
    \*****************************************************************/

  /*! exports provided: isScheduler */

  /***/
  function node_modulesRxjs_esm2015InternalUtilIsSchedulerJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "isScheduler", function () {
      return isScheduler;
    });

    function isScheduler(value) {
      return value && typeof value.schedule === 'function';
    } //# sourceMappingURL=isScheduler.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/noop.js":
  /*!**********************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/noop.js ***!
    \**********************************************************/

  /*! exports provided: noop */

  /***/
  function node_modulesRxjs_esm2015InternalUtilNoopJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "noop", function () {
      return noop;
    });

    function noop() {} //# sourceMappingURL=noop.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/not.js":
  /*!*********************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/not.js ***!
    \*********************************************************/

  /*! exports provided: not */

  /***/
  function node_modulesRxjs_esm2015InternalUtilNotJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "not", function () {
      return not;
    });

    function not(pred, thisArg) {
      function notPred() {
        return !notPred.pred.apply(notPred.thisArg, arguments);
      }

      notPred.pred = pred;
      notPred.thisArg = thisArg;
      return notPred;
    } //# sourceMappingURL=not.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/pipe.js":
  /*!**********************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/pipe.js ***!
    \**********************************************************/

  /*! exports provided: pipe, pipeFromArray */

  /***/
  function node_modulesRxjs_esm2015InternalUtilPipeJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "pipe", function () {
      return pipe;
    });
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "pipeFromArray", function () {
      return pipeFromArray;
    });
    /* harmony import */


    var _identity__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./identity */
    "./node_modules/rxjs/_esm2015/internal/util/identity.js");

    function pipe() {
      for (var _len63 = arguments.length, fns = new Array(_len63), _key57 = 0; _key57 < _len63; _key57++) {
        fns[_key57] = arguments[_key57];
      }

      return pipeFromArray(fns);
    }

    function pipeFromArray(fns) {
      if (fns.length === 0) {
        return _identity__WEBPACK_IMPORTED_MODULE_0__["identity"];
      }

      if (fns.length === 1) {
        return fns[0];
      }

      return function piped(input) {
        return fns.reduce(function (prev, fn) {
          return fn(prev);
        }, input);
      };
    } //# sourceMappingURL=pipe.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/subscribeTo.js":
  /*!*****************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/subscribeTo.js ***!
    \*****************************************************************/

  /*! exports provided: subscribeTo */

  /***/
  function node_modulesRxjs_esm2015InternalUtilSubscribeToJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "subscribeTo", function () {
      return subscribeTo;
    });
    /* harmony import */


    var _subscribeToArray__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./subscribeToArray */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToArray.js");
    /* harmony import */


    var _subscribeToPromise__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./subscribeToPromise */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToPromise.js");
    /* harmony import */


    var _subscribeToIterable__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ./subscribeToIterable */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToIterable.js");
    /* harmony import */


    var _subscribeToObservable__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ./subscribeToObservable */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeToObservable.js");
    /* harmony import */


    var _isArrayLike__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ./isArrayLike */
    "./node_modules/rxjs/_esm2015/internal/util/isArrayLike.js");
    /* harmony import */


    var _isPromise__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(
    /*! ./isPromise */
    "./node_modules/rxjs/_esm2015/internal/util/isPromise.js");
    /* harmony import */


    var _isObject__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(
    /*! ./isObject */
    "./node_modules/rxjs/_esm2015/internal/util/isObject.js");
    /* harmony import */


    var _symbol_iterator__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(
    /*! ../symbol/iterator */
    "./node_modules/rxjs/_esm2015/internal/symbol/iterator.js");
    /* harmony import */


    var _symbol_observable__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(
    /*! ../symbol/observable */
    "./node_modules/rxjs/_esm2015/internal/symbol/observable.js");

    var subscribeTo = function subscribeTo(result) {
      if (!!result && typeof result[_symbol_observable__WEBPACK_IMPORTED_MODULE_8__["observable"]] === 'function') {
        return Object(_subscribeToObservable__WEBPACK_IMPORTED_MODULE_3__["subscribeToObservable"])(result);
      } else if (Object(_isArrayLike__WEBPACK_IMPORTED_MODULE_4__["isArrayLike"])(result)) {
        return Object(_subscribeToArray__WEBPACK_IMPORTED_MODULE_0__["subscribeToArray"])(result);
      } else if (Object(_isPromise__WEBPACK_IMPORTED_MODULE_5__["isPromise"])(result)) {
        return Object(_subscribeToPromise__WEBPACK_IMPORTED_MODULE_1__["subscribeToPromise"])(result);
      } else if (!!result && typeof result[_symbol_iterator__WEBPACK_IMPORTED_MODULE_7__["iterator"]] === 'function') {
        return Object(_subscribeToIterable__WEBPACK_IMPORTED_MODULE_2__["subscribeToIterable"])(result);
      } else {
        var value = Object(_isObject__WEBPACK_IMPORTED_MODULE_6__["isObject"])(result) ? 'an invalid object' : "'".concat(result, "'");
        var msg = "You provided ".concat(value, " where a stream was expected.") + ' You can provide an Observable, Promise, Array, or Iterable.';
        throw new TypeError(msg);
      }
    }; //# sourceMappingURL=subscribeTo.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/subscribeToArray.js":
  /*!**********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/subscribeToArray.js ***!
    \**********************************************************************/

  /*! exports provided: subscribeToArray */

  /***/
  function node_modulesRxjs_esm2015InternalUtilSubscribeToArrayJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "subscribeToArray", function () {
      return subscribeToArray;
    });

    var subscribeToArray = function subscribeToArray(array) {
      return function (subscriber) {
        for (var i = 0, _len64 = array.length; i < _len64 && !subscriber.closed; i++) {
          subscriber.next(array[i]);
        }

        subscriber.complete();
      };
    }; //# sourceMappingURL=subscribeToArray.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/subscribeToIterable.js":
  /*!*************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/subscribeToIterable.js ***!
    \*************************************************************************/

  /*! exports provided: subscribeToIterable */

  /***/
  function node_modulesRxjs_esm2015InternalUtilSubscribeToIterableJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "subscribeToIterable", function () {
      return subscribeToIterable;
    });
    /* harmony import */


    var _symbol_iterator__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../symbol/iterator */
    "./node_modules/rxjs/_esm2015/internal/symbol/iterator.js");

    var subscribeToIterable = function subscribeToIterable(iterable) {
      return function (subscriber) {
        var iterator = iterable[_symbol_iterator__WEBPACK_IMPORTED_MODULE_0__["iterator"]]();

        do {
          var item = iterator.next();

          if (item.done) {
            subscriber.complete();
            break;
          }

          subscriber.next(item.value);

          if (subscriber.closed) {
            break;
          }
        } while (true);

        if (typeof iterator["return"] === 'function') {
          subscriber.add(function () {
            if (iterator["return"]) {
              iterator["return"]();
            }
          });
        }

        return subscriber;
      };
    }; //# sourceMappingURL=subscribeToIterable.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/subscribeToObservable.js":
  /*!***************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/subscribeToObservable.js ***!
    \***************************************************************************/

  /*! exports provided: subscribeToObservable */

  /***/
  function node_modulesRxjs_esm2015InternalUtilSubscribeToObservableJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "subscribeToObservable", function () {
      return subscribeToObservable;
    });
    /* harmony import */


    var _symbol_observable__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../symbol/observable */
    "./node_modules/rxjs/_esm2015/internal/symbol/observable.js");

    var subscribeToObservable = function subscribeToObservable(obj) {
      return function (subscriber) {
        var obs = obj[_symbol_observable__WEBPACK_IMPORTED_MODULE_0__["observable"]]();

        if (typeof obs.subscribe !== 'function') {
          throw new TypeError('Provided object does not correctly implement Symbol.observable');
        } else {
          return obs.subscribe(subscriber);
        }
      };
    }; //# sourceMappingURL=subscribeToObservable.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/subscribeToPromise.js":
  /*!************************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/subscribeToPromise.js ***!
    \************************************************************************/

  /*! exports provided: subscribeToPromise */

  /***/
  function node_modulesRxjs_esm2015InternalUtilSubscribeToPromiseJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "subscribeToPromise", function () {
      return subscribeToPromise;
    });
    /* harmony import */


    var _hostReportError__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ./hostReportError */
    "./node_modules/rxjs/_esm2015/internal/util/hostReportError.js");

    var subscribeToPromise = function subscribeToPromise(promise) {
      return function (subscriber) {
        promise.then(function (value) {
          if (!subscriber.closed) {
            subscriber.next(value);
            subscriber.complete();
          }
        }, function (err) {
          return subscriber.error(err);
        }).then(null, _hostReportError__WEBPACK_IMPORTED_MODULE_0__["hostReportError"]);
        return subscriber;
      };
    }; //# sourceMappingURL=subscribeToPromise.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js":
  /*!***********************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js ***!
    \***********************************************************************/

  /*! exports provided: subscribeToResult */

  /***/
  function node_modulesRxjs_esm2015InternalUtilSubscribeToResultJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "subscribeToResult", function () {
      return subscribeToResult;
    });
    /* harmony import */


    var _InnerSubscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../InnerSubscriber */
    "./node_modules/rxjs/_esm2015/internal/InnerSubscriber.js");
    /* harmony import */


    var _subscribeTo__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ./subscribeTo */
    "./node_modules/rxjs/_esm2015/internal/util/subscribeTo.js");
    /* harmony import */


    var _Observable__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../Observable */
    "./node_modules/rxjs/_esm2015/internal/Observable.js");

    function subscribeToResult(outerSubscriber, result, outerValue, outerIndex) {
      var innerSubscriber = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : new _InnerSubscriber__WEBPACK_IMPORTED_MODULE_0__["InnerSubscriber"](outerSubscriber, outerValue, outerIndex);

      if (innerSubscriber.closed) {
        return undefined;
      }

      if (result instanceof _Observable__WEBPACK_IMPORTED_MODULE_2__["Observable"]) {
        return result.subscribe(innerSubscriber);
      }

      return Object(_subscribeTo__WEBPACK_IMPORTED_MODULE_1__["subscribeTo"])(result)(innerSubscriber);
    } //# sourceMappingURL=subscribeToResult.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/internal/util/toSubscriber.js":
  /*!******************************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/internal/util/toSubscriber.js ***!
    \******************************************************************/

  /*! exports provided: toSubscriber */

  /***/
  function node_modulesRxjs_esm2015InternalUtilToSubscriberJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony export (binding) */


    __webpack_require__.d(__webpack_exports__, "toSubscriber", function () {
      return toSubscriber;
    });
    /* harmony import */


    var _Subscriber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../Subscriber */
    "./node_modules/rxjs/_esm2015/internal/Subscriber.js");
    /* harmony import */


    var _symbol_rxSubscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../symbol/rxSubscriber */
    "./node_modules/rxjs/_esm2015/internal/symbol/rxSubscriber.js");
    /* harmony import */


    var _Observer__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../Observer */
    "./node_modules/rxjs/_esm2015/internal/Observer.js");

    function toSubscriber(nextOrObserver, error, complete) {
      if (nextOrObserver) {
        if (nextOrObserver instanceof _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"]) {
          return nextOrObserver;
        }

        if (nextOrObserver[_symbol_rxSubscriber__WEBPACK_IMPORTED_MODULE_1__["rxSubscriber"]]) {
          return nextOrObserver[_symbol_rxSubscriber__WEBPACK_IMPORTED_MODULE_1__["rxSubscriber"]]();
        }
      }

      if (!nextOrObserver && !error && !complete) {
        return new _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"](_Observer__WEBPACK_IMPORTED_MODULE_2__["empty"]);
      }

      return new _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"](nextOrObserver, error, complete);
    } //# sourceMappingURL=toSubscriber.js.map

    /***/

  },

  /***/
  "./node_modules/rxjs/_esm2015/operators/index.js":
  /*!*******************************************************!*\
    !*** ./node_modules/rxjs/_esm2015/operators/index.js ***!
    \*******************************************************/

  /*! exports provided: audit, auditTime, buffer, bufferCount, bufferTime, bufferToggle, bufferWhen, catchError, combineAll, combineLatest, concat, concatAll, concatMap, concatMapTo, count, debounce, debounceTime, defaultIfEmpty, delay, delayWhen, dematerialize, distinct, distinctUntilChanged, distinctUntilKeyChanged, elementAt, endWith, every, exhaust, exhaustMap, expand, filter, finalize, find, findIndex, first, groupBy, ignoreElements, isEmpty, last, map, mapTo, materialize, max, merge, mergeAll, mergeMap, flatMap, mergeMapTo, mergeScan, min, multicast, observeOn, onErrorResumeNext, pairwise, partition, pluck, publish, publishBehavior, publishLast, publishReplay, race, reduce, repeat, repeatWhen, retry, retryWhen, refCount, sample, sampleTime, scan, sequenceEqual, share, shareReplay, single, skip, skipLast, skipUntil, skipWhile, startWith, subscribeOn, switchAll, switchMap, switchMapTo, take, takeLast, takeUntil, takeWhile, tap, throttle, throttleTime, throwIfEmpty, timeInterval, timeout, timeoutWith, timestamp, toArray, window, windowCount, windowTime, windowToggle, windowWhen, withLatestFrom, zip, zipAll */

  /***/
  function node_modulesRxjs_esm2015OperatorsIndexJs(module, __webpack_exports__, __webpack_require__) {
    "use strict";

    __webpack_require__.r(__webpack_exports__);
    /* harmony import */


    var _internal_operators_audit__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(
    /*! ../internal/operators/audit */
    "./node_modules/rxjs/_esm2015/internal/operators/audit.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "audit", function () {
      return _internal_operators_audit__WEBPACK_IMPORTED_MODULE_0__["audit"];
    });
    /* harmony import */


    var _internal_operators_auditTime__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
    /*! ../internal/operators/auditTime */
    "./node_modules/rxjs/_esm2015/internal/operators/auditTime.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "auditTime", function () {
      return _internal_operators_auditTime__WEBPACK_IMPORTED_MODULE_1__["auditTime"];
    });
    /* harmony import */


    var _internal_operators_buffer__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
    /*! ../internal/operators/buffer */
    "./node_modules/rxjs/_esm2015/internal/operators/buffer.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "buffer", function () {
      return _internal_operators_buffer__WEBPACK_IMPORTED_MODULE_2__["buffer"];
    });
    /* harmony import */


    var _internal_operators_bufferCount__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
    /*! ../internal/operators/bufferCount */
    "./node_modules/rxjs/_esm2015/internal/operators/bufferCount.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "bufferCount", function () {
      return _internal_operators_bufferCount__WEBPACK_IMPORTED_MODULE_3__["bufferCount"];
    });
    /* harmony import */


    var _internal_operators_bufferTime__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(
    /*! ../internal/operators/bufferTime */
    "./node_modules/rxjs/_esm2015/internal/operators/bufferTime.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "bufferTime", function () {
      return _internal_operators_bufferTime__WEBPACK_IMPORTED_MODULE_4__["bufferTime"];
    });
    /* harmony import */


    var _internal_operators_bufferToggle__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(
    /*! ../internal/operators/bufferToggle */
    "./node_modules/rxjs/_esm2015/internal/operators/bufferToggle.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "bufferToggle", function () {
      return _internal_operators_bufferToggle__WEBPACK_IMPORTED_MODULE_5__["bufferToggle"];
    });
    /* harmony import */


    var _internal_operators_bufferWhen__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(
    /*! ../internal/operators/bufferWhen */
    "./node_modules/rxjs/_esm2015/internal/operators/bufferWhen.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "bufferWhen", function () {
      return _internal_operators_bufferWhen__WEBPACK_IMPORTED_MODULE_6__["bufferWhen"];
    });
    /* harmony import */


    var _internal_operators_catchError__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(
    /*! ../internal/operators/catchError */
    "./node_modules/rxjs/_esm2015/internal/operators/catchError.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "catchError", function () {
      return _internal_operators_catchError__WEBPACK_IMPORTED_MODULE_7__["catchError"];
    });
    /* harmony import */


    var _internal_operators_combineAll__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(
    /*! ../internal/operators/combineAll */
    "./node_modules/rxjs/_esm2015/internal/operators/combineAll.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "combineAll", function () {
      return _internal_operators_combineAll__WEBPACK_IMPORTED_MODULE_8__["combineAll"];
    });
    /* harmony import */


    var _internal_operators_combineLatest__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(
    /*! ../internal/operators/combineLatest */
    "./node_modules/rxjs/_esm2015/internal/operators/combineLatest.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "combineLatest", function () {
      return _internal_operators_combineLatest__WEBPACK_IMPORTED_MODULE_9__["combineLatest"];
    });
    /* harmony import */


    var _internal_operators_concat__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(
    /*! ../internal/operators/concat */
    "./node_modules/rxjs/_esm2015/internal/operators/concat.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "concat", function () {
      return _internal_operators_concat__WEBPACK_IMPORTED_MODULE_10__["concat"];
    });
    /* harmony import */


    var _internal_operators_concatAll__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(
    /*! ../internal/operators/concatAll */
    "./node_modules/rxjs/_esm2015/internal/operators/concatAll.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "concatAll", function () {
      return _internal_operators_concatAll__WEBPACK_IMPORTED_MODULE_11__["concatAll"];
    });
    /* harmony import */


    var _internal_operators_concatMap__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(
    /*! ../internal/operators/concatMap */
    "./node_modules/rxjs/_esm2015/internal/operators/concatMap.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "concatMap", function () {
      return _internal_operators_concatMap__WEBPACK_IMPORTED_MODULE_12__["concatMap"];
    });
    /* harmony import */


    var _internal_operators_concatMapTo__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(
    /*! ../internal/operators/concatMapTo */
    "./node_modules/rxjs/_esm2015/internal/operators/concatMapTo.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "concatMapTo", function () {
      return _internal_operators_concatMapTo__WEBPACK_IMPORTED_MODULE_13__["concatMapTo"];
    });
    /* harmony import */


    var _internal_operators_count__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(
    /*! ../internal/operators/count */
    "./node_modules/rxjs/_esm2015/internal/operators/count.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "count", function () {
      return _internal_operators_count__WEBPACK_IMPORTED_MODULE_14__["count"];
    });
    /* harmony import */


    var _internal_operators_debounce__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(
    /*! ../internal/operators/debounce */
    "./node_modules/rxjs/_esm2015/internal/operators/debounce.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "debounce", function () {
      return _internal_operators_debounce__WEBPACK_IMPORTED_MODULE_15__["debounce"];
    });
    /* harmony import */


    var _internal_operators_debounceTime__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(
    /*! ../internal/operators/debounceTime */
    "./node_modules/rxjs/_esm2015/internal/operators/debounceTime.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "debounceTime", function () {
      return _internal_operators_debounceTime__WEBPACK_IMPORTED_MODULE_16__["debounceTime"];
    });
    /* harmony import */


    var _internal_operators_defaultIfEmpty__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(
    /*! ../internal/operators/defaultIfEmpty */
    "./node_modules/rxjs/_esm2015/internal/operators/defaultIfEmpty.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "defaultIfEmpty", function () {
      return _internal_operators_defaultIfEmpty__WEBPACK_IMPORTED_MODULE_17__["defaultIfEmpty"];
    });
    /* harmony import */


    var _internal_operators_delay__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(
    /*! ../internal/operators/delay */
    "./node_modules/rxjs/_esm2015/internal/operators/delay.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "delay", function () {
      return _internal_operators_delay__WEBPACK_IMPORTED_MODULE_18__["delay"];
    });
    /* harmony import */


    var _internal_operators_delayWhen__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(
    /*! ../internal/operators/delayWhen */
    "./node_modules/rxjs/_esm2015/internal/operators/delayWhen.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "delayWhen", function () {
      return _internal_operators_delayWhen__WEBPACK_IMPORTED_MODULE_19__["delayWhen"];
    });
    /* harmony import */


    var _internal_operators_dematerialize__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(
    /*! ../internal/operators/dematerialize */
    "./node_modules/rxjs/_esm2015/internal/operators/dematerialize.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "dematerialize", function () {
      return _internal_operators_dematerialize__WEBPACK_IMPORTED_MODULE_20__["dematerialize"];
    });
    /* harmony import */


    var _internal_operators_distinct__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(
    /*! ../internal/operators/distinct */
    "./node_modules/rxjs/_esm2015/internal/operators/distinct.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "distinct", function () {
      return _internal_operators_distinct__WEBPACK_IMPORTED_MODULE_21__["distinct"];
    });
    /* harmony import */


    var _internal_operators_distinctUntilChanged__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(
    /*! ../internal/operators/distinctUntilChanged */
    "./node_modules/rxjs/_esm2015/internal/operators/distinctUntilChanged.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "distinctUntilChanged", function () {
      return _internal_operators_distinctUntilChanged__WEBPACK_IMPORTED_MODULE_22__["distinctUntilChanged"];
    });
    /* harmony import */


    var _internal_operators_distinctUntilKeyChanged__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(
    /*! ../internal/operators/distinctUntilKeyChanged */
    "./node_modules/rxjs/_esm2015/internal/operators/distinctUntilKeyChanged.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "distinctUntilKeyChanged", function () {
      return _internal_operators_distinctUntilKeyChanged__WEBPACK_IMPORTED_MODULE_23__["distinctUntilKeyChanged"];
    });
    /* harmony import */


    var _internal_operators_elementAt__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(
    /*! ../internal/operators/elementAt */
    "./node_modules/rxjs/_esm2015/internal/operators/elementAt.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "elementAt", function () {
      return _internal_operators_elementAt__WEBPACK_IMPORTED_MODULE_24__["elementAt"];
    });
    /* harmony import */


    var _internal_operators_endWith__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(
    /*! ../internal/operators/endWith */
    "./node_modules/rxjs/_esm2015/internal/operators/endWith.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "endWith", function () {
      return _internal_operators_endWith__WEBPACK_IMPORTED_MODULE_25__["endWith"];
    });
    /* harmony import */


    var _internal_operators_every__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(
    /*! ../internal/operators/every */
    "./node_modules/rxjs/_esm2015/internal/operators/every.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "every", function () {
      return _internal_operators_every__WEBPACK_IMPORTED_MODULE_26__["every"];
    });
    /* harmony import */


    var _internal_operators_exhaust__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__(
    /*! ../internal/operators/exhaust */
    "./node_modules/rxjs/_esm2015/internal/operators/exhaust.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "exhaust", function () {
      return _internal_operators_exhaust__WEBPACK_IMPORTED_MODULE_27__["exhaust"];
    });
    /* harmony import */


    var _internal_operators_exhaustMap__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__(
    /*! ../internal/operators/exhaustMap */
    "./node_modules/rxjs/_esm2015/internal/operators/exhaustMap.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "exhaustMap", function () {
      return _internal_operators_exhaustMap__WEBPACK_IMPORTED_MODULE_28__["exhaustMap"];
    });
    /* harmony import */


    var _internal_operators_expand__WEBPACK_IMPORTED_MODULE_29__ = __webpack_require__(
    /*! ../internal/operators/expand */
    "./node_modules/rxjs/_esm2015/internal/operators/expand.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "expand", function () {
      return _internal_operators_expand__WEBPACK_IMPORTED_MODULE_29__["expand"];
    });
    /* harmony import */


    var _internal_operators_filter__WEBPACK_IMPORTED_MODULE_30__ = __webpack_require__(
    /*! ../internal/operators/filter */
    "./node_modules/rxjs/_esm2015/internal/operators/filter.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "filter", function () {
      return _internal_operators_filter__WEBPACK_IMPORTED_MODULE_30__["filter"];
    });
    /* harmony import */


    var _internal_operators_finalize__WEBPACK_IMPORTED_MODULE_31__ = __webpack_require__(
    /*! ../internal/operators/finalize */
    "./node_modules/rxjs/_esm2015/internal/operators/finalize.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "finalize", function () {
      return _internal_operators_finalize__WEBPACK_IMPORTED_MODULE_31__["finalize"];
    });
    /* harmony import */


    var _internal_operators_find__WEBPACK_IMPORTED_MODULE_32__ = __webpack_require__(
    /*! ../internal/operators/find */
    "./node_modules/rxjs/_esm2015/internal/operators/find.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "find", function () {
      return _internal_operators_find__WEBPACK_IMPORTED_MODULE_32__["find"];
    });
    /* harmony import */


    var _internal_operators_findIndex__WEBPACK_IMPORTED_MODULE_33__ = __webpack_require__(
    /*! ../internal/operators/findIndex */
    "./node_modules/rxjs/_esm2015/internal/operators/findIndex.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "findIndex", function () {
      return _internal_operators_findIndex__WEBPACK_IMPORTED_MODULE_33__["findIndex"];
    });
    /* harmony import */


    var _internal_operators_first__WEBPACK_IMPORTED_MODULE_34__ = __webpack_require__(
    /*! ../internal/operators/first */
    "./node_modules/rxjs/_esm2015/internal/operators/first.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "first", function () {
      return _internal_operators_first__WEBPACK_IMPORTED_MODULE_34__["first"];
    });
    /* harmony import */


    var _internal_operators_groupBy__WEBPACK_IMPORTED_MODULE_35__ = __webpack_require__(
    /*! ../internal/operators/groupBy */
    "./node_modules/rxjs/_esm2015/internal/operators/groupBy.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "groupBy", function () {
      return _internal_operators_groupBy__WEBPACK_IMPORTED_MODULE_35__["groupBy"];
    });
    /* harmony import */


    var _internal_operators_ignoreElements__WEBPACK_IMPORTED_MODULE_36__ = __webpack_require__(
    /*! ../internal/operators/ignoreElements */
    "./node_modules/rxjs/_esm2015/internal/operators/ignoreElements.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "ignoreElements", function () {
      return _internal_operators_ignoreElements__WEBPACK_IMPORTED_MODULE_36__["ignoreElements"];
    });
    /* harmony import */


    var _internal_operators_isEmpty__WEBPACK_IMPORTED_MODULE_37__ = __webpack_require__(
    /*! ../internal/operators/isEmpty */
    "./node_modules/rxjs/_esm2015/internal/operators/isEmpty.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "isEmpty", function () {
      return _internal_operators_isEmpty__WEBPACK_IMPORTED_MODULE_37__["isEmpty"];
    });
    /* harmony import */


    var _internal_operators_last__WEBPACK_IMPORTED_MODULE_38__ = __webpack_require__(
    /*! ../internal/operators/last */
    "./node_modules/rxjs/_esm2015/internal/operators/last.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "last", function () {
      return _internal_operators_last__WEBPACK_IMPORTED_MODULE_38__["last"];
    });
    /* harmony import */


    var _internal_operators_map__WEBPACK_IMPORTED_MODULE_39__ = __webpack_require__(
    /*! ../internal/operators/map */
    "./node_modules/rxjs/_esm2015/internal/operators/map.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "map", function () {
      return _internal_operators_map__WEBPACK_IMPORTED_MODULE_39__["map"];
    });
    /* harmony import */


    var _internal_operators_mapTo__WEBPACK_IMPORTED_MODULE_40__ = __webpack_require__(
    /*! ../internal/operators/mapTo */
    "./node_modules/rxjs/_esm2015/internal/operators/mapTo.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "mapTo", function () {
      return _internal_operators_mapTo__WEBPACK_IMPORTED_MODULE_40__["mapTo"];
    });
    /* harmony import */


    var _internal_operators_materialize__WEBPACK_IMPORTED_MODULE_41__ = __webpack_require__(
    /*! ../internal/operators/materialize */
    "./node_modules/rxjs/_esm2015/internal/operators/materialize.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "materialize", function () {
      return _internal_operators_materialize__WEBPACK_IMPORTED_MODULE_41__["materialize"];
    });
    /* harmony import */


    var _internal_operators_max__WEBPACK_IMPORTED_MODULE_42__ = __webpack_require__(
    /*! ../internal/operators/max */
    "./node_modules/rxjs/_esm2015/internal/operators/max.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "max", function () {
      return _internal_operators_max__WEBPACK_IMPORTED_MODULE_42__["max"];
    });
    /* harmony import */


    var _internal_operators_merge__WEBPACK_IMPORTED_MODULE_43__ = __webpack_require__(
    /*! ../internal/operators/merge */
    "./node_modules/rxjs/_esm2015/internal/operators/merge.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "merge", function () {
      return _internal_operators_merge__WEBPACK_IMPORTED_MODULE_43__["merge"];
    });
    /* harmony import */


    var _internal_operators_mergeAll__WEBPACK_IMPORTED_MODULE_44__ = __webpack_require__(
    /*! ../internal/operators/mergeAll */
    "./node_modules/rxjs/_esm2015/internal/operators/mergeAll.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "mergeAll", function () {
      return _internal_operators_mergeAll__WEBPACK_IMPORTED_MODULE_44__["mergeAll"];
    });
    /* harmony import */


    var _internal_operators_mergeMap__WEBPACK_IMPORTED_MODULE_45__ = __webpack_require__(
    /*! ../internal/operators/mergeMap */
    "./node_modules/rxjs/_esm2015/internal/operators/mergeMap.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "mergeMap", function () {
      return _internal_operators_mergeMap__WEBPACK_IMPORTED_MODULE_45__["mergeMap"];
    });
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "flatMap", function () {
      return _internal_operators_mergeMap__WEBPACK_IMPORTED_MODULE_45__["mergeMap"];
    });
    /* harmony import */


    var _internal_operators_mergeMapTo__WEBPACK_IMPORTED_MODULE_46__ = __webpack_require__(
    /*! ../internal/operators/mergeMapTo */
    "./node_modules/rxjs/_esm2015/internal/operators/mergeMapTo.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "mergeMapTo", function () {
      return _internal_operators_mergeMapTo__WEBPACK_IMPORTED_MODULE_46__["mergeMapTo"];
    });
    /* harmony import */


    var _internal_operators_mergeScan__WEBPACK_IMPORTED_MODULE_47__ = __webpack_require__(
    /*! ../internal/operators/mergeScan */
    "./node_modules/rxjs/_esm2015/internal/operators/mergeScan.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "mergeScan", function () {
      return _internal_operators_mergeScan__WEBPACK_IMPORTED_MODULE_47__["mergeScan"];
    });
    /* harmony import */


    var _internal_operators_min__WEBPACK_IMPORTED_MODULE_48__ = __webpack_require__(
    /*! ../internal/operators/min */
    "./node_modules/rxjs/_esm2015/internal/operators/min.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "min", function () {
      return _internal_operators_min__WEBPACK_IMPORTED_MODULE_48__["min"];
    });
    /* harmony import */


    var _internal_operators_multicast__WEBPACK_IMPORTED_MODULE_49__ = __webpack_require__(
    /*! ../internal/operators/multicast */
    "./node_modules/rxjs/_esm2015/internal/operators/multicast.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "multicast", function () {
      return _internal_operators_multicast__WEBPACK_IMPORTED_MODULE_49__["multicast"];
    });
    /* harmony import */


    var _internal_operators_observeOn__WEBPACK_IMPORTED_MODULE_50__ = __webpack_require__(
    /*! ../internal/operators/observeOn */
    "./node_modules/rxjs/_esm2015/internal/operators/observeOn.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "observeOn", function () {
      return _internal_operators_observeOn__WEBPACK_IMPORTED_MODULE_50__["observeOn"];
    });
    /* harmony import */


    var _internal_operators_onErrorResumeNext__WEBPACK_IMPORTED_MODULE_51__ = __webpack_require__(
    /*! ../internal/operators/onErrorResumeNext */
    "./node_modules/rxjs/_esm2015/internal/operators/onErrorResumeNext.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "onErrorResumeNext", function () {
      return _internal_operators_onErrorResumeNext__WEBPACK_IMPORTED_MODULE_51__["onErrorResumeNext"];
    });
    /* harmony import */


    var _internal_operators_pairwise__WEBPACK_IMPORTED_MODULE_52__ = __webpack_require__(
    /*! ../internal/operators/pairwise */
    "./node_modules/rxjs/_esm2015/internal/operators/pairwise.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "pairwise", function () {
      return _internal_operators_pairwise__WEBPACK_IMPORTED_MODULE_52__["pairwise"];
    });
    /* harmony import */


    var _internal_operators_partition__WEBPACK_IMPORTED_MODULE_53__ = __webpack_require__(
    /*! ../internal/operators/partition */
    "./node_modules/rxjs/_esm2015/internal/operators/partition.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "partition", function () {
      return _internal_operators_partition__WEBPACK_IMPORTED_MODULE_53__["partition"];
    });
    /* harmony import */


    var _internal_operators_pluck__WEBPACK_IMPORTED_MODULE_54__ = __webpack_require__(
    /*! ../internal/operators/pluck */
    "./node_modules/rxjs/_esm2015/internal/operators/pluck.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "pluck", function () {
      return _internal_operators_pluck__WEBPACK_IMPORTED_MODULE_54__["pluck"];
    });
    /* harmony import */


    var _internal_operators_publish__WEBPACK_IMPORTED_MODULE_55__ = __webpack_require__(
    /*! ../internal/operators/publish */
    "./node_modules/rxjs/_esm2015/internal/operators/publish.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "publish", function () {
      return _internal_operators_publish__WEBPACK_IMPORTED_MODULE_55__["publish"];
    });
    /* harmony import */


    var _internal_operators_publishBehavior__WEBPACK_IMPORTED_MODULE_56__ = __webpack_require__(
    /*! ../internal/operators/publishBehavior */
    "./node_modules/rxjs/_esm2015/internal/operators/publishBehavior.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "publishBehavior", function () {
      return _internal_operators_publishBehavior__WEBPACK_IMPORTED_MODULE_56__["publishBehavior"];
    });
    /* harmony import */


    var _internal_operators_publishLast__WEBPACK_IMPORTED_MODULE_57__ = __webpack_require__(
    /*! ../internal/operators/publishLast */
    "./node_modules/rxjs/_esm2015/internal/operators/publishLast.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "publishLast", function () {
      return _internal_operators_publishLast__WEBPACK_IMPORTED_MODULE_57__["publishLast"];
    });
    /* harmony import */


    var _internal_operators_publishReplay__WEBPACK_IMPORTED_MODULE_58__ = __webpack_require__(
    /*! ../internal/operators/publishReplay */
    "./node_modules/rxjs/_esm2015/internal/operators/publishReplay.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "publishReplay", function () {
      return _internal_operators_publishReplay__WEBPACK_IMPORTED_MODULE_58__["publishReplay"];
    });
    /* harmony import */


    var _internal_operators_race__WEBPACK_IMPORTED_MODULE_59__ = __webpack_require__(
    /*! ../internal/operators/race */
    "./node_modules/rxjs/_esm2015/internal/operators/race.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "race", function () {
      return _internal_operators_race__WEBPACK_IMPORTED_MODULE_59__["race"];
    });
    /* harmony import */


    var _internal_operators_reduce__WEBPACK_IMPORTED_MODULE_60__ = __webpack_require__(
    /*! ../internal/operators/reduce */
    "./node_modules/rxjs/_esm2015/internal/operators/reduce.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "reduce", function () {
      return _internal_operators_reduce__WEBPACK_IMPORTED_MODULE_60__["reduce"];
    });
    /* harmony import */


    var _internal_operators_repeat__WEBPACK_IMPORTED_MODULE_61__ = __webpack_require__(
    /*! ../internal/operators/repeat */
    "./node_modules/rxjs/_esm2015/internal/operators/repeat.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "repeat", function () {
      return _internal_operators_repeat__WEBPACK_IMPORTED_MODULE_61__["repeat"];
    });
    /* harmony import */


    var _internal_operators_repeatWhen__WEBPACK_IMPORTED_MODULE_62__ = __webpack_require__(
    /*! ../internal/operators/repeatWhen */
    "./node_modules/rxjs/_esm2015/internal/operators/repeatWhen.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "repeatWhen", function () {
      return _internal_operators_repeatWhen__WEBPACK_IMPORTED_MODULE_62__["repeatWhen"];
    });
    /* harmony import */


    var _internal_operators_retry__WEBPACK_IMPORTED_MODULE_63__ = __webpack_require__(
    /*! ../internal/operators/retry */
    "./node_modules/rxjs/_esm2015/internal/operators/retry.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "retry", function () {
      return _internal_operators_retry__WEBPACK_IMPORTED_MODULE_63__["retry"];
    });
    /* harmony import */


    var _internal_operators_retryWhen__WEBPACK_IMPORTED_MODULE_64__ = __webpack_require__(
    /*! ../internal/operators/retryWhen */
    "./node_modules/rxjs/_esm2015/internal/operators/retryWhen.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "retryWhen", function () {
      return _internal_operators_retryWhen__WEBPACK_IMPORTED_MODULE_64__["retryWhen"];
    });
    /* harmony import */


    var _internal_operators_refCount__WEBPACK_IMPORTED_MODULE_65__ = __webpack_require__(
    /*! ../internal/operators/refCount */
    "./node_modules/rxjs/_esm2015/internal/operators/refCount.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "refCount", function () {
      return _internal_operators_refCount__WEBPACK_IMPORTED_MODULE_65__["refCount"];
    });
    /* harmony import */


    var _internal_operators_sample__WEBPACK_IMPORTED_MODULE_66__ = __webpack_require__(
    /*! ../internal/operators/sample */
    "./node_modules/rxjs/_esm2015/internal/operators/sample.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "sample", function () {
      return _internal_operators_sample__WEBPACK_IMPORTED_MODULE_66__["sample"];
    });
    /* harmony import */


    var _internal_operators_sampleTime__WEBPACK_IMPORTED_MODULE_67__ = __webpack_require__(
    /*! ../internal/operators/sampleTime */
    "./node_modules/rxjs/_esm2015/internal/operators/sampleTime.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "sampleTime", function () {
      return _internal_operators_sampleTime__WEBPACK_IMPORTED_MODULE_67__["sampleTime"];
    });
    /* harmony import */


    var _internal_operators_scan__WEBPACK_IMPORTED_MODULE_68__ = __webpack_require__(
    /*! ../internal/operators/scan */
    "./node_modules/rxjs/_esm2015/internal/operators/scan.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "scan", function () {
      return _internal_operators_scan__WEBPACK_IMPORTED_MODULE_68__["scan"];
    });
    /* harmony import */


    var _internal_operators_sequenceEqual__WEBPACK_IMPORTED_MODULE_69__ = __webpack_require__(
    /*! ../internal/operators/sequenceEqual */
    "./node_modules/rxjs/_esm2015/internal/operators/sequenceEqual.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "sequenceEqual", function () {
      return _internal_operators_sequenceEqual__WEBPACK_IMPORTED_MODULE_69__["sequenceEqual"];
    });
    /* harmony import */


    var _internal_operators_share__WEBPACK_IMPORTED_MODULE_70__ = __webpack_require__(
    /*! ../internal/operators/share */
    "./node_modules/rxjs/_esm2015/internal/operators/share.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "share", function () {
      return _internal_operators_share__WEBPACK_IMPORTED_MODULE_70__["share"];
    });
    /* harmony import */


    var _internal_operators_shareReplay__WEBPACK_IMPORTED_MODULE_71__ = __webpack_require__(
    /*! ../internal/operators/shareReplay */
    "./node_modules/rxjs/_esm2015/internal/operators/shareReplay.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "shareReplay", function () {
      return _internal_operators_shareReplay__WEBPACK_IMPORTED_MODULE_71__["shareReplay"];
    });
    /* harmony import */


    var _internal_operators_single__WEBPACK_IMPORTED_MODULE_72__ = __webpack_require__(
    /*! ../internal/operators/single */
    "./node_modules/rxjs/_esm2015/internal/operators/single.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "single", function () {
      return _internal_operators_single__WEBPACK_IMPORTED_MODULE_72__["single"];
    });
    /* harmony import */


    var _internal_operators_skip__WEBPACK_IMPORTED_MODULE_73__ = __webpack_require__(
    /*! ../internal/operators/skip */
    "./node_modules/rxjs/_esm2015/internal/operators/skip.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "skip", function () {
      return _internal_operators_skip__WEBPACK_IMPORTED_MODULE_73__["skip"];
    });
    /* harmony import */


    var _internal_operators_skipLast__WEBPACK_IMPORTED_MODULE_74__ = __webpack_require__(
    /*! ../internal/operators/skipLast */
    "./node_modules/rxjs/_esm2015/internal/operators/skipLast.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "skipLast", function () {
      return _internal_operators_skipLast__WEBPACK_IMPORTED_MODULE_74__["skipLast"];
    });
    /* harmony import */


    var _internal_operators_skipUntil__WEBPACK_IMPORTED_MODULE_75__ = __webpack_require__(
    /*! ../internal/operators/skipUntil */
    "./node_modules/rxjs/_esm2015/internal/operators/skipUntil.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "skipUntil", function () {
      return _internal_operators_skipUntil__WEBPACK_IMPORTED_MODULE_75__["skipUntil"];
    });
    /* harmony import */


    var _internal_operators_skipWhile__WEBPACK_IMPORTED_MODULE_76__ = __webpack_require__(
    /*! ../internal/operators/skipWhile */
    "./node_modules/rxjs/_esm2015/internal/operators/skipWhile.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "skipWhile", function () {
      return _internal_operators_skipWhile__WEBPACK_IMPORTED_MODULE_76__["skipWhile"];
    });
    /* harmony import */


    var _internal_operators_startWith__WEBPACK_IMPORTED_MODULE_77__ = __webpack_require__(
    /*! ../internal/operators/startWith */
    "./node_modules/rxjs/_esm2015/internal/operators/startWith.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "startWith", function () {
      return _internal_operators_startWith__WEBPACK_IMPORTED_MODULE_77__["startWith"];
    });
    /* harmony import */


    var _internal_operators_subscribeOn__WEBPACK_IMPORTED_MODULE_78__ = __webpack_require__(
    /*! ../internal/operators/subscribeOn */
    "./node_modules/rxjs/_esm2015/internal/operators/subscribeOn.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "subscribeOn", function () {
      return _internal_operators_subscribeOn__WEBPACK_IMPORTED_MODULE_78__["subscribeOn"];
    });
    /* harmony import */


    var _internal_operators_switchAll__WEBPACK_IMPORTED_MODULE_79__ = __webpack_require__(
    /*! ../internal/operators/switchAll */
    "./node_modules/rxjs/_esm2015/internal/operators/switchAll.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "switchAll", function () {
      return _internal_operators_switchAll__WEBPACK_IMPORTED_MODULE_79__["switchAll"];
    });
    /* harmony import */


    var _internal_operators_switchMap__WEBPACK_IMPORTED_MODULE_80__ = __webpack_require__(
    /*! ../internal/operators/switchMap */
    "./node_modules/rxjs/_esm2015/internal/operators/switchMap.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "switchMap", function () {
      return _internal_operators_switchMap__WEBPACK_IMPORTED_MODULE_80__["switchMap"];
    });
    /* harmony import */


    var _internal_operators_switchMapTo__WEBPACK_IMPORTED_MODULE_81__ = __webpack_require__(
    /*! ../internal/operators/switchMapTo */
    "./node_modules/rxjs/_esm2015/internal/operators/switchMapTo.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "switchMapTo", function () {
      return _internal_operators_switchMapTo__WEBPACK_IMPORTED_MODULE_81__["switchMapTo"];
    });
    /* harmony import */


    var _internal_operators_take__WEBPACK_IMPORTED_MODULE_82__ = __webpack_require__(
    /*! ../internal/operators/take */
    "./node_modules/rxjs/_esm2015/internal/operators/take.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "take", function () {
      return _internal_operators_take__WEBPACK_IMPORTED_MODULE_82__["take"];
    });
    /* harmony import */


    var _internal_operators_takeLast__WEBPACK_IMPORTED_MODULE_83__ = __webpack_require__(
    /*! ../internal/operators/takeLast */
    "./node_modules/rxjs/_esm2015/internal/operators/takeLast.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "takeLast", function () {
      return _internal_operators_takeLast__WEBPACK_IMPORTED_MODULE_83__["takeLast"];
    });
    /* harmony import */


    var _internal_operators_takeUntil__WEBPACK_IMPORTED_MODULE_84__ = __webpack_require__(
    /*! ../internal/operators/takeUntil */
    "./node_modules/rxjs/_esm2015/internal/operators/takeUntil.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "takeUntil", function () {
      return _internal_operators_takeUntil__WEBPACK_IMPORTED_MODULE_84__["takeUntil"];
    });
    /* harmony import */


    var _internal_operators_takeWhile__WEBPACK_IMPORTED_MODULE_85__ = __webpack_require__(
    /*! ../internal/operators/takeWhile */
    "./node_modules/rxjs/_esm2015/internal/operators/takeWhile.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "takeWhile", function () {
      return _internal_operators_takeWhile__WEBPACK_IMPORTED_MODULE_85__["takeWhile"];
    });
    /* harmony import */


    var _internal_operators_tap__WEBPACK_IMPORTED_MODULE_86__ = __webpack_require__(
    /*! ../internal/operators/tap */
    "./node_modules/rxjs/_esm2015/internal/operators/tap.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "tap", function () {
      return _internal_operators_tap__WEBPACK_IMPORTED_MODULE_86__["tap"];
    });
    /* harmony import */


    var _internal_operators_throttle__WEBPACK_IMPORTED_MODULE_87__ = __webpack_require__(
    /*! ../internal/operators/throttle */
    "./node_modules/rxjs/_esm2015/internal/operators/throttle.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "throttle", function () {
      return _internal_operators_throttle__WEBPACK_IMPORTED_MODULE_87__["throttle"];
    });
    /* harmony import */


    var _internal_operators_throttleTime__WEBPACK_IMPORTED_MODULE_88__ = __webpack_require__(
    /*! ../internal/operators/throttleTime */
    "./node_modules/rxjs/_esm2015/internal/operators/throttleTime.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "throttleTime", function () {
      return _internal_operators_throttleTime__WEBPACK_IMPORTED_MODULE_88__["throttleTime"];
    });
    /* harmony import */


    var _internal_operators_throwIfEmpty__WEBPACK_IMPORTED_MODULE_89__ = __webpack_require__(
    /*! ../internal/operators/throwIfEmpty */
    "./node_modules/rxjs/_esm2015/internal/operators/throwIfEmpty.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "throwIfEmpty", function () {
      return _internal_operators_throwIfEmpty__WEBPACK_IMPORTED_MODULE_89__["throwIfEmpty"];
    });
    /* harmony import */


    var _internal_operators_timeInterval__WEBPACK_IMPORTED_MODULE_90__ = __webpack_require__(
    /*! ../internal/operators/timeInterval */
    "./node_modules/rxjs/_esm2015/internal/operators/timeInterval.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "timeInterval", function () {
      return _internal_operators_timeInterval__WEBPACK_IMPORTED_MODULE_90__["timeInterval"];
    });
    /* harmony import */


    var _internal_operators_timeout__WEBPACK_IMPORTED_MODULE_91__ = __webpack_require__(
    /*! ../internal/operators/timeout */
    "./node_modules/rxjs/_esm2015/internal/operators/timeout.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "timeout", function () {
      return _internal_operators_timeout__WEBPACK_IMPORTED_MODULE_91__["timeout"];
    });
    /* harmony import */


    var _internal_operators_timeoutWith__WEBPACK_IMPORTED_MODULE_92__ = __webpack_require__(
    /*! ../internal/operators/timeoutWith */
    "./node_modules/rxjs/_esm2015/internal/operators/timeoutWith.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "timeoutWith", function () {
      return _internal_operators_timeoutWith__WEBPACK_IMPORTED_MODULE_92__["timeoutWith"];
    });
    /* harmony import */


    var _internal_operators_timestamp__WEBPACK_IMPORTED_MODULE_93__ = __webpack_require__(
    /*! ../internal/operators/timestamp */
    "./node_modules/rxjs/_esm2015/internal/operators/timestamp.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "timestamp", function () {
      return _internal_operators_timestamp__WEBPACK_IMPORTED_MODULE_93__["timestamp"];
    });
    /* harmony import */


    var _internal_operators_toArray__WEBPACK_IMPORTED_MODULE_94__ = __webpack_require__(
    /*! ../internal/operators/toArray */
    "./node_modules/rxjs/_esm2015/internal/operators/toArray.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "toArray", function () {
      return _internal_operators_toArray__WEBPACK_IMPORTED_MODULE_94__["toArray"];
    });
    /* harmony import */


    var _internal_operators_window__WEBPACK_IMPORTED_MODULE_95__ = __webpack_require__(
    /*! ../internal/operators/window */
    "./node_modules/rxjs/_esm2015/internal/operators/window.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "window", function () {
      return _internal_operators_window__WEBPACK_IMPORTED_MODULE_95__["window"];
    });
    /* harmony import */


    var _internal_operators_windowCount__WEBPACK_IMPORTED_MODULE_96__ = __webpack_require__(
    /*! ../internal/operators/windowCount */
    "./node_modules/rxjs/_esm2015/internal/operators/windowCount.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "windowCount", function () {
      return _internal_operators_windowCount__WEBPACK_IMPORTED_MODULE_96__["windowCount"];
    });
    /* harmony import */


    var _internal_operators_windowTime__WEBPACK_IMPORTED_MODULE_97__ = __webpack_require__(
    /*! ../internal/operators/windowTime */
    "./node_modules/rxjs/_esm2015/internal/operators/windowTime.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "windowTime", function () {
      return _internal_operators_windowTime__WEBPACK_IMPORTED_MODULE_97__["windowTime"];
    });
    /* harmony import */


    var _internal_operators_windowToggle__WEBPACK_IMPORTED_MODULE_98__ = __webpack_require__(
    /*! ../internal/operators/windowToggle */
    "./node_modules/rxjs/_esm2015/internal/operators/windowToggle.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "windowToggle", function () {
      return _internal_operators_windowToggle__WEBPACK_IMPORTED_MODULE_98__["windowToggle"];
    });
    /* harmony import */


    var _internal_operators_windowWhen__WEBPACK_IMPORTED_MODULE_99__ = __webpack_require__(
    /*! ../internal/operators/windowWhen */
    "./node_modules/rxjs/_esm2015/internal/operators/windowWhen.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "windowWhen", function () {
      return _internal_operators_windowWhen__WEBPACK_IMPORTED_MODULE_99__["windowWhen"];
    });
    /* harmony import */


    var _internal_operators_withLatestFrom__WEBPACK_IMPORTED_MODULE_100__ = __webpack_require__(
    /*! ../internal/operators/withLatestFrom */
    "./node_modules/rxjs/_esm2015/internal/operators/withLatestFrom.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "withLatestFrom", function () {
      return _internal_operators_withLatestFrom__WEBPACK_IMPORTED_MODULE_100__["withLatestFrom"];
    });
    /* harmony import */


    var _internal_operators_zip__WEBPACK_IMPORTED_MODULE_101__ = __webpack_require__(
    /*! ../internal/operators/zip */
    "./node_modules/rxjs/_esm2015/internal/operators/zip.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "zip", function () {
      return _internal_operators_zip__WEBPACK_IMPORTED_MODULE_101__["zip"];
    });
    /* harmony import */


    var _internal_operators_zipAll__WEBPACK_IMPORTED_MODULE_102__ = __webpack_require__(
    /*! ../internal/operators/zipAll */
    "./node_modules/rxjs/_esm2015/internal/operators/zipAll.js");
    /* harmony reexport (safe) */


    __webpack_require__.d(__webpack_exports__, "zipAll", function () {
      return _internal_operators_zipAll__WEBPACK_IMPORTED_MODULE_102__["zipAll"];
    }); //# sourceMappingURL=index.js.map

    /***/

  }
}]);
//# sourceMappingURL=vendor-es5.js.map